Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Pgsql Novice > Difficulties wi...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 3061 of 3160
Post > Topic >>

Difficulties with postgresql based session handlers

by gjwalsh@[EMAIL PROTECTED] ("G. J. Walsh") Apr 5, 2008 at 03:42 PM

Hello!

I have attempted to install a session handler based on the script laid
out on page 442 of "Beginning PHP and PostgreSQL 8". The script works
correctly in that session info is written to the table. For that reason
I have not listed the script which appears to be in general usage.

BUT .... there are 2 problematic areas.

First: in executing this simple script:
<?php

INCLUDE "pgsessionhandlers.php";
session_start();
$_SESSION{'name'] = "George";

?>

followed by the psql: select * from sessioninfo;

I can 'see' the sessionid and the expiration columns. The third column,
'value' was expected to show: name|s:6:"George";
Instead it shows the text column as 64 character hex.
What am I doing/setting that is causing the column data to NOT be
displayed as plain text? 

Second: Later I discovered to my dismay that phppgadmin will no longer
load. The error log complains 'Failed to initialize storage module,
use(path:/var/lib/php)' and points to the 2 lines:
session_name('PPA_ID'); and session_start(); which are invoked from
within /var/www/phppgadmin/libraries/lib.inc.php because
session.auto_start is off (which is correct). 

I suspect there is some kind of conflict arising from the ini settings
related to postgresql sessions. Session.save_handler was originally
equated to files and sessions were logged there (once I changed the file
permissions to 770). When I set up the postgresql session handlers I
changed this equate to 'users' and that change resulted in the logging
to the postgresql table rather then the file.

Sorry for the wordy explanation. I am just a little tormented by this
latest 'resistance' and perhaps it shows. 

If any of you have been down this road before, I'd appreciate a friendly
hand. It is not a matter of life or death (I can simply scrap the use of
postgresql for session logging, after all) but I am trying to utilize
the db to force my familiarity with ever more aspects of it.

Many thanks.

George
 

-- 
Sent via pgsql-novice mailing list (pgsql-novice@[EMAIL PROTECTED]
)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-novice
 




 1 Posts in Topic:
Difficulties with postgresql based session handlers
gjwalsh@[EMAIL PROTECTED]  2008-04-05 15:42:04 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan13V112 Sun Jul 6 19:04:21 CDT 2008.