Open samrat-more opened 10 years ago
Same issue here. I get the page name as the first thing in the fragment identifier. It prevents me from (trivially) using the hash as a querystring to something else.
I feel bad for the person who answered you on SO who clearly went to a lot of work to explain this to someone who is using this library already (and understands the concept of history state) when he could have just read your two URLs and noticed the difference between them, what he said, and the examples on the demo site. For some reason, the demo site doesn't have the same behavior for me in IE9.
After looking at the demo again it occurs to me that the demo URL ends in /.
I moved my script into a directory and named it index -- voila. The hash state no longer includes the file name. Seems like a huge oversight to me? I can't see why you would need the filename as part of the hash. If nothing else it's definitely undocumented behavior.
History.pushState appending extra #data in URL.
Browser URL other than Internet Explorer
Internet Explorer URL
Extra #mobile-phones getting appended after using History.pushState in Internet Explorer.
I Have tried below code.
I have raised this issue in stackoverflow as well. Link: http://stackoverflow.com/questions/24387055/history-pushstate-in-ie9-adding-hash-tag