All pastes #262752 Raw Edit

Untitled

public text v1 · immutable
#262752 ·published 2006-11-30 21:26 UTC
rendered paste body
diff -ruN nagvis.orig/etc/config.ini.php nagvis/etc/config.ini.php
--- nagvis.orig/etc/config.ini.php      2006-11-30 16:22:58.000000000 -0500
+++ nagvis/etc/config.ini.php   2006-11-30 16:24:55.000000000 -0500
@@ -81,9 +81,6 @@

 ; options for the HTML-Backend
 [backend_html]
-
-; with this user, the script reads the CGIs
-[]
 cgiuser="nagios"
 cgi="/usr/local/nagios/sbin/"

@@ -100,7 +97,7 @@
 ;debugginig options for developer purposes
 [debug]
 ; debug on/off (0/1)
-debug=1
+debug=0
 ; debugStates on/off (0/1)
 debugstates=0
 ; debugCheckState on/off (0/1)
Binary files nagvis.orig/includes/classes/.class.CheckState_html.php.swp and nagvis/includes/classes/.class.CheckState_html.php.swp differ
diff -ruN nagvis.orig/includes/classes/class.CheckState_html.php nagvis/includes/classes/class.CheckState_html.php
--- nagvis.orig/includes/classes/class.CheckState_html.php      2006-11-30 16:22:58.000000000 -0500
+++ nagvis/includes/classes/class.CheckState_html.php   2006-11-30 16:25:40.000000000 -0500
@@ -16,6 +16,7 @@
 */
 class backend {
        var $MAINCFG;
+       var $MAPCFG;

        /**
        * Constructor
@@ -33,16 +34,22 @@
        }

        function checkCgiPath() {
-               if(!file_exists($this->MAINCFG->getValue('backend_html', 'cgi'))) {
-                       $FRONTEND = new frontend($this->MAINCFG);
-          $FRONTEND->openSite();
-            $FRONTEND->messageBox("0", "STATUSCGI~".$this->MAINCFG->getValue('backend_html', 'cgi'));
-           $FRONTEND->closeSite();
-            $FRONTEND->printSite();
-
-            exit;
-        }
-    }
+
+               $this->MAPCFG = new MapCfg($this->MAINCFG,$_GET['map']);
+               $this->MAPCFG->readMapConfig();
+
+               if(!file_exists($this->MAINCFG->getValue('backend_html', 'cgi')))
+               {
+                       $FRONTEND = new frontend($this->MAINCFG, $this->MAPCFG);
+
+                       $FRONTEND->openSite();
+                       $FRONTEND->messageBox("0", "STATUSCGI~".$this->MAINCFG->getValue('backend_html', 'cgi'));
+                       $FRONTEND->closeSite();
+                       $FRONTEND->printSite();
+
+                       exit;
+               }
+       }

        /**
        * Find State from a Host