HTML Standard Tracker

Diff (omit for latest revision)
Filter

Short URL: http://html5.org/r/2165

File a bug

SVNBugCommentTime (UTC)
2165WF2: Begin to define how to handle enctype, action, method, and target attributes.2008-09-12 01:01
Index: source
===================================================================
--- source	(revision 2164)
+++ source	(revision 2165)
@@ -24597,6 +24597,42 @@
   <p class="big-issue">... <dfn title="concept-fe-value">value</dfn></p>
 
 
+  <h4>Attributes for form submission</h4>
+
+  <p class="big-issue">... <dfn title="attr-fs-action">action</dfn> content attribute</p>
+
+  <p class="big-issue">... <dfn title="dom-fs-action">action</dfn> DOM attribute</p>
+
+  <p class="big-issue">... <dfn title="concept-fs-action">action</dfn> if present else form's else default</p>
+
+  <p class="big-issue">... <dfn title="attr-fs-method">method</dfn> content attribute</p>
+
+  <p class="big-issue">... <dfn title="dom-fs-method">method</dfn> DOM attribute</p>
+
+  <p class="big-issue">... <dfn title="concept-fs-method">method</dfn> if present else form's else default</p>
+
+  <p class="big-issue">... <dfn title="attr-fs-enctype">enctype</dfn> content attribute</p>
+
+  <p class="big-issue">... <dfn title="dom-fs-enctype">enctype</dfn> DOM attribute</p>
+
+  <p class="big-issue">... <dfn title="concept-fs-enctype">enctype</dfn> if present else form's else default</p>
+
+  <p class="big-issue">... <dfn title="attr-fs-target">target</dfn> content attribute</p>
+
+  <p class="big-issue">... <dfn title="dom-fs-target">target</dfn> DOM attribute</p>
+
+  <p class="big-issue">... <dfn title="concept-fs-target">target</dfn> if present else form's else base target else default</p> <!-- c.f. hyperlink following -->
+
+  <p>Attributes for form submission can be specified both on
+  <code>form</code> elements and on elements that represent buttons
+  that submit forms, e.g. an <code>input</code> element whose <code
+  title="attr-input-type">type</code> attribute is in the <span
+  title="attr-input-type-submit-state">Submit Button</span> state. The
+  attributes on the buttons, when omitted, default to the values given
+  on the corresponding the <code>form</code> element.</p>
+  
+
+
   <h4>Constraint validation</h4>
 
   <p class="big-issue">...</p>
@@ -24788,12 +24824,175 @@
 
    </li>
 
