This is a discussion on "Cookie Data" within the Classic ASP section. This forum, and the thread "Cookie Data are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
Cookie Data
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
|||
|
Cookie Data
How do I pre-populate a form's text field with cookie data? I have a form that requests user input. For example, name and initials, among other things. The input is saved into a Cookie. I'd like to have the cookie data fill in the name and initials fields automatically from the cookie. Help!
|
|
|
|
|||
|
Suggestion - take a step back and do NOT store personal data directly in cookies. As and when your site visitors look at their cookies, they're likely to freak out at finding their personal data revealed there - especially if they happen to be sharing a computer at an internet cafe or using an internet telephone at an airport or motorway service area! You're potentially making it easier for the identity thief :o .
Alternative - send out a single cookie that contains a unique key, and save the data for the user on your server - either in a database or a text file. To repopulate the form ... get the cookie ... read the appropriate file or row ... print the contents into the "value" as you display the fields next time. |
|
|||
|
the above answer is what should really be doing, but here ya go anywayz:
|
![]() |
| Tags |
| cookie, data |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [SOLVED] cookie does not get saved | thosecars82 | JavaScript Forum | 2 | May 23rd, 2008 12:13 |
| Help with login script (session/cookie)... | skuliaxe | PHP Forum | 3 | Feb 16th, 2008 14:07 |
| Fortune Cookie | alexgeek | Webforumz Cafe | 7 | Oct 11th, 2007 13:13 |
| (localhost) cookie weirdness | Donny Bahama | PHP Forum | 4 | May 29th, 2007 14:44 |
| Cookie Help! | graeme | JavaScript Forum | 3 | Jun 17th, 2006 14:22 |