Alex Rivera | Logout

Setting a PHP $_SESSION['var'] using jQuery

Asked 2009-03-03T19:04:01.493
35

I need to set a PHP $_SESSION variable using the jQuery. IF the user clicks on an image I want to save a piece of information associated with that image as a session variable in php.

I think I can do this by calling a php page or function and appending that piece of info to the query string.

Any ideas. I have found little help through google.

thanks mike

Edit
Report

1 Answer

7

Might want to try putting the PHP function on another PHP page, and use an AJAX call to set the variable.

answered 2009-03-03T19:08:40.093

Your Answer