Skip to content
Permalink
Browse files

[giow] (2) Allow parser-inserted scripts to rerun if they failed to b…

…e run by the parser.

Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=10519

git-svn-id: http://svn.whatwg.org/webapps@5496 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information...
Hixie committed Sep 25, 2010
1 parent 1e1573a commit 3b637ebd2a7b0a8fe0e549b07d4aaa528261169f
Showing with 84 additions and 12 deletions.
  1. +28 −4 complete.html
  2. +28 −4 index
  3. +28 −4 source

</li>

<li>

<p>If the element has its <a href=#parser-inserted>"parser-inserted"</a> flag set,
then set <var title="">was-parser-inserted</var> to true and unset
the element's <a href=#parser-inserted>"parser-inserted"</a> flag. Otherwise, set
<var title="">was-parser-inserted</var> to false.</p>

<p class=note>This is done so that if parser-inserted
<code><a href=#script>script</a></code> elements fail to run when the parser tries to
run them, e.g. because they are empty or specify an unsupported
scripting language, another script can later mutate them and cause
them to run again.</p>

<!-- q.v. http://hsivonen.iki.fi/test/moz/script-setting-src-on-parser-inserted-script.html -->

</li>

<li id=script-processing-empty>

<p>If the element has no <code title=attr-script-src><a href=#attr-script-src>src</a></code>
attribute, and its child nodes consist only of comment nodes and
empty <a href=#text-node title="text node">text nodes</a>, then the user
agent must abort these steps at this point. The script is not
executed.</p>
attribute, and its child nodes, if any, consist only of comment
nodes and empty <a href=#text-node title="text node">text nodes</a>, then
the user agent must abort these steps at this point. The script is
not executed.</p>

</li>


</li>

<li>

<p>If <var title="">was-parser-inserted</var> is true, then flag
the element as <a href=#parser-inserted>"parser-inserted"</a> again.</p>

</li>

<li>

<p>If the element's <code><a href=#document>Document</a></code> has an <a href=#active-parser>active
32 index

</li>

<li>

<p>If the element has its <a href=#parser-inserted>"parser-inserted"</a> flag set,
then set <var title="">was-parser-inserted</var> to true and unset
the element's <a href=#parser-inserted>"parser-inserted"</a> flag. Otherwise, set
<var title="">was-parser-inserted</var> to false.</p>

<p class=note>This is done so that if parser-inserted
<code><a href=#script>script</a></code> elements fail to run when the parser tries to
run them, e.g. because they are empty or specify an unsupported
scripting language, another script can later mutate them and cause
them to run again.</p>

<!-- q.v. http://hsivonen.iki.fi/test/moz/script-setting-src-on-parser-inserted-script.html -->

</li>

<li id=script-processing-empty>

<p>If the element has no <code title=attr-script-src><a href=#attr-script-src>src</a></code>
attribute, and its child nodes consist only of comment nodes and
empty <a href=#text-node title="text node">text nodes</a>, then the user
agent must abort these steps at this point. The script is not
executed.</p>
attribute, and its child nodes, if any, consist only of comment
nodes and empty <a href=#text-node title="text node">text nodes</a>, then
the user agent must abort these steps at this point. The script is
not executed.</p>

</li>


</li>

<li>

<p>If <var title="">was-parser-inserted</var> is true, then flag
the element as <a href=#parser-inserted>"parser-inserted"</a> again.</p>

</li>

<li>

<p>If the element's <code><a href=#document>Document</a></code> has an <a href=#active-parser>active
32 source

</li>

<li>

<p>If the element has its <span>"parser-inserted"</span> flag set,
then set <var title="">was-parser-inserted</var> to true and unset
the element's <span>"parser-inserted"</span> flag. Otherwise, set
<var title="">was-parser-inserted</var> to false.</p>

<p class="note">This is done so that if parser-inserted
<code>script</code> elements fail to run when the parser tries to
run them, e.g. because they are empty or specify an unsupported
scripting language, another script can later mutate them and cause
them to run again.</p>

<!-- q.v. http://hsivonen.iki.fi/test/moz/script-setting-src-on-parser-inserted-script.html -->

</li>

<li id="script-processing-empty">

<p>If the element has no <code title="attr-script-src">src</code>
attribute, and its child nodes consist only of comment nodes and
empty <span title="text node">text nodes</span>, then the user
agent must abort these steps at this point. The script is not
executed.</p>
attribute, and its child nodes, if any, consist only of comment
nodes and empty <span title="text node">text nodes</span>, then
the user agent must abort these steps at this point. The script is
not executed.</p>

</li>


</li>

<li>

<p>If <var title="">was-parser-inserted</var> is true, then flag
the element as <span>"parser-inserted"</span> again.</p>

</li>

<li>

<p>If the element's <code>Document</code> has an <span>active

0 comments on commit 3b637eb

Please sign in to comment.
You can’t perform that action at this time.