Modify url with no refresh
Ok i'm trying to do some url manipulation without refresh. i've read a bunch of articles and everything i read says i have to use parent.location.hash. i don't want this because i don't want to use an anchored navigation. i also don't want the # sign to show up at all. let me explain what i want to accomplish.
let's say your at mysite.com. i want you to be able to click a link and it adds to the url without refreshing the page. i will then write some ajax that will listen for that change and do some functions that i desire. so if you're at mysite.com and you click on the about link, i want the url to read mysite.com/about, but without refreshing the page. i know this has to be possible because i've seen something very similar on actionmethod.com. if anyone has an action method account if you login and type anything in the search and pay attention to the url you will see exactly what i mean. and that's exactly what i want to do. in action method, for those who don't have it, the url will read, for example.
when you login. and when you type something in the search. if you look at the url it will change to (ex. search is "Steps")
the page never refreshes and an ajax is called to perform the search and display it in the middle of the page for you.
i am trying to do the exact same thing. i want to go to mysite.com. then if i click on about it will change the url to mysite.com WITH NO REFRESH and an ajax script will take care of the rest from there.
any suggestions is absolutely welcome. i'm starting to learn jquery and i think it might be able to do what i want so if anyone has any ideas all are welcome
p.s. if anyone knows how to simply remove the # that document.location.hash adds to the url this would work as well. i can do a work around for the anchored navigation. i just hate seeing the # on the url.
so if anyone knows how to make this work,
document.location.hash = "hello";
go to mysite.com/hello instead of mysite.com/#hello
that would perfect. i know this is something the browser adds but there must me some work around to it.
THANK YOU IN ADVANCED FOR ANY POSTS TO THIS REPLY. I APPRECIATE ANYONE EVEN READING THROUGH THIS AND TAKING THE TIME TO ASSIST ME.
Last edited by selanac82; 02-18-2009 at 04:48 PM..
Reason: adding content