[gst-cvs] CVS: www/status admin.php,1.4,1.5

Andy Wingo wingo at users.sourceforge.net
Wed Oct 24 12:18:16 PDT 2001


Update of /cvsroot/gstreamer/www/status
In directory usw-pr-cvs1:/tmp/cvs-serv29576/status

Modified Files:
	admin.php 
Log Message:
* documented web site layout in README.website
* there is now one password for gstreamer.net/admin.php that gets carried
  down for all other admin pages
* more documentation on the web site administration scripts in the root admin page


Index: admin.php
===================================================================
RCS file: /cvsroot/gstreamer/www/status/admin.php,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- admin.php	2001/10/20 19:55:26	1.4
+++ admin.php	2001/10/24 19:17:27	1.5
@@ -5,21 +5,27 @@
   $top = get_header('GStreamer: Status: Admin', '..');
 
   if(!isset($PHP_AUTH_USER)) {
-    Header("WWW-Authenticate: Basic realm=\"gstreamer-status-admin\"");
-    Header("HTTP/1.0 401 Unauthorized");
-    echo $top, "<p>You must be an authorized user to access the GStreamer status administration page. Sorry, holmes
-.", get_footer();
-    exit;
-  } else {
-    if (strcmp($PHP_AUTH_USER, $status_user)!=0 ||
-        strcmp($PHP_AUTH_PW, $status_pass)!=0) {
-      Header("WWW-Authenticate: Basic realm=\"gstreamer-status-admin\"");
+      Header("WWW-Authenticate: Basic realm=\"gstreamer-admin\"");
       Header("HTTP/1.0 401 Unauthorized");
-      echo $top, "<p>You must be an authorized user to access the GStreamer status administration page. Sorry, holmes.</p>", get_footer();
+      echo $top;
+      echo <<<EOF
+<p>You must be an authorized user to access the GStreamer administration pages. Sorry.</p>
+EOF;
+      echo get_footer();
       exit;
-    }
-    echo $top;
+  } else if (strcmp($PHP_AUTH_USER, $admin_user)!=0 ||
+             strcmp($PHP_AUTH_PW,   $admin_pass)!=0) {
+      Header("WWW-Authenticate: Basic realm=\"gstreamer-admin\"");
+      Header("HTTP/1.0 401 Unauthorized");
+      echo $top;
+      echo <<<EOF
+<p>You must be an authorized user to access the GStreamer administration pages. Sorry.</p>
+EOF;
+      echo get_footer();
+      exit;
   }
+  
+  echo $top;
 
   $link = mysql_pconnect ($mysql_host, $mysql_user, $mysql_pass);
   mysql_select_db ($mysql_database);





More information about the Gstreamer-commits mailing list