[Mapbender-commits] r6575 - trunk/mapbender/http/classes

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Mon Jul 5 11:39:55 EDT 2010


Author: christoph
Date: 2010-07-05 15:39:55 +0000 (Mon, 05 Jul 2010)
New Revision: 6575

Modified:
   trunk/mapbender/http/classes/class_user.php
Log:


Modified: trunk/mapbender/http/classes/class_user.php
===================================================================
--- trunk/mapbender/http/classes/class_user.php	2010-07-05 14:49:45 UTC (rev 6574)
+++ trunk/mapbender/http/classes/class_user.php	2010-07-05 15:39:55 UTC (rev 6575)
@@ -429,9 +429,11 @@
     */
     public static function getList($filter) {
     //FIXME: optimize
-      $users = Array();
-      $sql_userlist = "SELECT mb_user_id FROM mb_user ORDER BY mb_user_name";
-      $res_users = db_query($sql_userlist);
+      $name = $filter->name ? $filter->name : "%";
+      
+	  $users = Array();
+      $sql_userlist = "SELECT mb_user_id FROM mb_user WHERE mb_user_name LIKE $1 ORDER BY mb_user_name";
+      $res_users = db_prep_query($sql_userlist, array($name), array("s"));
 
       while($row = db_fetch_array($res_users))
       {



More information about the Mapbender_commits mailing list