Index: trunk/ippMonitor/raw/ipp.php
===================================================================
--- trunk/ippMonitor/raw/ipp.php	(revision 26888)
+++ trunk/ippMonitor/raw/ipp.php	(revision 26947)
@@ -283,6 +283,5 @@
   if (! $project) { $project = "none"; }
 
-  $file = fopen ($source, "r");
-
+  // hardwire this name based on the configuration (use ipp.php.in)
   global $DBHOST;
   $HOST = $_SERVER['SERVER_NAME'];
@@ -291,7 +290,27 @@
   echo "<table class=menu cellspacing=0px>\n";
 
+  menulines ($source, $root, $append, $project);
+
+  echo '</table></td><td class="body" valign=top>', "\n\n";
+}
+
+function menulines ($source, $root, $append, $project) {
+
+  $file = fopen ($source, "r");
+
+  // loop over the lines in the file and generate lines in the menu
   while ($line = fgetcsv ($file, 1024, "|")) {
+    if (ereg ('^[:blank:]*#', $line[0])) continue;
+    if (count($line) < 2) continue;
+
+    if (count($line) == 2) {
+      $value = trim($line[0]);
+      if ($value == "input") {
+        $value = trim($line[1]);
+        menulines ($value, $root, $append, $project);
+      }
+      continue;
+    }
     if (count($line) != 5) continue;
-    if (ereg ('^[:blank:]*#', $line[0])) continue;
 
     $type = trim($line[2]);
@@ -333,5 +352,4 @@
   }
   fclose ($file);
-  echo '</table></td><td class="body" valign=top>', "\n\n";
 }
 
@@ -430,8 +448,4 @@
   }
   if ($value == "") { return $where; }
-
-  global $restricted;
-  $restricted = 1;
-
   if ($where) { 
     $where = $where . " AND"; 
