从(window.location.hash)删除哈希[重复]

I'm using this code

$("#reset_filter").on("click", function(e) {
    window.location.hash = "";
    window.location.reload();
});

for reset the URL on the page but because of (window.location.hash) on the end of the URL I always get #. Is it possible somehow to remove the hash from the URL? I already have tried with

window.location.href.substr(0, window.location.href.indexOf('#'))

and

window.location.href.split('#')[0]

but it was not working, any proposition and help please.

</div>

No. If you explicitly tell javascript to set a hash-location there will be a hash in the location.

you can just make the page reload or you use

Remove hash from url

this:

< a href='#anchor' onclick='return anchorJump(this.href)'>click

or

http://ajaxian.com/archives/ajax-tackle-the-refresh-button

but anyway what browser do you use?