+   <li><p>Let <var title="">action</var> be the <var
+   title="">submitter</var> element's <span
+   title="concept-fs-action">action</span>.</p></li>
+
+   <li><p><span title="resolve a url">Resolve</span> the
+   <span>URL</span> <var title="">action</var>. If this fails, abort
+   these steps.</p></li>
+
+   <li><p>Let <var title="">scheme</var> be the <span
+   title="url-scheme">&lt;scheme&gt;</span> of the resulting
+   <span>absolute URL</span>.</p></li>
+
+   <li><p>Let <var title="">enctype</var> be the <var
+   title="">submitter</var> element's <span
+   title="concept-fs-enctype">enctype</span>.</p></li>
+
+   <li><p>Let <var title="">method</var> be the <var
+   title="">submitter</var> element's <span
+   title="concept-fs-method">method</span>.</p></li>
+
+   <li><p>Let <var title="">target</var> be the <var
+   title="">submitter</var> element's <span
+   title="concept-fs-target">target</span>.</p></li>
+
+   <li>
+
+    <p>Select the appropriate row in the table below based on the
+    value of <var title="">scheme</var> as given by the first cell of
+    each row. Then, select the appropriate cell on that row based on
+    the value of <var title="">method</var> as given in the first cell
+    of each column. Then, jump to the steps named in that cell and
+    defined below the table.</p>
+
+    <table>
+     <tr>
+      <td>
+      <th> GET
+      <th> POST
+      <th> PUT
+      <th> DELETE
+     <tr>
+      <th> <code title="">http</code>
+      <td> <span title="submit-mutate-action">Mutate action</span>
+      <td> <span title="submit-body">Submit as entity body</span>
+      <td> <span title="submit-body">Submit as entity body</span>
+      <td> <span title="submit-delete-action">Delete action</span>
+     <tr>
+      <th> <code title="">https</code>
+      <td> <span title="submit-mutate-action">Mutate action</span>
+      <td> <span title="submit-body">Submit as entity body</span>
+      <td> <span title="submit-body">Submit as entity body</span>
+      <td> <span title="submit-delete-action">Delete action</span>
+     <tr>
+      <th> <code title="">ftp</code>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+     <tr>
+      <th> <code title="">javascript</code>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-get-action">Get action</span>
+     <tr>
+      <th> <code title="">data</code>
+      <td> <span title="submit-get-action">Get action</span>
+      <td> <span title="submit-data-post">Post to data:</span>
+      <td> <span title="submit-data-put">Put to data:</span>
+      <td> <span title="submit-get-action">Get action</span>
+     <tr>
+      <th> <code title="">mailto</code>
+      <td> <span title="submit-mailto-headers">Mail with headers</span>
+      <td> <span title="submit-mailto-body">Mail as body</span>
+      <td> <span title="submit-mailto-headers">Mail with headers</span>
+      <td> <span title="submit-mailto-headers">Mail with headers</span>
+    </table>
+
+    <p>If <var title="">scheme</var> is not one of those listed in
+    this table, then the behavior is not defined by this
+    specification. User agents should, in the absence of another
+    specification defining this, act in a manner analogous to that
+    defined in this specification for similar schemes.</p>
+
+    <p>The behaviors are as follows:</p>
+
+    <dl class="switch">
+
+     <dt><dfn title="submit-mutate-action">Mutate action</dfn>
+     <dd>
+
+      <p>Let <var title="">query</var> be the resulting encoding the
+      <var title="">form data set</var> using the <span><code
+      title="">application/x-www-form-urlencoded</code> encoding
+      algorithm</span>.</p>
+
+      <p>Let <var title="">destination</var> be a new <span>URL</span>
+      that is equal to the <var title="">action</var> except that its
+      <span title="url-query">&lt;query&gt;</span> component is
+      replaced by <var title="">query</var> (adding a U+003F QUESTION
+      MARK (?)  character if appropriate).</p>
+
+      <p>If the user indicated a specific <span>browsing
+      context</span> to use when submitting the form, then let <var
+      title="">target browsing context</var> be that <span>browsing
+      context</span>.</p>
+
+      <p>Otherwise, apply <span>the rules for choosing a browsing
+      context given a browsing context name</span> using <var
+      title="">target</var> as the name and the <span>browsing
+      context</span> of <var title="">form</var> as the context in
+      which the algorithm is executed, and let <var title="">target
+      browsing context</var> be the resulting <span>browsing
+      context</span>.</p>
+
+      <p><span>Navigate</span> <var title="">target browsing
+      context</var> to <var title="">destination</var>. If <var
+      title="">target browsing context</var> was newly created for
+      this purpose by the steps above, then it must be navigated with
+      <span>replacement enabled</span>.</p>
+
+     </dd>
+
+     <dt><dfn title="submit-body">Submit as entity body</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-delete-action">Delete action</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-get-action">Get action</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-data-post">Post to data:</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-data-put">Put to data:</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-mailto-headers">Mail with headers</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+     <dt><dfn title="submit-mailto-body">Mail as body</dfn>
+     <dd><p class="big-issue">...</p></dd>
+
+    </dl>
+
+   </li>
+
    <li><p class="big-issue">...</p></li>
 
   </ol>
 
+  <p>The <dfn><code
+  title="">application/x-www-form-urlencoded</code> encoding
+  algorithm</dfn> is as follows:</p>
 
+  <ol>
 
+   <li><p class="big-issue">...</p></li>
+
+   <!-- During this step, the form data set is examined to ensure all
+   the characters are representable in the submission character
+   encoding. -->
+
+  </ol>
+
+
+
+
   <h3>Scripting</h3>
 
   <p>Scripts allow authors to add interactivity to their documents.</p>
@@ -37097,17 +37296,18 @@
   hyperlink must further have its <var>hyperlink suffix</var> appended
   to it.</p>
 
-  <p>If the user indicated a specific browsing context when following
-  the hyperlink, or if the user agent is configured to follow
-  hyperlinks by navigating a particular browsing context, then that
-  must be the browsing context that is navigated.</p>
+  <p>If the user indicated a specific <span>browsing context</span>
+  when following the hyperlink, or if the user agent is configured to
+  follow hyperlinks by navigating a particular browsing context, then
+  that must be the <span>browsing context</span> that is
+  navigated.</p>
 
   <p>Otherwise, if the hyperlink element is an <code>a</code> or
   <code>area</code> element that has a <code
   title="attr-hyperlink-target">target</code> attribute, then the
-  browsing context that is navigated must be chosen by applying
-  <span>the rules for choosing a browsing context given a browsing
-  context name</span>, using the value of the <code
+  <span>browsing context</span> that is navigated must be chosen by
+  applying <span>the rules for choosing a browsing context given a
+  browsing context name</span>, using the value of the <code
   title="attr-hyperlink-target">target</code> attribute as the
   browsing context name. If these rules result in the creation of a
   new <span>browsing context</span>, it must be navigated with

|