[html5] r7650 - [e] (0) Cleanup. Affected topics: DOM APIs, Microdata, Security
whatwg at whatwg.org
whatwg at whatwg.org
Fri Jan 25 15:54:14 PST 2013
Author: ianh
Date: 2013-01-25 15:54:13 -0800 (Fri, 25 Jan 2013)
New Revision: 7650
Modified:
complete.html
index
source
Log:
[e] (0) Cleanup.
Affected topics: DOM APIs, Microdata, Security
Modified: complete.html
===================================================================
--- complete.html 2013-01-25 23:49:43 UTC (rev 7649)
+++ complete.html 2013-01-25 23:54:13 UTC (rev 7650)
@@ -65913,18 +65913,18 @@
<li><p>Let <var title="">items</var> be an empty array.</li>
- <li><p>For each <var title="">node</var> in <var title="">nodes</var>, check if the element is a <a href=#top-level-microdata-items title="top-level microdata items">top-level microdata item</a>,
- and if it is then <a href=#get-the-object>get the object</a> for that element and
- add it to <var title="">items</var>.</li>
+ <li><p>For each <var title="">node</var> in <var title="">nodes</var>, check if the element is a
+ <a href=#top-level-microdata-items title="top-level microdata items">top-level microdata item</a>, and if it is then
+ <a href=#get-the-object>get the object</a> for that element and add it to <var title="">items</var>.</li>
- <li><p>Add an entry to <var title="">result</var> called "<code title="">items</code>" whose value is the array <var title="">items</var>.</li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">items</code>" whose
+ value is the array <var title="">items</var>.</li>
- <li><p>Return the result of serializing <var title="">result</var>
- to JSON in the shortest possible way (meaning no whitespace between
- tokens, no unnecessary zero digits in numbers, and only using
- Unicode escapes in strings for characters that do not have a
- dedicated escape sequence), and with a lowercase "<code title="">e</code>" used, when appropriate, in the representation of
- any numbers. <a href=#refsJSON>[JSON]</a></li>
+ <li><p>Return the result of serializing <var title="">result</var> to JSON in the shortest
+ possible way (meaning no whitespace between tokens, no unnecessary zero digits in numbers, and
+ only using Unicode escapes in strings for characters that do not have a dedicated escape
+ sequence), and with a lowercase "<code title="">e</code>" used, when appropriate, in the
+ representation of any numbers. <a href=#refsJSON>[JSON]</a></li>
</ol><p class=note>This algorithm returns an object with a single property that is an array, instead
of just returning an array, so that it is possible to extend the algorithm in the future if
@@ -65938,42 +65938,34 @@
<li><p>Add <var title="">item</var> to <var title="">memory</var>.</li>
- <li><p>If the <var title="">item</var> has any <a href=#item-types>item
- types</a>, add an entry to <var title="">result</var> called
- "<code title="">type</code>" whose value is an array listing the
- <a href=#item-types>item types</a> of <var title="">item</var>, in the order
- they were specified on the <code title=attr-itemtype><a href=#attr-itemtype>itemtype</a></code> attribute.</p>
+ <li><p>If the <var title="">item</var> has any <a href=#item-types>item types</a>, add an entry to <var title="">result</var> called "<code title="">type</code>" whose value is an array listing the
+ <a href=#item-types>item types</a> of <var title="">item</var>, in the order they were specified on the
+ <code title=attr-itemtype><a href=#attr-itemtype>itemtype</a></code> attribute.</p>
- <li><p>If the <var title="">item</var> has a <a href=#global-identifier>global
- identifier</a>, add an entry to <var title="">result</var>
- called "<code title="">id</code>" whose value is the <a href=#global-identifier>global
+ <li><p>If the <var title="">item</var> has a <a href=#global-identifier>global identifier</a>, add an entry to <var title="">result</var> called "<code title="">id</code>" whose value is the <a href=#global-identifier>global
identifier</a> of <var title="">item</var>.</li>
- <li><p>Let <var title="">properties</var> be an empty
- object.</li>
+ <li><p>Let <var title="">properties</var> be an empty object.</li>
<li>
- <p>For each element <var title="">element</var> that has one or
- more <a href=#property-names>property names</a> and is one of <a href=#the-properties-of-an-item title="the
- properties of an item">the properties of the item</a> <var title="">item</var>, in the order those elements are given by the
- algorithm that returns <a href=#the-properties-of-an-item>the properties of an item</a>, run
- the following substeps:</p>
+ <p>For each element <var title="">element</var> that has one or more <a href=#property-names>property names</a>
+ and is one of <a href=#the-properties-of-an-item title="the properties of an item">the properties of the item</a> <var title="">item</var>, in the order those elements are given by the algorithm that returns
+ <a href=#the-properties-of-an-item>the properties of an item</a>, run the following substeps:</p>
- <ol><li><p>Let <var title="">value</var> be the <a href=#concept-property-value title=concept-property-value>property value</a> of <var title="">element</var>.</li>
+ <ol><li><p>Let <var title="">value</var> be the <a href=#concept-property-value title=concept-property-value>property
+ value</a> of <var title="">element</var>.</li>
- <li><p>If <var title="">value</var> is an <a href=#concept-item title=concept-item>item</a>, then: If <var title="">value</var> is in <var title="">memory</var>, then let
- <var title="">value</var> be the string "<code title="">ERROR</code>". Otherwise, <a href=#get-the-object>get the object</a>
- for <var title="">value</var>, passing a copy of <var title="">memory</var>, and then replace <var title="">value</var>
- with the object returned from those steps.</li>
+ <li><p>If <var title="">value</var> is an <a href=#concept-item title=concept-item>item</a>, then: If <var title="">value</var> is in <var title="">memory</var>, then let <var title="">value</var> be
+ the string "<code title="">ERROR</code>". Otherwise, <a href=#get-the-object>get the object</a> for <var title="">value</var>, passing a copy of <var title="">memory</var>, and then replace <var title="">value</var> with the object returned from those steps.</li>
<li>
- <p>For each name <var title="">name</var> in <var title="">element</var>'s <a href=#property-names>property names</a>, run the
- following substeps:</p>
+ <p>For each name <var title="">name</var> in <var title="">element</var>'s <a href=#property-names>property
+ names</a>, run the following substeps:</p>
- <ol><li><p>If there is no entry named <var title="">name</var> in
- <var title="">properties</var>, then add an entry named <var title="">name</var> to <var title="">properties</var> whose
+ <ol><li><p>If there is no entry named <var title="">name</var> in <var title="">properties</var>,
+ then add an entry named <var title="">name</var> to <var title="">properties</var> whose
value is an empty array.</li>
<li><p>Append <var title="">value</var> to the entry named <var title="">name</var> in <var title="">properties</var>.</li>
@@ -65982,7 +65974,8 @@
</ol></li>
- <li><p>Add an entry to <var title="">result</var> called "<code title="">properties</code>" whose value is the object <var title="">properties</var>.</li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">properties</code>" whose
+ value is the object <var title="">properties</var>.</li>
<li><p>Return <var title="">result</var>.</li>
@@ -66736,27 +66729,23 @@
</dl><div class=impl>
- <p>The <code><a href=#window>Window</a></code> interface must only be <a href=#expose title=expose>exposed</a> if the <a href=#javascript-global-environment>JavaScript global
- environment</a> is a <a href=#document-environment>document environment</a>.</p>
+ <p>The <code><a href=#window>Window</a></code> interface must only be <a href=#expose title=expose>exposed</a> if the
+ <a href=#javascript-global-environment>JavaScript global environment</a> is a <a href=#document-environment>document environment</a>.</p>
- <p>The <dfn id=dom-window title=dom-window><code>window</code></dfn>, <dfn id=dom-frames title=dom-frames><code>frames</code></dfn>, and <dfn id=dom-self title=dom-self><code>self</code></dfn> IDL attributes must all
- return the <code><a href=#window>Window</a></code> object's <a href=#browsing-context>browsing
- context</a>'s <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
+ <p>The <dfn id=dom-window title=dom-window><code>window</code></dfn>, <dfn id=dom-frames title=dom-frames><code>frames</code></dfn>, and <dfn id=dom-self title=dom-self><code>self</code></dfn>
+ IDL attributes must all return the <code><a href=#window>Window</a></code> object's <a href=#browsing-context>browsing context</a>'s
+ <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
- <p>The <dfn id=dom-document-0 title=dom-document><code>document</code></dfn> IDL
- attribute must return the <code><a href=#document>Document</a></code> object of the
- <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a>.</p>
+ <p>The <dfn id=dom-document-0 title=dom-document><code>document</code></dfn> IDL attribute must return the
+ <code><a href=#document>Document</a></code> object of the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
+ <a href=#browsing-context>browsing context</a>'s <a href=#active-document>active document</a>.</p>
- <p>The <dfn id=dom-document-defaultview title=dom-document-defaultView><code>defaultView</code></dfn> IDL
- attribute of the <code><a href=#document>Document</a></code> interface must return the
- <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s
- <code><a href=#windowproxy>WindowProxy</a></code> object, if there is one, or null
- otherwise.</p>
+ <p>The <dfn id=dom-document-defaultview title=dom-document-defaultView><code>defaultView</code></dfn> IDL attribute of the
+ <code><a href=#document>Document</a></code> interface must return the <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing
+ context</a>'s <code><a href=#windowproxy>WindowProxy</a></code> object, if there is one, or null otherwise.</p>
- <hr><p>For historical reasons, <code><a href=#window>Window</a></code> objects must also
- have a writable, configurable, non-enumerable property named
- <dfn id=htmldocument><code>HTMLDocument</code></dfn> whose value is the
+ <hr><p>For historical reasons, <code><a href=#window>Window</a></code> objects must also have a writable, configurable,
+ non-enumerable property named <dfn id=htmldocument><code>HTMLDocument</code></dfn> whose value is the
<code><a href=#document>Document</a></code> interface object.</p>
</div>
@@ -66788,29 +66777,23 @@
<li>The <a href=#dynamic-nested-browsing-context-properties>dynamic nested browsing context properties</a>
- </ul><p>When a script whose <a href=#effective-script-origin>effective script origin</a> is not
- the same as the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
- <a href=#effective-script-origin>effective script origin</a> attempts to access that
- <code><a href=#window>Window</a></code> object's methods or attributes, the user agent
- must act as if any changes to the <code><a href=#window>Window</a></code> object's
- properties, getters, setters, etc, were not present.</p>
+ </ul><p>When a script whose <a href=#effective-script-origin>effective script origin</a> is not the same as the
+ <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s <a href=#effective-script-origin>effective script origin</a> attempts
+ to access that <code><a href=#window>Window</a></code> object's methods or attributes, the user agent must act as if
+ any changes to the <code><a href=#window>Window</a></code> object's properties, getters, setters, etc, were not
+ present.</p>
- <p>For members that return objects (including function objects),
- each distinct <a href=#effective-script-origin>effective script origin</a> that is not the
- same as the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
- <a href=#effective-script-origin>effective script origin</a> must be provided with a
- separate set of objects. These objects must have the prototype chain
- appropriate for the script for which the objects are created (not
- those that would be appropriate for scripts whose <a href="#script's-global-object">script's
- global object</a> is the <code><a href=#window>Window</a></code> object in
- question).</p>
+ <p>For members that return objects (including function objects), each distinct <a href=#effective-script-origin>effective
+ script origin</a> that is not the same as the <code><a href=#window>Window</a></code> object's
+ <code><a href=#document>Document</a></code>'s <a href=#effective-script-origin>effective script origin</a> must be provided with a separate set
+ of objects. These objects must have the prototype chain appropriate for the script for which the
+ objects are created (not those that would be appropriate for scripts whose <a href="#script's-global-object">script's global
+ object</a> is the <code><a href=#window>Window</a></code> object in question).</p>
<div class=example>
- <p>For instance, if two frames containing <code><a href=#document>Document</a></code>s
- from different <a href=#origin title=origin>origins</a> access the same
- <code><a href=#window>Window</a></code> object's <code title=dom-window-postMessage><a href=#dom-window-postmessage>postMessage()</a></code> method, they
- will get distinct objects that are not equal.</p>
+ <p>For instance, if two frames containing <code><a href=#document>Document</a></code>s from different <a href=#origin title=origin>origins</a> access the same <code><a href=#window>Window</a></code> object's <code title=dom-window-postMessage><a href=#dom-window-postmessage>postMessage()</a></code> method, they will get distinct objects that
+ are not equal.</p>
</div>
@@ -66825,12 +66808,11 @@
<dd>
- <p>Opens a window to show <var title="">url</var> (defaults to
- <code><a href=#about:blank>about:blank</a></code>), and returns it. The <var title="">target</var> argument gives the name of the new
- window. If a window exists with that name already, it is
- reused. The <var title="">replace</var> attribute, if true, means
- that whatever page is currently open in that window will be
- removed from the window's session history. The <var title="">features</var> argument is ignored.</p>
+ <p>Opens a window to show <var title="">url</var> (defaults to <code><a href=#about:blank>about:blank</a></code>), and
+ returns it. The <var title="">target</var> argument gives the name of the new window. If a
+ window exists with that name already, it is reused. The <var title="">replace</var> attribute,
+ if true, means that whatever page is currently open in that window will be removed from the
+ window's session history. The <var title="">features</var> argument is ignored.</p>
</dd>
@@ -66864,130 +66846,96 @@
<!-- This whole section should be rewritten to use algorithmic style -->
- <p>The <dfn id=dom-open title=dom-open><code>open()</code></dfn> method on
- <code><a href=#window>Window</a></code> objects provides a mechanism for <a href=#navigate title=navigate>navigating</a> an existing <a href=#browsing-context>browsing
- context</a> or opening and navigating an <a href=#auxiliary-browsing-context>auxiliary browsing
- context</a>.</p>
+ <p>The <dfn id=dom-open title=dom-open><code>open()</code></dfn> method on <code><a href=#window>Window</a></code> objects
+ provides a mechanism for <a href=#navigate title=navigate>navigating</a> an existing <a href=#browsing-context>browsing
+ context</a> or opening and navigating an <a href=#auxiliary-browsing-context>auxiliary browsing context</a>.</p>
<p>The method has four arguments, though they are all optional.</p>
- <p>The first argument, <var title="">url</var>, must be a
- <a href=#valid-non-empty-url>valid non-empty URL</a> for a page to load in the browsing
- context. If no arguments are provided, or if the first argument is
- the empty string, then the <var title="">url</var> argument defaults
- to "<code><a href=#about:blank>about:blank</a></code>". The argument must be <a href=#resolve-a-url title="resolve a url">resolved</a> to an <a href=#absolute-url>absolute
- URL</a> (or an error), relative to the <a href=#entry-script>entry
- script</a>'s <a href="#script's-base-url" title="script's base URL">base URL</a>,
- when the method is invoked.</p>
+ <p>The first argument, <var title="">url</var>, must be a <a href=#valid-non-empty-url>valid non-empty URL</a> for a
+ page to load in the browsing context. If no arguments are provided, or if the first argument is
+ the empty string, then the <var title="">url</var> argument defaults to
+ "<code><a href=#about:blank>about:blank</a></code>". The argument must be <a href=#resolve-a-url title="resolve a url">resolved</a> to an
+ <a href=#absolute-url>absolute URL</a> (or an error), relative to the <a href=#entry-script>entry script</a>'s <a href="#script's-base-url" title="script's base URL">base URL</a>, when the method is invoked.</p>
- <p>The second argument, <var title="">target</var>, specifies the
- <a href=#browsing-context-name title="browsing context name">name</a> of the browsing
- context that is to be navigated. It must be a <a href=#valid-browsing-context-name-or-keyword>valid browsing
- context name or keyword</a>. If fewer than two arguments are
- provided, then the <var title="">target</var> argument defaults to the
- value "<code>_blank</code>".</p>
+ <p>The second argument, <var title="">target</var>, specifies the <a href=#browsing-context-name title="browsing context
+ name">name</a> of the browsing context that is to be navigated. It must be a <a href=#valid-browsing-context-name-or-keyword>valid
+ browsing context name or keyword</a>. If fewer than two arguments are provided, then the <var title="">target</var> argument defaults to the value "<code>_blank</code>".</p>
- <p>The third argument, <var title="">features</var>, has no defined
- effect and is mentioned for historical reasons only. User agents may
- interpret this argument as instructions to set the size and position
- of the browsing context, but are encouraged to instead ignore the
- argument entirely.</p>
+ <p>The third argument, <var title="">features</var>, has no defined effect and is mentioned for
+ historical reasons only. User agents may interpret this argument as instructions to set the size
+ and position of the browsing context, but are encouraged to instead ignore the argument
+ entirely.</p>
- <p>The fourth argument, <var title="">replace</var>, specifies
- whether or not the new page will <a href=#replacement-enabled title="replacement
- enabled">replace</a> the page currently loaded in the browsing
- context, when <var title="">target</var> identifies an existing
- browsing context (as opposed to leaving the current page in the
- browsing context's <a href=#session-history>session history</a>). When three or
- fewer arguments are provided, <var title="">replace</var> defaults
- to false.</p>
+ <p>The fourth argument, <var title="">replace</var>, specifies whether or not the new page will
+ <a href=#replacement-enabled title="replacement enabled">replace</a> the page currently loaded in the browsing
+ context, when <var title="">target</var> identifies an existing browsing context (as opposed to
+ leaving the current page in the browsing context's <a href=#session-history>session history</a>). When three or
+ fewer arguments are provided, <var title="">replace</var> defaults to false.</p>
- <p>When the method is invoked, the user agent must first select a
- <a href=#browsing-context>browsing context</a> to navigate by applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the
- rules for choosing a browsing context given a browsing context
- name</a> using the <var title="">target</var> argument as the
- name and the <a href=#browsing-context>browsing context</a> of the script as the
- context in which the algorithm is executed, unless the user has
- indicated a preference, in which case the browsing context to
- navigate may instead be the one indicated by the user.</p>
+ <p>When the method is invoked, the user agent must first select a <a href=#browsing-context>browsing context</a> to
+ navigate by applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a browsing context
+ name</a> using the <var title="">target</var> argument as the name and the <a href=#browsing-context>browsing
+ context</a> of the script as the context in which the algorithm is executed, unless the user
+ has indicated a preference, in which case the browsing context to navigate may instead be the one
+ indicated by the user.</p>
- <p class=example>For example, suppose there is a user agent that
- supports control-clicking a link to open it in a new tab. If a user
- clicks in that user agent on an element whose <code title=handler-onclick><a href=#handler-onclick>onclick</a></code> handler uses the <code title=dom-open><a href=#dom-open>window.open()</a></code> API to open a page in an
- iframe, but, while doing so, holds the control key down, the user
- agent could override the selection of the target browsing context to
- instead target a new tab.</p>
+ <p class=example>For example, suppose there is a user agent that supports control-clicking a
+ link to open it in a new tab. If a user clicks in that user agent on an element whose <code title=handler-onclick><a href=#handler-onclick>onclick</a></code> handler uses the <code title=dom-open><a href=#dom-open>window.open()</a></code> API to open a page in an iframe, but, while doing so, holds
+ the control key down, the user agent could override the selection of the target browsing context
+ to instead target a new tab.</p>
<p>If applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a browsing context
name</a> using the <var title="">target</var> argument would result in there not being a chosen
browsing context, then throw an <code><a href=#invalidaccesserror>InvalidAccessError</a></code> exception and abort these
steps.</p>
- <p>Otherwise, if <var title="">url</var> is not
- "<code><a href=#about:blank>about:blank</a></code>", the user agent must
- <a href=#navigate>navigate</a><!--DONAV window.open()--> the selected
- <a href=#browsing-context>browsing context</a> to the <a href=#absolute-url>absolute URL</a>
- obtained from <a href=#resolve-a-url title="resolve a url">resolving</a> <var title="">url</var> earlier. If the <var title="">replace</var> is
- true or if the <a href=#browsing-context>browsing context</a> was just created as
- part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
- browsing context name</a>, then <a href=#replacement-enabled title="replacement
- enabled">replacement must be enabled</a>. The navigation must be
- done with the <a href="#script's-browsing-context" title="script's browsing context">browsing
- context</a> of the <a href=#entry-script>entry script</a> as the <a href=#source-browsing-context>source
- browsing context</a>. If the <a href=#resolve-a-url>resolve a URL</a> algorithm
- failed, then the user agent may either instead <a href=#navigate>navigate</a>
- to an inline error page, using the same replacement behavior and
- source browsing context behavior as described earlier in this
- paragraph; or treat the <var title="">url</var> as
- "<code><a href=#about:blank>about:blank</a></code>", acting as described in the next
- paragraph.</p>
+ <p>Otherwise, if <var title="">url</var> is not "<code><a href=#about:blank>about:blank</a></code>", the user agent must
+ <a href=#navigate>navigate</a><!--DONAV window.open()--> the selected <a href=#browsing-context>browsing context</a> to the
+ <a href=#absolute-url>absolute URL</a> obtained from <a href=#resolve-a-url title="resolve a url">resolving</a> <var title="">url</var> earlier. If the <var title="">replace</var> is true or if the <a href=#browsing-context>browsing
+ context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
+ browsing context name</a>, then <a href=#replacement-enabled title="replacement enabled">replacement must be
+ enabled</a>. The navigation must be done with the <a href="#script's-browsing-context" title="script's browsing
+ context">browsing context</a> of the <a href=#entry-script>entry script</a> as the <a href=#source-browsing-context>source browsing
+ context</a>. If the <a href=#resolve-a-url>resolve a URL</a> algorithm failed, then the user agent may either
+ instead <a href=#navigate>navigate</a> to an inline error page, using the same replacement behavior and
+ source browsing context behavior as described earlier in this paragraph; or treat the <var title="">url</var> as "<code><a href=#about:blank>about:blank</a></code>", acting as described in the next paragraph.</p>
- <p>If <var title="">url</var> <em>is</em>
- "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing context</a> was just created as
- part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
- browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue
- a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected <a href=#browsing-context>browsing
- context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected
- <a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object's
- <code><a href=#document>Document</a></code> object (and the <code title=dom-event-currentTarget>currentTarget</code> set to the
- <code><a href=#window>Window</a></code> object).</p>
+ <p>If <var title="">url</var> <em>is</em> "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing
+ context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
+ browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue a task</a> to
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected
+ <a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected <a href=#browsing-context>browsing context</a>'s
+ <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code> object (and the <code title=dom-event-currentTarget>currentTarget</code> set to the <code><a href=#window>Window</a></code> object).</p>
- <p>The method must return the <code><a href=#windowproxy>WindowProxy</a></code> object of the
- <a href=#browsing-context>browsing context</a> that was navigated, or null if no
- browsing context was navigated.</p>
+ <p>The method must return the <code><a href=#windowproxy>WindowProxy</a></code> object of the <a href=#browsing-context>browsing context</a>
+ that was navigated, or null if no browsing context was navigated.</p>
- <hr><p>The <dfn id=dom-name title=dom-name><code>name</code></dfn> attribute of
- the <code><a href=#window>Window</a></code> object must, on getting, return the current
- <a href=#browsing-context-name title="browsing context name">name</a> of the
- <a href=#browsing-context>browsing context</a>, and, on setting, set the <a href=#browsing-context-name title="browsing context name">name</a> of the <a href=#browsing-context>browsing
- context</a> to the new value.</p>
+ <hr><p>The <dfn id=dom-name title=dom-name><code>name</code></dfn> attribute of the <code><a href=#window>Window</a></code> object
+ must, on getting, return the current <a href=#browsing-context-name title="browsing context name">name</a> of the
+ <a href=#browsing-context>browsing context</a>, and, on setting, set the <a href=#browsing-context-name title="browsing context
+ name">name</a> of the <a href=#browsing-context>browsing context</a> to the new value.</p>
- <p class=note>The name <a href=#resetBCName>gets reset</a> when
- the browsing context is navigated to another domain.</p>
+ <p class=note>The name <a href=#resetBCName>gets reset</a> when the browsing context is
+ navigated to another domain.</p>
- <hr><p>The <dfn id=dom-window-close title=dom-window-close><code>close()</code></dfn>
- method on <code><a href=#window>Window</a></code> objects should, if the corresponding
- <a href=#browsing-context>browsing context</a> <var title="">A</var> is
- <a href=#script-closable>script-closable</a> and the <a href="#script's-browsing-context" title="script's browsing
- context">browsing context</a> of the <a href=#concept-script title=concept-script>script</a> that invokes the method is
- <a href=#allowed-to-navigate>allowed to navigate</a> the <a href=#browsing-context>browsing context</a>
- <var title="">A</var>, <a href=#close-a-browsing-context title="close a browsing
- context">close</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>.</p>
+ <hr><p>The <dfn id=dom-window-close title=dom-window-close><code>close()</code></dfn> method on <code><a href=#window>Window</a></code>
+ objects should, if the corresponding <a href=#browsing-context>browsing context</a> <var title="">A</var> is
+ <a href=#script-closable>script-closable</a> and the <a href="#script's-browsing-context" title="script's browsing context">browsing
+ context</a> of the <a href=#concept-script title=concept-script>script</a> that invokes the method is
+ <a href=#allowed-to-navigate>allowed to navigate</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>, <a href=#close-a-browsing-context title="close a browsing context">close</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>.</p>
- <p>A <a href=#browsing-context>browsing context</a> is <dfn id=script-closable>script-closable</dfn> if
- it is an <a href=#auxiliary-browsing-context>auxiliary browsing context</a> that was created by
- a script (as opposed to by an action of the user), or if it is a
- <a href=#browsing-context>browsing context</a> whose <a href=#session-history>session history</a>
- contains only one <code><a href=#document>Document</a></code>.</p>
+ <p>A <a href=#browsing-context>browsing context</a> is <dfn id=script-closable>script-closable</dfn> if it is an <a href=#auxiliary-browsing-context>auxiliary
+ browsing context</a> that was created by a script (as opposed to by an action of the user), or
+ if it is a <a href=#browsing-context>browsing context</a> whose <a href=#session-history>session history</a> contains only one
+ <code><a href=#document>Document</a></code>.</p>
- <p>The <dfn id=dom-window-stop title=dom-window-stop><code>stop()</code></dfn> method
- on <code><a href=#window>Window</a></code> objects should, if there is an existing
- attempt to <a href=#navigate>navigate</a> the <a href=#browsing-context>browsing context</a>
- and that attempt is not currently running the <a href=#unload-a-document>unload a
- document</a> algorithm, cancel that <a href=#navigate title=navigate>navigation</a>; then, it must <a href=#abort-a-document title="abort
- a document">abort</a> the <a href=#active-document>active document</a> of the
- <a href=#browsing-context>browsing context</a> of the <code><a href=#window>Window</a></code> object on
- which it was invoked.</p>
+ <p>The <dfn id=dom-window-stop title=dom-window-stop><code>stop()</code></dfn> method on <code><a href=#window>Window</a></code>
+ objects should, if there is an existing attempt to <a href=#navigate>navigate</a> the <a href=#browsing-context>browsing
+ context</a> and that attempt is not currently running the <a href=#unload-a-document>unload a document</a>
+ algorithm, cancel that <a href=#navigate title=navigate>navigation</a>; then, it must <a href=#abort-a-document title="abort
+ a document">abort</a> the <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing context</a> of
+ the <code><a href=#window>Window</a></code> object on which it was invoked.</p>
</div>
@@ -66998,8 +66946,8 @@
<dd>
- <p>Returns the number of <a href=#child-browsing-context title="child browsing
- context">child browsing contexts</a>.</p>
+ <p>Returns the number of <a href=#child-browsing-context title="child browsing context">child browsing
+ contexts</a>.</p>
</dd>
@@ -67013,37 +66961,28 @@
</dl><div class=impl>
- <p>The <dfn id=dom-length title=dom-length><code>length</code></dfn> IDL
- attribute on the <code><a href=#window>Window</a></code> interface must return the
- number of <a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> that are <a href=#browsing-context-nested-through title="browsing context nested
- through">nested through</a> elements that are <a href=#in-a-document title="in a
- document">in the <code>Document</code></a> that is the
- <a href=#active-document>active document</a> of that <code><a href=#window>Window</a></code> object, if
- that <code><a href=#window>Window</a></code>'s <a href=#browsing-context>browsing context</a> shares the
- same <a href=#event-loop>event loop</a> as the <a href="#script's-browsing-context">script's browsing
- context</a> of the <a href=#entry-script>entry script</a> accessing the IDL
- attribute; otherwise, it must return zero.</p>
+ <p>The <dfn id=dom-length title=dom-length><code>length</code></dfn> IDL attribute on the <code><a href=#window>Window</a></code>
+ interface must return the number of <a href=#child-browsing-context title="child browsing context">child browsing
+ contexts</a> that are <a href=#browsing-context-nested-through title="browsing context nested through">nested through</a>
+ elements that are <a href=#in-a-document title="in a document">in the <code>Document</code></a> that is the
+ <a href=#active-document>active document</a> of that <code><a href=#window>Window</a></code> object, if that <code><a href=#window>Window</a></code>'s
+ <a href=#browsing-context>browsing context</a> shares the same <a href=#event-loop>event loop</a> as the <a href="#script's-browsing-context">script's
+ browsing context</a> of the <a href=#entry-script>entry script</a> accessing the IDL attribute; otherwise,
+ it must return zero.</p>
<!-- in other words, frames are only accessible to same-thread processes -->
- <p>The <a href=#supported-property-indices>supported property indices</a> on the
- <code><a href=#window>Window</a></code> object at any instant are the numbers in the
- range 0 .. <span title=""><var title="">n</var>-1</span>, where <var title="">n</var> is the number returned by the <code title=dom-length><a href=#dom-length>length</a></code> IDL attribute. If <var title="">n</var> is zero then there are no <a href=#supported-property-indices>supported property
+ <p>The <a href=#supported-property-indices>supported property indices</a> on the <code><a href=#window>Window</a></code> object at any instant
+ are the numbers in the range 0 .. <span title=""><var title="">n</var>-1</span>, where <var title="">n</var> is the number returned by the <code title=dom-length><a href=#dom-length>length</a></code> IDL
+ attribute. If <var title="">n</var> is zero then there are no <a href=#supported-property-indices>supported property
indices</a>.</p>
- <p>To <dfn id=dom-window-item title=dom-window-item>determine the value of an indexed
- property</dfn> <var title="">index</var> of a <code><a href=#window>Window</a></code>
- object, the user agent must return the <code><a href=#windowproxy>WindowProxy</a></code>
- object of the <var title="">index</var>th <a href=#child-browsing-context>child browsing
- context</a> of the <code><a href=#document>Document</a></code> that is nested through
- an element that is <a href=#in-a-document title="in a document">in the
- <code>Document</code></a>, sorted in the <a href=#tree-order>tree order</a>
- of the elements nesting those <a href=#browsing-context title="browsing
- context">browsing contexts</a>.</p>
+ <p>To <dfn id=dom-window-item title=dom-window-item>determine the value of an indexed property</dfn> <var title="">index</var> of a <code><a href=#window>Window</a></code> object, the user agent must return the
+ <code><a href=#windowproxy>WindowProxy</a></code> object of the <var title="">index</var>th <a href=#child-browsing-context>child browsing
+ context</a> of the <code><a href=#document>Document</a></code> that is nested through an element that is <a href=#in-a-document title="in a document">in the <code>Document</code></a>, sorted in the <a href=#tree-order>tree order</a>
+ of the elements nesting those <a href=#browsing-context title="browsing context">browsing contexts</a>.</p>
- <p>These properties are the <dfn id=dynamic-nested-browsing-context-properties>dynamic nested browsing context
- properties</dfn>.</p>
+ <p>These properties are the <dfn id=dynamic-nested-browsing-context-properties>dynamic nested browsing context properties</dfn>.</p>
</div>
@@ -67061,81 +67000,69 @@
</dl><div class=impl>
- <p>The <code><a href=#window>Window</a></code> interface <a href=#support-named-properties title="support named
- properties">supports named properties</a>. The <a href=#supported-property-names>supported
- property names</a> at any moment consist of:</p>
+ <p>The <code><a href=#window>Window</a></code> interface <a href=#support-named-properties title="support named properties">supports named
+ properties</a>. The <a href=#supported-property-names>supported property names</a> at any moment consist of:</p>
- <ul><li>the <a href=#browsing-context-name>browsing context name</a> of any <a href=#child-browsing-context>child
- browsing context</a> of the <a href=#active-document>active document</a> whose
- name is not the empty string,</li>
+ <ul><li>the <a href=#browsing-context-name>browsing context name</a> of any <a href=#child-browsing-context>child browsing context</a> of the
+ <a href=#active-document>active document</a> whose name is not the empty string,</li>
- <li>the value of the <code title="">name</code> content attribute
- for all <code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>,
- <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>,
- <code><a href=#the-img-element>img</a></code>, and <code><a href=#the-object-element>object</a></code> elements in the
- <a href=#active-document>active document</a> that have a <code title="">name</code>
- content attribute, and</li>
+ <li>the value of the <code title="">name</code> content attribute for all <code><a href=#the-a-element>a</a></code>,
+ <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>, <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>,
+ <code><a href=#frameset>frameset</a></code>, <code><a href=#the-img-element>img</a></code>, and <code><a href=#the-object-element>object</a></code> elements in the <a href=#active-document>active
+ document</a> that have a <code title="">name</code> content attribute, and</li>
- <li>the value of the <code title=attr-id><a href=#the-id-attribute>id</a></code> content
- attribute of any <a href=#html-elements title="HTML elements">HTML element</a> in
- the <a href=#active-document>active document</a> with an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute.</li>
+ <li>the value of the <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute of any <a href=#html-elements title="HTML
+ elements">HTML element</a> in the <a href=#active-document>active document</a> with an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute.</li>
- </ul><p>To <a href=#determine-the-value-of-a-named-property>determine the value of a named property</a> <var title="">name</var> when <dfn id=dom-window-nameditem title=dom-window-namedItem>the
- <code>Window</code> object is indexed for property retrieval</dfn>,
- the user agent must return the value obtained using the following
- steps:</p>
+ </ul><p>To <a href=#determine-the-value-of-a-named-property>determine the value of a named property</a> <var title="">name</var> when <dfn id=dom-window-nameditem title=dom-window-namedItem>the <code>Window</code> object is indexed for property
+ retrieval</dfn>, the user agent must return the value obtained using the following steps:</p>
<ol><!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1716 --><li>
- <p>Let <var title="">objects</var> be the list of <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the
- name <var title="">name</var> in the <a href=#active-document>active document</a>.
+ <p>Let <var title="">objects</var> be the list of <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the name <var title="">name</var>
+ in the <a href=#active-document>active document</a>.
- <p class=note>There will be at least one such object, by
- definition.<!-- (If there wasn't, then this algorithm wouldn't
- have been invoked by Web IDL.) --></p>
+ <p class=note>There will be at least one such object, by definition.<!-- (If there wasn't,
+ then this algorithm wouldn't have been invoked by Web IDL.) --></p>
</li>
<li>
- <p>If <var title="">objects</var> contains a <a href=#nested-browsing-context>nested browsing
- context</a>, then return the <code><a href=#windowproxy>WindowProxy</a></code> object of
- the <a href=#nested-browsing-context>nested browsing context</a> corresponding to the
- first <a href=#browsing-context-container>browsing context container</a> in <a href=#tree-order>tree
- order</a> whose <a href=#browsing-context>browsing context</a> is in <var title="">objects</var>, and abort these steps.</p>
+ <p>If <var title="">objects</var> contains a <a href=#nested-browsing-context>nested browsing context</a>, then return
+ the <code><a href=#windowproxy>WindowProxy</a></code> object of the <a href=#nested-browsing-context>nested browsing context</a> corresponding to
+ the first <a href=#browsing-context-container>browsing context container</a> in <a href=#tree-order>tree order</a> whose
+ <a href=#browsing-context>browsing context</a> is in <var title="">objects</var>, and abort these steps.</p>
</li>
<li>
- <p>Otherwise, if <var title="">elements</var> has only one
- element, return that element and abort these steps.</p>
+ <p>Otherwise, if <var title="">elements</var> has only one element, return that element and
+ abort these steps.</p>
</li>
<li>
- <p>Otherwise return an <code><a href=#htmlcollection>HTMLCollection</a></code> rooted at the
- <code><a href=#document>Document</a></code> node, whose filter matches only <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the
- name <var title="">name</var>. (By definition, these will all be
- elements.)</p> <!-- the same one each time is returned, because of
- the rule under collections -->
+ <p>Otherwise return an <code><a href=#htmlcollection>HTMLCollection</a></code> rooted at the <code><a href=#document>Document</a></code> node,
+ whose filter matches only <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with
+ the name <var title="">name</var>. (By definition, these will all be elements.)</p> <!-- the
+ same one each time is returned, because of the rule under collections -->
</li>
- </ol><p><dfn id=dom-window-nameditem-filter title=dom-window-nameditem-filter>Named objects</dfn>
- with the name <var title="">name</var>, for the purposes of the
- above algorithm, are those that are either:</p>
+ </ol><p><dfn id=dom-window-nameditem-filter title=dom-window-nameditem-filter>Named objects</dfn> with the name <var title="">name</var>, for the purposes of the above algorithm, are those that are either:</p>
- <ul><li><a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> of the <a href=#active-document>active document</a> whose name is
- <var title="">name</var>,</li>
+ <ul><li><a href=#child-browsing-context title="child browsing context">child browsing contexts</a> of the <a href=#active-document>active
+ document</a> whose name is <var title="">name</var>,</li>
- <li><code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>,
- <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>,
- <code><a href=#the-img-element>img</a></code>, or <code><a href=#the-object-element>object</a></code> elements that have a <code title=attr-name>name</code> content attribute whose value is <var title="">name</var>, or</li>
+ <li><code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>, <code><a href=#the-embed-element>embed</a></code>,
+ <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>, <code><a href=#the-img-element>img</a></code>, or <code><a href=#the-object-element>object</a></code> elements that
+ have a <code title=attr-name>name</code> content attribute whose value is <var title="">name</var>, or</li>
- <li><a href=#html-elements>HTML elements</a> that have an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute whose value is <var title="">name</var>.</li>
+ <li><a href=#html-elements>HTML elements</a> that have an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute
+ whose value is <var title="">name</var>.</li>
</ul></div>
@@ -67144,72 +67071,53 @@
<h4 id=garbage-collection-and-browsing-contexts><span class=secno>6.2.5 </span>Garbage collection and browsing contexts</h4>
- <p>A <a href=#browsing-context>browsing context</a> has a strong reference to each of
- its <code><a href=#document>Document</a></code>s and its <code><a href=#windowproxy>WindowProxy</a></code> object,
- and the user agent itself has a strong reference to its <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing
- contexts</a>.</p>
+ <p>A <a href=#browsing-context>browsing context</a> has a strong reference to each of its <code><a href=#document>Document</a></code>s
+ and its <code><a href=#windowproxy>WindowProxy</a></code> object, and the user agent itself has a strong reference to its
+ <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a>.</p>
- <p>A <code><a href=#document>Document</a></code> has a strong reference to its
- <code><a href=#window>Window</a></code> object.</p>
+ <p>A <code><a href=#document>Document</a></code> has a strong reference to its <code><a href=#window>Window</a></code> object.</p>
- <p class=note>A <code><a href=#window>Window</a></code> object <a href=#implied-strong-reference title="implied
- strong reference">has a strong reference</a> to its
- <code><a href=#document>Document</a></code> object through its <code title=dom-document><a href=#dom-document-0>document</a></code> attribute. Thus, references
- from other scripts to either of those objects will keep both
- alive. Similarly, both <code><a href=#document>Document</a></code> and <code><a href=#window>Window</a></code>
- objects have <a href=#implied-strong-reference title="implied strong reference">implied strong
- references</a> to the <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
+ <p class=note>A <code><a href=#window>Window</a></code> object <a href=#implied-strong-reference title="implied strong reference">has a strong
+ reference</a> to its <code><a href=#document>Document</a></code> object through its <code title=dom-document><a href=#dom-document-0>document</a></code> attribute. Thus, references from other scripts to either of
+ those objects will keep both alive. Similarly, both <code><a href=#document>Document</a></code> and <code><a href=#window>Window</a></code>
+ objects have <a href=#implied-strong-reference title="implied strong reference">implied strong references</a> to the
+ <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
- <p>Each <a href=#concept-script title=concept-script>script</a> has a strong
- reference to its <a href="#script's-browsing-context" title="script's browsing context">browsing
- context</a> and its <a href="#script's-document" title="script's
+ <p>Each <a href=#concept-script title=concept-script>script</a> has a strong reference to its <a href="#script's-browsing-context" title="script's browsing context">browsing context</a> and its <a href="#script's-document" title="script's
document">document</a>.</p>
<!-- discard a document -->
- <p>When a <a href=#browsing-context>browsing context</a> is to <dfn id=discard-a-document>discard a
- <code>Document</code></dfn>, the user agent must run the following
- steps:</p>
+ <p>When a <a href=#browsing-context>browsing context</a> is to <dfn id=discard-a-document>discard a <code>Document</code></dfn>, the user
+ agent must run the following steps:</p>
- <ol><li><p>Set the <code><a href=#document>Document</a></code>'s <var title=concept-document-salvageable><a href=#concept-document-salvageable>salvageable</a></var> state to
- false.</li>
+ <ol><li><p>Set the <code><a href=#document>Document</a></code>'s <var title=concept-document-salvageable><a href=#concept-document-salvageable>salvageable</a></var> state to false.</li>
- <li><p>Run any <a href=#unloading-document-cleanup-steps>unloading document cleanup steps</a> for
- the <code><a href=#document>Document</a></code> that are defined by this specification
- and <a href=#other-applicable-specifications>other applicable specifications</a>.</li>
+ <li><p>Run any <a href=#unloading-document-cleanup-steps>unloading document cleanup steps</a> for the <code><a href=#document>Document</a></code> that
+ are defined by this specification and <a href=#other-applicable-specifications>other applicable specifications</a>.</li>
- <li><p><a href=#abort-a-document title="abort a document">Abort the
- <code>Document</code></a>.</li>
+ <li><p><a href=#abort-a-document title="abort a document">Abort the <code>Document</code></a>.</li>
- <li><p>Remove any <a href=#concept-task title=concept-task>tasks</a>
- associated with the <code><a href=#document>Document</a></code> in any <a href=#task-source>task
- source</a>, without running those tasks.</li>
+ <li><p>Remove any <a href=#concept-task title=concept-task>tasks</a> associated with the
+ <code><a href=#document>Document</a></code> in any <a href=#task-source>task source</a>, without running those tasks.</li>
- <li><p><a href=#a-browsing-context-is-discarded title="a browsing context is discarded">Discard</a>
- all the <a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> of the <code><a href=#document>Document</a></code>.</li>
+ <li><p><a href=#a-browsing-context-is-discarded title="a browsing context is discarded">Discard</a> all the <a href=#child-browsing-context title="child
+ browsing context">child browsing contexts</a> of the <code><a href=#document>Document</a></code>.</li>
- <li><p>Lose the strong reference from the <code><a href=#document>Document</a></code>'s
- <a href=#browsing-context>browsing context</a> to the
- <code><a href=#document>Document</a></code>.</li>
+ <li><p>Lose the strong reference from the <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>
+ to the <code><a href=#document>Document</a></code>.</li>
- </ol><p class=note>Whenever a <code><a href=#document>Document</a></code> object is <a href=#discard-a-document title="discard a Document">discarded</a>, it is also removed from
- the list of <a href="#the-worker's-documents">the worker's <code>Document</code>s</a> of each
- worker whose list contains that <code><a href=#document>Document</a></code>.</p>
+ </ol><p class=note>Whenever a <code><a href=#document>Document</a></code> object is <a href=#discard-a-document title="discard a
+ Document">discarded</a>, it is also removed from the list of <a href="#the-worker's-documents">the worker's
+ <code>Document</code>s</a> of each worker whose list contains that <code><a href=#document>Document</a></code>.</p>
- <p>When <dfn id=a-browsing-context-is-discarded>a <em><span>browsing context</span></em> is
- discarded</dfn>, the strong reference from the user agent itself to
- the <a href=#browsing-context>browsing context</a> must be severed, and all the
- <code><a href=#document>Document</a></code> objects for all the entries in the
- <a href=#browsing-context>browsing context</a>'s session history must be <a href=#discard-a-document title="discard a document">discarded</a> as well.</p>
+ <p>When <dfn id=a-browsing-context-is-discarded>a <em><span>browsing context</span></em> is discarded</dfn>, the strong reference
+ from the user agent itself to the <a href=#browsing-context>browsing context</a> must be severed, and all the
+ <code><a href=#document>Document</a></code> objects for all the entries in the <a href=#browsing-context>browsing context</a>'s session
+ history must be <a href=#discard-a-document title="discard a document">discarded</a> as well.</p>
- <p>User agents may <a href=#a-browsing-context-is-discarded title="a browsing context is
- discarded">discard</a> <a href=#top-level-browsing-context title="top-level browsing
- context">top-level browsing contexts</a> at any time (typically,
- in response to user requests, e.g. when a user force-closes a window
- containing one or more <a href=#top-level-browsing-context title="top-level browsing
- context">top-level browsing contexts</a>). Other <a href=#browsing-context title="browsing context">browsing contexts</a> must be discarded
- once their <code><a href=#windowproxy>WindowProxy</a></code> object is eligible for garbage
- collection.</p>
+ <p>User agents may <a href=#a-browsing-context-is-discarded title="a browsing context is discarded">discard</a> <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a> at any time (typically, in
+ response to user requests, e.g. when a user force-closes a window containing one or more <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a>). Other <a href=#browsing-context title="browsing context">browsing contexts</a> must be discarded once their
+ <code><a href=#windowproxy>WindowProxy</a></code> object is eligible for garbage collection.</p>
</div>
@@ -67286,35 +67194,30 @@
</dl><div class=impl>
- <p>The <dfn id=dom-barprop-visible title=dom-BarProp-visible>visible</dfn> attribute, on
- getting, must return either true or a value determined by the user
- agent to most accurately represent the visibility state of the user
- interface element that the object represents, as described below. On
- setting, the new value must be discarded.</p>
+ <p>The <dfn id=dom-barprop-visible title=dom-BarProp-visible>visible</dfn> attribute, on getting, must return either
+ true or a value determined by the user agent to most accurately represent the visibility state of
+ the user interface element that the object represents, as described below. On setting, the new
+ value must be discarded.</p>
- <p>The following <code><a href=#barprop>BarProp</a></code> objects exist for each
- <code><a href=#document>Document</a></code> object in a <a href=#browsing-context>browsing
- context</a>. Some of the user interface elements represented by
- these objects might have no equivalent in some user agents; for
- those user agents, except when otherwise specified, the object must
- act as if it was present and visible (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute must return
- true).</p>
+ <p>The following <code><a href=#barprop>BarProp</a></code> objects exist for each <code><a href=#document>Document</a></code> object in a
+ <a href=#browsing-context>browsing context</a>. Some of the user interface elements represented by these objects
+ might have no equivalent in some user agents; for those user agents, except when otherwise
+ specified, the object must act as if it was present and visible (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute must return true).</p>
<dl><dt><dfn id=the-location-bar-barprop-object>The location bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a control
- that displays the <a href=#url>URL</a> of the <a href=#active-document>active
- document</a>, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a control that displays the
+ <a href=#url>URL</a> of the <a href=#active-document>active document</a>, or some similar interface concept.</dd>
<dt><dfn id=the-menu-bar-barprop-object>The menu bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a list of
- commands in menu form, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a list of commands in menu form, or some
+ similar interface concept.</dd>
<dt><dfn id=the-personal-bar-barprop-object>The personal bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains links to
- the user's favorite pages, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains links to the user's favorite pages, or
+ some similar interface concept.</dd>
<dt><dfn id=the-scrollbar-barprop-object>The scrollbar <code>BarProp</code> object</dfn></dt>
@@ -67323,56 +67226,42 @@
<dt><dfn id=the-status-bar-barprop-object>The status bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents a user interface element found immediately below or
- after the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code>
- attribute may return false).</dd>
+ <dd>Represents a user interface element found immediately below or after the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute may return false).</dd>
<dt><dfn id=the-toolbar-barprop-object>The toolbar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element found immediately above
- or before the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code>
- attribute may return false).</dd>
+ <dd>Represents the user interface element found immediately above or before the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute may return false).</dd>
- </dl><p>The <dfn id=dom-window-locationbar title=dom-window-locationbar><code>locationbar</code></dfn>
- attribute must return <a href=#the-location-bar-barprop-object>the location bar <code>BarProp</code>
- object</a>.</p>
+ </dl><p>The <dfn id=dom-window-locationbar title=dom-window-locationbar><code>locationbar</code></dfn> attribute must return
+ <a href=#the-location-bar-barprop-object>the location bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-menubar title=dom-window-menubar><code>menubar</code></dfn>
- attribute must return <a href=#the-menu-bar-barprop-object>the menu bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-menubar title=dom-window-menubar><code>menubar</code></dfn> attribute must return <a href=#the-menu-bar-barprop-object>the
+ menu bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-personalbar title=dom-window-personalbar><code>personalbar</code></dfn>
- attribute must return <a href=#the-personal-bar-barprop-object>the personal bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-personalbar title=dom-window-personalbar><code>personalbar</code></dfn> attribute must return
+ <a href=#the-personal-bar-barprop-object>the personal bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-scrollbars title=dom-window-scrollbars><code>scrollbars</code></dfn>
- attribute must return <a href=#the-scrollbar-barprop-object>the scrollbar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-scrollbars title=dom-window-scrollbars><code>scrollbars</code></dfn> attribute must return
+ <a href=#the-scrollbar-barprop-object>the scrollbar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-statusbar title=dom-window-statusbar><code>statusbar</code></dfn> attribute
- must return <a href=#the-status-bar-barprop-object>the status bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-statusbar title=dom-window-statusbar><code>statusbar</code></dfn> attribute must return
+ <a href=#the-status-bar-barprop-object>the status bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-toolbar title=dom-window-toolbar><code>toolbar</code></dfn>
- attribute must return <a href=#the-toolbar-barprop-object>the toolbar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-toolbar title=dom-window-toolbar><code>toolbar</code></dfn> attribute must return <a href=#the-toolbar-barprop-object>the
+ toolbar <code>BarProp</code> object</a>.</p>
<!--
- <p>For legacy reasons, the <dfn
- title="dom-window-directories"><code>directories</code></dfn>
- attribute must also return <span>the personal bar
- <code>BarProp</code> object</span>.</p>
+ <p>For legacy reasons, the <dfn title="dom-window-directories"><code>directories</code></dfn>
+ attribute must also return <span>the personal bar <code>BarProp</code> object</span>.</p>
-->
- <hr><p>For historical reasons, the <dfn id=dom-window-status title=dom-window-status><code>status</code></dfn> attribute on the
- <code><a href=#window>Window</a></code> object must return an empty string on getting,
- and do nothing on setting.</p>
+ <hr><p>For historical reasons, the <dfn id=dom-window-status title=dom-window-status><code>status</code></dfn> attribute
+ on the <code><a href=#window>Window</a></code> object must return an empty string on getting, and do nothing on
+ setting.</p>
</div>
@@ -67383,27 +67272,24 @@
<p>As mentioned earlier, each <a href=#browsing-context>browsing context</a> has a
- <dfn id=windowproxy><code>WindowProxy</code></dfn> object. This object is unusual
- in that all operations that would be performed on it must be
- performed on the <code><a href=#window>Window</a></code> object of the <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a> instead. It is thus
- indistinguishable from that <code><a href=#window>Window</a></code> object in every way
- until the <a href=#browsing-context>browsing context</a> is navigated.</p>
+ <dfn id=windowproxy><code>WindowProxy</code></dfn> object. This object is unusual in that all operations that
+ would be performed on it must be performed on the <code><a href=#window>Window</a></code> object of the <a href=#browsing-context>browsing
+ context</a>'s <a href=#active-document>active document</a> instead. It is thus indistinguishable from that
+ <code><a href=#window>Window</a></code> object in every way until the <a href=#browsing-context>browsing context</a> is navigated.</p>
<p>There is no <code><a href=#windowproxy>WindowProxy</a></code> interface object.</p>
- <p class=note>The <code><a href=#windowproxy>WindowProxy</a></code> object allows scripts
- to act as if each <a href=#browsing-context>browsing context</a> had a single
- <code><a href=#window>Window</a></code> object, while still keeping separate
- <code><a href=#window>Window</a></code> objects for each <code><a href=#document>Document</a></code>.</p>
+ <p class=note>The <code><a href=#windowproxy>WindowProxy</a></code> object allows scripts to act as if each
+ <a href=#browsing-context>browsing context</a> had a single <code><a href=#window>Window</a></code> object, while still keeping
+ separate <code><a href=#window>Window</a></code> objects for each <code><a href=#document>Document</a></code>.</p>
<div class=example>
- <p>In the following example, the variable <var title="">x</var> is
- set to the <code><a href=#windowproxy>WindowProxy</a></code> object returned by the <code title=dom-window><a href=#dom-window>window</a></code> accessor on the global object. All
- of the expressions following the assignment return true, because in
- every respect, the <code><a href=#windowproxy>WindowProxy</a></code> object acts like the
- underlying <code><a href=#window>Window</a></code> object.</p>
+ <p>In the following example, the variable <var title="">x</var> is set to the
+ <code><a href=#windowproxy>WindowProxy</a></code> object returned by the <code title=dom-window><a href=#dom-window>window</a></code> accessor
+ on the global object. All of the expressions following the assignment return true, because in
+ every respect, the <code><a href=#windowproxy>WindowProxy</a></code> object acts like the underlying <code><a href=#window>Window</a></code>
+ object.</p>
<pre>var x = window;
x instanceof Window; // true
@@ -67420,10 +67306,9 @@
<h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>
<!-- Hallowed are the Ori -->
- <p>The <dfn id=origin>origin</dfn> of a resource and the <dfn id=effective-script-origin>effective script
- origin</dfn> of a resource are both either opaque identifiers or
- tuples consisting of a scheme component, a host component, a port
- component, and optionally extra data.</p>
+ <p>The <dfn id=origin>origin</dfn> of a resource and the <dfn id=effective-script-origin>effective script origin</dfn> of a resource
+ are both either opaque identifiers or tuples consisting of a scheme component, a host component, a
+ port component, and optionally extra data.</p>
<p class=note>The extra data could include the certificate of the
site when using encrypted connections, to ensure that if the site's
@@ -67432,13 +67317,10 @@
<div class=impl>
- <p>An <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a>
- can be defined as an <dfn id=concept-origin-alias title=concept-origin-alias>alias</dfn>
- to another <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script
- origin</a>. The value of the <a href=#origin>origin</a> or
- <a href=#effective-script-origin>effective script origin</a> is then the value of the
- <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> to which
- it is an alias.</p>
+ <p>An <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> can be defined as an <dfn id=concept-origin-alias title=concept-origin-alias>alias</dfn> to another <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script
+ origin</a>. The value of the <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> is
+ then the value of the <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> to which it is
+ an alias.</p>
<p>These characteristics are defined as follows:</p>
@@ -67446,9 +67328,8 @@
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of the <a href=#url>URL</a> are the origin defined in
- <cite>The Web Origin Concept</cite>. <a href=#refsORIGIN>[ORIGIN]</a></p>
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of the <a href=#url>URL</a> are
+ the origin defined in <cite>The Web Origin Concept</cite>. <a href=#refsORIGIN>[ORIGIN]</a></p>
</dd>
@@ -67457,18 +67338,16 @@
<dd>
- <dl class=switch><dt id=sandboxOrigin>If a <code><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set>active
- sandboxing flag set</a> has its <a href=#sandboxed-origin-browsing-context-flag>sandboxed origin
- browsing context flag</a> set</dt>
+ <dl class=switch><dt id=sandboxOrigin>If a <code><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set>active sandboxing flag set</a> has
+ its <a href=#sandboxed-origin-browsing-context-flag>sandboxed origin browsing context flag</a> set</dt>
<dd>
- <p>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the <code><a href=#document>Document</a></code> is created.</p>
+ <p>The <a href=#origin>origin</a> is a globally unique identifier assigned when the
+ <code><a href=#document>Document</a></code> is created.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
@@ -67479,77 +67358,64 @@
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the script of that <a href=#javascript-protocol title="javascript protocol"><code>javascript:</code>
- URL</a>.</p>
+ <a href=#origin>origin</a> of the script of that <a href=#javascript-protocol title="javascript
+ protocol"><code>javascript:</code> URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was served over the network and
- has an address that uses a URL scheme with a server-based naming
- authority</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was served over the network and has an address that uses a URL
+ scheme with a server-based naming authority</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of <a href="#the-document's-address">the <code>Document</code>'s
- address</a>.</p>
+ <a href=#origin>origin</a> of <a href="#the-document's-address">the <code>Document</code>'s address</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> that
- was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in
- other protocols)</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> that was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in other protocols)</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <a href=#url>URL</a> that redirected to
- the <a href=#data-protocol title="data protocol"><code title="">data:</code>
- URL</a>.</p>
+ <a href=#origin>origin</a> of the <a href=#url>URL</a> that redirected to the <a href=#data-protocol title="data
+ protocol"><code title="">data:</code> URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a>
- found in another <code><a href=#document>Document</a></code> or in a script</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> found in another <code><a href=#document>Document</a></code> or in a script</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> or script that
- initiated the <a href=#navigate title=navigate>navigation</a> to that
- <a href=#url>URL</a>.</p>
+ <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to that <a href=#url>URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to that <a href=#url>URL</a>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to
+ that <a href=#url>URL</a>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> has the <a href="#the-document's-address" title="the
- document's address">address</a>
+ <dt>If a <code><a href=#document>Document</a></code> has the <a href="#the-document's-address" title="the document's address">address</a>
"<code><a href=#about:blank>about:blank</a></code>"</dt>
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of the <code><a href=#document>Document</a></code> are <a href=#about-blank-origin>those it was assigned when its
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code> are <a href=#about-blank-origin>those it was assigned when its
browsing context was created</a>.</p>
</dd>
@@ -67559,41 +67425,34 @@
<dd>
- <p>The <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> is an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>'s
- <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
+ <p>The <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
container</a>'s <code><a href=#document>Document</a></code>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s
- <a href=#browsing-context-container>browsing context container</a>'s
- <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
+ container</a>'s <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was obtained in some other manner
- (e.g. a <a href=#data-protocol title="data protocol"><code title="">data:</code>
- URL</a> typed in by the user, a <code><a href=#document>Document</a></code> created
- using the <code title=dom-DOMImplementation-createDocument><a href=#dom-domimplementation-createdocument>createDocument()</a></code>
+ <dt>If a <code><a href=#document>Document</a></code> was obtained in some other manner (e.g. a <a href=#data-protocol title="data
+ protocol"><code title="">data:</code> URL</a> typed in by the user, a <code><a href=#document>Document</a></code>
+ created using the <code title=dom-DOMImplementation-createDocument><a href=#dom-domimplementation-createdocument>createDocument()</a></code>
API, etc)</dt>
<dd>
- <p>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the <code><a href=#document>Document</a></code> is created.</p>
+ <p>The <a href=#origin>origin</a> is a globally unique identifier assigned when the
+ <code><a href=#document>Document</a></code> is created.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- </dl><p class=note>The <a href=#effective-script-origin>effective script origin</a> of a
- <code><a href=#document>Document</a></code> can be manipulated using the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> IDL
+ </dl><p class=note>The <a href=#effective-script-origin>effective script origin</a> of a <code><a href=#document>Document</a></code> can be
+ manipulated using the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> IDL
attribute.</p>
</dd>
@@ -67603,23 +67462,21 @@
<dd>
- <dl class=switch><dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and
- its image data is <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
+ <dl class=switch><dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and its image data is
+ <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
- <dd>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <a href=#origin>origin</a> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and
- its image data is <a href=#cors-same-origin>CORS-same-origin</a></dt>
+ <dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and its image data is
+ <a href=#cors-same-origin>CORS-same-origin</a></dt>
<dd>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#the-img-element>img</a></code> element's
- <code><a href=#document>Document</a></code>.</dd>
+ <a href=#origin>origin</a> of the <code><a href=#the-img-element>img</a></code> element's <code><a href=#document>Document</a></code>.</dd>
- <!-- all image loads go through the "potentially CORS-enabled
- fetch" algorithm so they're all either CORS-cross-origin or
- CORS-same-origin if they succeed at all -->
+ <!-- all image loads go through the "potentially CORS-enabled fetch" algorithm so they're all
+ either CORS-cross-origin or CORS-same-origin if they succeed at all -->
</dl><p>Images do not have an <a href=#effective-script-origin>effective script origin</a>.</p>
@@ -67630,22 +67487,19 @@
<dd>
- <dl class=switch><dt>If the <a href=#media-data>media data</a> is
- <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
+ <dl class=switch><dt>If the <a href=#media-data>media data</a> is <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
- <dd>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <a href=#origin>origin</a> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If the <a href=#media-data>media data</a> is
- <a href=#cors-same-origin>CORS-same-origin</a></dt>
+ <dt>If the <a href=#media-data>media data</a> is <a href=#cors-same-origin>CORS-same-origin</a></dt>
<dd>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <a href=#media-element>media element</a>'s
- <code><a href=#document>Document</a></code>.</dd>
+ <a href=#origin>origin</a> of the <a href=#media-element>media element</a>'s <code><a href=#document>Document</a></code>.</dd>
- </dl><p><a href=#media-element title="media element">Media elements</a> do not have
- an <a href=#effective-script-origin>effective script origin</a>.</p>
+ </dl><p><a href=#media-element title="media element">Media elements</a> do not have an <a href=#effective-script-origin>effective script
+ origin</a>.</p>
</dd>
@@ -67661,10 +67515,8 @@
own site in some fashion controlled by the data you want to read
-->
- <p>The <a href=#origin>origin</a> of a locally installed system font is
- an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> in which that
- font is being used.</p>
+ <p>The <a href=#origin>origin</a> of a locally installed system font is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code> in which that font is being used.</p>
<p>Fonts do not have an <a href=#effective-script-origin>effective script origin</a>.</p>
@@ -67675,177 +67527,154 @@
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of a script are determined from another resource,
- called the <i>owner</i>:</p>
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of a script are determined
+ from another resource, called the <i>owner</i>:</p>
<dl class=switch><dt>If a script is in a <code><a href=#the-script-element>script</a></code> element</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> to which the
- <code><a href=#the-script-element>script</a></code> element belongs.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> to which the <code><a href=#the-script-element>script</a></code> element
+ belongs.</dd>
- <dt>If a script is in an <a href=#event-handler-content-attributes title="event handler content
- attributes">event handler content attribute</a></dt>
+ <dt>If a script is in an <a href=#event-handler-content-attributes title="event handler content attributes">event handler content
+ attribute</a></dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> to which the
- attribute node belongs.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> to which the attribute node belongs.</dd>
- <dt>If a script is a function or other code reference created by
- another script</dt>
+ <dt>If a script is a function or other code reference created by another script</dt>
<dd>The owner is the script that created it.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> that was returned as the
- location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in
- other protocols)</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> that was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in other protocols)</dt>
- <dd>The owner is the <a href=#url>URL</a> that redirected to the
- <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a>.</dd>
+ <dd>The owner is the <a href=#url>URL</a> that redirected to the <a href=#javascript-protocol title="javascript
+ protocol"><code title="">javascript:</code> URL</a>.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> in an attribute</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> in an attribute</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the element on
- which the attribute is found.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the element on which the attribute is found.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> in a style sheet</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> in a style sheet</dt>
<dd>The owner is the <a href=#url>URL</a> of the style sheet.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been provided by the user (e.g. by using a
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been provided by the user (e.g. by using a
<i>bookmarklet</i>)</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a>.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the <a href=#browsing-context>browsing context</a>'s <a href=#active-document>active
+ document</a>.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been declared in markup</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been declared in markup</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the element
- (e.g. an <code><a href=#the-a-element>a</a></code> or <code><a href=#the-area-element>area</a></code> element) that
- declared the URL.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the element (e.g. an <code><a href=#the-a-element>a</a></code> or
+ <code><a href=#the-area-element>area</a></code> element) that declared the URL.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been provided by script</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been provided by script</dt>
<dd>The owner is the script that provided the URL.</dd>
- </dl><p>The <a href=#origin>origin</a> of the script is then an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the owner, and the <a href=#effective-script-origin>effective script
- origin</a> of the script is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective
- script origin</a> of the owner.</p>
+ </dl><p>The <a href=#origin>origin</a> of the script is then an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the owner, and the
+ <a href=#effective-script-origin>effective script origin</a> of the script is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ owner.</p>
</dd>
- </dl><p>Other specifications can override the above definitions by
- themselves specifying the origin of a particular <a href=#url>URL</a>,
- <code><a href=#document>Document</a></code>, image, <a href=#media-element>media element</a>, font, or
+ </dl><p>Other specifications can override the above definitions by themselves specifying the origin of
+ a particular <a href=#url>URL</a>, <code><a href=#document>Document</a></code>, image, <a href=#media-element>media element</a>, font, or
<a href=#concept-script title=concept-script>script</a>.</p>
<!-- e.g.:
- <p>The <span>origin</span> of a <code>Document</code> object
- returned by the <code>XMLHttpRequest</code> API is an <span
- title="concept-origin-alias">alias</span> to the
- <span>XMLHttpRequest origin</span> of the
- <code>XMLHttpRequest</code> object.</p>
+ <p>The <span>origin</span> of a <code>Document</code> object returned by the
+ <code>XMLHttpRequest</code> API is an <span title="concept-origin-alias">alias</span> to the
+ <span>XMLHttpRequest origin</span> of the <code>XMLHttpRequest</code> object.</p>
-->
- <hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <a href=#origin>origin</a>:</p>
+ <hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <a href=#origin>origin</a>:</p>
- <ol><li><p>If the <a href=#origin>origin</a> in question is not a
- scheme/host/port tuple, then return the literal string "<code title="">null</code>" and abort these steps.</li>
+ <ol><li><p>If the <a href=#origin>origin</a> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <a href=#origin>origin</a> tuple.</li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <a href=#origin>origin</a>
+ tuple.</li>
<li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</li>
- <li><p>Apply the IDNA ToUnicode algorithm to each component of the
- host part of the <a href=#origin>origin</a> tuple, and append the results
- — each component, in the same order, separated by U+002E FULL
- STOP characters (.) — to <var title="">result</var>. <a href=#refsRFC3490>[RFC3490]</a></li>
+ <li><p>Apply the IDNA ToUnicode algorithm to each component of the host part of the
+ <a href=#origin>origin</a> tuple, and append the results — each component, in the same order,
+ separated by U+002E FULL STOP characters (.) — to <var title="">result</var>. <a href=#refsRFC3490>[RFC3490]</a></li>
- <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <a href=#origin>origin</a> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</li>
+ <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <a href=#origin>origin</a> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var title="">result</var>.</li>
<li><p>Return <var title="">result</var>.</li>
- </ol><p>The <dfn id=ascii-serialization-of-an-origin>ASCII serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <a href=#origin>origin</a>:</p>
+ </ol><p>The <dfn id=ascii-serialization-of-an-origin>ASCII serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <a href=#origin>origin</a>:</p>
- <ol><li><p>If the <a href=#origin>origin</a> in question is not a
- scheme/host/port tuple, then return the literal string "<code title="">null</code>" and abort these steps.</li>
+ <ol><li><p>If the <a href=#origin>origin</a> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <a href=#origin>origin</a> tuple.</li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <a href=#origin>origin</a>
+ tuple.</li>
<li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</li>
<li>
- <p>Apply the IDNA ToASCII algorithm the host part of the
- <a href=#origin>origin</a> tuple, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and append the results <var title="">result</var>.</p>
+ <p>Apply the IDNA ToASCII algorithm the host part of the <a href=#origin>origin</a> tuple, with both
+ the AllowUnassigned and UseSTD3ASCIIRules flags set, and append the results <var title="">result</var>.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then return the empty string and abort these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then return the empty string and abort these steps.
+ <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
- <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <a href=#origin>origin</a> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</li>
+ <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <a href=#origin>origin</a> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var title="">result</var>.</li>
<li><p>Return <var title="">result</var>.</li>
- </ol><p>Two <a href=#origin title=origin>origins</a> are said to be the
- <dfn id=same-origin>same origin</dfn> if the following algorithm returns true:</p>
+ </ol><p>Two <a href=#origin title=origin>origins</a> are said to be the <dfn id=same-origin>same origin</dfn> if the
+ following algorithm returns true:</p>
- <ol><li><p>Let <var title="">A</var> be the first <a href=#origin>origin</a>
- being compared, and <var title="">B</var> be the second
- <a href=#origin>origin</a> being compared.</li>
+ <ol><li><p>Let <var title="">A</var> be the first <a href=#origin>origin</a> being compared, and <var title="">B</var> be the second <a href=#origin>origin</a> being compared.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> are both
- opaque identifiers, and their value is equal, then return
- true.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> are both opaque identifiers, and their
+ value is equal, then return true.</li>
- <li><p>Otherwise, if either <var title="">A</var> or <var title="">B</var> or both are opaque identifiers, return
- false.</li>
+ <li><p>Otherwise, if either <var title="">A</var> or <var title="">B</var> or both are opaque
+ identifiers, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have
- scheme components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have scheme components that are not
+ identical, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have host
- components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have host components that are not
+ identical, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have port
- components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have port components that are not
+ identical, return false.</li>
- <li><p>If either <var title="">A</var> or <var title="">B</var>
- have additional data, but that data is not identical for both,
- return false.</li>
+ <li><p>If either <var title="">A</var> or <var title="">B</var> have additional data, but that
+ data is not identical for both, return false.</li>
<li><p>Return true.</li>
@@ -67860,89 +67689,76 @@
<p>Returns the current domain used for security checks.</p>
- <p>Can be set to a value that removes subdomains, to change the
- <a href=#effective-script-origin>effective script origin</a> to allow pages on other
- subdomains of the same domain (if they do the same thing) to
- access each other.</p>
+ <p>Can be set to a value that removes subdomains, to change the <a href=#effective-script-origin>effective script
+ origin</a> to allow pages on other subdomains of the same domain (if they do the same thing)
+ to access each other.</p>
</dd>
</dl><div class=impl>
- <p>The <dfn id=dom-document-domain title=dom-document-domain><code>domain</code></dfn>
- attribute on <code><a href=#document>Document</a></code> objects must be initialized to
- <a href="#the-document's-domain">the document's domain</a>, if it has one, and the empty
- string otherwise. If the value is an IPv6 address, then the square
- brackets from the host portion of the <a href=#url-host title=url-host><host></a> component must be omitted from
- the attribute's value.</p>
+ <p>The <dfn id=dom-document-domain title=dom-document-domain><code>domain</code></dfn> attribute on
+ <code><a href=#document>Document</a></code> objects must be initialized to <a href="#the-document's-domain">the document's domain</a>, if it has
+ one, and the empty string otherwise. If the value is an IPv6 address, then the square brackets
+ from the host portion of the <a href=#url-host title=url-host><host></a> component must be omitted
+ from the attribute's value.</p>
- <p>On getting, the attribute must return its current value, unless
- the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing context</a>, in
- which case it must return the empty string.</p>
+ <p>On getting, the attribute must return its current value, unless the <code><a href=#document>Document</a></code> has
+ no <a href=#browsing-context>browsing context</a>, in which case it must return the empty string.</p>
<p>On setting, the user agent must run the following algorithm:</p>
<ol><li>
- <p>If the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing
- context</a>, throw a <code><a href=#securityerror>SecurityError</a></code> exception and
- abort these steps.</p>
+ <p>If the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing context</a>, throw a
+ <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps.</p>
</li>
<li>
- <p>If the new value is an IP address, let <var title="">new
- value</var> be the new value. Otherwise, apply the IDNA ToASCII
- algorithm to the new value, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and let <var title="">new value</var>
- be the result of the ToASCII algorithm.</p>
+ <p>If the new value is an IP address, let <var title="">new value</var> be the new value.
+ Otherwise, apply the IDNA ToASCII algorithm to the new value, with both the AllowUnassigned and
+ UseSTD3ASCIIRules flags set, and let <var title="">new value</var> be the result of the ToASCII
+ algorithm.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort
- these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and
+ abort these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
<li>
- <p>If <var title="">new value</var> is not exactly equal to the
- current value of the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not exactly equal to the current value of the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute, then run these substeps:</p>
<ol><li>
- <p>If the current value is an IP address, throw a
- <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps.</p>
+ <p>If the current value is an IP address, throw a <code><a href=#securityerror>SecurityError</a></code> exception and
+ abort these steps.</p>
</li>
<li>
- <p>If <var title="">new value</var>, prefixed by a U+002E FULL
- STOP (.), does not exactly match the end of the current value,
- throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort these
- steps.</p>
+ <p>If <var title="">new value</var>, prefixed by a U+002E FULL STOP (.), does not exactly
+ match the end of the current value, throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort
+ these steps.</p>
- <!-- this is the step that prevents us from ever setting
- document.domain if the >effective script origin< isn't a
- scheme/host/port tuple -->
+ <!-- this is the step that prevents us from ever setting document.domain if the >effective
+ script origin< isn't a scheme/host/port tuple -->
</li>
<li>
- <p>If <var title="">new value</var> matches a suffix in the
- Public Suffix List, or, if <var title="">new value</var>,
- prefixed by a U+002E FULL STOP (.), matches the end of a
- suffix in the Public Suffix List, then throw a
- <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps. <a href=#refsPSL>[PSL]</a></p>
+ <p>If <var title="">new value</var> matches a suffix in the Public Suffix List, or, if <var title="">new value</var>, prefixed by a U+002E FULL STOP (.), matches the end of a suffix in
+ the Public Suffix List, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort these
+ steps. <a href=#refsPSL>[PSL]</a></p>
- <p>Suffixes must be compared after applying the IDNA ToASCII
- algorithm to them, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, in an <a href=#ascii-case-insensitive>ASCII
- case-insensitive</a> manner. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>Suffixes must be compared after applying the IDNA ToASCII algorithm to them, with both the
+ AllowUnassigned and UseSTD3ASCIIRules flags set, in an <a href=#ascii-case-insensitive>ASCII case-insensitive</a>
+ manner. <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
@@ -67958,57 +67774,47 @@
<li>
- <p>If the <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a>, set it to the value of
- the <a href=#effective-script-origin>effective script origin</a> (essentially de-aliasing
- the <a href=#effective-script-origin>effective script origin</a>).</p>
+ <p>If the <a href=#effective-script-origin>effective script origin</a> of the <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a>, set it to the value of the <a href=#effective-script-origin>effective script
+ origin</a> (essentially de-aliasing the <a href=#effective-script-origin>effective script origin</a>).</p>
</li>
<li>
- <p>If <var title="">new value</var> is not the empty string, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not the empty string, then2 run these substeps:</p>
<ol><li>
- <p>Set the host part of the <a href=#effective-script-origin>effective script origin</a>
- tuple of the <code><a href=#document>Document</a></code> to <var title="">new
- value</var>.</p>
+ <p>Set the host part of the <a href=#effective-script-origin>effective script origin</a> tuple of the
+ <code><a href=#document>Document</a></code> to <var title="">new value</var>.</p>
</li>
<li>
- <p>Set the port part of the <a href=#effective-script-origin>effective script origin</a>
- tuple of the <code><a href=#document>Document</a></code> to "manual override" (a value
- that, for the purposes of <a href=#same-origin title="same origin">comparing
- origins</a>, is identical to "manual override" but not
+ <p>Set the port part of the <a href=#effective-script-origin>effective script origin</a> tuple of the
+ <code><a href=#document>Document</a></code> to "manual override" (a value that, for the purposes of <a href=#same-origin title="same origin">comparing origins</a>, is identical to "manual override" but not
identical to any other value).</p>
</li>
</ol></li>
- </ol><p>The <dfn id="the-document's-domain" title="the document's domain">domain</dfn> of a
- <code><a href=#document>Document</a></code> is the host part of the document's
- <a href=#origin>origin</a>, if the value of that <a href=#origin>origin</a> is a
- scheme/host/port tuple. If it isn't, then the document does not have
- a domain.</p>
+ </ol><p>The <dfn id="the-document's-domain" title="the document's domain">domain</dfn> of a <code><a href=#document>Document</a></code> is the host part
+ of the document's <a href=#origin>origin</a>, if the value of that <a href=#origin>origin</a> is a
+ scheme/host/port tuple. If it isn't, then the document does not have a domain.</p>
</div>
- <p class=note>The <code title=dom-document-domain><a href=#dom-document-domain>domain</a></code>
- attribute is used to enable pages on different hosts of a domain to
- access each others' DOMs.</p>
+ <p class=note>The <code title=dom-document-domain><a href=#dom-document-domain>domain</a></code> attribute is used to enable
+ pages on different hosts of a domain to access each others' DOMs.</p>
- <p class=warning>Do not use the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute when
- using shared hosting. If an untrusted third party is able to host an
- HTTP server at the same IP address but on a different port, then the
- same-origin protection that normally protects two different sites on
- the same host will fail, as the ports are ignored when comparing
- origins after the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute has
- been used.</p>
+ <p class=warning>Do not use the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code>
+ attribute when using shared hosting. If an untrusted third party is able to host an HTTP server at
+ the same IP address but on a different port, then the same-origin protection that normally
+ protects two different sites on the same host will fail, as the ports are ignored when comparing
+ origins after the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute has been
+ used.</p>
<!--TOPIC:HTML-->
Modified: index
===================================================================
--- index 2013-01-25 23:49:43 UTC (rev 7649)
+++ index 2013-01-25 23:54:13 UTC (rev 7650)
@@ -65913,18 +65913,18 @@
<li><p>Let <var title="">items</var> be an empty array.</li>
- <li><p>For each <var title="">node</var> in <var title="">nodes</var>, check if the element is a <a href=#top-level-microdata-items title="top-level microdata items">top-level microdata item</a>,
- and if it is then <a href=#get-the-object>get the object</a> for that element and
- add it to <var title="">items</var>.</li>
+ <li><p>For each <var title="">node</var> in <var title="">nodes</var>, check if the element is a
+ <a href=#top-level-microdata-items title="top-level microdata items">top-level microdata item</a>, and if it is then
+ <a href=#get-the-object>get the object</a> for that element and add it to <var title="">items</var>.</li>
- <li><p>Add an entry to <var title="">result</var> called "<code title="">items</code>" whose value is the array <var title="">items</var>.</li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">items</code>" whose
+ value is the array <var title="">items</var>.</li>
- <li><p>Return the result of serializing <var title="">result</var>
- to JSON in the shortest possible way (meaning no whitespace between
- tokens, no unnecessary zero digits in numbers, and only using
- Unicode escapes in strings for characters that do not have a
- dedicated escape sequence), and with a lowercase "<code title="">e</code>" used, when appropriate, in the representation of
- any numbers. <a href=#refsJSON>[JSON]</a></li>
+ <li><p>Return the result of serializing <var title="">result</var> to JSON in the shortest
+ possible way (meaning no whitespace between tokens, no unnecessary zero digits in numbers, and
+ only using Unicode escapes in strings for characters that do not have a dedicated escape
+ sequence), and with a lowercase "<code title="">e</code>" used, when appropriate, in the
+ representation of any numbers. <a href=#refsJSON>[JSON]</a></li>
</ol><p class=note>This algorithm returns an object with a single property that is an array, instead
of just returning an array, so that it is possible to extend the algorithm in the future if
@@ -65938,42 +65938,34 @@
<li><p>Add <var title="">item</var> to <var title="">memory</var>.</li>
- <li><p>If the <var title="">item</var> has any <a href=#item-types>item
- types</a>, add an entry to <var title="">result</var> called
- "<code title="">type</code>" whose value is an array listing the
- <a href=#item-types>item types</a> of <var title="">item</var>, in the order
- they were specified on the <code title=attr-itemtype><a href=#attr-itemtype>itemtype</a></code> attribute.</p>
+ <li><p>If the <var title="">item</var> has any <a href=#item-types>item types</a>, add an entry to <var title="">result</var> called "<code title="">type</code>" whose value is an array listing the
+ <a href=#item-types>item types</a> of <var title="">item</var>, in the order they were specified on the
+ <code title=attr-itemtype><a href=#attr-itemtype>itemtype</a></code> attribute.</p>
- <li><p>If the <var title="">item</var> has a <a href=#global-identifier>global
- identifier</a>, add an entry to <var title="">result</var>
- called "<code title="">id</code>" whose value is the <a href=#global-identifier>global
+ <li><p>If the <var title="">item</var> has a <a href=#global-identifier>global identifier</a>, add an entry to <var title="">result</var> called "<code title="">id</code>" whose value is the <a href=#global-identifier>global
identifier</a> of <var title="">item</var>.</li>
- <li><p>Let <var title="">properties</var> be an empty
- object.</li>
+ <li><p>Let <var title="">properties</var> be an empty object.</li>
<li>
- <p>For each element <var title="">element</var> that has one or
- more <a href=#property-names>property names</a> and is one of <a href=#the-properties-of-an-item title="the
- properties of an item">the properties of the item</a> <var title="">item</var>, in the order those elements are given by the
- algorithm that returns <a href=#the-properties-of-an-item>the properties of an item</a>, run
- the following substeps:</p>
+ <p>For each element <var title="">element</var> that has one or more <a href=#property-names>property names</a>
+ and is one of <a href=#the-properties-of-an-item title="the properties of an item">the properties of the item</a> <var title="">item</var>, in the order those elements are given by the algorithm that returns
+ <a href=#the-properties-of-an-item>the properties of an item</a>, run the following substeps:</p>
- <ol><li><p>Let <var title="">value</var> be the <a href=#concept-property-value title=concept-property-value>property value</a> of <var title="">element</var>.</li>
+ <ol><li><p>Let <var title="">value</var> be the <a href=#concept-property-value title=concept-property-value>property
+ value</a> of <var title="">element</var>.</li>
- <li><p>If <var title="">value</var> is an <a href=#concept-item title=concept-item>item</a>, then: If <var title="">value</var> is in <var title="">memory</var>, then let
- <var title="">value</var> be the string "<code title="">ERROR</code>". Otherwise, <a href=#get-the-object>get the object</a>
- for <var title="">value</var>, passing a copy of <var title="">memory</var>, and then replace <var title="">value</var>
- with the object returned from those steps.</li>
+ <li><p>If <var title="">value</var> is an <a href=#concept-item title=concept-item>item</a>, then: If <var title="">value</var> is in <var title="">memory</var>, then let <var title="">value</var> be
+ the string "<code title="">ERROR</code>". Otherwise, <a href=#get-the-object>get the object</a> for <var title="">value</var>, passing a copy of <var title="">memory</var>, and then replace <var title="">value</var> with the object returned from those steps.</li>
<li>
- <p>For each name <var title="">name</var> in <var title="">element</var>'s <a href=#property-names>property names</a>, run the
- following substeps:</p>
+ <p>For each name <var title="">name</var> in <var title="">element</var>'s <a href=#property-names>property
+ names</a>, run the following substeps:</p>
- <ol><li><p>If there is no entry named <var title="">name</var> in
- <var title="">properties</var>, then add an entry named <var title="">name</var> to <var title="">properties</var> whose
+ <ol><li><p>If there is no entry named <var title="">name</var> in <var title="">properties</var>,
+ then add an entry named <var title="">name</var> to <var title="">properties</var> whose
value is an empty array.</li>
<li><p>Append <var title="">value</var> to the entry named <var title="">name</var> in <var title="">properties</var>.</li>
@@ -65982,7 +65974,8 @@
</ol></li>
- <li><p>Add an entry to <var title="">result</var> called "<code title="">properties</code>" whose value is the object <var title="">properties</var>.</li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">properties</code>" whose
+ value is the object <var title="">properties</var>.</li>
<li><p>Return <var title="">result</var>.</li>
@@ -66736,27 +66729,23 @@
</dl><div class=impl>
- <p>The <code><a href=#window>Window</a></code> interface must only be <a href=#expose title=expose>exposed</a> if the <a href=#javascript-global-environment>JavaScript global
- environment</a> is a <a href=#document-environment>document environment</a>.</p>
+ <p>The <code><a href=#window>Window</a></code> interface must only be <a href=#expose title=expose>exposed</a> if the
+ <a href=#javascript-global-environment>JavaScript global environment</a> is a <a href=#document-environment>document environment</a>.</p>
- <p>The <dfn id=dom-window title=dom-window><code>window</code></dfn>, <dfn id=dom-frames title=dom-frames><code>frames</code></dfn>, and <dfn id=dom-self title=dom-self><code>self</code></dfn> IDL attributes must all
- return the <code><a href=#window>Window</a></code> object's <a href=#browsing-context>browsing
- context</a>'s <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
+ <p>The <dfn id=dom-window title=dom-window><code>window</code></dfn>, <dfn id=dom-frames title=dom-frames><code>frames</code></dfn>, and <dfn id=dom-self title=dom-self><code>self</code></dfn>
+ IDL attributes must all return the <code><a href=#window>Window</a></code> object's <a href=#browsing-context>browsing context</a>'s
+ <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
- <p>The <dfn id=dom-document-0 title=dom-document><code>document</code></dfn> IDL
- attribute must return the <code><a href=#document>Document</a></code> object of the
- <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a>.</p>
+ <p>The <dfn id=dom-document-0 title=dom-document><code>document</code></dfn> IDL attribute must return the
+ <code><a href=#document>Document</a></code> object of the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
+ <a href=#browsing-context>browsing context</a>'s <a href=#active-document>active document</a>.</p>
- <p>The <dfn id=dom-document-defaultview title=dom-document-defaultView><code>defaultView</code></dfn> IDL
- attribute of the <code><a href=#document>Document</a></code> interface must return the
- <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s
- <code><a href=#windowproxy>WindowProxy</a></code> object, if there is one, or null
- otherwise.</p>
+ <p>The <dfn id=dom-document-defaultview title=dom-document-defaultView><code>defaultView</code></dfn> IDL attribute of the
+ <code><a href=#document>Document</a></code> interface must return the <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing
+ context</a>'s <code><a href=#windowproxy>WindowProxy</a></code> object, if there is one, or null otherwise.</p>
- <hr><p>For historical reasons, <code><a href=#window>Window</a></code> objects must also
- have a writable, configurable, non-enumerable property named
- <dfn id=htmldocument><code>HTMLDocument</code></dfn> whose value is the
+ <hr><p>For historical reasons, <code><a href=#window>Window</a></code> objects must also have a writable, configurable,
+ non-enumerable property named <dfn id=htmldocument><code>HTMLDocument</code></dfn> whose value is the
<code><a href=#document>Document</a></code> interface object.</p>
</div>
@@ -66788,29 +66777,23 @@
<li>The <a href=#dynamic-nested-browsing-context-properties>dynamic nested browsing context properties</a>
- </ul><p>When a script whose <a href=#effective-script-origin>effective script origin</a> is not
- the same as the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
- <a href=#effective-script-origin>effective script origin</a> attempts to access that
- <code><a href=#window>Window</a></code> object's methods or attributes, the user agent
- must act as if any changes to the <code><a href=#window>Window</a></code> object's
- properties, getters, setters, etc, were not present.</p>
+ </ul><p>When a script whose <a href=#effective-script-origin>effective script origin</a> is not the same as the
+ <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s <a href=#effective-script-origin>effective script origin</a> attempts
+ to access that <code><a href=#window>Window</a></code> object's methods or attributes, the user agent must act as if
+ any changes to the <code><a href=#window>Window</a></code> object's properties, getters, setters, etc, were not
+ present.</p>
- <p>For members that return objects (including function objects),
- each distinct <a href=#effective-script-origin>effective script origin</a> that is not the
- same as the <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code>'s
- <a href=#effective-script-origin>effective script origin</a> must be provided with a
- separate set of objects. These objects must have the prototype chain
- appropriate for the script for which the objects are created (not
- those that would be appropriate for scripts whose <a href="#script's-global-object">script's
- global object</a> is the <code><a href=#window>Window</a></code> object in
- question).</p>
+ <p>For members that return objects (including function objects), each distinct <a href=#effective-script-origin>effective
+ script origin</a> that is not the same as the <code><a href=#window>Window</a></code> object's
+ <code><a href=#document>Document</a></code>'s <a href=#effective-script-origin>effective script origin</a> must be provided with a separate set
+ of objects. These objects must have the prototype chain appropriate for the script for which the
+ objects are created (not those that would be appropriate for scripts whose <a href="#script's-global-object">script's global
+ object</a> is the <code><a href=#window>Window</a></code> object in question).</p>
<div class=example>
- <p>For instance, if two frames containing <code><a href=#document>Document</a></code>s
- from different <a href=#origin title=origin>origins</a> access the same
- <code><a href=#window>Window</a></code> object's <code title=dom-window-postMessage><a href=#dom-window-postmessage>postMessage()</a></code> method, they
- will get distinct objects that are not equal.</p>
+ <p>For instance, if two frames containing <code><a href=#document>Document</a></code>s from different <a href=#origin title=origin>origins</a> access the same <code><a href=#window>Window</a></code> object's <code title=dom-window-postMessage><a href=#dom-window-postmessage>postMessage()</a></code> method, they will get distinct objects that
+ are not equal.</p>
</div>
@@ -66825,12 +66808,11 @@
<dd>
- <p>Opens a window to show <var title="">url</var> (defaults to
- <code><a href=#about:blank>about:blank</a></code>), and returns it. The <var title="">target</var> argument gives the name of the new
- window. If a window exists with that name already, it is
- reused. The <var title="">replace</var> attribute, if true, means
- that whatever page is currently open in that window will be
- removed from the window's session history. The <var title="">features</var> argument is ignored.</p>
+ <p>Opens a window to show <var title="">url</var> (defaults to <code><a href=#about:blank>about:blank</a></code>), and
+ returns it. The <var title="">target</var> argument gives the name of the new window. If a
+ window exists with that name already, it is reused. The <var title="">replace</var> attribute,
+ if true, means that whatever page is currently open in that window will be removed from the
+ window's session history. The <var title="">features</var> argument is ignored.</p>
</dd>
@@ -66864,130 +66846,96 @@
<!-- This whole section should be rewritten to use algorithmic style -->
- <p>The <dfn id=dom-open title=dom-open><code>open()</code></dfn> method on
- <code><a href=#window>Window</a></code> objects provides a mechanism for <a href=#navigate title=navigate>navigating</a> an existing <a href=#browsing-context>browsing
- context</a> or opening and navigating an <a href=#auxiliary-browsing-context>auxiliary browsing
- context</a>.</p>
+ <p>The <dfn id=dom-open title=dom-open><code>open()</code></dfn> method on <code><a href=#window>Window</a></code> objects
+ provides a mechanism for <a href=#navigate title=navigate>navigating</a> an existing <a href=#browsing-context>browsing
+ context</a> or opening and navigating an <a href=#auxiliary-browsing-context>auxiliary browsing context</a>.</p>
<p>The method has four arguments, though they are all optional.</p>
- <p>The first argument, <var title="">url</var>, must be a
- <a href=#valid-non-empty-url>valid non-empty URL</a> for a page to load in the browsing
- context. If no arguments are provided, or if the first argument is
- the empty string, then the <var title="">url</var> argument defaults
- to "<code><a href=#about:blank>about:blank</a></code>". The argument must be <a href=#resolve-a-url title="resolve a url">resolved</a> to an <a href=#absolute-url>absolute
- URL</a> (or an error), relative to the <a href=#entry-script>entry
- script</a>'s <a href="#script's-base-url" title="script's base URL">base URL</a>,
- when the method is invoked.</p>
+ <p>The first argument, <var title="">url</var>, must be a <a href=#valid-non-empty-url>valid non-empty URL</a> for a
+ page to load in the browsing context. If no arguments are provided, or if the first argument is
+ the empty string, then the <var title="">url</var> argument defaults to
+ "<code><a href=#about:blank>about:blank</a></code>". The argument must be <a href=#resolve-a-url title="resolve a url">resolved</a> to an
+ <a href=#absolute-url>absolute URL</a> (or an error), relative to the <a href=#entry-script>entry script</a>'s <a href="#script's-base-url" title="script's base URL">base URL</a>, when the method is invoked.</p>
- <p>The second argument, <var title="">target</var>, specifies the
- <a href=#browsing-context-name title="browsing context name">name</a> of the browsing
- context that is to be navigated. It must be a <a href=#valid-browsing-context-name-or-keyword>valid browsing
- context name or keyword</a>. If fewer than two arguments are
- provided, then the <var title="">target</var> argument defaults to the
- value "<code>_blank</code>".</p>
+ <p>The second argument, <var title="">target</var>, specifies the <a href=#browsing-context-name title="browsing context
+ name">name</a> of the browsing context that is to be navigated. It must be a <a href=#valid-browsing-context-name-or-keyword>valid
+ browsing context name or keyword</a>. If fewer than two arguments are provided, then the <var title="">target</var> argument defaults to the value "<code>_blank</code>".</p>
- <p>The third argument, <var title="">features</var>, has no defined
- effect and is mentioned for historical reasons only. User agents may
- interpret this argument as instructions to set the size and position
- of the browsing context, but are encouraged to instead ignore the
- argument entirely.</p>
+ <p>The third argument, <var title="">features</var>, has no defined effect and is mentioned for
+ historical reasons only. User agents may interpret this argument as instructions to set the size
+ and position of the browsing context, but are encouraged to instead ignore the argument
+ entirely.</p>
- <p>The fourth argument, <var title="">replace</var>, specifies
- whether or not the new page will <a href=#replacement-enabled title="replacement
- enabled">replace</a> the page currently loaded in the browsing
- context, when <var title="">target</var> identifies an existing
- browsing context (as opposed to leaving the current page in the
- browsing context's <a href=#session-history>session history</a>). When three or
- fewer arguments are provided, <var title="">replace</var> defaults
- to false.</p>
+ <p>The fourth argument, <var title="">replace</var>, specifies whether or not the new page will
+ <a href=#replacement-enabled title="replacement enabled">replace</a> the page currently loaded in the browsing
+ context, when <var title="">target</var> identifies an existing browsing context (as opposed to
+ leaving the current page in the browsing context's <a href=#session-history>session history</a>). When three or
+ fewer arguments are provided, <var title="">replace</var> defaults to false.</p>
- <p>When the method is invoked, the user agent must first select a
- <a href=#browsing-context>browsing context</a> to navigate by applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the
- rules for choosing a browsing context given a browsing context
- name</a> using the <var title="">target</var> argument as the
- name and the <a href=#browsing-context>browsing context</a> of the script as the
- context in which the algorithm is executed, unless the user has
- indicated a preference, in which case the browsing context to
- navigate may instead be the one indicated by the user.</p>
+ <p>When the method is invoked, the user agent must first select a <a href=#browsing-context>browsing context</a> to
+ navigate by applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a browsing context
+ name</a> using the <var title="">target</var> argument as the name and the <a href=#browsing-context>browsing
+ context</a> of the script as the context in which the algorithm is executed, unless the user
+ has indicated a preference, in which case the browsing context to navigate may instead be the one
+ indicated by the user.</p>
- <p class=example>For example, suppose there is a user agent that
- supports control-clicking a link to open it in a new tab. If a user
- clicks in that user agent on an element whose <code title=handler-onclick><a href=#handler-onclick>onclick</a></code> handler uses the <code title=dom-open><a href=#dom-open>window.open()</a></code> API to open a page in an
- iframe, but, while doing so, holds the control key down, the user
- agent could override the selection of the target browsing context to
- instead target a new tab.</p>
+ <p class=example>For example, suppose there is a user agent that supports control-clicking a
+ link to open it in a new tab. If a user clicks in that user agent on an element whose <code title=handler-onclick><a href=#handler-onclick>onclick</a></code> handler uses the <code title=dom-open><a href=#dom-open>window.open()</a></code> API to open a page in an iframe, but, while doing so, holds
+ the control key down, the user agent could override the selection of the target browsing context
+ to instead target a new tab.</p>
<p>If applying <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a browsing context
name</a> using the <var title="">target</var> argument would result in there not being a chosen
browsing context, then throw an <code><a href=#invalidaccesserror>InvalidAccessError</a></code> exception and abort these
steps.</p>
- <p>Otherwise, if <var title="">url</var> is not
- "<code><a href=#about:blank>about:blank</a></code>", the user agent must
- <a href=#navigate>navigate</a><!--DONAV window.open()--> the selected
- <a href=#browsing-context>browsing context</a> to the <a href=#absolute-url>absolute URL</a>
- obtained from <a href=#resolve-a-url title="resolve a url">resolving</a> <var title="">url</var> earlier. If the <var title="">replace</var> is
- true or if the <a href=#browsing-context>browsing context</a> was just created as
- part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
- browsing context name</a>, then <a href=#replacement-enabled title="replacement
- enabled">replacement must be enabled</a>. The navigation must be
- done with the <a href="#script's-browsing-context" title="script's browsing context">browsing
- context</a> of the <a href=#entry-script>entry script</a> as the <a href=#source-browsing-context>source
- browsing context</a>. If the <a href=#resolve-a-url>resolve a URL</a> algorithm
- failed, then the user agent may either instead <a href=#navigate>navigate</a>
- to an inline error page, using the same replacement behavior and
- source browsing context behavior as described earlier in this
- paragraph; or treat the <var title="">url</var> as
- "<code><a href=#about:blank>about:blank</a></code>", acting as described in the next
- paragraph.</p>
+ <p>Otherwise, if <var title="">url</var> is not "<code><a href=#about:blank>about:blank</a></code>", the user agent must
+ <a href=#navigate>navigate</a><!--DONAV window.open()--> the selected <a href=#browsing-context>browsing context</a> to the
+ <a href=#absolute-url>absolute URL</a> obtained from <a href=#resolve-a-url title="resolve a url">resolving</a> <var title="">url</var> earlier. If the <var title="">replace</var> is true or if the <a href=#browsing-context>browsing
+ context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
+ browsing context name</a>, then <a href=#replacement-enabled title="replacement enabled">replacement must be
+ enabled</a>. The navigation must be done with the <a href="#script's-browsing-context" title="script's browsing
+ context">browsing context</a> of the <a href=#entry-script>entry script</a> as the <a href=#source-browsing-context>source browsing
+ context</a>. If the <a href=#resolve-a-url>resolve a URL</a> algorithm failed, then the user agent may either
+ instead <a href=#navigate>navigate</a> to an inline error page, using the same replacement behavior and
+ source browsing context behavior as described earlier in this paragraph; or treat the <var title="">url</var> as "<code><a href=#about:blank>about:blank</a></code>", acting as described in the next paragraph.</p>
- <p>If <var title="">url</var> <em>is</em>
- "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing context</a> was just created as
- part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
- browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue
- a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected <a href=#browsing-context>browsing
- context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected
- <a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object's
- <code><a href=#document>Document</a></code> object (and the <code title=dom-event-currentTarget>currentTarget</code> set to the
- <code><a href=#window>Window</a></code> object).</p>
+ <p>If <var title="">url</var> <em>is</em> "<code><a href=#about:blank>about:blank</a></code>", and the <a href=#browsing-context>browsing
+ context</a> was just created as part of <a href=#the-rules-for-choosing-a-browsing-context-given-a-browsing-context-name>the rules for choosing a browsing context given a
+ browsing context name</a>, then the user agent must instead <a href=#queue-a-task>queue a task</a> to
+ <a href=#fire-a-simple-event>fire a simple event</a> named <code title=event-load>load</code> at the selected
+ <a href=#browsing-context>browsing context</a>'s <code><a href=#window>Window</a></code> object, but with its <code title=dom-event-target><a href=#dom-event-target>target</a></code> set to the selected <a href=#browsing-context>browsing context</a>'s
+ <code><a href=#window>Window</a></code> object's <code><a href=#document>Document</a></code> object (and the <code title=dom-event-currentTarget>currentTarget</code> set to the <code><a href=#window>Window</a></code> object).</p>
- <p>The method must return the <code><a href=#windowproxy>WindowProxy</a></code> object of the
- <a href=#browsing-context>browsing context</a> that was navigated, or null if no
- browsing context was navigated.</p>
+ <p>The method must return the <code><a href=#windowproxy>WindowProxy</a></code> object of the <a href=#browsing-context>browsing context</a>
+ that was navigated, or null if no browsing context was navigated.</p>
- <hr><p>The <dfn id=dom-name title=dom-name><code>name</code></dfn> attribute of
- the <code><a href=#window>Window</a></code> object must, on getting, return the current
- <a href=#browsing-context-name title="browsing context name">name</a> of the
- <a href=#browsing-context>browsing context</a>, and, on setting, set the <a href=#browsing-context-name title="browsing context name">name</a> of the <a href=#browsing-context>browsing
- context</a> to the new value.</p>
+ <hr><p>The <dfn id=dom-name title=dom-name><code>name</code></dfn> attribute of the <code><a href=#window>Window</a></code> object
+ must, on getting, return the current <a href=#browsing-context-name title="browsing context name">name</a> of the
+ <a href=#browsing-context>browsing context</a>, and, on setting, set the <a href=#browsing-context-name title="browsing context
+ name">name</a> of the <a href=#browsing-context>browsing context</a> to the new value.</p>
- <p class=note>The name <a href=#resetBCName>gets reset</a> when
- the browsing context is navigated to another domain.</p>
+ <p class=note>The name <a href=#resetBCName>gets reset</a> when the browsing context is
+ navigated to another domain.</p>
- <hr><p>The <dfn id=dom-window-close title=dom-window-close><code>close()</code></dfn>
- method on <code><a href=#window>Window</a></code> objects should, if the corresponding
- <a href=#browsing-context>browsing context</a> <var title="">A</var> is
- <a href=#script-closable>script-closable</a> and the <a href="#script's-browsing-context" title="script's browsing
- context">browsing context</a> of the <a href=#concept-script title=concept-script>script</a> that invokes the method is
- <a href=#allowed-to-navigate>allowed to navigate</a> the <a href=#browsing-context>browsing context</a>
- <var title="">A</var>, <a href=#close-a-browsing-context title="close a browsing
- context">close</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>.</p>
+ <hr><p>The <dfn id=dom-window-close title=dom-window-close><code>close()</code></dfn> method on <code><a href=#window>Window</a></code>
+ objects should, if the corresponding <a href=#browsing-context>browsing context</a> <var title="">A</var> is
+ <a href=#script-closable>script-closable</a> and the <a href="#script's-browsing-context" title="script's browsing context">browsing
+ context</a> of the <a href=#concept-script title=concept-script>script</a> that invokes the method is
+ <a href=#allowed-to-navigate>allowed to navigate</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>, <a href=#close-a-browsing-context title="close a browsing context">close</a> the <a href=#browsing-context>browsing context</a> <var title="">A</var>.</p>
- <p>A <a href=#browsing-context>browsing context</a> is <dfn id=script-closable>script-closable</dfn> if
- it is an <a href=#auxiliary-browsing-context>auxiliary browsing context</a> that was created by
- a script (as opposed to by an action of the user), or if it is a
- <a href=#browsing-context>browsing context</a> whose <a href=#session-history>session history</a>
- contains only one <code><a href=#document>Document</a></code>.</p>
+ <p>A <a href=#browsing-context>browsing context</a> is <dfn id=script-closable>script-closable</dfn> if it is an <a href=#auxiliary-browsing-context>auxiliary
+ browsing context</a> that was created by a script (as opposed to by an action of the user), or
+ if it is a <a href=#browsing-context>browsing context</a> whose <a href=#session-history>session history</a> contains only one
+ <code><a href=#document>Document</a></code>.</p>
- <p>The <dfn id=dom-window-stop title=dom-window-stop><code>stop()</code></dfn> method
- on <code><a href=#window>Window</a></code> objects should, if there is an existing
- attempt to <a href=#navigate>navigate</a> the <a href=#browsing-context>browsing context</a>
- and that attempt is not currently running the <a href=#unload-a-document>unload a
- document</a> algorithm, cancel that <a href=#navigate title=navigate>navigation</a>; then, it must <a href=#abort-a-document title="abort
- a document">abort</a> the <a href=#active-document>active document</a> of the
- <a href=#browsing-context>browsing context</a> of the <code><a href=#window>Window</a></code> object on
- which it was invoked.</p>
+ <p>The <dfn id=dom-window-stop title=dom-window-stop><code>stop()</code></dfn> method on <code><a href=#window>Window</a></code>
+ objects should, if there is an existing attempt to <a href=#navigate>navigate</a> the <a href=#browsing-context>browsing
+ context</a> and that attempt is not currently running the <a href=#unload-a-document>unload a document</a>
+ algorithm, cancel that <a href=#navigate title=navigate>navigation</a>; then, it must <a href=#abort-a-document title="abort
+ a document">abort</a> the <a href=#active-document>active document</a> of the <a href=#browsing-context>browsing context</a> of
+ the <code><a href=#window>Window</a></code> object on which it was invoked.</p>
</div>
@@ -66998,8 +66946,8 @@
<dd>
- <p>Returns the number of <a href=#child-browsing-context title="child browsing
- context">child browsing contexts</a>.</p>
+ <p>Returns the number of <a href=#child-browsing-context title="child browsing context">child browsing
+ contexts</a>.</p>
</dd>
@@ -67013,37 +66961,28 @@
</dl><div class=impl>
- <p>The <dfn id=dom-length title=dom-length><code>length</code></dfn> IDL
- attribute on the <code><a href=#window>Window</a></code> interface must return the
- number of <a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> that are <a href=#browsing-context-nested-through title="browsing context nested
- through">nested through</a> elements that are <a href=#in-a-document title="in a
- document">in the <code>Document</code></a> that is the
- <a href=#active-document>active document</a> of that <code><a href=#window>Window</a></code> object, if
- that <code><a href=#window>Window</a></code>'s <a href=#browsing-context>browsing context</a> shares the
- same <a href=#event-loop>event loop</a> as the <a href="#script's-browsing-context">script's browsing
- context</a> of the <a href=#entry-script>entry script</a> accessing the IDL
- attribute; otherwise, it must return zero.</p>
+ <p>The <dfn id=dom-length title=dom-length><code>length</code></dfn> IDL attribute on the <code><a href=#window>Window</a></code>
+ interface must return the number of <a href=#child-browsing-context title="child browsing context">child browsing
+ contexts</a> that are <a href=#browsing-context-nested-through title="browsing context nested through">nested through</a>
+ elements that are <a href=#in-a-document title="in a document">in the <code>Document</code></a> that is the
+ <a href=#active-document>active document</a> of that <code><a href=#window>Window</a></code> object, if that <code><a href=#window>Window</a></code>'s
+ <a href=#browsing-context>browsing context</a> shares the same <a href=#event-loop>event loop</a> as the <a href="#script's-browsing-context">script's
+ browsing context</a> of the <a href=#entry-script>entry script</a> accessing the IDL attribute; otherwise,
+ it must return zero.</p>
<!-- in other words, frames are only accessible to same-thread processes -->
- <p>The <a href=#supported-property-indices>supported property indices</a> on the
- <code><a href=#window>Window</a></code> object at any instant are the numbers in the
- range 0 .. <span title=""><var title="">n</var>-1</span>, where <var title="">n</var> is the number returned by the <code title=dom-length><a href=#dom-length>length</a></code> IDL attribute. If <var title="">n</var> is zero then there are no <a href=#supported-property-indices>supported property
+ <p>The <a href=#supported-property-indices>supported property indices</a> on the <code><a href=#window>Window</a></code> object at any instant
+ are the numbers in the range 0 .. <span title=""><var title="">n</var>-1</span>, where <var title="">n</var> is the number returned by the <code title=dom-length><a href=#dom-length>length</a></code> IDL
+ attribute. If <var title="">n</var> is zero then there are no <a href=#supported-property-indices>supported property
indices</a>.</p>
- <p>To <dfn id=dom-window-item title=dom-window-item>determine the value of an indexed
- property</dfn> <var title="">index</var> of a <code><a href=#window>Window</a></code>
- object, the user agent must return the <code><a href=#windowproxy>WindowProxy</a></code>
- object of the <var title="">index</var>th <a href=#child-browsing-context>child browsing
- context</a> of the <code><a href=#document>Document</a></code> that is nested through
- an element that is <a href=#in-a-document title="in a document">in the
- <code>Document</code></a>, sorted in the <a href=#tree-order>tree order</a>
- of the elements nesting those <a href=#browsing-context title="browsing
- context">browsing contexts</a>.</p>
+ <p>To <dfn id=dom-window-item title=dom-window-item>determine the value of an indexed property</dfn> <var title="">index</var> of a <code><a href=#window>Window</a></code> object, the user agent must return the
+ <code><a href=#windowproxy>WindowProxy</a></code> object of the <var title="">index</var>th <a href=#child-browsing-context>child browsing
+ context</a> of the <code><a href=#document>Document</a></code> that is nested through an element that is <a href=#in-a-document title="in a document">in the <code>Document</code></a>, sorted in the <a href=#tree-order>tree order</a>
+ of the elements nesting those <a href=#browsing-context title="browsing context">browsing contexts</a>.</p>
- <p>These properties are the <dfn id=dynamic-nested-browsing-context-properties>dynamic nested browsing context
- properties</dfn>.</p>
+ <p>These properties are the <dfn id=dynamic-nested-browsing-context-properties>dynamic nested browsing context properties</dfn>.</p>
</div>
@@ -67061,81 +67000,69 @@
</dl><div class=impl>
- <p>The <code><a href=#window>Window</a></code> interface <a href=#support-named-properties title="support named
- properties">supports named properties</a>. The <a href=#supported-property-names>supported
- property names</a> at any moment consist of:</p>
+ <p>The <code><a href=#window>Window</a></code> interface <a href=#support-named-properties title="support named properties">supports named
+ properties</a>. The <a href=#supported-property-names>supported property names</a> at any moment consist of:</p>
- <ul><li>the <a href=#browsing-context-name>browsing context name</a> of any <a href=#child-browsing-context>child
- browsing context</a> of the <a href=#active-document>active document</a> whose
- name is not the empty string,</li>
+ <ul><li>the <a href=#browsing-context-name>browsing context name</a> of any <a href=#child-browsing-context>child browsing context</a> of the
+ <a href=#active-document>active document</a> whose name is not the empty string,</li>
- <li>the value of the <code title="">name</code> content attribute
- for all <code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>,
- <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>,
- <code><a href=#the-img-element>img</a></code>, and <code><a href=#the-object-element>object</a></code> elements in the
- <a href=#active-document>active document</a> that have a <code title="">name</code>
- content attribute, and</li>
+ <li>the value of the <code title="">name</code> content attribute for all <code><a href=#the-a-element>a</a></code>,
+ <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>, <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>,
+ <code><a href=#frameset>frameset</a></code>, <code><a href=#the-img-element>img</a></code>, and <code><a href=#the-object-element>object</a></code> elements in the <a href=#active-document>active
+ document</a> that have a <code title="">name</code> content attribute, and</li>
- <li>the value of the <code title=attr-id><a href=#the-id-attribute>id</a></code> content
- attribute of any <a href=#html-elements title="HTML elements">HTML element</a> in
- the <a href=#active-document>active document</a> with an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute.</li>
+ <li>the value of the <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute of any <a href=#html-elements title="HTML
+ elements">HTML element</a> in the <a href=#active-document>active document</a> with an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute.</li>
- </ul><p>To <a href=#determine-the-value-of-a-named-property>determine the value of a named property</a> <var title="">name</var> when <dfn id=dom-window-nameditem title=dom-window-namedItem>the
- <code>Window</code> object is indexed for property retrieval</dfn>,
- the user agent must return the value obtained using the following
- steps:</p>
+ </ul><p>To <a href=#determine-the-value-of-a-named-property>determine the value of a named property</a> <var title="">name</var> when <dfn id=dom-window-nameditem title=dom-window-namedItem>the <code>Window</code> object is indexed for property
+ retrieval</dfn>, the user agent must return the value obtained using the following steps:</p>
<ol><!-- http://software.hixie.ch/utilities/js/live-dom-viewer/saved/1716 --><li>
- <p>Let <var title="">objects</var> be the list of <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the
- name <var title="">name</var> in the <a href=#active-document>active document</a>.
+ <p>Let <var title="">objects</var> be the list of <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the name <var title="">name</var>
+ in the <a href=#active-document>active document</a>.
- <p class=note>There will be at least one such object, by
- definition.<!-- (If there wasn't, then this algorithm wouldn't
- have been invoked by Web IDL.) --></p>
+ <p class=note>There will be at least one such object, by definition.<!-- (If there wasn't,
+ then this algorithm wouldn't have been invoked by Web IDL.) --></p>
</li>
<li>
- <p>If <var title="">objects</var> contains a <a href=#nested-browsing-context>nested browsing
- context</a>, then return the <code><a href=#windowproxy>WindowProxy</a></code> object of
- the <a href=#nested-browsing-context>nested browsing context</a> corresponding to the
- first <a href=#browsing-context-container>browsing context container</a> in <a href=#tree-order>tree
- order</a> whose <a href=#browsing-context>browsing context</a> is in <var title="">objects</var>, and abort these steps.</p>
+ <p>If <var title="">objects</var> contains a <a href=#nested-browsing-context>nested browsing context</a>, then return
+ the <code><a href=#windowproxy>WindowProxy</a></code> object of the <a href=#nested-browsing-context>nested browsing context</a> corresponding to
+ the first <a href=#browsing-context-container>browsing context container</a> in <a href=#tree-order>tree order</a> whose
+ <a href=#browsing-context>browsing context</a> is in <var title="">objects</var>, and abort these steps.</p>
</li>
<li>
- <p>Otherwise, if <var title="">elements</var> has only one
- element, return that element and abort these steps.</p>
+ <p>Otherwise, if <var title="">elements</var> has only one element, return that element and
+ abort these steps.</p>
</li>
<li>
- <p>Otherwise return an <code><a href=#htmlcollection>HTMLCollection</a></code> rooted at the
- <code><a href=#document>Document</a></code> node, whose filter matches only <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with the
- name <var title="">name</var>. (By definition, these will all be
- elements.)</p> <!-- the same one each time is returned, because of
- the rule under collections -->
+ <p>Otherwise return an <code><a href=#htmlcollection>HTMLCollection</a></code> rooted at the <code><a href=#document>Document</a></code> node,
+ whose filter matches only <a href=#dom-window-nameditem-filter title=dom-window-namedItem-filter>named objects</a> with
+ the name <var title="">name</var>. (By definition, these will all be elements.)</p> <!-- the
+ same one each time is returned, because of the rule under collections -->
</li>
- </ol><p><dfn id=dom-window-nameditem-filter title=dom-window-nameditem-filter>Named objects</dfn>
- with the name <var title="">name</var>, for the purposes of the
- above algorithm, are those that are either:</p>
+ </ol><p><dfn id=dom-window-nameditem-filter title=dom-window-nameditem-filter>Named objects</dfn> with the name <var title="">name</var>, for the purposes of the above algorithm, are those that are either:</p>
- <ul><li><a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> of the <a href=#active-document>active document</a> whose name is
- <var title="">name</var>,</li>
+ <ul><li><a href=#child-browsing-context title="child browsing context">child browsing contexts</a> of the <a href=#active-document>active
+ document</a> whose name is <var title="">name</var>,</li>
- <li><code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>,
- <code><a href=#the-embed-element>embed</a></code>, <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>,
- <code><a href=#the-img-element>img</a></code>, or <code><a href=#the-object-element>object</a></code> elements that have a <code title=attr-name>name</code> content attribute whose value is <var title="">name</var>, or</li>
+ <li><code><a href=#the-a-element>a</a></code>, <code><a href=#the-applet-element>applet</a></code>, <code><a href=#the-area-element>area</a></code>, <code><a href=#the-embed-element>embed</a></code>,
+ <code><a href=#the-form-element>form</a></code>, <code><a href=#frameset>frameset</a></code>, <code><a href=#the-img-element>img</a></code>, or <code><a href=#the-object-element>object</a></code> elements that
+ have a <code title=attr-name>name</code> content attribute whose value is <var title="">name</var>, or</li>
- <li><a href=#html-elements>HTML elements</a> that have an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute whose value is <var title="">name</var>.</li>
+ <li><a href=#html-elements>HTML elements</a> that have an <code title=attr-id><a href=#the-id-attribute>id</a></code> content attribute
+ whose value is <var title="">name</var>.</li>
</ul></div>
@@ -67144,72 +67071,53 @@
<h4 id=garbage-collection-and-browsing-contexts><span class=secno>6.2.5 </span>Garbage collection and browsing contexts</h4>
- <p>A <a href=#browsing-context>browsing context</a> has a strong reference to each of
- its <code><a href=#document>Document</a></code>s and its <code><a href=#windowproxy>WindowProxy</a></code> object,
- and the user agent itself has a strong reference to its <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing
- contexts</a>.</p>
+ <p>A <a href=#browsing-context>browsing context</a> has a strong reference to each of its <code><a href=#document>Document</a></code>s
+ and its <code><a href=#windowproxy>WindowProxy</a></code> object, and the user agent itself has a strong reference to its
+ <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a>.</p>
- <p>A <code><a href=#document>Document</a></code> has a strong reference to its
- <code><a href=#window>Window</a></code> object.</p>
+ <p>A <code><a href=#document>Document</a></code> has a strong reference to its <code><a href=#window>Window</a></code> object.</p>
- <p class=note>A <code><a href=#window>Window</a></code> object <a href=#implied-strong-reference title="implied
- strong reference">has a strong reference</a> to its
- <code><a href=#document>Document</a></code> object through its <code title=dom-document><a href=#dom-document-0>document</a></code> attribute. Thus, references
- from other scripts to either of those objects will keep both
- alive. Similarly, both <code><a href=#document>Document</a></code> and <code><a href=#window>Window</a></code>
- objects have <a href=#implied-strong-reference title="implied strong reference">implied strong
- references</a> to the <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
+ <p class=note>A <code><a href=#window>Window</a></code> object <a href=#implied-strong-reference title="implied strong reference">has a strong
+ reference</a> to its <code><a href=#document>Document</a></code> object through its <code title=dom-document><a href=#dom-document-0>document</a></code> attribute. Thus, references from other scripts to either of
+ those objects will keep both alive. Similarly, both <code><a href=#document>Document</a></code> and <code><a href=#window>Window</a></code>
+ objects have <a href=#implied-strong-reference title="implied strong reference">implied strong references</a> to the
+ <code><a href=#windowproxy>WindowProxy</a></code> object.</p>
- <p>Each <a href=#concept-script title=concept-script>script</a> has a strong
- reference to its <a href="#script's-browsing-context" title="script's browsing context">browsing
- context</a> and its <a href="#script's-document" title="script's
+ <p>Each <a href=#concept-script title=concept-script>script</a> has a strong reference to its <a href="#script's-browsing-context" title="script's browsing context">browsing context</a> and its <a href="#script's-document" title="script's
document">document</a>.</p>
<!-- discard a document -->
- <p>When a <a href=#browsing-context>browsing context</a> is to <dfn id=discard-a-document>discard a
- <code>Document</code></dfn>, the user agent must run the following
- steps:</p>
+ <p>When a <a href=#browsing-context>browsing context</a> is to <dfn id=discard-a-document>discard a <code>Document</code></dfn>, the user
+ agent must run the following steps:</p>
- <ol><li><p>Set the <code><a href=#document>Document</a></code>'s <var title=concept-document-salvageable><a href=#concept-document-salvageable>salvageable</a></var> state to
- false.</li>
+ <ol><li><p>Set the <code><a href=#document>Document</a></code>'s <var title=concept-document-salvageable><a href=#concept-document-salvageable>salvageable</a></var> state to false.</li>
- <li><p>Run any <a href=#unloading-document-cleanup-steps>unloading document cleanup steps</a> for
- the <code><a href=#document>Document</a></code> that are defined by this specification
- and <a href=#other-applicable-specifications>other applicable specifications</a>.</li>
+ <li><p>Run any <a href=#unloading-document-cleanup-steps>unloading document cleanup steps</a> for the <code><a href=#document>Document</a></code> that
+ are defined by this specification and <a href=#other-applicable-specifications>other applicable specifications</a>.</li>
- <li><p><a href=#abort-a-document title="abort a document">Abort the
- <code>Document</code></a>.</li>
+ <li><p><a href=#abort-a-document title="abort a document">Abort the <code>Document</code></a>.</li>
- <li><p>Remove any <a href=#concept-task title=concept-task>tasks</a>
- associated with the <code><a href=#document>Document</a></code> in any <a href=#task-source>task
- source</a>, without running those tasks.</li>
+ <li><p>Remove any <a href=#concept-task title=concept-task>tasks</a> associated with the
+ <code><a href=#document>Document</a></code> in any <a href=#task-source>task source</a>, without running those tasks.</li>
- <li><p><a href=#a-browsing-context-is-discarded title="a browsing context is discarded">Discard</a>
- all the <a href=#child-browsing-context title="child browsing context">child browsing
- contexts</a> of the <code><a href=#document>Document</a></code>.</li>
+ <li><p><a href=#a-browsing-context-is-discarded title="a browsing context is discarded">Discard</a> all the <a href=#child-browsing-context title="child
+ browsing context">child browsing contexts</a> of the <code><a href=#document>Document</a></code>.</li>
- <li><p>Lose the strong reference from the <code><a href=#document>Document</a></code>'s
- <a href=#browsing-context>browsing context</a> to the
- <code><a href=#document>Document</a></code>.</li>
+ <li><p>Lose the strong reference from the <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>
+ to the <code><a href=#document>Document</a></code>.</li>
- </ol><p class=note>Whenever a <code><a href=#document>Document</a></code> object is <a href=#discard-a-document title="discard a Document">discarded</a>, it is also removed from
- the list of <a href="#the-worker's-documents">the worker's <code>Document</code>s</a> of each
- worker whose list contains that <code><a href=#document>Document</a></code>.</p>
+ </ol><p class=note>Whenever a <code><a href=#document>Document</a></code> object is <a href=#discard-a-document title="discard a
+ Document">discarded</a>, it is also removed from the list of <a href="#the-worker's-documents">the worker's
+ <code>Document</code>s</a> of each worker whose list contains that <code><a href=#document>Document</a></code>.</p>
- <p>When <dfn id=a-browsing-context-is-discarded>a <em><span>browsing context</span></em> is
- discarded</dfn>, the strong reference from the user agent itself to
- the <a href=#browsing-context>browsing context</a> must be severed, and all the
- <code><a href=#document>Document</a></code> objects for all the entries in the
- <a href=#browsing-context>browsing context</a>'s session history must be <a href=#discard-a-document title="discard a document">discarded</a> as well.</p>
+ <p>When <dfn id=a-browsing-context-is-discarded>a <em><span>browsing context</span></em> is discarded</dfn>, the strong reference
+ from the user agent itself to the <a href=#browsing-context>browsing context</a> must be severed, and all the
+ <code><a href=#document>Document</a></code> objects for all the entries in the <a href=#browsing-context>browsing context</a>'s session
+ history must be <a href=#discard-a-document title="discard a document">discarded</a> as well.</p>
- <p>User agents may <a href=#a-browsing-context-is-discarded title="a browsing context is
- discarded">discard</a> <a href=#top-level-browsing-context title="top-level browsing
- context">top-level browsing contexts</a> at any time (typically,
- in response to user requests, e.g. when a user force-closes a window
- containing one or more <a href=#top-level-browsing-context title="top-level browsing
- context">top-level browsing contexts</a>). Other <a href=#browsing-context title="browsing context">browsing contexts</a> must be discarded
- once their <code><a href=#windowproxy>WindowProxy</a></code> object is eligible for garbage
- collection.</p>
+ <p>User agents may <a href=#a-browsing-context-is-discarded title="a browsing context is discarded">discard</a> <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a> at any time (typically, in
+ response to user requests, e.g. when a user force-closes a window containing one or more <a href=#top-level-browsing-context title="top-level browsing context">top-level browsing contexts</a>). Other <a href=#browsing-context title="browsing context">browsing contexts</a> must be discarded once their
+ <code><a href=#windowproxy>WindowProxy</a></code> object is eligible for garbage collection.</p>
</div>
@@ -67286,35 +67194,30 @@
</dl><div class=impl>
- <p>The <dfn id=dom-barprop-visible title=dom-BarProp-visible>visible</dfn> attribute, on
- getting, must return either true or a value determined by the user
- agent to most accurately represent the visibility state of the user
- interface element that the object represents, as described below. On
- setting, the new value must be discarded.</p>
+ <p>The <dfn id=dom-barprop-visible title=dom-BarProp-visible>visible</dfn> attribute, on getting, must return either
+ true or a value determined by the user agent to most accurately represent the visibility state of
+ the user interface element that the object represents, as described below. On setting, the new
+ value must be discarded.</p>
- <p>The following <code><a href=#barprop>BarProp</a></code> objects exist for each
- <code><a href=#document>Document</a></code> object in a <a href=#browsing-context>browsing
- context</a>. Some of the user interface elements represented by
- these objects might have no equivalent in some user agents; for
- those user agents, except when otherwise specified, the object must
- act as if it was present and visible (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute must return
- true).</p>
+ <p>The following <code><a href=#barprop>BarProp</a></code> objects exist for each <code><a href=#document>Document</a></code> object in a
+ <a href=#browsing-context>browsing context</a>. Some of the user interface elements represented by these objects
+ might have no equivalent in some user agents; for those user agents, except when otherwise
+ specified, the object must act as if it was present and visible (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute must return true).</p>
<dl><dt><dfn id=the-location-bar-barprop-object>The location bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a control
- that displays the <a href=#url>URL</a> of the <a href=#active-document>active
- document</a>, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a control that displays the
+ <a href=#url>URL</a> of the <a href=#active-document>active document</a>, or some similar interface concept.</dd>
<dt><dfn id=the-menu-bar-barprop-object>The menu bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a list of
- commands in menu form, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a list of commands in menu form, or some
+ similar interface concept.</dd>
<dt><dfn id=the-personal-bar-barprop-object>The personal bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains links to
- the user's favorite pages, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains links to the user's favorite pages, or
+ some similar interface concept.</dd>
<dt><dfn id=the-scrollbar-barprop-object>The scrollbar <code>BarProp</code> object</dfn></dt>
@@ -67323,56 +67226,42 @@
<dt><dfn id=the-status-bar-barprop-object>The status bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents a user interface element found immediately below or
- after the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code>
- attribute may return false).</dd>
+ <dd>Represents a user interface element found immediately below or after the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute may return false).</dd>
<dt><dfn id=the-toolbar-barprop-object>The toolbar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element found immediately above
- or before the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code>
- attribute may return false).</dd>
+ <dd>Represents the user interface element found immediately above or before the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code title=dom-BarProp-visible><a href=#dom-barprop-visible>visible</a></code> attribute may return false).</dd>
- </dl><p>The <dfn id=dom-window-locationbar title=dom-window-locationbar><code>locationbar</code></dfn>
- attribute must return <a href=#the-location-bar-barprop-object>the location bar <code>BarProp</code>
- object</a>.</p>
+ </dl><p>The <dfn id=dom-window-locationbar title=dom-window-locationbar><code>locationbar</code></dfn> attribute must return
+ <a href=#the-location-bar-barprop-object>the location bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-menubar title=dom-window-menubar><code>menubar</code></dfn>
- attribute must return <a href=#the-menu-bar-barprop-object>the menu bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-menubar title=dom-window-menubar><code>menubar</code></dfn> attribute must return <a href=#the-menu-bar-barprop-object>the
+ menu bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-personalbar title=dom-window-personalbar><code>personalbar</code></dfn>
- attribute must return <a href=#the-personal-bar-barprop-object>the personal bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-personalbar title=dom-window-personalbar><code>personalbar</code></dfn> attribute must return
+ <a href=#the-personal-bar-barprop-object>the personal bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-scrollbars title=dom-window-scrollbars><code>scrollbars</code></dfn>
- attribute must return <a href=#the-scrollbar-barprop-object>the scrollbar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-scrollbars title=dom-window-scrollbars><code>scrollbars</code></dfn> attribute must return
+ <a href=#the-scrollbar-barprop-object>the scrollbar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-statusbar title=dom-window-statusbar><code>statusbar</code></dfn> attribute
- must return <a href=#the-status-bar-barprop-object>the status bar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-statusbar title=dom-window-statusbar><code>statusbar</code></dfn> attribute must return
+ <a href=#the-status-bar-barprop-object>the status bar <code>BarProp</code> object</a>.</p>
- <p>The <dfn id=dom-window-toolbar title=dom-window-toolbar><code>toolbar</code></dfn>
- attribute must return <a href=#the-toolbar-barprop-object>the toolbar <code>BarProp</code>
- object</a>.</p>
+ <p>The <dfn id=dom-window-toolbar title=dom-window-toolbar><code>toolbar</code></dfn> attribute must return <a href=#the-toolbar-barprop-object>the
+ toolbar <code>BarProp</code> object</a>.</p>
<!--
- <p>For legacy reasons, the <dfn
- title="dom-window-directories"><code>directories</code></dfn>
- attribute must also return <span>the personal bar
- <code>BarProp</code> object</span>.</p>
+ <p>For legacy reasons, the <dfn title="dom-window-directories"><code>directories</code></dfn>
+ attribute must also return <span>the personal bar <code>BarProp</code> object</span>.</p>
-->
- <hr><p>For historical reasons, the <dfn id=dom-window-status title=dom-window-status><code>status</code></dfn> attribute on the
- <code><a href=#window>Window</a></code> object must return an empty string on getting,
- and do nothing on setting.</p>
+ <hr><p>For historical reasons, the <dfn id=dom-window-status title=dom-window-status><code>status</code></dfn> attribute
+ on the <code><a href=#window>Window</a></code> object must return an empty string on getting, and do nothing on
+ setting.</p>
</div>
@@ -67383,27 +67272,24 @@
<p>As mentioned earlier, each <a href=#browsing-context>browsing context</a> has a
- <dfn id=windowproxy><code>WindowProxy</code></dfn> object. This object is unusual
- in that all operations that would be performed on it must be
- performed on the <code><a href=#window>Window</a></code> object of the <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a> instead. It is thus
- indistinguishable from that <code><a href=#window>Window</a></code> object in every way
- until the <a href=#browsing-context>browsing context</a> is navigated.</p>
+ <dfn id=windowproxy><code>WindowProxy</code></dfn> object. This object is unusual in that all operations that
+ would be performed on it must be performed on the <code><a href=#window>Window</a></code> object of the <a href=#browsing-context>browsing
+ context</a>'s <a href=#active-document>active document</a> instead. It is thus indistinguishable from that
+ <code><a href=#window>Window</a></code> object in every way until the <a href=#browsing-context>browsing context</a> is navigated.</p>
<p>There is no <code><a href=#windowproxy>WindowProxy</a></code> interface object.</p>
- <p class=note>The <code><a href=#windowproxy>WindowProxy</a></code> object allows scripts
- to act as if each <a href=#browsing-context>browsing context</a> had a single
- <code><a href=#window>Window</a></code> object, while still keeping separate
- <code><a href=#window>Window</a></code> objects for each <code><a href=#document>Document</a></code>.</p>
+ <p class=note>The <code><a href=#windowproxy>WindowProxy</a></code> object allows scripts to act as if each
+ <a href=#browsing-context>browsing context</a> had a single <code><a href=#window>Window</a></code> object, while still keeping
+ separate <code><a href=#window>Window</a></code> objects for each <code><a href=#document>Document</a></code>.</p>
<div class=example>
- <p>In the following example, the variable <var title="">x</var> is
- set to the <code><a href=#windowproxy>WindowProxy</a></code> object returned by the <code title=dom-window><a href=#dom-window>window</a></code> accessor on the global object. All
- of the expressions following the assignment return true, because in
- every respect, the <code><a href=#windowproxy>WindowProxy</a></code> object acts like the
- underlying <code><a href=#window>Window</a></code> object.</p>
+ <p>In the following example, the variable <var title="">x</var> is set to the
+ <code><a href=#windowproxy>WindowProxy</a></code> object returned by the <code title=dom-window><a href=#dom-window>window</a></code> accessor
+ on the global object. All of the expressions following the assignment return true, because in
+ every respect, the <code><a href=#windowproxy>WindowProxy</a></code> object acts like the underlying <code><a href=#window>Window</a></code>
+ object.</p>
<pre>var x = window;
x instanceof Window; // true
@@ -67420,10 +67306,9 @@
<h3 id=origin-0><span class=secno>6.3 </span>Origin</h3>
<!-- Hallowed are the Ori -->
- <p>The <dfn id=origin>origin</dfn> of a resource and the <dfn id=effective-script-origin>effective script
- origin</dfn> of a resource are both either opaque identifiers or
- tuples consisting of a scheme component, a host component, a port
- component, and optionally extra data.</p>
+ <p>The <dfn id=origin>origin</dfn> of a resource and the <dfn id=effective-script-origin>effective script origin</dfn> of a resource
+ are both either opaque identifiers or tuples consisting of a scheme component, a host component, a
+ port component, and optionally extra data.</p>
<p class=note>The extra data could include the certificate of the
site when using encrypted connections, to ensure that if the site's
@@ -67432,13 +67317,10 @@
<div class=impl>
- <p>An <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a>
- can be defined as an <dfn id=concept-origin-alias title=concept-origin-alias>alias</dfn>
- to another <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script
- origin</a>. The value of the <a href=#origin>origin</a> or
- <a href=#effective-script-origin>effective script origin</a> is then the value of the
- <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> to which
- it is an alias.</p>
+ <p>An <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> can be defined as an <dfn id=concept-origin-alias title=concept-origin-alias>alias</dfn> to another <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script
+ origin</a>. The value of the <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> is
+ then the value of the <a href=#origin>origin</a> or <a href=#effective-script-origin>effective script origin</a> to which it is
+ an alias.</p>
<p>These characteristics are defined as follows:</p>
@@ -67446,9 +67328,8 @@
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of the <a href=#url>URL</a> are the origin defined in
- <cite>The Web Origin Concept</cite>. <a href=#refsORIGIN>[ORIGIN]</a></p>
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of the <a href=#url>URL</a> are
+ the origin defined in <cite>The Web Origin Concept</cite>. <a href=#refsORIGIN>[ORIGIN]</a></p>
</dd>
@@ -67457,18 +67338,16 @@
<dd>
- <dl class=switch><dt id=sandboxOrigin>If a <code><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set>active
- sandboxing flag set</a> has its <a href=#sandboxed-origin-browsing-context-flag>sandboxed origin
- browsing context flag</a> set</dt>
+ <dl class=switch><dt id=sandboxOrigin>If a <code><a href=#document>Document</a></code>'s <a href=#active-sandboxing-flag-set>active sandboxing flag set</a> has
+ its <a href=#sandboxed-origin-browsing-context-flag>sandboxed origin browsing context flag</a> set</dt>
<dd>
- <p>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the <code><a href=#document>Document</a></code> is created.</p>
+ <p>The <a href=#origin>origin</a> is a globally unique identifier assigned when the
+ <code><a href=#document>Document</a></code> is created.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
@@ -67479,77 +67358,64 @@
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the script of that <a href=#javascript-protocol title="javascript protocol"><code>javascript:</code>
- URL</a>.</p>
+ <a href=#origin>origin</a> of the script of that <a href=#javascript-protocol title="javascript
+ protocol"><code>javascript:</code> URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was served over the network and
- has an address that uses a URL scheme with a server-based naming
- authority</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was served over the network and has an address that uses a URL
+ scheme with a server-based naming authority</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of <a href="#the-document's-address">the <code>Document</code>'s
- address</a>.</p>
+ <a href=#origin>origin</a> of <a href="#the-document's-address">the <code>Document</code>'s address</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> that
- was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in
- other protocols)</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> that was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in other protocols)</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <a href=#url>URL</a> that redirected to
- the <a href=#data-protocol title="data protocol"><code title="">data:</code>
- URL</a>.</p>
+ <a href=#origin>origin</a> of the <a href=#url>URL</a> that redirected to the <a href=#data-protocol title="data
+ protocol"><code title="">data:</code> URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a>
- found in another <code><a href=#document>Document</a></code> or in a script</dt>
+ <dt>If a <code><a href=#document>Document</a></code> was generated from a <a href=#data-protocol title="data protocol"><code title="">data:</code> URL</a> found in another <code><a href=#document>Document</a></code> or in a script</dt>
<dd>
<p>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> or script that
- initiated the <a href=#navigate title=navigate>navigation</a> to that
- <a href=#url>URL</a>.</p>
+ <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to that <a href=#url>URL</a>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to that <a href=#url>URL</a>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code> or script that initiated the <a href=#navigate title=navigate>navigation</a> to
+ that <a href=#url>URL</a>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> has the <a href="#the-document's-address" title="the
- document's address">address</a>
+ <dt>If a <code><a href=#document>Document</a></code> has the <a href="#the-document's-address" title="the document's address">address</a>
"<code><a href=#about:blank>about:blank</a></code>"</dt>
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of the <code><a href=#document>Document</a></code> are <a href=#about-blank-origin>those it was assigned when its
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code> are <a href=#about-blank-origin>those it was assigned when its
browsing context was created</a>.</p>
</dd>
@@ -67559,41 +67425,34 @@
<dd>
- <p>The <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> is an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>'s
- <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
+ <p>The <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
container</a>'s <code><a href=#document>Document</a></code>.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s
- <a href=#browsing-context-container>browsing context container</a>'s
- <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ <code><a href=#document>Document</a></code>'s <a href=#browsing-context>browsing context</a>'s <a href=#browsing-context-container>browsing context
+ container</a>'s <code><a href=#document>Document</a></code>.</p>
</dd>
- <dt>If a <code><a href=#document>Document</a></code> was obtained in some other manner
- (e.g. a <a href=#data-protocol title="data protocol"><code title="">data:</code>
- URL</a> typed in by the user, a <code><a href=#document>Document</a></code> created
- using the <code title=dom-DOMImplementation-createDocument><a href=#dom-domimplementation-createdocument>createDocument()</a></code>
+ <dt>If a <code><a href=#document>Document</a></code> was obtained in some other manner (e.g. a <a href=#data-protocol title="data
+ protocol"><code title="">data:</code> URL</a> typed in by the user, a <code><a href=#document>Document</a></code>
+ created using the <code title=dom-DOMImplementation-createDocument><a href=#dom-domimplementation-createdocument>createDocument()</a></code>
API, etc)</dt>
<dd>
- <p>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the <code><a href=#document>Document</a></code> is created.</p>
+ <p>The <a href=#origin>origin</a> is a globally unique identifier assigned when the
+ <code><a href=#document>Document</a></code> is created.</p>
- <p>The <a href=#effective-script-origin>effective script origin</a> is initially an
- <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code>.</p>
+ <p>The <a href=#effective-script-origin>effective script origin</a> is initially an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code>.</p>
</dd>
- </dl><p class=note>The <a href=#effective-script-origin>effective script origin</a> of a
- <code><a href=#document>Document</a></code> can be manipulated using the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> IDL
+ </dl><p class=note>The <a href=#effective-script-origin>effective script origin</a> of a <code><a href=#document>Document</a></code> can be
+ manipulated using the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> IDL
attribute.</p>
</dd>
@@ -67603,23 +67462,21 @@
<dd>
- <dl class=switch><dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and
- its image data is <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
+ <dl class=switch><dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and its image data is
+ <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
- <dd>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <a href=#origin>origin</a> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and
- its image data is <a href=#cors-same-origin>CORS-same-origin</a></dt>
+ <dt>If an image is the image of an <code><a href=#the-img-element>img</a></code> element and its image data is
+ <a href=#cors-same-origin>CORS-same-origin</a></dt>
<dd>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#the-img-element>img</a></code> element's
- <code><a href=#document>Document</a></code>.</dd>
+ <a href=#origin>origin</a> of the <code><a href=#the-img-element>img</a></code> element's <code><a href=#document>Document</a></code>.</dd>
- <!-- all image loads go through the "potentially CORS-enabled
- fetch" algorithm so they're all either CORS-cross-origin or
- CORS-same-origin if they succeed at all -->
+ <!-- all image loads go through the "potentially CORS-enabled fetch" algorithm so they're all
+ either CORS-cross-origin or CORS-same-origin if they succeed at all -->
</dl><p>Images do not have an <a href=#effective-script-origin>effective script origin</a>.</p>
@@ -67630,22 +67487,19 @@
<dd>
- <dl class=switch><dt>If the <a href=#media-data>media data</a> is
- <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
+ <dl class=switch><dt>If the <a href=#media-data>media data</a> is <a href=#cors-cross-origin>CORS-cross-origin</a></dt>
- <dd>The <a href=#origin>origin</a> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <a href=#origin>origin</a> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If the <a href=#media-data>media data</a> is
- <a href=#cors-same-origin>CORS-same-origin</a></dt>
+ <dt>If the <a href=#media-data>media data</a> is <a href=#cors-same-origin>CORS-same-origin</a></dt>
<dd>The <a href=#origin>origin</a> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <a href=#media-element>media element</a>'s
- <code><a href=#document>Document</a></code>.</dd>
+ <a href=#origin>origin</a> of the <a href=#media-element>media element</a>'s <code><a href=#document>Document</a></code>.</dd>
- </dl><p><a href=#media-element title="media element">Media elements</a> do not have
- an <a href=#effective-script-origin>effective script origin</a>.</p>
+ </dl><p><a href=#media-element title="media element">Media elements</a> do not have an <a href=#effective-script-origin>effective script
+ origin</a>.</p>
</dd>
@@ -67661,10 +67515,8 @@
own site in some fashion controlled by the data you want to read
-->
- <p>The <a href=#origin>origin</a> of a locally installed system font is
- an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the <code><a href=#document>Document</a></code> in which that
- font is being used.</p>
+ <p>The <a href=#origin>origin</a> of a locally installed system font is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the
+ <code><a href=#document>Document</a></code> in which that font is being used.</p>
<p>Fonts do not have an <a href=#effective-script-origin>effective script origin</a>.</p>
@@ -67675,177 +67527,154 @@
<dd>
- <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script
- origin</a> of a script are determined from another resource,
- called the <i>owner</i>:</p>
+ <p>The <a href=#origin>origin</a> and <a href=#effective-script-origin>effective script origin</a> of a script are determined
+ from another resource, called the <i>owner</i>:</p>
<dl class=switch><dt>If a script is in a <code><a href=#the-script-element>script</a></code> element</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> to which the
- <code><a href=#the-script-element>script</a></code> element belongs.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> to which the <code><a href=#the-script-element>script</a></code> element
+ belongs.</dd>
- <dt>If a script is in an <a href=#event-handler-content-attributes title="event handler content
- attributes">event handler content attribute</a></dt>
+ <dt>If a script is in an <a href=#event-handler-content-attributes title="event handler content attributes">event handler content
+ attribute</a></dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> to which the
- attribute node belongs.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> to which the attribute node belongs.</dd>
- <dt>If a script is a function or other code reference created by
- another script</dt>
+ <dt>If a script is a function or other code reference created by another script</dt>
<dd>The owner is the script that created it.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> that was returned as the
- location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in
- other protocols)</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> that was returned as the location of an HTTP redirect (<a href=#concept-http-equivalent-codes title=concept-http-equivalent-codes>or equivalent</a> in other protocols)</dt>
- <dd>The owner is the <a href=#url>URL</a> that redirected to the
- <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a>.</dd>
+ <dd>The owner is the <a href=#url>URL</a> that redirected to the <a href=#javascript-protocol title="javascript
+ protocol"><code title="">javascript:</code> URL</a>.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> in an attribute</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> in an attribute</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the element on
- which the attribute is found.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the element on which the attribute is found.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> in a style sheet</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> in a style sheet</dt>
<dd>The owner is the <a href=#url>URL</a> of the style sheet.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been provided by the user (e.g. by using a
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been provided by the user (e.g. by using a
<i>bookmarklet</i>)</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the <a href=#browsing-context>browsing
- context</a>'s <a href=#active-document>active document</a>.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the <a href=#browsing-context>browsing context</a>'s <a href=#active-document>active
+ document</a>.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been declared in markup</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been declared in markup</dt>
- <dd>The owner is the <code><a href=#document>Document</a></code> of the element
- (e.g. an <code><a href=#the-a-element>a</a></code> or <code><a href=#the-area-element>area</a></code> element) that
- declared the URL.</dd>
+ <dd>The owner is the <code><a href=#document>Document</a></code> of the element (e.g. an <code><a href=#the-a-element>a</a></code> or
+ <code><a href=#the-area-element>area</a></code> element) that declared the URL.</dd>
- <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code> URL</a> to which a <a href=#browsing-context>browsing
- context</a> is being <a href=#navigate title=navigate>navigated</a>,
- the URL having been provided by script</dt>
+ <dt>If a script is a <a href=#javascript-protocol title="javascript protocol"><code title="">javascript:</code>
+ URL</a> to which a <a href=#browsing-context>browsing context</a> is being <a href=#navigate title=navigate>navigated</a>, the URL having been provided by script</dt>
<dd>The owner is the script that provided the URL.</dd>
- </dl><p>The <a href=#origin>origin</a> of the script is then an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the
- <a href=#origin>origin</a> of the owner, and the <a href=#effective-script-origin>effective script
- origin</a> of the script is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective
- script origin</a> of the owner.</p>
+ </dl><p>The <a href=#origin>origin</a> of the script is then an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#origin>origin</a> of the owner, and the
+ <a href=#effective-script-origin>effective script origin</a> of the script is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a> to the <a href=#effective-script-origin>effective script origin</a> of the
+ owner.</p>
</dd>
- </dl><p>Other specifications can override the above definitions by
- themselves specifying the origin of a particular <a href=#url>URL</a>,
- <code><a href=#document>Document</a></code>, image, <a href=#media-element>media element</a>, font, or
+ </dl><p>Other specifications can override the above definitions by themselves specifying the origin of
+ a particular <a href=#url>URL</a>, <code><a href=#document>Document</a></code>, image, <a href=#media-element>media element</a>, font, or
<a href=#concept-script title=concept-script>script</a>.</p>
<!-- e.g.:
- <p>The <span>origin</span> of a <code>Document</code> object
- returned by the <code>XMLHttpRequest</code> API is an <span
- title="concept-origin-alias">alias</span> to the
- <span>XMLHttpRequest origin</span> of the
- <code>XMLHttpRequest</code> object.</p>
+ <p>The <span>origin</span> of a <code>Document</code> object returned by the
+ <code>XMLHttpRequest</code> API is an <span title="concept-origin-alias">alias</span> to the
+ <span>XMLHttpRequest origin</span> of the <code>XMLHttpRequest</code> object.</p>
-->
- <hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <a href=#origin>origin</a>:</p>
+ <hr><p>The <dfn id=unicode-serialization-of-an-origin>Unicode serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <a href=#origin>origin</a>:</p>
- <ol><li><p>If the <a href=#origin>origin</a> in question is not a
- scheme/host/port tuple, then return the literal string "<code title="">null</code>" and abort these steps.</li>
+ <ol><li><p>If the <a href=#origin>origin</a> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <a href=#origin>origin</a> tuple.</li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <a href=#origin>origin</a>
+ tuple.</li>
<li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</li>
- <li><p>Apply the IDNA ToUnicode algorithm to each component of the
- host part of the <a href=#origin>origin</a> tuple, and append the results
- — each component, in the same order, separated by U+002E FULL
- STOP characters (.) — to <var title="">result</var>. <a href=#refsRFC3490>[RFC3490]</a></li>
+ <li><p>Apply the IDNA ToUnicode algorithm to each component of the host part of the
+ <a href=#origin>origin</a> tuple, and append the results — each component, in the same order,
+ separated by U+002E FULL STOP characters (.) — to <var title="">result</var>. <a href=#refsRFC3490>[RFC3490]</a></li>
- <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <a href=#origin>origin</a> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</li>
+ <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <a href=#origin>origin</a> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var title="">result</var>.</li>
<li><p>Return <var title="">result</var>.</li>
- </ol><p>The <dfn id=ascii-serialization-of-an-origin>ASCII serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <a href=#origin>origin</a>:</p>
+ </ol><p>The <dfn id=ascii-serialization-of-an-origin>ASCII serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <a href=#origin>origin</a>:</p>
- <ol><li><p>If the <a href=#origin>origin</a> in question is not a
- scheme/host/port tuple, then return the literal string "<code title="">null</code>" and abort these steps.</li>
+ <ol><li><p>If the <a href=#origin>origin</a> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <a href=#origin>origin</a> tuple.</li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <a href=#origin>origin</a>
+ tuple.</li>
<li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</li>
<li>
- <p>Apply the IDNA ToASCII algorithm the host part of the
- <a href=#origin>origin</a> tuple, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and append the results <var title="">result</var>.</p>
+ <p>Apply the IDNA ToASCII algorithm the host part of the <a href=#origin>origin</a> tuple, with both
+ the AllowUnassigned and UseSTD3ASCIIRules flags set, and append the results <var title="">result</var>.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then return the empty string and abort these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then return the empty string and abort these steps.
+ <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
- <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <a href=#origin>origin</a> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</li>
+ <li><p>If the port part of the <a href=#origin>origin</a> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <a href=#origin>origin</a> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var title="">result</var>.</li>
<li><p>Return <var title="">result</var>.</li>
- </ol><p>Two <a href=#origin title=origin>origins</a> are said to be the
- <dfn id=same-origin>same origin</dfn> if the following algorithm returns true:</p>
+ </ol><p>Two <a href=#origin title=origin>origins</a> are said to be the <dfn id=same-origin>same origin</dfn> if the
+ following algorithm returns true:</p>
- <ol><li><p>Let <var title="">A</var> be the first <a href=#origin>origin</a>
- being compared, and <var title="">B</var> be the second
- <a href=#origin>origin</a> being compared.</li>
+ <ol><li><p>Let <var title="">A</var> be the first <a href=#origin>origin</a> being compared, and <var title="">B</var> be the second <a href=#origin>origin</a> being compared.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> are both
- opaque identifiers, and their value is equal, then return
- true.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> are both opaque identifiers, and their
+ value is equal, then return true.</li>
- <li><p>Otherwise, if either <var title="">A</var> or <var title="">B</var> or both are opaque identifiers, return
- false.</li>
+ <li><p>Otherwise, if either <var title="">A</var> or <var title="">B</var> or both are opaque
+ identifiers, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have
- scheme components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have scheme components that are not
+ identical, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have host
- components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have host components that are not
+ identical, return false.</li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have port
- components that are not identical, return false.</li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have port components that are not
+ identical, return false.</li>
- <li><p>If either <var title="">A</var> or <var title="">B</var>
- have additional data, but that data is not identical for both,
- return false.</li>
+ <li><p>If either <var title="">A</var> or <var title="">B</var> have additional data, but that
+ data is not identical for both, return false.</li>
<li><p>Return true.</li>
@@ -67860,89 +67689,76 @@
<p>Returns the current domain used for security checks.</p>
- <p>Can be set to a value that removes subdomains, to change the
- <a href=#effective-script-origin>effective script origin</a> to allow pages on other
- subdomains of the same domain (if they do the same thing) to
- access each other.</p>
+ <p>Can be set to a value that removes subdomains, to change the <a href=#effective-script-origin>effective script
+ origin</a> to allow pages on other subdomains of the same domain (if they do the same thing)
+ to access each other.</p>
</dd>
</dl><div class=impl>
- <p>The <dfn id=dom-document-domain title=dom-document-domain><code>domain</code></dfn>
- attribute on <code><a href=#document>Document</a></code> objects must be initialized to
- <a href="#the-document's-domain">the document's domain</a>, if it has one, and the empty
- string otherwise. If the value is an IPv6 address, then the square
- brackets from the host portion of the <a href=#url-host title=url-host><host></a> component must be omitted from
- the attribute's value.</p>
+ <p>The <dfn id=dom-document-domain title=dom-document-domain><code>domain</code></dfn> attribute on
+ <code><a href=#document>Document</a></code> objects must be initialized to <a href="#the-document's-domain">the document's domain</a>, if it has
+ one, and the empty string otherwise. If the value is an IPv6 address, then the square brackets
+ from the host portion of the <a href=#url-host title=url-host><host></a> component must be omitted
+ from the attribute's value.</p>
- <p>On getting, the attribute must return its current value, unless
- the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing context</a>, in
- which case it must return the empty string.</p>
+ <p>On getting, the attribute must return its current value, unless the <code><a href=#document>Document</a></code> has
+ no <a href=#browsing-context>browsing context</a>, in which case it must return the empty string.</p>
<p>On setting, the user agent must run the following algorithm:</p>
<ol><li>
- <p>If the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing
- context</a>, throw a <code><a href=#securityerror>SecurityError</a></code> exception and
- abort these steps.</p>
+ <p>If the <code><a href=#document>Document</a></code> has no <a href=#browsing-context>browsing context</a>, throw a
+ <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps.</p>
</li>
<li>
- <p>If the new value is an IP address, let <var title="">new
- value</var> be the new value. Otherwise, apply the IDNA ToASCII
- algorithm to the new value, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and let <var title="">new value</var>
- be the result of the ToASCII algorithm.</p>
+ <p>If the new value is an IP address, let <var title="">new value</var> be the new value.
+ Otherwise, apply the IDNA ToASCII algorithm to the new value, with both the AllowUnassigned and
+ UseSTD3ASCIIRules flags set, and let <var title="">new value</var> be the result of the ToASCII
+ algorithm.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort
- these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and
+ abort these steps. <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
<li>
- <p>If <var title="">new value</var> is not exactly equal to the
- current value of the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not exactly equal to the current value of the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute, then run these substeps:</p>
<ol><li>
- <p>If the current value is an IP address, throw a
- <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps.</p>
+ <p>If the current value is an IP address, throw a <code><a href=#securityerror>SecurityError</a></code> exception and
+ abort these steps.</p>
</li>
<li>
- <p>If <var title="">new value</var>, prefixed by a U+002E FULL
- STOP (.), does not exactly match the end of the current value,
- throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort these
- steps.</p>
+ <p>If <var title="">new value</var>, prefixed by a U+002E FULL STOP (.), does not exactly
+ match the end of the current value, throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort
+ these steps.</p>
- <!-- this is the step that prevents us from ever setting
- document.domain if the >effective script origin< isn't a
- scheme/host/port tuple -->
+ <!-- this is the step that prevents us from ever setting document.domain if the >effective
+ script origin< isn't a scheme/host/port tuple -->
</li>
<li>
- <p>If <var title="">new value</var> matches a suffix in the
- Public Suffix List, or, if <var title="">new value</var>,
- prefixed by a U+002E FULL STOP (.), matches the end of a
- suffix in the Public Suffix List, then throw a
- <code><a href=#securityerror>SecurityError</a></code> exception and abort these steps. <a href=#refsPSL>[PSL]</a></p>
+ <p>If <var title="">new value</var> matches a suffix in the Public Suffix List, or, if <var title="">new value</var>, prefixed by a U+002E FULL STOP (.), matches the end of a suffix in
+ the Public Suffix List, then throw a <code><a href=#securityerror>SecurityError</a></code> exception and abort these
+ steps. <a href=#refsPSL>[PSL]</a></p>
- <p>Suffixes must be compared after applying the IDNA ToASCII
- algorithm to them, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, in an <a href=#ascii-case-insensitive>ASCII
- case-insensitive</a> manner. <a href=#refsRFC3490>[RFC3490]</a></p>
+ <p>Suffixes must be compared after applying the IDNA ToASCII algorithm to them, with both the
+ AllowUnassigned and UseSTD3ASCIIRules flags set, in an <a href=#ascii-case-insensitive>ASCII case-insensitive</a>
+ manner. <a href=#refsRFC3490>[RFC3490]</a></p>
</li>
@@ -67958,57 +67774,47 @@
<li>
- <p>If the <a href=#effective-script-origin>effective script origin</a> of the
- <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a>, set it to the value of
- the <a href=#effective-script-origin>effective script origin</a> (essentially de-aliasing
- the <a href=#effective-script-origin>effective script origin</a>).</p>
+ <p>If the <a href=#effective-script-origin>effective script origin</a> of the <code><a href=#document>Document</a></code> is an <a href=#concept-origin-alias title=concept-origin-alias>alias</a>, set it to the value of the <a href=#effective-script-origin>effective script
+ origin</a> (essentially de-aliasing the <a href=#effective-script-origin>effective script origin</a>).</p>
</li>
<li>
- <p>If <var title="">new value</var> is not the empty string, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not the empty string, then2 run these substeps:</p>
<ol><li>
- <p>Set the host part of the <a href=#effective-script-origin>effective script origin</a>
- tuple of the <code><a href=#document>Document</a></code> to <var title="">new
- value</var>.</p>
+ <p>Set the host part of the <a href=#effective-script-origin>effective script origin</a> tuple of the
+ <code><a href=#document>Document</a></code> to <var title="">new value</var>.</p>
</li>
<li>
- <p>Set the port part of the <a href=#effective-script-origin>effective script origin</a>
- tuple of the <code><a href=#document>Document</a></code> to "manual override" (a value
- that, for the purposes of <a href=#same-origin title="same origin">comparing
- origins</a>, is identical to "manual override" but not
+ <p>Set the port part of the <a href=#effective-script-origin>effective script origin</a> tuple of the
+ <code><a href=#document>Document</a></code> to "manual override" (a value that, for the purposes of <a href=#same-origin title="same origin">comparing origins</a>, is identical to "manual override" but not
identical to any other value).</p>
</li>
</ol></li>
- </ol><p>The <dfn id="the-document's-domain" title="the document's domain">domain</dfn> of a
- <code><a href=#document>Document</a></code> is the host part of the document's
- <a href=#origin>origin</a>, if the value of that <a href=#origin>origin</a> is a
- scheme/host/port tuple. If it isn't, then the document does not have
- a domain.</p>
+ </ol><p>The <dfn id="the-document's-domain" title="the document's domain">domain</dfn> of a <code><a href=#document>Document</a></code> is the host part
+ of the document's <a href=#origin>origin</a>, if the value of that <a href=#origin>origin</a> is a
+ scheme/host/port tuple. If it isn't, then the document does not have a domain.</p>
</div>
- <p class=note>The <code title=dom-document-domain><a href=#dom-document-domain>domain</a></code>
- attribute is used to enable pages on different hosts of a domain to
- access each others' DOMs.</p>
+ <p class=note>The <code title=dom-document-domain><a href=#dom-document-domain>domain</a></code> attribute is used to enable
+ pages on different hosts of a domain to access each others' DOMs.</p>
- <p class=warning>Do not use the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute when
- using shared hosting. If an untrusted third party is able to host an
- HTTP server at the same IP address but on a different port, then the
- same-origin protection that normally protects two different sites on
- the same host will fail, as the ports are ignored when comparing
- origins after the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute has
- been used.</p>
+ <p class=warning>Do not use the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code>
+ attribute when using shared hosting. If an untrusted third party is able to host an HTTP server at
+ the same IP address but on a different port, then the same-origin protection that normally
+ protects two different sites on the same host will fail, as the ports are ignored when comparing
+ origins after the <code title=dom-document-domain><a href=#dom-document-domain>document.domain</a></code> attribute has been
+ used.</p>
<!--TOPIC:HTML-->
Modified: source
===================================================================
--- source 2013-01-25 23:49:43 UTC (rev 7649)
+++ source 2013-01-25 23:54:13 UTC (rev 7650)
@@ -77185,23 +77185,18 @@
<li><p>Let <var title="">items</var> be an empty array.</p></li>
- <li><p>For each <var title="">node</var> in <var
- title="">nodes</var>, check if the element is a <span
- title="top-level microdata items">top-level microdata item</span>,
- and if it is then <span>get the object</span> for that element and
- add it to <var title="">items</var>.</p></li>
+ <li><p>For each <var title="">node</var> in <var title="">nodes</var>, check if the element is a
+ <span title="top-level microdata items">top-level microdata item</span>, and if it is then
+ <span>get the object</span> for that element and add it to <var title="">items</var>.</p></li>
- <li><p>Add an entry to <var title="">result</var> called "<code
- title="">items</code>" whose value is the array <var
- title="">items</var>.</p></li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">items</code>" whose
+ value is the array <var title="">items</var>.</p></li>
- <li><p>Return the result of serializing <var title="">result</var>
- to JSON in the shortest possible way (meaning no whitespace between
- tokens, no unnecessary zero digits in numbers, and only using
- Unicode escapes in strings for characters that do not have a
- dedicated escape sequence), and with a lowercase "<code
- title="">e</code>" used, when appropriate, in the representation of
- any numbers. <a href="#refsJSON">[JSON]</a></p></li>
+ <li><p>Return the result of serializing <var title="">result</var> to JSON in the shortest
+ possible way (meaning no whitespace between tokens, no unnecessary zero digits in numbers, and
+ only using Unicode escapes in strings for characters that do not have a dedicated escape
+ sequence), and with a lowercase "<code title="">e</code>" used, when appropriate, in the
+ representation of any numbers. <a href="#refsJSON">[JSON]</a></p></li>
</ol>
@@ -77217,63 +77212,50 @@
<li><p>Let <var title="">result</var> be an empty object.</p></li>
- <li><p>Add <var title="">item</var> to <var
- title="">memory</var>.</p></li>
+ <li><p>Add <var title="">item</var> to <var title="">memory</var>.</p></li>
- <li><p>If the <var title="">item</var> has any <span>item
- types</span>, add an entry to <var title="">result</var> called
- "<code title="">type</code>" whose value is an array listing the
- <span>item types</span> of <var title="">item</var>, in the order
- they were specified on the <code
- title="attr-itemtype">itemtype</code> attribute.</p>
+ <li><p>If the <var title="">item</var> has any <span>item types</span>, add an entry to <var
+ title="">result</var> called "<code title="">type</code>" whose value is an array listing the
+ <span>item types</span> of <var title="">item</var>, in the order they were specified on the
+ <code title="attr-itemtype">itemtype</code> attribute.</p>
- <li><p>If the <var title="">item</var> has a <span>global
- identifier</span>, add an entry to <var title="">result</var>
- called "<code title="">id</code>" whose value is the <span>global
+ <li><p>If the <var title="">item</var> has a <span>global identifier</span>, add an entry to <var
+ title="">result</var> called "<code title="">id</code>" whose value is the <span>global
identifier</span> of <var title="">item</var>.</p></li>
- <li><p>Let <var title="">properties</var> be an empty
- object.</p></li>
+ <li><p>Let <var title="">properties</var> be an empty object.</p></li>
<li>
- <p>For each element <var title="">element</var> that has one or
- more <span>property names</span> and is one of <span title="the
- properties of an item">the properties of the item</span> <var
- title="">item</var>, in the order those elements are given by the
- algorithm that returns <span>the properties of an item</span>, run
- the following substeps:</p>
+ <p>For each element <var title="">element</var> that has one or more <span>property names</span>
+ and is one of <span title="the properties of an item">the properties of the item</span> <var
+ title="">item</var>, in the order those elements are given by the algorithm that returns
+ <span>the properties of an item</span>, run the following substeps:</p>
<ol>
- <li><p>Let <var title="">value</var> be the <span
- title="concept-property-value">property value</span> of <var
- title="">element</var>.</p></li>
+ <li><p>Let <var title="">value</var> be the <span title="concept-property-value">property
+ value</span> of <var title="">element</var>.</p></li>
- <li><p>If <var title="">value</var> is an <span
- title="concept-item">item</span>, then: If <var
- title="">value</var> is in <var title="">memory</var>, then let
- <var title="">value</var> be the string "<code
- title="">ERROR</code>". Otherwise, <span>get the object</span>
- for <var title="">value</var>, passing a copy of <var
- title="">memory</var>, and then replace <var title="">value</var>
- with the object returned from those steps.</p></li>
+ <li><p>If <var title="">value</var> is an <span title="concept-item">item</span>, then: If <var
+ title="">value</var> is in <var title="">memory</var>, then let <var title="">value</var> be
+ the string "<code title="">ERROR</code>". Otherwise, <span>get the object</span> for <var
+ title="">value</var>, passing a copy of <var title="">memory</var>, and then replace <var
+ title="">value</var> with the object returned from those steps.</p></li>
<li>
- <p>For each name <var title="">name</var> in <var
- title="">element</var>'s <span>property names</span>, run the
- following substeps:</p>
+ <p>For each name <var title="">name</var> in <var title="">element</var>'s <span>property
+ names</span>, run the following substeps:</p>
<ol>
- <li><p>If there is no entry named <var title="">name</var> in
- <var title="">properties</var>, then add an entry named <var
- title="">name</var> to <var title="">properties</var> whose
+ <li><p>If there is no entry named <var title="">name</var> in <var title="">properties</var>,
+ then add an entry named <var title="">name</var> to <var title="">properties</var> whose
value is an empty array.</p></li>
- <li><p>Append <var title="">value</var> to the entry named <var
- title="">name</var> in <var title="">properties</var>.</p></li>
+ <li><p>Append <var title="">value</var> to the entry named <var title="">name</var> in <var
+ title="">properties</var>.</p></li>
</ol>
@@ -77283,9 +77265,8 @@
</li>
- <li><p>Add an entry to <var title="">result</var> called "<code
- title="">properties</code>" whose value is the object <var
- title="">properties</var>.</p></li>
+ <li><p>Add an entry to <var title="">result</var> called "<code title="">properties</code>" whose
+ value is the object <var title="">properties</var>.</p></li>
<li><p>Return <var title="">result</var>.</p></li>
@@ -78142,33 +78123,26 @@
<div class="impl">
- <p>The <code>Window</code> interface must only be <span
- title="expose">exposed</span> if the <span>JavaScript global
- environment</span> is a <span>document environment</span>.</p>
+ <p>The <code>Window</code> interface must only be <span title="expose">exposed</span> if the
+ <span>JavaScript global environment</span> is a <span>document environment</span>.</p>
<p>The <dfn title="dom-window"><code>window</code></dfn>, <dfn
- title="dom-frames"><code>frames</code></dfn>, and <dfn
- title="dom-self"><code>self</code></dfn> IDL attributes must all
- return the <code>Window</code> object's <span>browsing
- context</span>'s <code>WindowProxy</code> object.</p>
+ title="dom-frames"><code>frames</code></dfn>, and <dfn title="dom-self"><code>self</code></dfn>
+ IDL attributes must all return the <code>Window</code> object's <span>browsing context</span>'s
+ <code>WindowProxy</code> object.</p>
- <p>The <dfn title="dom-document"><code>document</code></dfn> IDL
- attribute must return the <code>Document</code> object of the
- <code>Window</code> object's <code>Document</code>'s <span>browsing
- context</span>'s <span>active document</span>.</p>
+ <p>The <dfn title="dom-document"><code>document</code></dfn> IDL attribute must return the
+ <code>Document</code> object of the <code>Window</code> object's <code>Document</code>'s
+ <span>browsing context</span>'s <span>active document</span>.</p>
- <p>The <dfn
- title="dom-document-defaultView"><code>defaultView</code></dfn> IDL
- attribute of the <code>Document</code> interface must return the
- <code>Document</code>'s <span>browsing context</span>'s
- <code>WindowProxy</code> object, if there is one, or null
- otherwise.</p>
+ <p>The <dfn title="dom-document-defaultView"><code>defaultView</code></dfn> IDL attribute of the
+ <code>Document</code> interface must return the <code>Document</code>'s <span>browsing
+ context</span>'s <code>WindowProxy</code> object, if there is one, or null otherwise.</p>
<hr>
- <p>For historical reasons, <code>Window</code> objects must also
- have a writable, configurable, non-enumerable property named
- <dfn><code>HTMLDocument</code></dfn> whose value is the
+ <p>For historical reasons, <code>Window</code> objects must also have a writable, configurable,
+ non-enumerable property named <dfn><code>HTMLDocument</code></dfn> whose value is the
<code>Document</code> interface object.</p>
</div>
@@ -78204,30 +78178,25 @@
</ul>
- <p>When a script whose <span>effective script origin</span> is not
- the same as the <code>Window</code> object's <code>Document</code>'s
- <span>effective script origin</span> attempts to access that
- <code>Window</code> object's methods or attributes, the user agent
- must act as if any changes to the <code>Window</code> object's
- properties, getters, setters, etc, were not present.</p>
+ <p>When a script whose <span>effective script origin</span> is not the same as the
+ <code>Window</code> object's <code>Document</code>'s <span>effective script origin</span> attempts
+ to access that <code>Window</code> object's methods or attributes, the user agent must act as if
+ any changes to the <code>Window</code> object's properties, getters, setters, etc, were not
+ present.</p>
- <p>For members that return objects (including function objects),
- each distinct <span>effective script origin</span> that is not the
- same as the <code>Window</code> object's <code>Document</code>'s
- <span>effective script origin</span> must be provided with a
- separate set of objects. These objects must have the prototype chain
- appropriate for the script for which the objects are created (not
- those that would be appropriate for scripts whose <span>script's
- global object</span> is the <code>Window</code> object in
- question).</p>
+ <p>For members that return objects (including function objects), each distinct <span>effective
+ script origin</span> that is not the same as the <code>Window</code> object's
+ <code>Document</code>'s <span>effective script origin</span> must be provided with a separate set
+ of objects. These objects must have the prototype chain appropriate for the script for which the
+ objects are created (not those that would be appropriate for scripts whose <span>script's global
+ object</span> is the <code>Window</code> object in question).</p>
<div class="example">
- <p>For instance, if two frames containing <code>Document</code>s
- from different <span title="origin">origins</span> access the same
- <code>Window</code> object's <code
- title="dom-window-postMessage">postMessage()</code> method, they
- will get distinct objects that are not equal.</p>
+ <p>For instance, if two frames containing <code>Document</code>s from different <span
+ title="origin">origins</span> access the same <code>Window</code> object's <code
+ title="dom-window-postMessage">postMessage()</code> method, they will get distinct objects that
+ are not equal.</p>
</div>
@@ -78244,14 +78213,11 @@
<dd>
- <p>Opens a window to show <var title="">url</var> (defaults to
- <code>about:blank</code>), and returns it. The <var
- title="">target</var> argument gives the name of the new
- window. If a window exists with that name already, it is
- reused. The <var title="">replace</var> attribute, if true, means
- that whatever page is currently open in that window will be
- removed from the window's session history. The <var
- title="">features</var> argument is ignored.</p>
+ <p>Opens a window to show <var title="">url</var> (defaults to <code>about:blank</code>), and
+ returns it. The <var title="">target</var> argument gives the name of the new window. If a
+ window exists with that name already, it is reused. The <var title="">replace</var> attribute,
+ if true, means that whatever page is currently open in that window will be removed from the
+ window's session history. The <var title="">features</var> argument is ignored.</p>
</dd>
@@ -78287,146 +78253,110 @@
<!-- This whole section should be rewritten to use algorithmic style -->
- <p>The <dfn title="dom-open"><code>open()</code></dfn> method on
- <code>Window</code> objects provides a mechanism for <span
- title="navigate">navigating</span> an existing <span>browsing
- context</span> or opening and navigating an <span>auxiliary browsing
- context</span>.</p>
+ <p>The <dfn title="dom-open"><code>open()</code></dfn> method on <code>Window</code> objects
+ provides a mechanism for <span title="navigate">navigating</span> an existing <span>browsing
+ context</span> or opening and navigating an <span>auxiliary browsing context</span>.</p>
<p>The method has four arguments, though they are all optional.</p>
- <p>The first argument, <var title="">url</var>, must be a
- <span>valid non-empty URL</span> for a page to load in the browsing
- context. If no arguments are provided, or if the first argument is
- the empty string, then the <var title="">url</var> argument defaults
- to "<code>about:blank</code>". The argument must be <span
- title="resolve a url">resolved</span> to an <span>absolute
- URL</span> (or an error), relative to the <span>entry
- script</span>'s <span title="script's base URL">base URL</span>,
- when the method is invoked.</p>
+ <p>The first argument, <var title="">url</var>, must be a <span>valid non-empty URL</span> for a
+ page to load in the browsing context. If no arguments are provided, or if the first argument is
+ the empty string, then the <var title="">url</var> argument defaults to
+ "<code>about:blank</code>". The argument must be <span title="resolve a url">resolved</span> to an
+ <span>absolute URL</span> (or an error), relative to the <span>entry script</span>'s <span
+ title="script's base URL">base URL</span>, when the method is invoked.</p>
- <p>The second argument, <var title="">target</var>, specifies the
- <span title="browsing context name">name</span> of the browsing
- context that is to be navigated. It must be a <span>valid browsing
- context name or keyword</span>. If fewer than two arguments are
- provided, then the <var title="">target</var> argument defaults to the
- value "<code>_blank</code>".</p>
+ <p>The second argument, <var title="">target</var>, specifies the <span title="browsing context
+ name">name</span> of the browsing context that is to be navigated. It must be a <span>valid
+ browsing context name or keyword</span>. If fewer than two arguments are provided, then the <var
+ title="">target</var> argument defaults to the value "<code>_blank</code>".</p>
- <p>The third argument, <var title="">features</var>, has no defined
- effect and is mentioned for historical reasons only. User agents may
- interpret this argument as instructions to set the size and position
- of the browsing context, but are encouraged to instead ignore the
- argument entirely.</p>
+ <p>The third argument, <var title="">features</var>, has no defined effect and is mentioned for
+ historical reasons only. User agents may interpret this argument as instructions to set the size
+ and position of the browsing context, but are encouraged to instead ignore the argument
+ entirely.</p>
- <p>The fourth argument, <var title="">replace</var>, specifies
- whether or not the new page will <span title="replacement
- enabled">replace</span> the page currently loaded in the browsing
- context, when <var title="">target</var> identifies an existing
- browsing context (as opposed to leaving the current page in the
- browsing context's <span>session history</span>). When three or
- fewer arguments are provided, <var title="">replace</var> defaults
- to false.</p>
+ <p>The fourth argument, <var title="">replace</var>, specifies whether or not the new page will
+ <span title="replacement enabled">replace</span> the page currently loaded in the browsing
+ context, when <var title="">target</var> identifies an existing browsing context (as opposed to
+ leaving the current page in the browsing context's <span>session history</span>). When three or
+ fewer arguments are provided, <var title="">replace</var> defaults to false.</p>
- <p>When the method is invoked, the user agent must first select a
- <span>browsing context</span> to navigate by applying <span>the
- rules for choosing a browsing context given a browsing context
- name</span> using the <var title="">target</var> argument as the
- name and the <span>browsing context</span> of the script as the
- context in which the algorithm is executed, unless the user has
- indicated a preference, in which case the browsing context to
- navigate may instead be the one indicated by the user.</p>
+ <p>When the method is invoked, the user agent must first select a <span>browsing context</span> to
+ navigate by applying <span>the rules for choosing a browsing context given a browsing context
+ name</span> using the <var title="">target</var> argument as the name and the <span>browsing
+ context</span> of the script as the context in which the algorithm is executed, unless the user
+ has indicated a preference, in which case the browsing context to navigate may instead be the one
+ indicated by the user.</p>
- <p class="example">For example, suppose there is a user agent that
- supports control-clicking a link to open it in a new tab. If a user
- clicks in that user agent on an element whose <code
+ <p class="example">For example, suppose there is a user agent that supports control-clicking a
+ link to open it in a new tab. If a user clicks in that user agent on an element whose <code
title="handler-onclick">onclick</code> handler uses the <code
- title="dom-open">window.open()</code> API to open a page in an
- iframe, but, while doing so, holds the control key down, the user
- agent could override the selection of the target browsing context to
- instead target a new tab.</p>
+ title="dom-open">window.open()</code> API to open a page in an iframe, but, while doing so, holds
+ the control key down, the user agent could override the selection of the target browsing context
+ to instead target a new tab.</p>
<p>If applying <span>the rules for choosing a browsing context given a browsing context
name</span> using the <var title="">target</var> argument would result in there not being a chosen
browsing context, then throw an <code>InvalidAccessError</code> exception and abort these
steps.</p>
- <p>Otherwise, if <var title="">url</var> is not
- "<code>about:blank</code>", the user agent must
- <span>navigate</span><!--DONAV window.open()--> the selected
- <span>browsing context</span> to the <span>absolute URL</span>
- obtained from <span title="resolve a url">resolving</span> <var
- title="">url</var> earlier. If the <var title="">replace</var> is
- true or if the <span>browsing context</span> was just created as
- part of <span>the rules for choosing a browsing context given a
- browsing context name</span>, then <span title="replacement
- enabled">replacement must be enabled</span>. The navigation must be
- done with the <span title="script's browsing context">browsing
- context</span> of the <span>entry script</span> as the <span>source
- browsing context</span>. If the <span>resolve a URL</span> algorithm
- failed, then the user agent may either instead <span>navigate</span>
- to an inline error page, using the same replacement behavior and
- source browsing context behavior as described earlier in this
- paragraph; or treat the <var title="">url</var> as
- "<code>about:blank</code>", acting as described in the next
- paragraph.</p>
+ <p>Otherwise, if <var title="">url</var> is not "<code>about:blank</code>", the user agent must
+ <span>navigate</span><!--DONAV window.open()--> the selected <span>browsing context</span> to the
+ <span>absolute URL</span> obtained from <span title="resolve a url">resolving</span> <var
+ title="">url</var> earlier. If the <var title="">replace</var> is true or if the <span>browsing
+ context</span> was just created as part of <span>the rules for choosing a browsing context given a
+ browsing context name</span>, then <span title="replacement enabled">replacement must be
+ enabled</span>. The navigation must be done with the <span title="script's browsing
+ context">browsing context</span> of the <span>entry script</span> as the <span>source browsing
+ context</span>. If the <span>resolve a URL</span> algorithm failed, then the user agent may either
+ instead <span>navigate</span> to an inline error page, using the same replacement behavior and
+ source browsing context behavior as described earlier in this paragraph; or treat the <var
+ title="">url</var> as "<code>about:blank</code>", acting as described in the next paragraph.</p>
- <p>If <var title="">url</var> <em>is</em>
- "<code>about:blank</code>", and the <span>browsing context</span> was just created as
- part of <span>the rules for choosing a browsing context given a
- browsing context name</span>, then the user agent must instead <span>queue
- a task</span> to <span>fire a simple event</span> named <code
- title="event-load">load</code> at the selected <span>browsing
- context</span>'s <code>Window</code> object, but with its <code
- title="dom-event-target">target</code> set to the selected
- <span>browsing context</span>'s <code>Window</code> object's
- <code>Document</code> object (and the <code
- title="dom-event-currentTarget">currentTarget</code> set to the
- <code>Window</code> object).</p>
+ <p>If <var title="">url</var> <em>is</em> "<code>about:blank</code>", and the <span>browsing
+ context</span> was just created as part of <span>the rules for choosing a browsing context given a
+ browsing context name</span>, then the user agent must instead <span>queue a task</span> to
+ <span>fire a simple event</span> named <code title="event-load">load</code> at the selected
+ <span>browsing context</span>'s <code>Window</code> object, but with its <code
+ title="dom-event-target">target</code> set to the selected <span>browsing context</span>'s
+ <code>Window</code> object's <code>Document</code> object (and the <code
+ title="dom-event-currentTarget">currentTarget</code> set to the <code>Window</code> object).</p>
- <p>The method must return the <code>WindowProxy</code> object of the
- <span>browsing context</span> that was navigated, or null if no
- browsing context was navigated.</p>
+ <p>The method must return the <code>WindowProxy</code> object of the <span>browsing context</span>
+ that was navigated, or null if no browsing context was navigated.</p>
<hr>
- <p>The <dfn title="dom-name"><code>name</code></dfn> attribute of
- the <code>Window</code> object must, on getting, return the current
- <span title="browsing context name">name</span> of the
- <span>browsing context</span>, and, on setting, set the <span
- title="browsing context name">name</span> of the <span>browsing
- context</span> to the new value.</p>
+ <p>The <dfn title="dom-name"><code>name</code></dfn> attribute of the <code>Window</code> object
+ must, on getting, return the current <span title="browsing context name">name</span> of the
+ <span>browsing context</span>, and, on setting, set the <span title="browsing context
+ name">name</span> of the <span>browsing context</span> to the new value.</p>
- <p class="note">The name <a href="#resetBCName">gets reset</a> when
- the browsing context is navigated to another domain.</p>
+ <p class="note">The name <a href="#resetBCName">gets reset</a> when the browsing context is
+ navigated to another domain.</p>
<hr>
- <p>The <dfn title="dom-window-close"><code>close()</code></dfn>
- method on <code>Window</code> objects should, if the corresponding
- <span>browsing context</span> <var title="">A</var> is
- <span>script-closable</span> and the <span title="script's browsing
- context">browsing context</span> of the <span
- title="concept-script">script</span> that invokes the method is
- <span>allowed to navigate</span> the <span>browsing context</span>
- <var title="">A</var>, <span title="close a browsing
- context">close</span> the <span>browsing context</span> <var
+ <p>The <dfn title="dom-window-close"><code>close()</code></dfn> method on <code>Window</code>
+ objects should, if the corresponding <span>browsing context</span> <var title="">A</var> is
+ <span>script-closable</span> and the <span title="script's browsing context">browsing
+ context</span> of the <span title="concept-script">script</span> that invokes the method is
+ <span>allowed to navigate</span> the <span>browsing context</span> <var title="">A</var>, <span
+ title="close a browsing context">close</span> the <span>browsing context</span> <var
title="">A</var>.</p>
- <p>A <span>browsing context</span> is <dfn>script-closable</dfn> if
- it is an <span>auxiliary browsing context</span> that was created by
- a script (as opposed to by an action of the user), or if it is a
- <span>browsing context</span> whose <span>session history</span>
- contains only one <code>Document</code>.</p>
+ <p>A <span>browsing context</span> is <dfn>script-closable</dfn> if it is an <span>auxiliary
+ browsing context</span> that was created by a script (as opposed to by an action of the user), or
+ if it is a <span>browsing context</span> whose <span>session history</span> contains only one
+ <code>Document</code>.</p>
- <p>The <dfn title="dom-window-stop"><code>stop()</code></dfn> method
- on <code>Window</code> objects should, if there is an existing
- attempt to <span>navigate</span> the <span>browsing context</span>
- and that attempt is not currently running the <span>unload a
- document</span> algorithm, cancel that <span
- title="navigate">navigation</span>; then, it must <span title="abort
- a document">abort</span> the <span>active document</span> of the
- <span>browsing context</span> of the <code>Window</code> object on
- which it was invoked.</p>
+ <p>The <dfn title="dom-window-stop"><code>stop()</code></dfn> method on <code>Window</code>
+ objects should, if there is an existing attempt to <span>navigate</span> the <span>browsing
+ context</span> and that attempt is not currently running the <span>unload a document</span>
+ algorithm, cancel that <span title="navigate">navigation</span>; then, it must <span title="abort
+ a document">abort</span> the <span>active document</span> of the <span>browsing context</span> of
+ the <code>Window</code> object on which it was invoked.</p>
</div>
@@ -78439,8 +78369,8 @@
<dd>
- <p>Returns the number of <span title="child browsing
- context">child browsing contexts</span>.</p>
+ <p>Returns the number of <span title="child browsing context">child browsing
+ contexts</span>.</p>
</dd>
@@ -78456,40 +78386,31 @@
<div class="impl">
- <p>The <dfn title="dom-length"><code>length</code></dfn> IDL
- attribute on the <code>Window</code> interface must return the
- number of <span title="child browsing context">child browsing
- contexts</span> that are <span title="browsing context nested
- through">nested through</span> elements that are <span title="in a
- document">in the <code>Document</code></span> that is the
- <span>active document</span> of that <code>Window</code> object, if
- that <code>Window</code>'s <span>browsing context</span> shares the
- same <span>event loop</span> as the <span>script's browsing
- context</span> of the <span>entry script</span> accessing the IDL
- attribute; otherwise, it must return zero.</p>
+ <p>The <dfn title="dom-length"><code>length</code></dfn> IDL attribute on the <code>Window</code>
+ interface must return the number of <span title="child browsing context">child browsing
+ contexts</span> that are <span title="browsing context nested through">nested through</span>
+ elements that are <span title="in a document">in the <code>Document</code></span> that is the
+ <span>active document</span> of that <code>Window</code> object, if that <code>Window</code>'s
+ <span>browsing context</span> shares the same <span>event loop</span> as the <span>script's
+ browsing context</span> of the <span>entry script</span> accessing the IDL attribute; otherwise,
+ it must return zero.</p>
<!-- in other words, frames are only accessible to same-thread processes -->
- <p>The <span>supported property indices</span> on the
- <code>Window</code> object at any instant are the numbers in the
- range 0 .. <span title=""><var title="">n</var>-1</span>, where <var
- title="">n</var> is the number returned by the <code
- title="dom-length">length</code> IDL attribute. If <var
- title="">n</var> is zero then there are no <span>supported property
+ <p>The <span>supported property indices</span> on the <code>Window</code> object at any instant
+ are the numbers in the range 0 .. <span title=""><var title="">n</var>-1</span>, where <var
+ title="">n</var> is the number returned by the <code title="dom-length">length</code> IDL
+ attribute. If <var title="">n</var> is zero then there are no <span>supported property
indices</span>.</p>
- <p>To <dfn title="dom-window-item">determine the value of an indexed
- property</dfn> <var title="">index</var> of a <code>Window</code>
- object, the user agent must return the <code>WindowProxy</code>
- object of the <var title="">index</var>th <span>child browsing
- context</span> of the <code>Document</code> that is nested through
- an element that is <span title="in a document">in the
- <code>Document</code></span>, sorted in the <span>tree order</span>
- of the elements nesting those <span title="browsing
- context">browsing contexts</span>.</p>
+ <p>To <dfn title="dom-window-item">determine the value of an indexed property</dfn> <var
+ title="">index</var> of a <code>Window</code> object, the user agent must return the
+ <code>WindowProxy</code> object of the <var title="">index</var>th <span>child browsing
+ context</span> of the <code>Document</code> that is nested through an element that is <span
+ title="in a document">in the <code>Document</code></span>, sorted in the <span>tree order</span>
+ of the elements nesting those <span title="browsing context">browsing contexts</span>.</p>
- <p>These properties are the <dfn>dynamic nested browsing context
- properties</dfn>.</p>
+ <p>These properties are the <dfn>dynamic nested browsing context properties</dfn>.</p>
</div>
@@ -78511,35 +78432,28 @@
<div class="impl">
- <p>The <code>Window</code> interface <span title="support named
- properties">supports named properties</span>. The <span>supported
- property names</span> at any moment consist of:</p>
+ <p>The <code>Window</code> interface <span title="support named properties">supports named
+ properties</span>. The <span>supported property names</span> at any moment consist of:</p>
<ul>
- <li>the <span>browsing context name</span> of any <span>child
- browsing context</span> of the <span>active document</span> whose
- name is not the empty string,</li>
+ <li>the <span>browsing context name</span> of any <span>child browsing context</span> of the
+ <span>active document</span> whose name is not the empty string,</li>
- <li>the value of the <code title="">name</code> content attribute
- for all <code>a</code>, <code>applet</code>, <code>area</code>,
- <code>embed</code>, <code>form</code>, <code>frameset</code>,
- <code>img</code>, and <code>object</code> elements in the
- <span>active document</span> that have a <code title="">name</code>
- content attribute, and</li>
+ <li>the value of the <code title="">name</code> content attribute for all <code>a</code>,
+ <code>applet</code>, <code>area</code>, <code>embed</code>, <code>form</code>,
+ <code>frameset</code>, <code>img</code>, and <code>object</code> elements in the <span>active
+ document</span> that have a <code title="">name</code> content attribute, and</li>
- <li>the value of the <code title="attr-id">id</code> content
- attribute of any <span title="HTML elements">HTML element</span> in
- the <span>active document</span> with an <code
+ <li>the value of the <code title="attr-id">id</code> content attribute of any <span title="HTML
+ elements">HTML element</span> in the <span>active document</span> with an <code
title="attr-id">id</code> content attribute.</li>
</ul>
- <p>To <span>determine the value of a named property</span> <var
- title="">name</var> when <dfn title="dom-window-namedItem">the
- <code>Window</code> object is indexed for property retrieval</dfn>,
- the user agent must return the value obtained using the following
- steps:</p>
+ <p>To <span>determine the value of a named property</span> <var title="">name</var> when <dfn
+ title="dom-window-namedItem">the <code>Window</code> object is indexed for property
+ retrieval</dfn>, the user agent must return the value obtained using the following steps:</p>
<ol>
@@ -78548,65 +78462,56 @@
<li>
<p>Let <var title="">objects</var> be the list of <span
- title="dom-window-namedItem-filter">named objects</span> with the
- name <var title="">name</var> in the <span>active document</span>.
+ title="dom-window-namedItem-filter">named objects</span> with the name <var title="">name</var>
+ in the <span>active document</span>.
- <p class="note">There will be at least one such object, by
- definition.<!-- (If there wasn't, then this algorithm wouldn't
- have been invoked by Web IDL.) --></p>
+ <p class="note">There will be at least one such object, by definition.<!-- (If there wasn't,
+ then this algorithm wouldn't have been invoked by Web IDL.) --></p>
</li>
<li>
- <p>If <var title="">objects</var> contains a <span>nested browsing
- context</span>, then return the <code>WindowProxy</code> object of
- the <span>nested browsing context</span> corresponding to the
- first <span>browsing context container</span> in <span>tree
- order</span> whose <span>browsing context</span> is in <var
- title="">objects</var>, and abort these steps.</p>
+ <p>If <var title="">objects</var> contains a <span>nested browsing context</span>, then return
+ the <code>WindowProxy</code> object of the <span>nested browsing context</span> corresponding to
+ the first <span>browsing context container</span> in <span>tree order</span> whose
+ <span>browsing context</span> is in <var title="">objects</var>, and abort these steps.</p>
</li>
<li>
- <p>Otherwise, if <var title="">elements</var> has only one
- element, return that element and abort these steps.</p>
+ <p>Otherwise, if <var title="">elements</var> has only one element, return that element and
+ abort these steps.</p>
</li>
<li>
- <p>Otherwise return an <code>HTMLCollection</code> rooted at the
- <code>Document</code> node, whose filter matches only <span
- title="dom-window-namedItem-filter">named objects</span> with the
- name <var title="">name</var>. (By definition, these will all be
- elements.)</p> <!-- the same one each time is returned, because of
- the rule under collections -->
+ <p>Otherwise return an <code>HTMLCollection</code> rooted at the <code>Document</code> node,
+ whose filter matches only <span title="dom-window-namedItem-filter">named objects</span> with
+ the name <var title="">name</var>. (By definition, these will all be elements.)</p> <!-- the
+ same one each time is returned, because of the rule under collections -->
</li>
</ol>
- <p><dfn title="dom-window-nameditem-filter">Named objects</dfn>
- with the name <var title="">name</var>, for the purposes of the
- above algorithm, are those that are either:</p>
+ <p><dfn title="dom-window-nameditem-filter">Named objects</dfn> with the name <var
+ title="">name</var>, for the purposes of the above algorithm, are those that are either:</p>
<ul>
- <li><span title="child browsing context">child browsing
- contexts</span> of the <span>active document</span> whose name is
- <var title="">name</var>,</li>
+ <li><span title="child browsing context">child browsing contexts</span> of the <span>active
+ document</span> whose name is <var title="">name</var>,</li>
- <li><code>a</code>, <code>applet</code>, <code>area</code>,
- <code>embed</code>, <code>form</code>, <code>frameset</code>,
- <code>img</code>, or <code>object</code> elements that have a <code
- title="attr-name">name</code> content attribute whose value is <var
+ <li><code>a</code>, <code>applet</code>, <code>area</code>, <code>embed</code>,
+ <code>form</code>, <code>frameset</code>, <code>img</code>, or <code>object</code> elements that
+ have a <code title="attr-name">name</code> content attribute whose value is <var
title="">name</var>, or</li>
- <li><span>HTML elements</span> that have an <code
- title="attr-id">id</code> content attribute whose value is <var
- title="">name</var>.</li>
+ <li><span>HTML elements</span> that have an <code title="attr-id">id</code> content attribute
+ whose value is <var title="">name</var>.</li>
</ul>
@@ -78617,82 +78522,63 @@
<h4>Garbage collection and browsing contexts</h4>
- <p>A <span>browsing context</span> has a strong reference to each of
- its <code>Document</code>s and its <code>WindowProxy</code> object,
- and the user agent itself has a strong reference to its <span
- title="top-level browsing context">top-level browsing
- contexts</span>.</p>
+ <p>A <span>browsing context</span> has a strong reference to each of its <code>Document</code>s
+ and its <code>WindowProxy</code> object, and the user agent itself has a strong reference to its
+ <span title="top-level browsing context">top-level browsing contexts</span>.</p>
- <p>A <code>Document</code> has a strong reference to its
- <code>Window</code> object.</p>
+ <p>A <code>Document</code> has a strong reference to its <code>Window</code> object.</p>
- <p class="note">A <code>Window</code> object <span title="implied
- strong reference">has a strong reference</span> to its
- <code>Document</code> object through its <code
- title="dom-document">document</code> attribute. Thus, references
- from other scripts to either of those objects will keep both
- alive. Similarly, both <code>Document</code> and <code>Window</code>
- objects have <span title="implied strong reference">implied strong
- references</span> to the <code>WindowProxy</code> object.</p>
+ <p class="note">A <code>Window</code> object <span title="implied strong reference">has a strong
+ reference</span> to its <code>Document</code> object through its <code
+ title="dom-document">document</code> attribute. Thus, references from other scripts to either of
+ those objects will keep both alive. Similarly, both <code>Document</code> and <code>Window</code>
+ objects have <span title="implied strong reference">implied strong references</span> to the
+ <code>WindowProxy</code> object.</p>
- <p>Each <span title="concept-script">script</span> has a strong
- reference to its <span title="script's browsing context">browsing
- context</span> and its <span title="script's
+ <p>Each <span title="concept-script">script</span> has a strong reference to its <span
+ title="script's browsing context">browsing context</span> and its <span title="script's
document">document</span>.</p>
<!-- discard a document -->
- <p>When a <span>browsing context</span> is to <dfn>discard a
- <code>Document</code></dfn>, the user agent must run the following
- steps:</p>
+ <p>When a <span>browsing context</span> is to <dfn>discard a <code>Document</code></dfn>, the user
+ agent must run the following steps:</p>
<ol>
<li><p>Set the <code>Document</code>'s <var
- title="concept-document-salvageable">salvageable</var> state to
- false.</p></li>
+ title="concept-document-salvageable">salvageable</var> state to false.</p></li>
- <li><p>Run any <span>unloading document cleanup steps</span> for
- the <code>Document</code> that are defined by this specification
- and <span>other applicable specifications</span>.</p></li>
+ <li><p>Run any <span>unloading document cleanup steps</span> for the <code>Document</code> that
+ are defined by this specification and <span>other applicable specifications</span>.</p></li>
- <li><p><span title="abort a document">Abort the
- <code>Document</code></span>.</p></li>
+ <li><p><span title="abort a document">Abort the <code>Document</code></span>.</p></li>
- <li><p>Remove any <span title="concept-task">tasks</span>
- associated with the <code>Document</code> in any <span>task
- source</span>, without running those tasks.</p></li>
+ <li><p>Remove any <span title="concept-task">tasks</span> associated with the
+ <code>Document</code> in any <span>task source</span>, without running those tasks.</p></li>
- <li><p><span title="a browsing context is discarded">Discard</span>
- all the <span title="child browsing context">child browsing
- contexts</span> of the <code>Document</code>.</p></li>
+ <li><p><span title="a browsing context is discarded">Discard</span> all the <span title="child
+ browsing context">child browsing contexts</span> of the <code>Document</code>.</p></li>
- <li><p>Lose the strong reference from the <code>Document</code>'s
- <span>browsing context</span> to the
- <code>Document</code>.</p></li>
+ <li><p>Lose the strong reference from the <code>Document</code>'s <span>browsing context</span>
+ to the <code>Document</code>.</p></li>
</ol>
- <p class="note">Whenever a <code>Document</code> object is <span
- title="discard a Document">discarded</span>, it is also removed from
- the list of <span>the worker's <code>Document</code>s</span> of each
- worker whose list contains that <code>Document</code>.</p>
+ <p class="note">Whenever a <code>Document</code> object is <span title="discard a
+ Document">discarded</span>, it is also removed from the list of <span>the worker's
+ <code>Document</code>s</span> of each worker whose list contains that <code>Document</code>.</p>
- <p>When <dfn>a <em><span>browsing context</span></em> is
- discarded</dfn>, the strong reference from the user agent itself to
- the <span>browsing context</span> must be severed, and all the
- <code>Document</code> objects for all the entries in the
- <span>browsing context</span>'s session history must be <span
- title="discard a document">discarded</span> as well.</p>
+ <p>When <dfn>a <em><span>browsing context</span></em> is discarded</dfn>, the strong reference
+ from the user agent itself to the <span>browsing context</span> must be severed, and all the
+ <code>Document</code> objects for all the entries in the <span>browsing context</span>'s session
+ history must be <span title="discard a document">discarded</span> as well.</p>
- <p>User agents may <span title="a browsing context is
- discarded">discard</span> <span title="top-level browsing
- context">top-level browsing contexts</span> at any time (typically,
- in response to user requests, e.g. when a user force-closes a window
- containing one or more <span title="top-level browsing
- context">top-level browsing contexts</span>). Other <span
- title="browsing context">browsing contexts</span> must be discarded
- once their <code>WindowProxy</code> object is eligible for garbage
- collection.</p>
+ <p>User agents may <span title="a browsing context is discarded">discard</span> <span
+ title="top-level browsing context">top-level browsing contexts</span> at any time (typically, in
+ response to user requests, e.g. when a user force-closes a window containing one or more <span
+ title="top-level browsing context">top-level browsing contexts</span>). Other <span
+ title="browsing context">browsing contexts</span> must be discarded once their
+ <code>WindowProxy</code> object is eligible for garbage collection.</p>
</div>
@@ -78778,38 +78664,33 @@
<div class="impl">
- <p>The <dfn title="dom-BarProp-visible">visible</dfn> attribute, on
- getting, must return either true or a value determined by the user
- agent to most accurately represent the visibility state of the user
- interface element that the object represents, as described below. On
- setting, the new value must be discarded.</p>
+ <p>The <dfn title="dom-BarProp-visible">visible</dfn> attribute, on getting, must return either
+ true or a value determined by the user agent to most accurately represent the visibility state of
+ the user interface element that the object represents, as described below. On setting, the new
+ value must be discarded.</p>
- <p>The following <code>BarProp</code> objects exist for each
- <code>Document</code> object in a <span>browsing
- context</span>. Some of the user interface elements represented by
- these objects might have no equivalent in some user agents; for
- those user agents, except when otherwise specified, the object must
- act as if it was present and visible (i.e. its <code
- title="dom-BarProp-visible">visible</code> attribute must return
- true).</p>
+ <p>The following <code>BarProp</code> objects exist for each <code>Document</code> object in a
+ <span>browsing context</span>. Some of the user interface elements represented by these objects
+ might have no equivalent in some user agents; for those user agents, except when otherwise
+ specified, the object must act as if it was present and visible (i.e. its <code
+ title="dom-BarProp-visible">visible</code> attribute must return true).</p>
<dl>
<dt><dfn>The location bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a control
- that displays the <span>URL</span> of the <span>active
- document</span>, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a control that displays the
+ <span>URL</span> of the <span>active document</span>, or some similar interface concept.</dd>
<dt><dfn>The menu bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains a list of
- commands in menu form, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains a list of commands in menu form, or some
+ similar interface concept.</dd>
<dt><dfn>The personal bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element that contains links to
- the user's favorite pages, or some similar interface concept.</dd>
+ <dd>Represents the user interface element that contains links to the user's favorite pages, or
+ some similar interface concept.</dd>
<dt><dfn>The scrollbar <code>BarProp</code> object</dfn></dt>
@@ -78818,65 +78699,48 @@
<dt><dfn>The status bar <code>BarProp</code> object</dfn></dt>
- <dd>Represents a user interface element found immediately below or
- after the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title="dom-BarProp-visible">visible</code>
- attribute may return false).</dd>
+ <dd>Represents a user interface element found immediately below or after the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code
+ title="dom-BarProp-visible">visible</code> attribute may return false).</dd>
<dt><dfn>The toolbar <code>BarProp</code> object</dfn></dt>
- <dd>Represents the user interface element found immediately above
- or before the document, as appropriate for the user's media. If the
- user agent has no such user interface element, then the object may
- act as if the corresponding user interface element was absent
- (i.e. its <code title="dom-BarProp-visible">visible</code>
- attribute may return false).</dd>
+ <dd>Represents the user interface element found immediately above or before the document, as
+ appropriate for the user's media. If the user agent has no such user interface element, then the
+ object may act as if the corresponding user interface element was absent (i.e. its <code
+ title="dom-BarProp-visible">visible</code> attribute may return false).</dd>
</dl>
- <p>The <dfn
- title="dom-window-locationbar"><code>locationbar</code></dfn>
- attribute must return <span>the location bar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-locationbar"><code>locationbar</code></dfn> attribute must return
+ <span>the location bar <code>BarProp</code> object</span>.</p>
- <p>The <dfn title="dom-window-menubar"><code>menubar</code></dfn>
- attribute must return <span>the menu bar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-menubar"><code>menubar</code></dfn> attribute must return <span>the
+ menu bar <code>BarProp</code> object</span>.</p>
- <p>The <dfn
- title="dom-window-personalbar"><code>personalbar</code></dfn>
- attribute must return <span>the personal bar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-personalbar"><code>personalbar</code></dfn> attribute must return
+ <span>the personal bar <code>BarProp</code> object</span>.</p>
- <p>The <dfn
- title="dom-window-scrollbars"><code>scrollbars</code></dfn>
- attribute must return <span>the scrollbar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-scrollbars"><code>scrollbars</code></dfn> attribute must return
+ <span>the scrollbar <code>BarProp</code> object</span>.</p>
- <p>The <dfn
- title="dom-window-statusbar"><code>statusbar</code></dfn> attribute
- must return <span>the status bar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-statusbar"><code>statusbar</code></dfn> attribute must return
+ <span>the status bar <code>BarProp</code> object</span>.</p>
- <p>The <dfn title="dom-window-toolbar"><code>toolbar</code></dfn>
- attribute must return <span>the toolbar <code>BarProp</code>
- object</span>.</p>
+ <p>The <dfn title="dom-window-toolbar"><code>toolbar</code></dfn> attribute must return <span>the
+ toolbar <code>BarProp</code> object</span>.</p>
<!--
- <p>For legacy reasons, the <dfn
- title="dom-window-directories"><code>directories</code></dfn>
- attribute must also return <span>the personal bar
- <code>BarProp</code> object</span>.</p>
+ <p>For legacy reasons, the <dfn title="dom-window-directories"><code>directories</code></dfn>
+ attribute must also return <span>the personal bar <code>BarProp</code> object</span>.</p>
-->
<hr>
- <p>For historical reasons, the <dfn
- title="dom-window-status"><code>status</code></dfn> attribute on the
- <code>Window</code> object must return an empty string on getting,
- and do nothing on setting.</p>
+ <p>For historical reasons, the <dfn title="dom-window-status"><code>status</code></dfn> attribute
+ on the <code>Window</code> object must return an empty string on getting, and do nothing on
+ setting.</p>
</div>
@@ -78894,28 +78758,24 @@
<!--START complete--><!--START dev-html-->
<p>As mentioned earlier, each <span>browsing context</span> has a
- <dfn><code>WindowProxy</code></dfn> object. This object is unusual
- in that all operations that would be performed on it must be
- performed on the <code>Window</code> object of the <span>browsing
- context</span>'s <span>active document</span> instead. It is thus
- indistinguishable from that <code>Window</code> object in every way
- until the <span>browsing context</span> is navigated.</p>
+ <dfn><code>WindowProxy</code></dfn> object. This object is unusual in that all operations that
+ would be performed on it must be performed on the <code>Window</code> object of the <span>browsing
+ context</span>'s <span>active document</span> instead. It is thus indistinguishable from that
+ <code>Window</code> object in every way until the <span>browsing context</span> is navigated.</p>
<p>There is no <code>WindowProxy</code> interface object.</p>
- <p class="note">The <code>WindowProxy</code> object allows scripts
- to act as if each <span>browsing context</span> had a single
- <code>Window</code> object, while still keeping separate
- <code>Window</code> objects for each <code>Document</code>.</p>
+ <p class="note">The <code>WindowProxy</code> object allows scripts to act as if each
+ <span>browsing context</span> had a single <code>Window</code> object, while still keeping
+ separate <code>Window</code> objects for each <code>Document</code>.</p>
<div class="example">
- <p>In the following example, the variable <var title="">x</var> is
- set to the <code>WindowProxy</code> object returned by the <code
- title="dom-window">window</code> accessor on the global object. All
- of the expressions following the assignment return true, because in
- every respect, the <code>WindowProxy</code> object acts like the
- underlying <code>Window</code> object.</p>
+ <p>In the following example, the variable <var title="">x</var> is set to the
+ <code>WindowProxy</code> object returned by the <code title="dom-window">window</code> accessor
+ on the global object. All of the expressions following the assignment return true, because in
+ every respect, the <code>WindowProxy</code> object acts like the underlying <code>Window</code>
+ object.</p>
<pre>var x = window;
x instanceof Window; // true
@@ -78932,10 +78792,9 @@
<h3>Origin</h3>
<!-- Hallowed are the Ori -->
- <p>The <dfn>origin</dfn> of a resource and the <dfn>effective script
- origin</dfn> of a resource are both either opaque identifiers or
- tuples consisting of a scheme component, a host component, a port
- component, and optionally extra data.</p>
+ <p>The <dfn>origin</dfn> of a resource and the <dfn>effective script origin</dfn> of a resource
+ are both either opaque identifiers or tuples consisting of a scheme component, a host component, a
+ port component, and optionally extra data.</p>
<p class="note">The extra data could include the certificate of the
site when using encrypted connections, to ensure that if the site's
@@ -78944,13 +78803,11 @@
<div class="impl">
- <p>An <span>origin</span> or <span>effective script origin</span>
- can be defined as an <dfn title="concept-origin-alias">alias</dfn>
- to another <span>origin</span> or <span>effective script
- origin</span>. The value of the <span>origin</span> or
- <span>effective script origin</span> is then the value of the
- <span>origin</span> or <span>effective script origin</span> to which
- it is an alias.</p>
+ <p>An <span>origin</span> or <span>effective script origin</span> can be defined as an <dfn
+ title="concept-origin-alias">alias</dfn> to another <span>origin</span> or <span>effective script
+ origin</span>. The value of the <span>origin</span> or <span>effective script origin</span> is
+ then the value of the <span>origin</span> or <span>effective script origin</span> to which it is
+ an alias.</p>
<p>These characteristics are defined as follows:</p>
@@ -78960,9 +78817,8 @@
<dd>
- <p>The <span>origin</span> and <span>effective script
- origin</span> of the <span>URL</span> are the origin defined in
- <cite>The Web Origin Concept</cite>. <a
+ <p>The <span>origin</span> and <span>effective script origin</span> of the <span>URL</span> are
+ the origin defined in <cite>The Web Origin Concept</cite>. <a
href="#refsORIGIN">[ORIGIN]</a></p>
</dd>
@@ -78974,18 +78830,17 @@
<dl class="switch">
- <dt id="sandboxOrigin">If a <code>Document</code>'s <span>active
- sandboxing flag set</span> has its <span>sandboxed origin
- browsing context flag</span> set</dt>
+ <dt id="sandboxOrigin">If a <code>Document</code>'s <span>active sandboxing flag set</span> has
+ its <span>sandboxed origin browsing context flag</span> set</dt>
<dd>
- <p>The <span>origin</span> is a globally unique identifier
- assigned when the <code>Document</code> is created.</p>
+ <p>The <span>origin</span> is a globally unique identifier assigned when the
+ <code>Document</code> is created.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>.</p>
</dd>
@@ -78996,88 +78851,73 @@
<dd>
- <p>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the script of that <span
- title="javascript protocol"><code>javascript:</code>
- URL</span>.</p>
+ <p>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of the script of that <span title="javascript
+ protocol"><code>javascript:</code> URL</span>.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>.</p>
</dd>
- <dt>If a <code>Document</code> was served over the network and
- has an address that uses a URL scheme with a server-based naming
- authority</dt>
+ <dt>If a <code>Document</code> was served over the network and has an address that uses a URL
+ scheme with a server-based naming authority</dt>
<dd>
- <p>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of <span>the <code>Document</code>'s
- address</span>.</p>
+ <p>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of <span>the <code>Document</code>'s address</span>.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>.</p>
</dd>
- <dt>If a <code>Document</code> was generated from a <span
- title="data protocol"><code title="">data:</code> URL</span> that
- was returned as the location of an HTTP redirect (<span
- title="concept-http-equivalent-codes">or equivalent</span> in
- other protocols)</dt>
+ <dt>If a <code>Document</code> was generated from a <span title="data protocol"><code
+ title="">data:</code> URL</span> that was returned as the location of an HTTP redirect (<span
+ title="concept-http-equivalent-codes">or equivalent</span> in other protocols)</dt>
<dd>
- <p>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <span>URL</span> that redirected to
- the <span title="data protocol"><code title="">data:</code>
- URL</span>.</p>
+ <p>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of the <span>URL</span> that redirected to the <span title="data
+ protocol"><code title="">data:</code> URL</span>.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>.</p>
</dd>
- <dt>If a <code>Document</code> was generated from a <span
- title="data protocol"><code title="">data:</code> URL</span>
- found in another <code>Document</code> or in a script</dt>
+ <dt>If a <code>Document</code> was generated from a <span title="data protocol"><code
+ title="">data:</code> URL</span> found in another <code>Document</code> or in a script</dt>
<dd>
- <p>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code> or script that
- initiated the <span title="navigate">navigation</span> to that
- <span>URL</span>.</p>
-
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>effective script origin</span> of the
- <code>Document</code> or script that initiated the <span
+ <p>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of the <code>Document</code> or script that initiated the <span
title="navigate">navigation</span> to that <span>URL</span>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>effective script origin</span> of the
+ <code>Document</code> or script that initiated the <span title="navigate">navigation</span> to
+ that <span>URL</span>.</p>
+
</dd>
- <dt>If a <code>Document</code> has the <span title="the
- document's address">address</span>
+ <dt>If a <code>Document</code> has the <span title="the document's address">address</span>
"<code>about:blank</code>"</dt>
<dd>
- <p>The <span>origin</span> and <span>effective script
- origin</span> of the <code>Document</code> are <a
- href="#about-blank-origin">those it was assigned when its
+ <p>The <span>origin</span> and <span>effective script origin</span> of the
+ <code>Document</code> are <a href="#about-blank-origin">those it was assigned when its
browsing context was created</a>.</p>
</dd>
@@ -79088,45 +78928,39 @@
<dd>
- <p>The <span>origin</span> of the <code>Document</code> is an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>'s
- <span>browsing context</span>'s <span>browsing context
+ <p>The <span>origin</span> of the <code>Document</code> is an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>'s <span>browsing context</span>'s <span>browsing context
container</span>'s <code>Document</code>.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>effective script origin</span> of the
- <code>Document</code>'s <span>browsing context</span>'s
- <span>browsing context container</span>'s
- <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>effective script origin</span> of the
+ <code>Document</code>'s <span>browsing context</span>'s <span>browsing context
+ container</span>'s <code>Document</code>.</p>
</dd>
- <dt>If a <code>Document</code> was obtained in some other manner
- (e.g. a <span title="data protocol"><code title="">data:</code>
- URL</span> typed in by the user, a <code>Document</code> created
- using the <code
- title="dom-DOMImplementation-createDocument">createDocument()</code>
+ <dt>If a <code>Document</code> was obtained in some other manner (e.g. a <span title="data
+ protocol"><code title="">data:</code> URL</span> typed in by the user, a <code>Document</code>
+ created using the <code title="dom-DOMImplementation-createDocument">createDocument()</code>
API, etc)</dt>
<dd>
- <p>The <span>origin</span> is a globally unique identifier
- assigned when the <code>Document</code> is created.</p>
+ <p>The <span>origin</span> is a globally unique identifier assigned when the
+ <code>Document</code> is created.</p>
- <p>The <span>effective script origin</span> is initially an
- <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code>.</p>
+ <p>The <span>effective script origin</span> is initially an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code>.</p>
</dd>
</dl>
- <p class="note">The <span>effective script origin</span> of a
- <code>Document</code> can be manipulated using the <code
- title="dom-document-domain">document.domain</code> IDL
+ <p class="note">The <span>effective script origin</span> of a <code>Document</code> can be
+ manipulated using the <code title="dom-document-domain">document.domain</code> IDL
attribute.</p>
</dd>
@@ -79138,24 +78972,21 @@
<dl class="switch">
- <dt>If an image is the image of an <code>img</code> element and
- its image data is <span>CORS-cross-origin</span></dt>
+ <dt>If an image is the image of an <code>img</code> element and its image data is
+ <span>CORS-cross-origin</span></dt>
- <dd>The <span>origin</span> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <span>origin</span> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If an image is the image of an <code>img</code> element and
- its image data is <span>CORS-same-origin</span></dt>
+ <dt>If an image is the image of an <code>img</code> element and its image data is
+ <span>CORS-same-origin</span></dt>
- <dd>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>img</code> element's
- <code>Document</code>.</dd>
+ <dd>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of the <code>img</code> element's <code>Document</code>.</dd>
- <!-- all image loads go through the "potentially CORS-enabled
- fetch" algorithm so they're all either CORS-cross-origin or
- CORS-same-origin if they succeed at all -->
+ <!-- all image loads go through the "potentially CORS-enabled fetch" algorithm so they're all
+ either CORS-cross-origin or CORS-same-origin if they succeed at all -->
</dl>
@@ -79170,25 +79001,21 @@
<dl class="switch">
- <dt>If the <span>media data</span> is
- <span>CORS-cross-origin</span></dt>
+ <dt>If the <span>media data</span> is <span>CORS-cross-origin</span></dt>
- <dd>The <span>origin</span> is a globally unique identifier
- assigned when the image is created.</dd>
+ <dd>The <span>origin</span> is a globally unique identifier assigned when the image is
+ created.</dd>
- <dt>If the <span>media data</span> is
- <span>CORS-same-origin</span></dt>
+ <dt>If the <span>media data</span> is <span>CORS-same-origin</span></dt>
- <dd>The <span>origin</span> is an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <span>media element</span>'s
- <code>Document</code>.</dd>
+ <dd>The <span>origin</span> is an <span title="concept-origin-alias">alias</span> to the
+ <span>origin</span> of the <span>media element</span>'s <code>Document</code>.</dd>
</dl>
- <p><span title="media element">Media elements</span> do not have
- an <span>effective script origin</span>.</p>
+ <p><span title="media element">Media elements</span> do not have an <span>effective script
+ origin</span>.</p>
</dd>
@@ -79206,10 +79033,9 @@
own site in some fashion controlled by the data you want to read
-->
- <p>The <span>origin</span> of a locally installed system font is
- an <span title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the <code>Document</code> in which that
- font is being used.</p>
+ <p>The <span>origin</span> of a locally installed system font is an <span
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the
+ <code>Document</code> in which that font is being used.</p>
<p>Fonts do not have an <span>effective script origin</span>.</p>
@@ -79220,215 +79046,185 @@
<dd>
- <p>The <span>origin</span> and <span>effective script
- origin</span> of a script are determined from another resource,
- called the <i>owner</i>:</p>
+ <p>The <span>origin</span> and <span>effective script origin</span> of a script are determined
+ from another resource, called the <i>owner</i>:</p>
<dl class="switch">
<dt>If a script is in a <code>script</code> element</dt>
- <dd>The owner is the <code>Document</code> to which the
- <code>script</code> element belongs.</dd>
+ <dd>The owner is the <code>Document</code> to which the <code>script</code> element
+ belongs.</dd>
- <dt>If a script is in an <span title="event handler content
- attributes">event handler content attribute</span></dt>
+ <dt>If a script is in an <span title="event handler content attributes">event handler content
+ attribute</span></dt>
- <dd>The owner is the <code>Document</code> to which the
- attribute node belongs.</dd>
+ <dd>The owner is the <code>Document</code> to which the attribute node belongs.</dd>
- <dt>If a script is a function or other code reference created by
- another script</dt>
+ <dt>If a script is a function or other code reference created by another script</dt>
<dd>The owner is the script that created it.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> that was returned as the
- location of an HTTP redirect (<span
- title="concept-http-equivalent-codes">or equivalent</span> in
- other protocols)</dt>
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> that was returned as the location of an HTTP redirect (<span
+ title="concept-http-equivalent-codes">or equivalent</span> in other protocols)</dt>
- <dd>The owner is the <span>URL</span> that redirected to the
- <span title="javascript protocol"><code
- title="">javascript:</code> URL</span>.</dd>
+ <dd>The owner is the <span>URL</span> that redirected to the <span title="javascript
+ protocol"><code title="">javascript:</code> URL</span>.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> in an attribute</dt>
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> in an attribute</dt>
- <dd>The owner is the <code>Document</code> of the element on
- which the attribute is found.</dd>
+ <dd>The owner is the <code>Document</code> of the element on which the attribute is found.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> in a style sheet</dt>
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> in a style sheet</dt>
<dd>The owner is the <span>URL</span> of the style sheet.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> to which a <span>browsing
- context</span> is being <span title="navigate">navigated</span>,
- the URL having been provided by the user (e.g. by using a
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> to which a <span>browsing context</span> is being <span
+ title="navigate">navigated</span>, the URL having been provided by the user (e.g. by using a
<i>bookmarklet</i>)</dt>
- <dd>The owner is the <code>Document</code> of the <span>browsing
- context</span>'s <span>active document</span>.</dd>
+ <dd>The owner is the <code>Document</code> of the <span>browsing context</span>'s <span>active
+ document</span>.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> to which a <span>browsing
- context</span> is being <span title="navigate">navigated</span>,
- the URL having been declared in markup</dt>
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> to which a <span>browsing context</span> is being <span
+ title="navigate">navigated</span>, the URL having been declared in markup</dt>
- <dd>The owner is the <code>Document</code> of the element
- (e.g. an <code>a</code> or <code>area</code> element) that
- declared the URL.</dd>
+ <dd>The owner is the <code>Document</code> of the element (e.g. an <code>a</code> or
+ <code>area</code> element) that declared the URL.</dd>
- <dt>If a script is a <span title="javascript protocol"><code
- title="">javascript:</code> URL</span> to which a <span>browsing
- context</span> is being <span title="navigate">navigated</span>,
- the URL having been provided by script</dt>
+ <dt>If a script is a <span title="javascript protocol"><code title="">javascript:</code>
+ URL</span> to which a <span>browsing context</span> is being <span
+ title="navigate">navigated</span>, the URL having been provided by script</dt>
<dd>The owner is the script that provided the URL.</dd>
</dl>
<p>The <span>origin</span> of the script is then an <span
- title="concept-origin-alias">alias</span> to the
- <span>origin</span> of the owner, and the <span>effective script
- origin</span> of the script is an <span
- title="concept-origin-alias">alias</span> to the <span>effective
- script origin</span> of the owner.</p>
+ title="concept-origin-alias">alias</span> to the <span>origin</span> of the owner, and the
+ <span>effective script origin</span> of the script is an <span
+ title="concept-origin-alias">alias</span> to the <span>effective script origin</span> of the
+ owner.</p>
</dd>
</dl>
- <p>Other specifications can override the above definitions by
- themselves specifying the origin of a particular <span>URL</span>,
- <code>Document</code>, image, <span>media element</span>, font, or
+ <p>Other specifications can override the above definitions by themselves specifying the origin of
+ a particular <span>URL</span>, <code>Document</code>, image, <span>media element</span>, font, or
<span title="concept-script">script</span>.</p>
<!-- e.g.:
- <p>The <span>origin</span> of a <code>Document</code> object
- returned by the <code>XMLHttpRequest</code> API is an <span
- title="concept-origin-alias">alias</span> to the
- <span>XMLHttpRequest origin</span> of the
- <code>XMLHttpRequest</code> object.</p>
+ <p>The <span>origin</span> of a <code>Document</code> object returned by the
+ <code>XMLHttpRequest</code> API is an <span title="concept-origin-alias">alias</span> to the
+ <span>XMLHttpRequest origin</span> of the <code>XMLHttpRequest</code> object.</p>
-->
<hr>
- <p>The <dfn>Unicode serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <span>origin</span>:</p>
+ <p>The <dfn>Unicode serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <span>origin</span>:</p>
<ol>
- <li><p>If the <span>origin</span> in question is not a
- scheme/host/port tuple, then return the literal string "<code
- title="">null</code>" and abort these steps.</p></li>
+ <li><p>If the <span>origin</span> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</p></li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <span>origin</span> tuple.</p></li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <span>origin</span>
+ tuple.</p></li>
- <li><p>Append the string "<code title="">://</code>" to <var
- title="">result</var>.</p></li>
+ <li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</p></li>
- <li><p>Apply the IDNA ToUnicode algorithm to each component of the
- host part of the <span>origin</span> tuple, and append the results
- — each component, in the same order, separated by U+002E FULL
- STOP characters (.) — to <var title="">result</var>. <a
+ <li><p>Apply the IDNA ToUnicode algorithm to each component of the host part of the
+ <span>origin</span> tuple, and append the results — each component, in the same order,
+ separated by U+002E FULL STOP characters (.) — to <var title="">result</var>. <a
href="#refsRFC3490">[RFC3490]</a></p></li>
- <li><p>If the port part of the <span>origin</span> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <span>origin</span> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</p></li>
+ <li><p>If the port part of the <span>origin</span> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <span>origin</span> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var
+ title="">result</var>.</p></li>
<li><p>Return <var title="">result</var>.</p></li>
</ol>
- <p>The <dfn>ASCII serialization of an origin</dfn> is the string
- obtained by applying the following algorithm to the given
- <span>origin</span>:</p>
+ <p>The <dfn>ASCII serialization of an origin</dfn> is the string obtained by applying the
+ following algorithm to the given <span>origin</span>:</p>
<ol>
- <li><p>If the <span>origin</span> in question is not a
- scheme/host/port tuple, then return the literal string "<code
- title="">null</code>" and abort these steps.</p></li>
+ <li><p>If the <span>origin</span> in question is not a scheme/host/port tuple, then return the
+ literal string "<code title="">null</code>" and abort these steps.</p></li>
- <li><p>Otherwise, let <var title="">result</var> be the scheme part
- of the <span>origin</span> tuple.</p></li>
+ <li><p>Otherwise, let <var title="">result</var> be the scheme part of the <span>origin</span>
+ tuple.</p></li>
- <li><p>Append the string "<code title="">://</code>" to <var
- title="">result</var>.</p></li>
+ <li><p>Append the string "<code title="">://</code>" to <var title="">result</var>.</p></li>
<li>
- <p>Apply the IDNA ToASCII algorithm the host part of the
- <span>origin</span> tuple, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and append the results <var
+ <p>Apply the IDNA ToASCII algorithm the host part of the <span>origin</span> tuple, with both
+ the AllowUnassigned and UseSTD3ASCIIRules flags set, and append the results <var
title="">result</var>.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then return the empty string and abort these steps. <a
- href="#refsRFC3490">[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then return the empty string and abort these steps.
+ <a href="#refsRFC3490">[RFC3490]</a></p>
</li>
- <li><p>If the port part of the <span>origin</span> tuple gives a port
- that is different from the default port for the protocol given by
- the scheme part of the <span>origin</span> tuple, then append a
- U+003A COLON character (:) and the given port, in base ten, to
- <var title="">result</var>.</p></li>
+ <li><p>If the port part of the <span>origin</span> tuple gives a port that is different from the
+ default port for the protocol given by the scheme part of the <span>origin</span> tuple, then
+ append a U+003A COLON character (:) and the given port, in base ten, to <var
+ title="">result</var>.</p></li>
<li><p>Return <var title="">result</var>.</p></li>
</ol>
- <p>Two <span title="origin">origins</span> are said to be the
- <dfn>same origin</dfn> if the following algorithm returns true:</p>
+ <p>Two <span title="origin">origins</span> are said to be the <dfn>same origin</dfn> if the
+ following algorithm returns true:</p>
<ol>
- <li><p>Let <var title="">A</var> be the first <span>origin</span>
- being compared, and <var title="">B</var> be the second
- <span>origin</span> being compared.</p></li>
+ <li><p>Let <var title="">A</var> be the first <span>origin</span> being compared, and <var
+ title="">B</var> be the second <span>origin</span> being compared.</p></li>
- <li><p>If <var title="">A</var> and <var title="">B</var> are both
- opaque identifiers, and their value is equal, then return
- true.</p></li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> are both opaque identifiers, and their
+ value is equal, then return true.</p></li>
- <li><p>Otherwise, if either <var title="">A</var> or <var
- title="">B</var> or both are opaque identifiers, return
- false.</p></li>
+ <li><p>Otherwise, if either <var title="">A</var> or <var title="">B</var> or both are opaque
+ identifiers, return false.</p></li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have
- scheme components that are not identical, return false.</p></li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have scheme components that are not
+ identical, return false.</p></li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have host
- components that are not identical, return false.</p></li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have host components that are not
+ identical, return false.</p></li>
- <li><p>If <var title="">A</var> and <var title="">B</var> have port
- components that are not identical, return false.</p></li>
+ <li><p>If <var title="">A</var> and <var title="">B</var> have port components that are not
+ identical, return false.</p></li>
- <li><p>If either <var title="">A</var> or <var title="">B</var>
- have additional data, but that data is not identical for both,
- return false.</p></li>
+ <li><p>If either <var title="">A</var> or <var title="">B</var> have additional data, but that
+ data is not identical for both, return false.</p></li>
<li><p>Return true.</p></li>
@@ -79447,10 +79243,9 @@
<p>Returns the current domain used for security checks.</p>
- <p>Can be set to a value that removes subdomains, to change the
- <span>effective script origin</span> to allow pages on other
- subdomains of the same domain (if they do the same thing) to
- access each other.</p>
+ <p>Can be set to a value that removes subdomains, to change the <span>effective script
+ origin</span> to allow pages on other subdomains of the same domain (if they do the same thing)
+ to access each other.</p>
</dd>
@@ -79458,17 +79253,14 @@
<div class="impl">
- <p>The <dfn title="dom-document-domain"><code>domain</code></dfn>
- attribute on <code>Document</code> objects must be initialized to
- <span>the document's domain</span>, if it has one, and the empty
- string otherwise. If the value is an IPv6 address, then the square
- brackets from the host portion of the <span
- title="url-host"><host></span> component must be omitted from
- the attribute's value.</p>
+ <p>The <dfn title="dom-document-domain"><code>domain</code></dfn> attribute on
+ <code>Document</code> objects must be initialized to <span>the document's domain</span>, if it has
+ one, and the empty string otherwise. If the value is an IPv6 address, then the square brackets
+ from the host portion of the <span title="url-host"><host></span> component must be omitted
+ from the attribute's value.</p>
- <p>On getting, the attribute must return its current value, unless
- the <code>Document</code> has no <span>browsing context</span>, in
- which case it must return the empty string.</p>
+ <p>On getting, the attribute must return its current value, unless the <code>Document</code> has
+ no <span>browsing context</span>, in which case it must return the empty string.</p>
<p>On setting, the user agent must run the following algorithm:</p>
@@ -79476,70 +79268,59 @@
<li>
- <p>If the <code>Document</code> has no <span>browsing
- context</span>, throw a <code>SecurityError</code> exception and
- abort these steps.</p>
+ <p>If the <code>Document</code> has no <span>browsing context</span>, throw a
+ <code>SecurityError</code> exception and abort these steps.</p>
</li>
<li>
- <p>If the new value is an IP address, let <var title="">new
- value</var> be the new value. Otherwise, apply the IDNA ToASCII
- algorithm to the new value, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, and let <var title="">new value</var>
- be the result of the ToASCII algorithm.</p>
+ <p>If the new value is an IP address, let <var title="">new value</var> be the new value.
+ Otherwise, apply the IDNA ToASCII algorithm to the new value, with both the AllowUnassigned and
+ UseSTD3ASCIIRules flags set, and let <var title="">new value</var> be the result of the ToASCII
+ algorithm.</p>
- <p>If ToASCII fails to convert one of the components of the
- string, e.g. because it is too long or because it contains invalid
- characters, then throw a <code>SecurityError</code> exception and abort
- these steps. <a href="#refsRFC3490">[RFC3490]</a></p>
+ <p>If ToASCII fails to convert one of the components of the string, e.g. because it is too long
+ or because it contains invalid characters, then throw a <code>SecurityError</code> exception and
+ abort these steps. <a href="#refsRFC3490">[RFC3490]</a></p>
</li>
<li>
- <p>If <var title="">new value</var> is not exactly equal to the
- current value of the <code
- title="dom-document-domain">document.domain</code> attribute, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not exactly equal to the current value of the <code
+ title="dom-document-domain">document.domain</code> attribute, then run these substeps:</p>
<ol>
<li>
- <p>If the current value is an IP address, throw a
- <code>SecurityError</code> exception and abort these steps.</p>
+ <p>If the current value is an IP address, throw a <code>SecurityError</code> exception and
+ abort these steps.</p>
</li>
<li>
- <p>If <var title="">new value</var>, prefixed by a U+002E FULL
- STOP (.), does not exactly match the end of the current value,
- throw a <code>SecurityError</code> exception and abort these
- steps.</p>
+ <p>If <var title="">new value</var>, prefixed by a U+002E FULL STOP (.), does not exactly
+ match the end of the current value, throw a <code>SecurityError</code> exception and abort
+ these steps.</p>
- <!-- this is the step that prevents us from ever setting
- document.domain if the >effective script origin< isn't a
- scheme/host/port tuple -->
+ <!-- this is the step that prevents us from ever setting document.domain if the >effective
+ script origin< isn't a scheme/host/port tuple -->
</li>
<li>
- <p>If <var title="">new value</var> matches a suffix in the
- Public Suffix List, or, if <var title="">new value</var>,
- prefixed by a U+002E FULL STOP (.), matches the end of a
- suffix in the Public Suffix List, then throw a
- <code>SecurityError</code> exception and abort these steps. <a
- href="#refsPSL">[PSL]</a></p>
+ <p>If <var title="">new value</var> matches a suffix in the Public Suffix List, or, if <var
+ title="">new value</var>, prefixed by a U+002E FULL STOP (.), matches the end of a suffix in
+ the Public Suffix List, then throw a <code>SecurityError</code> exception and abort these
+ steps. <a href="#refsPSL">[PSL]</a></p>
- <p>Suffixes must be compared after applying the IDNA ToASCII
- algorithm to them, with both the AllowUnassigned and
- UseSTD3ASCIIRules flags set, in an <span>ASCII
- case-insensitive</span> manner. <a
- href="#refsRFC3490">[RFC3490]</a></p>
+ <p>Suffixes must be compared after applying the IDNA ToASCII algorithm to them, with both the
+ AllowUnassigned and UseSTD3ASCIIRules flags set, in an <span>ASCII case-insensitive</span>
+ manner. <a href="#refsRFC3490">[RFC3490]</a></p>
</li>
@@ -79557,35 +79338,30 @@
<li>
- <p>If the <span>effective script origin</span> of the
- <code>Document</code> is an <span
- title="concept-origin-alias">alias</span>, set it to the value of
- the <span>effective script origin</span> (essentially de-aliasing
- the <span>effective script origin</span>).</p>
+ <p>If the <span>effective script origin</span> of the <code>Document</code> is an <span
+ title="concept-origin-alias">alias</span>, set it to the value of the <span>effective script
+ origin</span> (essentially de-aliasing the <span>effective script origin</span>).</p>
</li>
<li>
- <p>If <var title="">new value</var> is not the empty string, then
- run these substeps:</p>
+ <p>If <var title="">new value</var> is not the empty string, then2 run these substeps:</p>
<ol>
<li>
- <p>Set the host part of the <span>effective script origin</span>
- tuple of the <code>Document</code> to <var title="">new
- value</var>.</p>
+ <p>Set the host part of the <span>effective script origin</span> tuple of the
+ <code>Document</code> to <var title="">new value</var>.</p>
</li>
<li>
- <p>Set the port part of the <span>effective script origin</span>
- tuple of the <code>Document</code> to "manual override" (a value
- that, for the purposes of <span title="same origin">comparing
- origins</span>, is identical to "manual override" but not
+ <p>Set the port part of the <span>effective script origin</span> tuple of the
+ <code>Document</code> to "manual override" (a value that, for the purposes of <span
+ title="same origin">comparing origins</span>, is identical to "manual override" but not
identical to any other value).</p>
</li>
@@ -79596,27 +79372,21 @@
</ol>
- <p>The <dfn title="the document's domain">domain</dfn> of a
- <code>Document</code> is the host part of the document's
- <span>origin</span>, if the value of that <span>origin</span> is a
- scheme/host/port tuple. If it isn't, then the document does not have
- a domain.</p>
+ <p>The <dfn title="the document's domain">domain</dfn> of a <code>Document</code> is the host part
+ of the document's <span>origin</span>, if the value of that <span>origin</span> is a
+ scheme/host/port tuple. If it isn't, then the document does not have a domain.</p>
</div>
- <p class="note">The <code title="dom-document-domain">domain</code>
- attribute is used to enable pages on different hosts of a domain to
- access each others' DOMs.</p>
+ <p class="note">The <code title="dom-document-domain">domain</code> attribute is used to enable
+ pages on different hosts of a domain to access each others' DOMs.</p>
- <p class="warning">Do not use the <code
- title="dom-document-domain">document.domain</code> attribute when
- using shared hosting. If an untrusted third party is able to host an
- HTTP server at the same IP address but on a different port, then the
- same-origin protection that normally protects two different sites on
- the same host will fail, as the ports are ignored when comparing
- origins after the <code
- title="dom-document-domain">document.domain</code> attribute has
- been used.</p>
+ <p class="warning">Do not use the <code title="dom-document-domain">document.domain</code>
+ attribute when using shared hosting. If an untrusted third party is able to host an HTTP server at
+ the same IP address but on a different port, then the same-origin protection that normally
+ protects two different sites on the same host will fail, as the ports are ignored when comparing
+ origins after the <code title="dom-document-domain">document.domain</code> attribute has been
+ used.</p>
<!--TOPIC:HTML-->
More information about the Commit-Watchers
mailing list