Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Session Variables

Status
Not open for further replies.

PaulTEG

Technical User
Sep 26, 2002
4,469
IE
Hi,

I'm running Apache on Linux, and Xitami on XP for a test bed.

I'm looking for a way to store persistent data on the server, preferably not a server dependent strategy, but must-do is a great master.

I'm doing a shopping cart type application, and the user can move freely around the "shop". Normally I would pass the data as hidden fields in the form in the webpage, but with a number of stops, this is going to be hairy to test, let alone implement.

I'm just looking for pointers

Regards
Paul
 
The last system I wrote puts a user identification string in a cookie sent to the users browser. All this is is a unique identifier for the user. When they visit each page, the application looks up their preferences in a database (MySQL) based on that unique identifier.

Will. will@hellacool.co.uk
 
Cheers Will,

I had already listed cookies as a last resort, but I know too many people who are security conscious to the nth degree, and as a consequence cookies aren't my first choice

Regards
Paul
 
Well, I can only think of GET, POST and cookies as being the methods that could be used here to allow a user to maintain a session. You are using POST already, GET I imagine you will have simiar problems to POST, leaving cookies.

Will will@hellacool.co.uk
 
Looks like just the cookie, came across Apache::Session as well, but the CGI::Session should work for both platforms

Thanks for that
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top