This content originally appeared on DEV Community and was authored by Shaswat Raj
Main Article :- https://codexdindia.blogspot.com/2020/12/how-to-change-adress-bar-url-without.html
Documentation Video :- https://www.youtube.com/watch?v=nTiRTyh6ayg
window.history.pushState('new' , 'title' , 'new.html')
Uses :-
1. Use setTimeout's ....
2. Use in Button onclick
Let's use it in a function...
function change(url) {
window.history.pushState('new' , 'title' , url) ;
}
See Demo Here :- https://codexdindia.blogspot.com/2020/12/how-to-change-adress-bar-url-without.html
This content originally appeared on DEV Community and was authored by Shaswat Raj
Shaswat Raj | Sciencx (2022-01-18T05:21:42+00:00) How to change Address bar URL without refreshing the page using JavaScript. Retrieved from https://www.scien.cx/2022/01/18/how-to-change-address-bar-url-without-refreshing-the-page-using-javascript/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.