From: cajus Date: Tue, 13 Nov 2007 18:41:10 +0000 (+0000) Subject: Updated to load index.php from html directory X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=356897aedf8d2dee40316857f40813072dc33ea5;p=gosa.git Updated to load index.php from html directory git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-playground@7793 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/html/index.php b/html/index.php new file mode 100755 index 000000000..857f1cd20 --- /dev/null +++ b/html/index.php @@ -0,0 +1,35 @@ +load("../gosa.conf"); + + /* Get a new instance of the main Viewport */ + $vc= new ViewportController(); + echo $vc->render(); + +} catch (Exception $e) { + echo "\n-GOsa Exception-----------------------------------------------------------\n\n". + $e->__toString(). + "\n\n--------------------------------------------------------------------------\n\n"; +} + +exit (0); + +?> diff --git a/include/class_ViewportController.inc b/include/class_ViewportController.inc index 692de5018..9eeda233a 100644 --- a/include/class_ViewportController.inc +++ b/include/class_ViewportController.inc @@ -55,7 +55,7 @@ class ViewportController { /* Do Smarty setup */ $this->Smarty= new Smarty; - $this->Smarty->template_dir= $BASE_DIR.'/templates/'; + $this->Smarty->template_dir= BASE_DIR.'/templates/'; $this->Smarty->caching= $config->getValue('cache-templates', FALSE); $this->Smarty->php_handling= SMARTY_PHP_REMOVE; @@ -64,7 +64,7 @@ class ViewportController { /* Check if our template directory is accessible */ if (!(is_dir($this->Smarty->compile_dir) && is_writable($this->Smarty->compile_dir))){ - throw new ViewportControllerException(sprintf(_("Directory '%s' specified as compile-directory is not accessible!"), $smarty->compile_dir)); + throw new ViewportControllerException(sprintf(_("Directory '%s' specified as compile-directory is not accessible!"), $this->Smarty->compile_dir)); } /* Check for old files in compile directory */ @@ -74,7 +74,6 @@ class ViewportController { private function cleanSmartyCompileDir() { #TODO: Clean compile dir - echo "TODO: clean compile dir\n"; } @@ -83,7 +82,7 @@ class ViewportController { /* Get the browser language if */ $lang= Utils::getBrowserLanguage(); if ($this->language != $lang){ - echo "Emit EventObject for changed language\n"; + #TODO: Emit EventObject for changed language $this->language= $lang; } diff --git a/index.php b/index.php deleted file mode 100755 index 5d71f7c21..000000000 --- a/index.php +++ /dev/null @@ -1,37 +0,0 @@ -#!/usr/bin/php -load("gosa.conf"); - - /* Get a new instance of the main Viewport */ - $vc= new ViewportController(); - echo $vc->render(); - -} catch (Exception $e) { - echo "\n-GOsa Exception-----------------------------------------------------------\n\n". - $e->__toString(). - "\n\n--------------------------------------------------------------------------\n\n"; -} - -exit (0); - -?>