Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1
This is the forum to discuss the Wrox book Professional PHP5 by Ed Lecky-Thompson, Heow Eide-Goodman, Steven D. Nowicki, Alec Cove; ISBN: 9780764572821
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional PHP 5 ISBN: 978-0-7645-7282-1 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 5th, 2005, 01:23 PM
Registered User
 
Join Date: Jan 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Sessions - Chap 15

Is this really the way commercial and bigger sites handle sessions? Does anyone have any experience in saving session info to a database?

Also, there is a problem with the logic for __set in usersession.phpm. The __set function does not check for the existence of the session variable before inserting into the database table. Every time a variable is set, a duplicate record is inserted into the database table. For example, using the test PHP script for TESTVAR = 'foo', I refreshed the page several times and the session_variable table had several records for foo under this session.
 
Old January 10th, 2005, 04:25 AM
Registered User
 
Join Date: Jan 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

From memory two changes need to be made to usersession but dont have the code here to do a diff ( will try later ). The first two instances of $maxlifetime need changed to $session_lifespan (I think - I'm only learning too).

The code I have only creates one session, and I thinl this is what I changed to fix it. My Problem however is getting PHP5 to compile on Suse 9.1 with Postgressql support. :-(




Similar Threads
Thread Thread Starter Forum Replies Last Post
php5 chap 15 help needed twr Beginning PHP 1 January 5th, 2008 06:20 AM
Pro PHP Chap 15 kgmcmillen Pro PHP 1 April 20th, 2006 02:38 PM
chap 15 manal_sag BOOK: Beginning ASP 3.0 2 July 10th, 2005 03:29 AM
help in chap 15 manal_sag BOOK: Beginning ASP 3.0 2 May 25th, 2005 02:59 AM
Chap 15 - Notifying the Bidder airhart BOOK: Beginning ASP 3.0 2 September 4th, 2003 03:05 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.