cvs: pearweb /include pear-database.php

From: Date: Sun, 12 Jan 2003 23:03:49 +0000
Subject: cvs: pearweb /include pear-database.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-8206@lists.php.net to get a copy of this message
ssb Sun Jan 12 18:03:49 2003 EDT Modified files: /pearweb/include pear-database.php Log: * added user::listAdmins method Index: pearweb/include/pear-database.php diff -u pearweb/include/pear-database.php:1.113 pearweb/include/pear-database.php:1.114 --- pearweb/include/pear-database.php:1.113 Sun Dec 1 13:37:32 2002 +++ pearweb/include/pear-database.php Sun Jan 12 18:03:48 2003 @@ -17,7 +17,7 @@ | Tomas V.V.Cox <cox@php.net> | | Martin Jansen <mj@php.net> | +----------------------------------------------------------------------+ - $Id: pear-database.php,v 1.113 2002/12/01 18:37:32 richard Exp $ + $Id: pear-database.php,v 1.114 2003/01/12 23:03:48 ssb Exp $ */ require_once 'DB/storage.php'; @@ -1534,6 +1534,17 @@ $sth = $dbh->query($query, array($handle)); return ($sth->numRows() > 0); + } + + // }}} + // {{{ proto bool user::listAdmins() + + function listAdmins() + { + global $dbh; + + $query = "SELECT email FROM users WHERE admin = 1"; + return $dbh->getCol($query); } // }}}

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