View Full Version : Saving Form Web Form Data

10-16-2006, 04:23 PM
Does anybody know how to have a web form remember the text entered in for textboxes and textarea fields, so that when the user brings it up again the form is filled in with the data from before?


10-16-2006, 04:24 PM
cookies? (they are cleared by the user every once in a while)

php storing by IP or login would work too. A bit complex, though... you'd need a database or at least a text file for this. DB would be easier, if possible.

10-16-2006, 06:16 PM
I suppose that I will try cookies then.

10-16-2006, 11:36 PM
cookies? (they are cleared by the user every once in a while)

They might also be rejected outright, and there is a limit to how much data they can hold. Moreover, on a shared machine, the data may not correspond to the original visitor that caused their creation.

If this feature the OP is working on is a must (for example, implementing partial completion of a form), then there's no realistic option in my opinion beyond creating a log-in system where that data is stored on the server.


10-17-2006, 04:01 AM
Sessions (using php) would work. That would ONLY last for the current session which is vaguely defined as "as long as they stay on your pages (where the session is continued in the php code) and don't close the browser window" or something like that.
Wouldn't work long term.
Cookies are what sessions use, but they also find a way around it if the cookie is refused, but only for that session, hence the name.

Yes, if you do need this to function, then logins are what you'd need.