I don't want to reload I just want to change the value in the url as follows:
http://localhost:3000/boards/10?show_customize=true
to
http://localhost:3000/boards/10?show_customize=false
Can I do this with jquery or javascript?
Yes, this is possible with the history API in the modern browsers using the pushState
method. Here is an explanation .
window.history.pushState({state:'new'},'New State','http://localhost:3000/boards/10?show_customize=false');
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.