• Main Page
  • Related Pages
  • Classes
  • Files
  • Directories
  • File List
  • File Members

index.php

Go to the documentation of this file.
00001 <?php
00002 
00003 // Setting error reporting mode
00004     // some 3rd party libraries still use deprecated functions
00005     error_reporting( E_ALL ^ E_NOTICE ^ E_DEPRECATED );
00006 
00007 //Know exactly where in the code the event occurred.
00008 //Zend platform only.
00009 if (function_exists('monitor_set_aggregation_hint') && isset($_REQUEST['cl'])) {
00010     $sAgregationHint = htmlentities($_REQUEST['cl'], ENT_QUOTES, 'UTF-8') . '/';
00011     if (isset($_REQUEST['fnc']))
00012         $sAgregationHint .= htmlentities($_REQUEST['fnc'], ENT_QUOTES, 'UTF-8');
00013     monitor_set_aggregation_hint($sAgregationHint);
00014 }
00015 
00016 
00017 //setting basic configuration parameters
00018 ini_set('session.name', 'sid' );
00019 ini_set('session.use_cookies', 0 );
00020 ini_set('session.use_trans_sid', 0);
00021 ini_set('url_rewriter.tags', '');
00022 ini_set('magic_quotes_runtime', 0);
00023 
00029 function getShopBasePath()
00030 {
00031     return dirname(__FILE__).'/';
00032 }
00033 
00034 
00035 if ( !function_exists( 'isAdmin' )) {
00041     function isAdmin()
00042     {
00043         return false;
00044     }
00045 }
00046 
00047 // custom functions file
00048 require getShopBasePath() . 'modules/functions.php';
00049 
00050 // Generic utility method file
00051 require_once getShopBasePath() . 'core/oxfunctions.php';
00052 
00053 
00054 // set the exception handler already here to catch everything, also uncaught exceptions from the config or utils
00055 
00056 // initializes singleton config class
00057 $myConfig = oxConfig::getInstance();
00058 
00059 //strips magics quote if any
00060 oxUtils::getInstance()->stripGpcMagicQuotes();
00061 
00062 // reset it so it is done with oxnew
00063 $iDebug = $myConfig->getConfigParam('iDebug');
00064 set_exception_handler(array(oxNew('oxexceptionhandler', $iDebug), 'handleUncaughtException'));
00065 // Admin handling
00066 if ( isAdmin() ) {
00067     $myConfig->setConfigParam( 'blAdmin', true );
00068     $myConfig->setConfigParam( 'blTemplateCaching', false );
00069     if ($sAdminDir)
00070         $myConfig->setConfigParam( 'sAdminDir', $sAdminDir );
00071     else
00072         $myConfig->setConfigParam( 'sAdminDir', "admin" );
00073 }
00074 
00075 //Starting the shop
00076 $oShopControl = oxNew('oxShopControl');
00077 $oShopControl->start();

Generated by  doxygen 1.7.1