How to change URL withought page postback

On July 25

How to change URL withought page postback

In many leading web sites like facebook we find that when we click on the link the content is loaded asynchronously without posting back the page, even though the URL changing :

the following code shows how tochange URL without post back of page, to load content you can use the ajax funtionality :


function changeURL(){


var pageurl = "your url";

 


if (pageurl != window.location) {
            window.history.pushState({ path: pageurl }, '', pageurl);

}


}



Responses

Nice

Yes, really goodone.

Could have been better.

Cool.

?

Leave your comment