Index: trunk/ippMonitor/raw/ipp.php
===================================================================
--- trunk/ippMonitor/raw/ipp.php	(revision 11490)
+++ trunk/ippMonitor/raw/ipp.php	(revision 12835)
@@ -28,4 +28,22 @@
     echo "</form>\n";
 
+    $db = dbconnect('ippadmin');
+
+    // make this a DB lookup
+    $sql = "SELECT projname FROM projects";
+
+    $qry = $db->query($sql);
+    if (DB::iserror($db)) {
+      echo "<b>error reading project list</b><br>\n";
+      menu_end();
+    }
+  
+    echo "<table class=select>\n";
+    echo "<tr class=select><th class=select> projects </th></tr>\n";
+    while ($qry->fetchInto($row)) {
+      echo "<tr class=select><td class=select> $row[0] </td></tr>\n";
+    }
+    echo "</table>\n";
+
     menu_end ();
 }
@@ -34,9 +52,13 @@
 
   // connect to the database
+  // these should be set on installation
   require_once('DB.php');
-  $db = DB::connect("mysql://ipp:ipp@alala/$database");
+  $password = "ipp";
+  $username = "ipp";
+  $hostname = "alala";
+  $db = DB::connect("mysql://$username:$password@$hostname/$database");
   if (DB::iserror($db)) {
     echo "<b>error accessing database</b><br>\n";
-    echo "<b>tried mysql://ipp:ipp@localhost/ipp</b><br>\n";
+    echo "<b>tried mysql://$username:$password@$hostname/$database</b><br>\n";
     menu_end();
   }
@@ -57,5 +79,5 @@
   $db = dbconnect('ippadmin');
 
-  // make this a DB lookup
+  // get the users from the DB
   $sql = "SELECT username FROM users WHERE username = '$username' AND password = '$password'";
 
@@ -227,7 +249,7 @@
     }
 	
-    $this = $_SERVER[SCRIPT_NAME]; 
+    $thisname = $_SERVER[SCRIPT_NAME]; 
     $page = "$root/" . $base;
-    if ($page == $this) {
+    if ($page == $thisname) {
 	$style = trim($line[1]);
     } else { 
