HTML Standard Tracker


File a bug

SVNBugCommentTime (UTC)
3220Define location.reload().2009-06-10 23:46
@@ -58917,31 +58917,58 @@ style/default.css</pre>
   with the <span title="script's browsing context">browsing
   context</span> of the script that invoked the method as the
   <span>source browsing context</span>.</p>
   <p>If the <span title="resolve a url">resolving</span> step of the
   <code title="dom-location-assign">assign()</code> and <code
   title="dom-location-replace">replace()</code> methods is not
   successful, then the user agent must instead throw a
   <code>SYNTAX_ERR</code> exception.</p>
-  <dfn title="dom-location-reload"><code>reload()</code></dfn>
-  reload during resize event:
-  redisplay the current page (without reloading it). This
-  theoretically would have no effect but in practice can be useful to
-  work around rendering bugs.
+  <p>When the <dfn
+  title="dom-location-reload"><code>reload()</code></dfn> method is
+  invoked, the user agent must run the appropriate steps from the
+  following list:</p>
-reload on shared Document updates all of them
+  <dl class="switch">
-user reload must be equivalent to .reload()
+   <dt>If the currently executing <span
+   title="concept-task">task</span> is the dispatch of a <code
+   title="event-resize">resize</code> event in response to the user
+   resizing the <span>browsing context</span></dt>
+   <dd><p>Repaint the <span>browsing context</span> and abort these
+   steps.</p></dd> <!-- this theoretically would have no effect but in
+   practice can be useful to work around rendering bugs. -->
+   <dt>Otherwise</dt>
+   <dd><p><span>Navigate</span> the <span>browsing context</span> to
+   the <span>the document's current address</span> with
+   <span>replacement enabled</span>. The <span>source browsing
+   context</span> must be the <span>browsing context</span> being
+   navigated.</p></dd> <!-- it appears that document.reload() always
+   uses GET and does not, e.g., re-POST. -->
+   <!-- -->
+  </dl>
+  <p>When a user requests that the current page be reloaded through a
+  user interface element, the user agent should <span>navigate</span>
+  the <span>browsing context</span> to the same resource as
+  <code>Document</code>, with <span>replacement enabled</span>. In the
+  case of non-idempotent methods (e.g. HTTP POST), the user agent
+  should prompt the user to confirm the operation first, since
+  otherwise transactions (e.g. purchases or database modifications)
+  could be repeated. User agents may allow the user to explicitly
+  override any caches when reloading.</p>
   <p>The <code>Location</code> interface also has the complement of
   <span>URL decomposition attributes</span>, <dfn
   title="dom-location-protocol"><code>protocol</code></dfn>, <dfn
   title="dom-location-host"><code>host</code></dfn>, <dfn
   title="dom-location-port"><code>port</code></dfn>, <dfn
   title="dom-location-hostname"><code>hostname</code></dfn>, <dfn
   title="dom-location-pathname"><code>pathname</code></dfn>, <dfn