[Bug 11587] [pending URL spec] window.location.hostname should remove brackets of IPv6 host

https://www.w3.org/Bugs/Public/show_bug.cgi?id=11587

--- Comment #9 from NARUSE, Yui <naruse@airemix.jp> 2012-09-29 01:27:34 UTC ---
Is here thinking ideal behavior of Location object,
or reverse engineering existed implementations/web pages?

The majority of existed web world is IE and Gecko,
and they do the same behavior for setting correct IPv6 address.
So if here is the latter, thinking the behavior makes sense or not is nonsense.


Moreover IPv6 within brackets is URI specific syntax.
In RFC2396 (and RFC 2732) there is "hostname" but its definition is
      hostport      = host [ ":" port ]
      host          = hostname | IPv4address | IPv6reference
      ipv6reference = "[" IPv6address "]"
      hostname      = *( domainlabel "." ) toplabel [ "." ]

RFC 3986 doesn't have "hostname":
      host        = IP-literal / IPv4address / reg-name
      IP-literal = "[" ( IPv6address / IPvFuture  ) "]"

Therefore thinking window.location.hostname is a host defined in RFC3986
doesn't have reason.

-- 
Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Saturday, 29 September 2012 01:27:36 UTC