[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 #7 from NARUSE, Yui <naruse@airemix.jp> 2012-09-28 15:38:54 UTC ---
(In reply to comment #6)
> But then scripts that combine the components back together need to first check
> if the hostname contains a colon so they can add the brackets back. That does
> not seem ideal.

If you want to combine the components, you should use window.location.host,
or just use windows.location.
Such usecase is not intended for this property.
See also
https://developer.mozilla.org/en-US/docs/DOM/window.location?redirectlocale=en-US&redirectslug=window.location

I think, it doesn't have brackets because hostname means DNS name.

-- 
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 Friday, 28 September 2012 15:38:56 UTC