Jump to content

Store form values in PHP Session variables before form is submitted


Recommended Posts

I have a form which will be submitted normally but there are a few fields I want storing in PHP session variables as they are typed in ie. before form submisssion. 

I was looking at possibly using onkeyup for each of these fields to run a function that stores the current form field value into the session variable.

 

I'm proficient at PHP but don't know much javascript/jquery and have never used ajax.

 

If anyone knows of a simple way to achieve this I would be greatful for suggestions and example code snippets.

Ok, thanks. I've looked through some of these tutorials and they look good for starting with jQuery so I'll work my way through some.

 

In the meantime if anyone knows of an example or tutorial that is close to what I'm try to achieve I'd be grateful if they could share.

I wouldn't have thought it would be too complicated to set a PHP session variable to the contents of a text form field as a user types in it - I thought I'd find an example of this but after lots of searching I've failed to find an easy way to do it. Any suggestions gladly received. Thanks

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.