Re: cvs: pear /Auth Auth.php Container.php /Auth/Container DB.php

From: Date: Wed, 11 Jul 2001 23:48:40 +0000
Subject: Re: cvs: pear /Auth Auth.php Container.php /Auth/Container DB.php
References: 1  Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-260@lists.php.net to get a copy of this message
In article <cvsmj994883731@cvsserver>, Martin Jansen wrote: >--mj994883731 >Content-Type: text/plain >class Auth_Container_DB extends Auth_Container ............ > > $query = sprintf("SELECT * FROM %s WHERE %s = '%s'", > $this->table, > $this->username_col, > $username > ); Hi Martin, Just a small suggestion. It might be handy to select a unix timestamp which you can check against the idle time of the user. Something like: $query = "SELECT UNIX_TIMESTAMP(now()) - UNIX_TIMESTAMP(idle) AS current FROM .... It will allow a person to check against a system wide idle time or a 'per user' based idle time. The unix timestamp works in both mysql and in postgres. I'm not sure about other dbservers. Regards, Hans -- http://phpreview.nl.linux.org

« previous php.pear.cvs (#260) next »