Bug 49669
| Summary: | Inconsistent history.replaceState and window.location.hash behaviour | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Dave <showerheadsuk> |
| Component: | DOM | Assignee: | Nobody <webkit-unassigned> |
| Status: | UNCONFIRMED | ||
| Severity: | Normal | CC: | ap, beidson, showerheadsuk |
| Priority: | P2 | ||
| Version: | 528+ (Nightly build) | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
Dave
When replacing the history state with a hash, window.location.hash does not contain the new hash in Safari and Webkit. Google Chrome works as I would expect.
Here is the log using the Developer Tools javascript console to input the commands:
Safari 5.0.2(7533.18.5):
history.replaceState(null,null,'#beans')
undefined
history.replaceState(null,null,'#poy')
undefined
window.location.hash
"#beans"
WebKit r71499:
history.replaceState(null,null,'#beans')
undefined
history.replaceState(null,null,'#poy')
undefined
window.location.hash
""
Chrome 7.0.517.44:
history.replaceState(null,null,'#beans')
undefined
history.replaceState(null,null,'#poy')
undefined
window.location.hash
"#poy"
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |