Forums

Clear form cache

NickOg 23 Apr, 2013
Hi

What is the procedure for clearing a forms cached values after submit and thus having finishing with the form? I guess I could set $form->data to NULL on exit before I move to the next URL. Is their some action anywhere to deal with this?

Regards

Nick
GreyHead 24 Apr, 2013
Hi Nick,

Most of the time you don't need to as it's rare for a real user to Submit a form more than once. The Session to Data action has an option to clear the session data if you do need to.

Bob
NickOg 24 Apr, 2013
That sounds like the go, Bob. I hadn't spotted that. I was anxious to do that in case a form was completed on a 'public' computer when the data could be picked up by the next user.
GreyHead 24 Apr, 2013
Hi Nick,

If that's a big concern you can also shorten the Joomla! user session from the default 15 minutes down to say 5 minutes. If your forms are short that shouldn't cause any problems with them.

Bob
NickOg 24 Apr, 2013
I will try both Bob. Thanks again for the help.
This topic is locked and no more replies can be posted.