SitePoint Sponsor |
|
User Tag List
Results 1 to 4 of 4
-
Jun 16, 2007, 06:44 #1
- Join Date
- Jul 2004
- Location
- Florida
- Posts
- 51
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Modify browser URL without refresh page
Hi All,
I would like to ask if it is possible to modify some part of the browser URL without refresh page in the OnClick event over a form or link inserted in the HTML code.
Currently I use ...
Code:if (blah == blah) { window.location.href = window.location.href.replace(/\&ni\=on/ig, ''); }
I want to remove "&ni=on" without refresh page as I mentioned.
Is it possible? Any idea is welcome.
Thank you in advance.
Mapg
-
Jun 16, 2007, 12:50 #2
To change the actual URL requires a page refresh there is no way around it. You could use an AJAX form of updating the data.
But no to change the URL in the address bar requires the page to be refreshed.
-
Jun 16, 2007, 13:29 #3
- Join Date
- Jun 2007
- Location
- Butler, PA
- Posts
- 42
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Why would you need to change the url address listed?
-
Jun 16, 2007, 15:13 #4
- Join Date
- Jul 2004
- Location
- Florida
- Posts
- 51
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thank you. I will try with Ajax then.
Mapg
Bookmarks