Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Stop reload when using window.location

On click of a button I am changing window.location.href, i.e. I am adding one query string parameter. This causes the page to be refreshed (as I am changing window.location.href). I want to know is it possible to stop this page refresh and append the query string in the url?

like image 519
Wondering Avatar asked Nov 30 '22 11:11

Wondering


1 Answers

No. You can change the #hashstring, but changing the query string results in a reload.

like image 155
Kobi Avatar answered Dec 05 '22 16:12

Kobi