Re: [PHP] Yet another session problem, with a twist.
PHPLib has session functions, and was essentially "what people used" before PHP4. It will of course require a fair bit of work to port your scripts across. Personally I'd change to another host :) Justin French on 29/06/02 2:17 PM, Cysec ([EMAIL PROTECTED]) wrote: > I have already scripted a site using PHP 4 and was at the point of uploading > it to my client's chosen server (decided to go third party) when I discover, > their server is running PHP3, launch is in five days, and I have 40+ pages > using PHP4's session handling (session_start() etc.). This would be a total > pain to change throughout the site, so I was wondering if anyone knew of a > script of functions that emulate PHP4's session handling. I would love to > be able to just update the server, and would have if it were one I was > administrating, however I can't. Any help would be vastly appreciated. > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] yet another session problem
I am testing user-handling of sessions (mysql database) and just do not understand this behavior. my SESSION table is created as CREATE TABLE SESSION ( id varchar(32) NOT NULL default '', time timestamp(14) NOT NULL, user_id mediumint(8) NOT NULL default '-1', data text NOT NULL, PRIMARY KEY (id) ) TYPE=MyISAM; I have a main script index.php3 set" ); } function increment() { $_SESSION['']++; echo "=".$_SESSION[''].""; } function set_() { echo "set "; $_SESSION[''] = 666; } if (isset($_POST['MYVAR'])) set_(); else increment(); echo "$PHP_SELF increment "; echo "$PHP_SELF register "; ?> and sessions.inc: I can see in the log file that session_write() is executed when I register . But there is a problem: PROBLEM: When I register , there is no call to session_write() in the log file, and no data for gets written to the database. Can you duplicate this behavior on your system? Do you have an explanation? Thanks! Rich