60
rated 0 times
[
63]
[
3]
/ answers: 1 / hits: 126126
/ 14 Years ago, fri, november 26, 2010, 12:00:00
Is there is a way how to add hash # to my URL without redirect?
More From » jquery
Is there is a way how to add hash # to my URL without redirect?
window.location.hash = 'something';
That is just plain JavaScript.
Your comment...
Hi, what I really need is to add only the hash... something like this:
window.location.hash = '#';
but in this way nothing is added.
Try this...
window.location = '#';
Also, don't forget about the window.location.replace()
method.