changing page url without refreshing page

后端 未结 3 2006
耶瑟儿~
耶瑟儿~ 2021-01-01 07:35

Is this even possible?

Here\'s the problem:

I have a keyword search with this URL(after searching) : http://localhost/thi/search?keyword=key

Then I h

3条回答
  •  耶瑟儿~
    2021-01-01 08:28

    The best thing I can suggest for this would be to use the hash in the url. This will allow users to bookmark the url and still keep state when they come back. The other benefit is that you can change the hash without refreshing the page.

    So your url would look something like...http://localhost/thi/search?keyword=key#price=100

    The JQuery Address plugin would work really well for this.

    http://www.asual.com/jquery/address/

提交回复
热议问题