[html5] r7992 - [giow] (3) Make <form> submission more like reality. Fixing https://www.w3.org/B [...]
whatwg at whatwg.org
whatwg at whatwg.org
Wed Jun 19 14:37:03 PDT 2013
Author: ianh
Date: 2013-06-19 14:37:02 -0700 (Wed, 19 Jun 2013)
New Revision: 7992
Modified:
complete.html
index
source
Log:
[giow] (3) Make <form> submission more like reality.
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=20580
Affected topics: HTML
Modified: complete.html
===================================================================
--- complete.html 2013-06-19 18:53:18 UTC (rev 7991)
+++ complete.html 2013-06-19 21:37:02 UTC (rev 7992)
@@ -55445,8 +55445,43 @@
defining this, act in a manner analogous to that defined in this specification for similar
schemes.</p>
- <p>The behaviors are as follows:</p>
+ <p>Each <code><a href=#the-form-element>form</a></code> element has a <dfn id=planned-navigation>planned navigation</dfn>, which is either null or a
+ <a href=#concept-task title=concept-task>task</a>; when the <code><a href=#the-form-element>form</a></code> is first created, its
+ <a href=#planned-navigation>planned navigation</a> must be set to null. In the behaviours described below, when the
+ user agent is required to <dfn id=plan-to-navigate>plan to navigate</dfn> to a particular resource <var title="">destination</var>, it must run the following steps:</p>
+ <ol><li><p>If the <code><a href=#the-form-element>form</a></code> has a non-null <a href=#planned-navigation>planned navigation</a>, remove it from
+ its <a href=#task-queue>task queue</a>.</li>
+
+ <li>
+
+ <p>Let the <code><a href=#the-form-element>form</a></code>'s <a href=#planned-navigation>planned navigation</a> be a new <a href=#concept-task title=concept-task>task</a> that consists of running the following steps:</p>
+
+ <ol><li><p>Let the <code><a href=#the-form-element>form</a></code>'s <a href=#planned-navigation>planned navigation</a> be null.</li>
+
+ <li><p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to
+ the particular resource <var title="">destination</var>. If <var title="">replace</var> is
+ true, then <var title="">target browsing context</var> must be navigated with
+ <a href=#replacement-enabled>replacement enabled</a>.</p>
+
+ </ol><p>For the purposes of this task, <var title="">target browsing context</var> and <var title="">replace</var> are the variables that were set up when the overall form submission
+ algorithm was run, with their values as they stood when this <a href=#planned-navigation>planned navigation</a>
+ was <a href=#queue-a-task title="queue a task">queued</a>.</p>
+
+ </li>
+
+ <li>
+
+ <p><a href=#queue-a-task title="queue a task">Queue the task</a> that is the <code><a href=#the-form-element>form</a></code>'s new
+ <a href=#planned-navigation>planned navigation</a>.</p>
+
+ <p>The <a href=#task-source>task source</a> for this task is the <a href=#dom-manipulation-task-source>DOM manipulation task
+ source</a>.</p>
+
+ </li>
+
+ </ol><p>The behaviors are as follows:</p>
+
<dl><dt><dfn id=submit-mutate-action title=submit-mutate-action>Mutate action URL</dfn>
<dd>
@@ -55462,8 +55497,7 @@
<p>Let <var title="">destination</var> be a new <a href=#url>URL</a> formed by applying the
<a href=#concept-url-serializer title=concept-url-serializer>URL serializer</a> algorithm to <var title="">parsed action</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
@@ -55492,18 +55526,16 @@
</dl><!--<p>If <var title="">method</var> is anything but (GET or) POST, and the
<span>origin</span> of <var title="">action</var> is not the <span>same origin</span> as that
of <var title="">form document</var>, then abort these steps.</p> [or do CORS] (this is
- commented out since only POST can trigger this now, and that's historically unrestricted)--><p>Otherwise, <a href=#navigate>navigate</a><!--DONAV form--> <var title="">target browsing
- context</var> to <var title="">action</var> using the HTTP method given by <var title="">method</var> and with <var title="">entity body</var> as the entity body, of type
- <var title="">MIME type</var>. If <var title="">replace</var> is true, then <var title="">target browsing context</var> must be navigated with <a href=#replacement-enabled>replacement
- enabled</a>.</p>
+ commented out since only POST can trigger this now, and that's historically unrestricted)--><p>Otherwise, <a href=#plan-to-navigate>plan to navigate</a> to <var title="">action</var> using the HTTP
+ method given by <var title="">method</var> and with <var title="">entity body</var> as the
+ entity body, of type <var title="">MIME type</var>.</p>
</dd>
<dt><dfn id=submit-get-action title=submit-get-action>Get action URL</dfn>
<dd>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">action</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">action</var>.</p>
<p class=note>The <var title="">form data set</var> is discarded.</p>
@@ -55527,11 +55559,8 @@
not characters in the URL <a href=#default-encode-set>default encode set</a>, and then, treating the result as a
US-ASCII string, replace the first occurrence of "<code title="">%%</code>" in <var title="">action</var> with the resulting escaped string. <a href=#refsURL>[URL]</a></p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to the
- potentially modified <var title="">action</var> (which will be a <a href=#data-protocol title="data
- protocol"><code title="">data:</code> URL</a>). If <var title="">replace</var> is true,
- then <var title="">target browsing context</var> must be navigated with <a href=#replacement-enabled>replacement
- enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to the potentially modified <var title="">action</var> (which
+ will be a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a>).</p>
</dd>
@@ -55553,8 +55582,7 @@
<p>Append <var title="">headers</var> to <var title="">destination</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
@@ -55576,8 +55604,7 @@
<p>Append <var title="">body</var>, interpreted as a US-ASCII string, to <var title="">destination</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
Modified: index
===================================================================
--- index 2013-06-19 18:53:18 UTC (rev 7991)
+++ index 2013-06-19 21:37:02 UTC (rev 7992)
@@ -55445,8 +55445,43 @@
defining this, act in a manner analogous to that defined in this specification for similar
schemes.</p>
- <p>The behaviors are as follows:</p>
+ <p>Each <code><a href=#the-form-element>form</a></code> element has a <dfn id=planned-navigation>planned navigation</dfn>, which is either null or a
+ <a href=#concept-task title=concept-task>task</a>; when the <code><a href=#the-form-element>form</a></code> is first created, its
+ <a href=#planned-navigation>planned navigation</a> must be set to null. In the behaviours described below, when the
+ user agent is required to <dfn id=plan-to-navigate>plan to navigate</dfn> to a particular resource <var title="">destination</var>, it must run the following steps:</p>
+ <ol><li><p>If the <code><a href=#the-form-element>form</a></code> has a non-null <a href=#planned-navigation>planned navigation</a>, remove it from
+ its <a href=#task-queue>task queue</a>.</li>
+
+ <li>
+
+ <p>Let the <code><a href=#the-form-element>form</a></code>'s <a href=#planned-navigation>planned navigation</a> be a new <a href=#concept-task title=concept-task>task</a> that consists of running the following steps:</p>
+
+ <ol><li><p>Let the <code><a href=#the-form-element>form</a></code>'s <a href=#planned-navigation>planned navigation</a> be null.</li>
+
+ <li><p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to
+ the particular resource <var title="">destination</var>. If <var title="">replace</var> is
+ true, then <var title="">target browsing context</var> must be navigated with
+ <a href=#replacement-enabled>replacement enabled</a>.</p>
+
+ </ol><p>For the purposes of this task, <var title="">target browsing context</var> and <var title="">replace</var> are the variables that were set up when the overall form submission
+ algorithm was run, with their values as they stood when this <a href=#planned-navigation>planned navigation</a>
+ was <a href=#queue-a-task title="queue a task">queued</a>.</p>
+
+ </li>
+
+ <li>
+
+ <p><a href=#queue-a-task title="queue a task">Queue the task</a> that is the <code><a href=#the-form-element>form</a></code>'s new
+ <a href=#planned-navigation>planned navigation</a>.</p>
+
+ <p>The <a href=#task-source>task source</a> for this task is the <a href=#dom-manipulation-task-source>DOM manipulation task
+ source</a>.</p>
+
+ </li>
+
+ </ol><p>The behaviors are as follows:</p>
+
<dl><dt><dfn id=submit-mutate-action title=submit-mutate-action>Mutate action URL</dfn>
<dd>
@@ -55462,8 +55497,7 @@
<p>Let <var title="">destination</var> be a new <a href=#url>URL</a> formed by applying the
<a href=#concept-url-serializer title=concept-url-serializer>URL serializer</a> algorithm to <var title="">parsed action</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
@@ -55492,18 +55526,16 @@
</dl><!--<p>If <var title="">method</var> is anything but (GET or) POST, and the
<span>origin</span> of <var title="">action</var> is not the <span>same origin</span> as that
of <var title="">form document</var>, then abort these steps.</p> [or do CORS] (this is
- commented out since only POST can trigger this now, and that's historically unrestricted)--><p>Otherwise, <a href=#navigate>navigate</a><!--DONAV form--> <var title="">target browsing
- context</var> to <var title="">action</var> using the HTTP method given by <var title="">method</var> and with <var title="">entity body</var> as the entity body, of type
- <var title="">MIME type</var>. If <var title="">replace</var> is true, then <var title="">target browsing context</var> must be navigated with <a href=#replacement-enabled>replacement
- enabled</a>.</p>
+ commented out since only POST can trigger this now, and that's historically unrestricted)--><p>Otherwise, <a href=#plan-to-navigate>plan to navigate</a> to <var title="">action</var> using the HTTP
+ method given by <var title="">method</var> and with <var title="">entity body</var> as the
+ entity body, of type <var title="">MIME type</var>.</p>
</dd>
<dt><dfn id=submit-get-action title=submit-get-action>Get action URL</dfn>
<dd>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">action</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">action</var>.</p>
<p class=note>The <var title="">form data set</var> is discarded.</p>
@@ -55527,11 +55559,8 @@
not characters in the URL <a href=#default-encode-set>default encode set</a>, and then, treating the result as a
US-ASCII string, replace the first occurrence of "<code title="">%%</code>" in <var title="">action</var> with the resulting escaped string. <a href=#refsURL>[URL]</a></p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to the
- potentially modified <var title="">action</var> (which will be a <a href=#data-protocol title="data
- protocol"><code title="">data:</code> URL</a>). If <var title="">replace</var> is true,
- then <var title="">target browsing context</var> must be navigated with <a href=#replacement-enabled>replacement
- enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to the potentially modified <var title="">action</var> (which
+ will be a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a>).</p>
</dd>
@@ -55553,8 +55582,7 @@
<p>Append <var title="">headers</var> to <var title="">destination</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
@@ -55576,8 +55604,7 @@
<p>Append <var title="">body</var>, interpreted as a US-ASCII string, to <var title="">destination</var>.</p>
- <p><a href=#navigate>Navigate</a><!--DONAV form--> <var title="">target browsing context</var> to <var title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <a href=#replacement-enabled>replacement enabled</a>.</p>
+ <p><a href=#plan-to-navigate>Plan to navigate</a> to <var title="">destination</var>.</p>
</dd>
Modified: source
===================================================================
--- source 2013-06-19 18:53:18 UTC (rev 7991)
+++ source 2013-06-19 21:37:02 UTC (rev 7992)
@@ -61189,6 +61189,52 @@
defining this, act in a manner analogous to that defined in this specification for similar
schemes.</p>
+ <p>Each <code>form</code> element has a <dfn>planned navigation</dfn>, which is either null or a
+ <span title="concept-task">task</span>; when the <code>form</code> is first created, its
+ <span>planned navigation</span> must be set to null. In the behaviours described below, when the
+ user agent is required to <dfn>plan to navigate</dfn> to a particular resource <var
+ title="">destination</var>, it must run the following steps:</p>
+
+ <ol>
+
+ <li><p>If the <code>form</code> has a non-null <span>planned navigation</span>, remove it from
+ its <span>task queue</span>.</p></li>
+
+ <li>
+
+ <p>Let the <code>form</code>'s <span>planned navigation</span> be a new <span
+ title="concept-task">task</span> that consists of running the following steps:</p>
+
+ <ol>
+
+ <li><p>Let the <code>form</code>'s <span>planned navigation</span> be null.</p></li>
+
+ <li><p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to
+ the particular resource <var title="">destination</var>. If <var title="">replace</var> is
+ true, then <var title="">target browsing context</var> must be navigated with
+ <span>replacement enabled</span>.</p>
+
+ </ol>
+
+ <p>For the purposes of this task, <var title="">target browsing context</var> and <var
+ title="">replace</var> are the variables that were set up when the overall form submission
+ algorithm was run, with their values as they stood when this <span>planned navigation</span>
+ was <span title="queue a task">queued</span>.</p>
+
+ </li>
+
+ <li>
+
+ <p><span title="queue a task">Queue the task</span> that is the <code>form</code>'s new
+ <span>planned navigation</span>.</p>
+
+ <p>The <span>task source</span> for this task is the <span>DOM manipulation task
+ source</span>.</p>
+
+ </li>
+
+ </ol>
+
<p>The behaviors are as follows:</p>
<dl>
@@ -61208,9 +61254,7 @@
<p>Let <var title="">destination</var> be a new <span>URL</span> formed by applying the
<span title="concept-url-serializer">URL serializer</span> algorithm to <var title="">parsed action</var>.</p>
- <p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to <var
- title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <span>replacement enabled</span>.</p>
+ <p><span>Plan to navigate</span> to <var title="">destination</var>.</p>
</dd>
@@ -61251,21 +61295,16 @@
of <var title="">form document</var>, then abort these steps.</p> [or do CORS] (this is
commented out since only POST can trigger this now, and that's historically unrestricted)-->
- <p>Otherwise, <span>navigate</span><!--DONAV form--> <var title="">target browsing
- context</var> to <var title="">action</var> using the HTTP method given by <var
- title="">method</var> and with <var title="">entity body</var> as the entity body, of type
- <var title="">MIME type</var>. If <var title="">replace</var> is true, then <var
- title="">target browsing context</var> must be navigated with <span>replacement
- enabled</span>.</p>
+ <p>Otherwise, <span>plan to navigate</span> to <var title="">action</var> using the HTTP
+ method given by <var title="">method</var> and with <var title="">entity body</var> as the
+ entity body, of type <var title="">MIME type</var>.</p>
</dd>
<dt><dfn title="submit-get-action">Get action URL</dfn>
<dd>
- <p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to <var
- title="">action</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <span>replacement enabled</span>.</p>
+ <p><span>Plan to navigate</span> to <var title="">action</var>.</p>
<p class="note">The <var title="">form data set</var> is discarded.</p>
@@ -61293,11 +61332,8 @@
US-ASCII string, replace the first occurrence of "<code title="">%%</code>" in <var
title="">action</var> with the resulting escaped string. <a href="#refsURL">[URL]</a></p>
- <p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to the
- potentially modified <var title="">action</var> (which will be a <span title="data
- protocol"><code title="">data:</code> URL</span>). If <var title="">replace</var> is true,
- then <var title="">target browsing context</var> must be navigated with <span>replacement
- enabled</span>.</p>
+ <p><span>Plan to navigate</span> to the potentially modified <var title="">action</var> (which
+ will be a <span title="data protocol"><code title="">data:</code> URL</span>).</p>
</dd>
@@ -61319,9 +61355,7 @@
<p>Append <var title="">headers</var> to <var title="">destination</var>.</p>
- <p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to <var
- title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <span>replacement enabled</span>.</p>
+ <p><span>Plan to navigate</span> to <var title="">destination</var>.</p>
</dd>
@@ -61345,9 +61379,7 @@
<p>Append <var title="">body</var>, interpreted as a US-ASCII string, to <var
title="">destination</var>.</p>
- <p><span>Navigate</span><!--DONAV form--> <var title="">target browsing context</var> to <var
- title="">destination</var>. If <var title="">replace</var> is true, then <var title="">target
- browsing context</var> must be navigated with <span>replacement enabled</span>.</p>
+ <p><span>Plan to navigate</span> to <var title="">destination</var>.</p>
</dd>
More information about the Commit-Watchers
mailing list