X-Git-Url: http://git.pjr.cc/?a=blobdiff_plain;f=lib%2Flib.php;h=e446b091e1cd2f9d82f84d7b52ec7d4d77f4136b;hb=38f5cf40e82e0d3cc9bcc52cf5710f883dd3447a;hp=0b5c2213795269a8431f0493bd5d5b36fbccb492;hpb=afe6e413d073cd29e366b0642ef0928db712c8e5;p=glcas.git diff --git a/lib/lib.php b/lib/lib.php index 0b5c221..e446b09 100644 --- a/lib/lib.php +++ b/lib/lib.php @@ -3,8 +3,13 @@ require_once("config.php"); require_once("wsdl.php"); + // first and foremost, load the plugins $basedir = dirname(__FILE__); + +// we load this first +if(file_exists("$basedir/plugins/www.php")) require_once("$basedir/plugins/www.php"); + if(is_dir("$basedir/plugins")) { $dh = opendir("$basedir/plugins"); if($dh) { @@ -23,11 +28,14 @@ if(is_dir("$basedir/plugins")) { function urlInterpretter() { global $BASE_URLS; + global $URL_COMPONENTS; if(isset($_REQUEST["q"])) $qry = $_REQUEST["q"]; else $qry = ""; $urlcomps = preg_split("/[,\/]/", $qry); + $URL_COMPONENTS = $urlcomps; + foreach($BASE_URLS as $bases_cd => $bases) { //echo "
checking $bases_cd for ".$bases["base"]." against \"".$urlcomps[0]."\"
"; if(strtolower($urlcomps[0]) == strtolower($bases["base"])) {