close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Store and Set entire form in cookie Help!

Thread began 2/11/2011 4:53 am by acaciasd344844 | Last modified 3/21/2011 7:56 am by Jason Byrnes | 4784 views | 18 replies |

acaciasd344844

Store and Set entire form in cookie Help!

Hi I wonder if someone can help me because I am quite confused, with the cookie toolkit.

I have read the instructions/help file but it doesnt seem to make things clear for me.

I have a form on a page containing 3 list boxes (page1). My users select items from the 3 list boxes and press a search button. The found list is displayed on the same page (page1) under the list boxes. The user then selects an item from the list and is then redirected to another page (page2). Once they have completed editing their work on page2 they have to click on a 'Previous' link, 'javascript' to return to page1. Unfortunately for them they have to perform the same search each time they return to page1.

So what I am after or was hoping to do, was store the search data from the 3 list boxes and possible the list data in a cookie so that each time they return to page1, the data is sitting there, waiting for them to select the next item of the list. If they then decide to perform another search on page1, then the new data is stored in the cookie once again. It is probable so simple but I cant figure out how to do it!


So far I have managed to get the 'Store entire form in cookie' upon Submit on to the form.
I can also see in the WA CookieToolkit List, 'Set entire form from cookie'. Which sounds like the option to use.

But how do I get it to 'Set the entire form from cookie' when the page initially loads and thats if data is stored in it.

Your guidance would be much appreciated


Thanks



John Henderson

Sign in to reply to this post

Jason ByrnesWebAssist

Select the submit button in design view, then add the Store entire form in cookie behavior to the onClick event of the submit button.


Then in the tag selector along the bottom of the Dreamweaver design view, select the Body tag, and add the Set Entire Form From Cookie behavior to the page onLoad behavior.

Sign in to reply to this post

acaciasd344844

Thanks for your prompt reply Jason,

I did exactly as you wrote down, but nothing happens when I return from page2. So now i am not sure if the cookie has been created or has it even stored the data. Is there a way that I can view the contents of the cookie. I also added both cookies from the bindings tab onto the page not sure if i need to or not. But it still didn't work any more ideas?

cheers


john

Sign in to reply to this post

Jason ByrnesWebAssist

please post a link where i can see the page.

Sign in to reply to this post

acaciasd344844

Web link

Hi Jason,

Sorry I couldnt get back to you sooner as I have been really busy on other things.

The web site is a demo managment information system so you will need to login to see the page.

Address: www.midas-demo.acacia-technologies.co.uk/

User Name: demo
Password: demo

You will need to click on the mobile phone icon first in the left frame
Then on the right frame click on the 'Coll' link
Then select the first Item from each drop down list and click on 'Search'
There is only one item in the list

This is the actual page where the cookie should store the found details and retrieve them when returning.

If you click on the street name link
this is where the customers details are found
IF you now click on the word 'Streets' it will return you to the collection listing page

But it does not retrieve the cookie data

Thanks for you for your time, it would be great to get this fixed and working as my customers are fed up having to keep clicking on the word 'Previous'.

Sign in to reply to this post

Jason ByrnesWebAssist

The submit button is storing the form data into a cookie named "m_colllist3_form1"

on the body onload function, it is retrieving a different cookie named editcustomer_form1

Sign in to reply to this post

acaciasd344844

It works but not as I expected

Hi Jason,

Thanxs again for your assistance.

Sign in to reply to this post

Jason ByrnesWebAssist

you say not as you expected?

What is the difference between what it is doing and your expectation?

Sign in to reply to this post

acaciasd344844

Thanks

Hi Jason,

Thanks for the reply, It does store the variables from the drop down menus, but I thought that it would store the list of street names too. It means the user will have to perform a search each time to retrieve the list.

What I found was that when the submit button was used to store the data, the cookie was created before any data was actually found. I removed it and added it to the Street name link. So when a user clicks on the street name the data is stored.

Now I'm guessing if I wanted the street list to be stored then I will have to use an input field, so may be that will work. At the moment I am using a binding field from a recordset.

By the way I did try and respond yesterday but your server or connection to the server was unavailable.

Thanks again for your Help

john

Sign in to reply to this post

Jason ByrnesWebAssist

Ok, so want the search results stored?


If you use DataAssist search to create the search and results page, The search will be stored in a session variable so that when you return to the results page, the search results will still be available:
?lid=ecommerce

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...