View Full Version : Resolved Passing javascript menu settings

07-13-2011, 08:08 PM
Hello! I have a question about a concept I'm working with. I want to create an html page that displays several links to different pages on the site. The user would then be able to drag and drop these links into some sort of list. That part I have figured out. Once they've finished creating their list, they would be able to click on the links in the list. The question I have is this: if they click on a link in the list and go to that page, can their list again be displayed on the new page along with the items they added to it on the previous page? If this is a simple cookie thing, that is awesome. I can't utilize a database or anything server-side for this. HTML and javascript only. Any help would be hugely appreciated, as my programmer is out today.

07-13-2011, 08:38 PM
i'm guessing your using OL or UL lists to save the links. if thats the case, then i think it is possible with a cookie. since it is a name/value pair, you could store a cookie as

name - value
links - link1, link2, link3, etc.

then use a script on the next page to pull in the cookie, split the values and write them to the list.

07-13-2011, 08:45 PM
Awesome. I figured there was a way. I thought I'd better find out from an authority before giving my client the idea.

This site is a challenge because it has a lot of content, but no support for database, php or anything to make life easier.

Thanks so much for your help!

07-13-2011, 09:21 PM
no problem. you may want to go back and mark this thread as resolved. Also, there is a way to do a client side database using javascript and xml. I have one on a site that I built just to see if I could actually do it. It works pretty well and I like the fact that the clients pc power does the work instead of the server. It's a flat file database, no relationships, but for displaying things such as product code, description, price, etc. it works perfectly.