Link to home
Start Free TrialLog in
Avatar of askurat1
askurat1Flag for United States of America

asked on

How to save the state of the webpage in jquery?

Basically I want to be a able to save the state of my webpage. foe example when I go to my webpage and then I go to the about page and I hit the refresh button it stays on the about page and doesn't go back to the home page. I am using jquery to go to each page or technically its just another section on that page.
Here is a link: http://www.acelogisticsllc.com/vCard-gallery-maps/
I have also added the files.

Thanks,
Tony

main.js
index.html
main.css
Avatar of level9wizard
level9wizard
Flag of Canada image

You could just have your js set a cookie on each click, and when the document loads, check to see if the cookie is set, retrieve the value, and use that to switch the menu.
Avatar of askurat1

ASKER

Do you maybe have an example of this? This was also what I was thinking but not quite sure how to implement it.

Thanks,
Tony
ASKER CERTIFIED SOLUTION
Avatar of HaloWebProjects
HaloWebProjects

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thank you! That works perfect.