Jump to content

Archived

This topic is now archived and is closed to further replies.

ronverdonk

Exchange data Javascript to PHP in the $_SESSION array

Recommended Posts

Is it possible to pass data from a JavaScript function to the $_SESSION array, so it can be picked up by a PHP script?
I'd be grateful for any help on this.

Ronald  8)

Share this post


Link to post
Share on other sites
I do not think that it's possible as js is only a browser side script language.

But you can use XMLHTTPReqeust object to send data to a php function which will set the session variable for you and then you can use that variable. It's ajaxian approach by the way

Share this post


Link to post
Share on other sites

×

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.