linea21-core
[ class tree: linea21-core ] [ index: linea21-core ] [ all elements ]

Source for file index.php

Documentation is available at index.php

  1. <?php
  2. /**
  3.  * @package linea21.core
  4.  * @subpackage admin
  5.  * @author linea21 <info@linea21.com>
  6.  * @version $id SVN
  7.  * @access public
  8.  * @license http://opensource.org/licenses/gpl-3.0.html
  9.  */
  10. include_once("../lib/functions_auth.php");
  11.  
  12.  
  13. if(!isset($_SESSION['sess_is_known'])) header("Location: login.php");
  14.  
  15.  
  16. include_once("../lib/no_cache.php");
  17. if(isset($_POST['rub']))    $rub=$_POST['rub'];
  18. if(isset($_GET['rub']))    $rub=$_GET['rub'];
  19.  
  20. if(!isset($_GET['todo']&& !isset($_POST['todo'])) {
  21.     $todo="list";
  22. else {
  23.     if(isset($_POST['todo']))    $todo=$_POST['todo'];
  24.     if(isset($_GET['todo']))    $todo=$_GET['todo'];
  25. }
  26. include_once("../config/define.php");
  27. include_once("../config/server.php");
  28. include_once("../lib/items.php");
  29.  
  30. if(defined('MOD_DEBUG'&& MOD_DEBUG == true{
  31.   include_once('../class/system/class.bench.php');
  32.   $bench new bench();
  33.   $bench->start_bench();
  34. }
  35.  
  36.  
  37. /**
  38. * Section include
  39. **/
  40.  
  41.  
  42. $dir="../";
  43. if(isset($rub)) {
  44.     switch ($rub{
  45.         case 'level':
  46.         $dir.="level";
  47.         break;
  48.         case 'scale':
  49.         $dir.="scale";
  50.         break;
  51.         case 'theme':
  52.         $dir.="theme";
  53.         break;        
  54.         case 'news':
  55.         $dir.="news";
  56.         break;
  57.         case 'project':
  58.         $dir.="project";
  59.         break;    
  60.         case 'newsletter':
  61.         $dir.="newsletter";
  62.         break;
  63.         case 'publication':
  64.         $dir.="publication";
  65.         break;
  66.         case 'sdi':
  67.         $dir.="sdi";
  68.         break;
  69.         case 'dashboard':
  70.         $dir.="dashboard";
  71.         break;
  72.         case 'user':
  73.         $dir.="user";
  74.         break;
  75.         case 'workshop':
  76.         $dir.="workshop";
  77.         break;
  78.         case 'workshoprep':
  79.         $dir.="workshoprep";
  80.         break;
  81.         case 'yellowpages':
  82.         $dir.="yellowpages";
  83.         break;
  84.         case 'resources':
  85.         $dir.="resources";
  86.         break;
  87.         case 'contents':
  88.         $dir.="contents";
  89.         break;
  90.         case 'system':
  91.         $dir.="system";
  92.         break;
  93.         default:
  94.         $dir.="home";
  95.         $rub="home";
  96.     }
  97. else {
  98.         $dir.="home";
  99.         $rub="home";
  100. }
  101.     
  102. /**
  103. * language include
  104. **/
  105.  
  106. include_once('../lib/lang.php')
  107.  
  108.  
  109.  
  110.  
  111. include_once("../lib/lib_common.php");
  112. include_once("../class/system/class.".SQL.".php");
  113.  
  114. if(defined('MOD_DEBUG'&& MOD_DEBUG == true{
  115.   $bench->add_flag('Pre-execute and includes');
  116. }
  117.  
  118. $sql_entity=SQL;
  119. $sql_object new $sql_entity;
  120. $sql_object -> DBInitialise();
  121. $sql_object -> DBConnexion();
  122. $rub_link="index.php?rub=".$rub;
  123.  
  124. include_once(SQL.'.inc.php');
  125. $sql_inc_file=$dir."/".SQL.".inc.php";
  126. if(file_exists($sql_inc_file)) include_once($sql_inc_file);
  127.  
  128. if(defined('MOD_DEBUG'&& MOD_DEBUG == true{
  129.   $bench->add_flag('... loading SQL files');
  130. }
  131.  
  132. include_once("header.php")
  133.  
  134. if(defined('MOD_DEBUG'&& MOD_DEBUG == true{
  135.   $bench->add_flag('... loading Header file');
  136. }
  137.  
  138. include_once($dir."/index.php")
  139. include_once("common_menu.php");
  140. include_once($dir."/quickbox.php")
  141.  
  142. if(defined('MOD_DEBUG'&& MOD_DEBUG == true{
  143.   $bench->add_flag('... loading Modules files');
  144. }
  145.  
  146. include_once("footer.php");
  147.  
  148. ?>

Documentation generated on Sat, 08 Nov 2008 14:52:38 +0100 by phpDocumentor 1.4.1