Navigation Menu

What's New?
Alphabetical Listing
Site Contents


Site FAQ
About JSS
JavaScript Forum
JavaScript Tutorial
Friends of JSS

Link to Us
JavaScript Help
Contribute a script
Technology Jobs

Become a Partner

Internet.commerce

Be a Commerce Partner














Internet.com

IT
Developer
Internet News
Small Business
Personal Technology
International

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers

Developer Channel

FlashKit.com
JavaScript.com
JavaScriptSource
Developer Jobs
ScriptSearch
StreamingMediaWorld
Web Developer's Journal
Web Developer's Virtual Library
WebDeveloper.com
Webreference
Web Hosts
XMLfiles.com

Great Sites

DocJavaScript.com
dhtml.com
The Freebie Directory
TheFreeSite.com

Browse Doc JS's Tips!


Hiermenus Central


Promotions

Free Announcements


Social Bookmark

General

This script will save all of your form fields in a cookie. It includes all text fields, radio button selections, checkbox values, etc. When your visitor returns, all form fields are automatically repopulated with the same value that they entered on their last visit.


Notes

Source Code

Paste this source code into the designated areas.

External file

Paste this code into an external JavaScript file named: saveRestoreForm.js


Head

Paste this code into the HEAD section of your HTML document.


User Comments

Add a comment, suggestion, or correction
[For questions about usage, consult the Notes tab above or visit the JavaScript forum. Do not include more than two (2) lines of code in your comments. If you have suggestions or corrections, you can submit them to us.]

    
   
       
[optional]
 
[optional]

   

Comments feed Comment Feed RSS 2.0

12. From: Michael D
Wroks Great!
11/03/2008 14:10:39

This works great! Just what I was looking for. Thanks!!

10. From: Warren Taylor
12/07/2007 16:40:09

I can't make this work. I get a javascript Runtime error at line 39 Error: 'null' is null or not an object

Has anyone been able to make this script work?

11. From: Lee Underwood (Admin)
01/29/2008 11:32:10

Due to the limitations of these comments, you will need to submit your question to the JavaScript Forum for further help.

8. From: sravan
11/06/2007 13:45:22

I want to save and restore form cookies to a form developed by my self. I designed a form using tables. Could you tell how your code can be implemented to tables.

9. From: Lee (Admin)
11/07/2007 15:58:47

Due to the limitations of these comments, you will need to submit your question to the JavaScript Forum for further help.

7. From: mike clarke
Wonderful
09/17/2007 14:18:15

Works perfectly,
Much better than the simple script I was developing,
Thanks for your hard work,
Mike

5. From: Kai
Does not work.
08/26/2007 16:30:03

I added it to a script I made that changes the color of an image and wanted the settings to be saved if the user returns. But this script returns an error

'null' is null or not an object.

line 130.

6. From: Lee (Admin)
10/03/2007 14:51:55

Since it is combined with another script, you will need to submit your question to the JavaScript Forum for further help. Include the link to your Web site or the actual code.

2. From: Monique
thanks for this code!
07/05/2007 17:19:07

it works perfectly!!!!! (in my test page for now)

thanks for the effort :o)!

Monique

3. From: Jason
I cant get it to work at all
07/27/2007 03:13:49

Any help would be great

next comments...

Do you write JavaScripts?
If you do, why not submit them to us?
We'll give you credit and a link back to your Web site.