[html5] r3747 - [] (0) Update the algorithms to be fully IRI-aware.

whatwg at whatwg.org whatwg at whatwg.org
Thu Sep 3 19:13:36 PDT 2009


Author: ianh
Date: 2009-09-03 19:13:36 -0700 (Thu, 03 Sep 2009)
New Revision: 3747

Modified:
   source
Log:
[] (0) Update the algorithms to be fully IRI-aware.

Modified: source
===================================================================
--- source	2009-09-04 00:12:03 UTC (rev 3746)
+++ source	2009-09-04 02:13:36 UTC (rev 3747)
@@ -71643,21 +71643,36 @@
 
   <ol>
 
-   <li><p><span title="parse a url">Parse</span> the <var
-   title="">url</var> string using the <span>parse a Web
-   address</span> algorithm defined by the Web addresses
-   specification. <a href="#refsWEBADDRESSES">[WEBADDRESSES]</a></p>
-
-   <li><p>If the previous step failed, or if <var title="">url</var>
-   does not have a <span title="url-scheme"><scheme></span>
-   component whose value is either "<code title="">ws</code>" or
-   "<code title="">wss</code>", when compared in an <span>ASCII
-   case-insensitive</span> manner, then fail this algorithm.</p></li>
-
    <li><p>If <var title="">protocol</var> is specified but is either
    the empty string or contains characters that are not in the range
    U+0021 .. U+007E, then fail this algorithm.</p></li>
 
+   <li><p>If the <var title="">url</var> string is not an
+   <span>absolute URL</span>, then fail this algorithm. <a
+   href="#refsWEBADDRESSES">[WEBADDRESSES]</a></p></li>
+
+   <li>
+
+    <p><span title="resolve a url">Resolve</span> the <var
+    title="">url</var> string using the <span>resolve a Web
+    address</span> algorithm defined by the Web addresses
+    specification, with the <span>URL character encoding</span> set to
+    UTF-8. <a href="#refsWEBADDRESSES">[WEBADDRESSES]</a> <a
+    href="#refsRFC3629">[RFC3629]</a></p> <!-- the URL character
+    encoding is used to escape the query component -->
+
+    <p class="note">It doesn't matter what it is resolved relative to,
+    since we already know it is an <span>absolute URL</span> at this
+    point.</p>
+
+   </li>
+
+   <li><p>If <var title="">url</var> does not have a <span
+   title="url-scheme"><scheme></span> component whose value is
+   either "<code title="">ws</code>" or "<code title="">wss</code>",
+   when compared in an <span>ASCII case-insensitive</span> manner,
+   then fail this algorithm.</p></li>
+
    <li><p>If the <span title="url-scheme"><scheme></span>
    component of <var title="">url</var> is "<code title="">ws</code>",
    set <var title="">secure</var> to false; otherwise, the <span
@@ -71668,7 +71683,8 @@
    <li><p>Let <var title="">host</var> be the value of the <span
    title="url-host"><host></span> component of <var
    title="">url</var>, <span>converted to ASCII
-   lowercase</span>.</p></li>
+   lowercase</span>.</p></li> <!-- at this point this is
+   Punycode-encoded already -->
 
    <li><p>If <var title="">url</var> has a <span
    title="url-port"><port></span> component, then let <var
@@ -71681,7 +71697,8 @@
 
    <li><p>Let <var title="">resource name</var> be the value of the
    <span title="url-path"><path></span> component (which might
-   be empty) of <var title="">url</var>.</p></li>
+   be empty) of <var title="">url</var>.</p></li> <!-- at this point
+   this is UTF-8 encoded and %-escaped -->
 
    <li><p>If <var title="">resource name</var> is the empty string,
    set it to a single character U+002F SOLIDUS (/).</p></li>
@@ -71690,7 +71707,8 @@
    title="url-query"><query></span> component, then append a
    single U+003F QUESTION MARK (?) character to <var title="">resource
    name</var>, followed by the value of the <span
-   title="url-query"><query></span> component.</p></li>
+   title="url-query"><query></span> component.</p></li> <!-- at
+   this point this is UTF-8 encoded and %-escaped -->
 
    <li><p>Return <var title="">host</var>, <var title="">port</var>,
    <var title="">resource name</var>, and <var
@@ -72809,7 +72827,7 @@
 
    <dt>URI scheme syntax.</dt>
    <dd>
-    <p>In ABNF terms using the terminals from the IRI specifications: <a href="#refsRFC5238">[RFC5238]</a> <a href="#refsRFC3987">[RFC3987]</a></p>
+    <p>In ABNF terms using the terminals from the IRI specifications: <a href="#refsRFC5234">[RFC5234]</a> <a href="#refsRFC3987">[RFC3987]</a></p>
     <pre>"ws" ":" ihier-part [ "?" iquery ]</pre>
    </dd>
 
@@ -72857,7 +72875,7 @@
 
    <dt>URI scheme syntax.</dt>
    <dd>
-    <p>In ABNF terms using the terminals from the IRI specifications: <a href="#refsRFC5238">[RFC5238]</a> <a href="#refsRFC3987">[RFC3987]</a></p>
+    <p>In ABNF terms using the terminals from the IRI specifications: <a href="#refsRFC5234">[RFC5234]</a> <a href="#refsRFC3987">[RFC3987]</a></p>
     <pre>"ws" ":" ihier-part [ "?" iquery ]</pre>
    </dd>
 




More information about the Commit-Watchers mailing list