diff --git a/administrator/includes/framework.php b/administrator/includes/framework.php index df7237ffa01..552b77f2f2d 100644 --- a/administrator/includes/framework.php +++ b/administrator/includes/framework.php @@ -12,20 +12,20 @@ */ // no direct access -defined( '_JEXEC' ) or die( 'Restricted access' ); +defined('_JEXEC') or die('Restricted access'); /* * Joomla! system checks */ -@set_magic_quotes_runtime( 0 ); +@set_magic_quotes_runtime(0); @ini_set('zend.ze1_compatibility_mode', '0'); /* * Installation check, and check on removal of the install directory. */ -if (!file_exists( JPATH_CONFIGURATION . DS . 'configuration.php' ) || (filesize( JPATH_CONFIGURATION . DS . 'configuration.php' ) < 10) /*|| file_exists( JPATH_INSTALLATION . DS . 'index.php' )*/) { - header( 'Location: ../installation/index.php' ); +if (!file_exists(JPATH_CONFIGURATION . DS . 'configuration.php') || (filesize(JPATH_CONFIGURATION . DS . 'configuration.php') < 10) /*|| file_exists(JPATH_INSTALLATION . DS . 'index.php')*/) { + header('Location: ../installation/index.php'); exit(); } @@ -43,38 +43,39 @@ require_once JPATH_CONFIGURATION .DS.'configuration.php'; $CONFIG = new JConfig(); if (@$CONFIG->error_reporting === 0) { - error_reporting( 0 ); + error_reporting(0); } else if (@$CONFIG->error_reporting > 0) { - error_reporting( $CONFIG->error_reporting ); - ini_set( 'display_errors', 1 ); + error_reporting($CONFIG->error_reporting); + ini_set('display_errors', 1); } -define( 'JDEBUG', $CONFIG->debug ); +define('JDEBUG', $CONFIG->debug); -unset( $CONFIG ); +unset($CONFIG); /* * Joomla! framework loading */ // Include object abstract class -jimport( 'joomla.utilities.compat.compat' ); +jimport('joomla.utilities.compat.compat'); // System profiler if (JDEBUG) { - jimport( 'joomla.error.profiler' ); - $_PROFILER =& JProfiler::getInstance( 'Application' ); + jimport('joomla.error.profiler'); + $_PROFILER =& JProfiler::getInstance('Application'); } // Joomla! library imports -jimport( 'joomla.application.menu' ); -jimport( 'joomla.user.user'); -jimport( 'joomla.environment.uri' ); -jimport( 'joomla.html.html' ); -jimport( 'joomla.html.parameter' ); -jimport( 'joomla.utilities.utility' ); -jimport( 'joomla.event.event'); -jimport( 'joomla.event.dispatcher'); -jimport( 'joomla.language.language'); -jimport( 'joomla.utilities.string' ); +jimport('joomla.acl.acl'); +jimport('joomla.application.menu'); +jimport('joomla.user.user'); +jimport('joomla.environment.uri'); +jimport('joomla.html.html'); +jimport('joomla.html.parameter'); +jimport('joomla.utilities.utility'); +jimport('joomla.event.event'); +jimport('joomla.event.dispatcher'); +jimport('joomla.language.language'); +jimport('joomla.utilities.string'); diff --git a/includes/framework.php b/includes/framework.php index 53ffe36f1f7..ba223745f4f 100644 --- a/includes/framework.php +++ b/includes/framework.php @@ -12,21 +12,21 @@ */ // no direct access -defined( '_JEXEC' ) or die( 'Restricted access' ); +defined('_JEXEC') or die('Restricted access'); /* * Joomla! system checks */ -@set_magic_quotes_runtime( 0 ); +@set_magic_quotes_runtime(0); @ini_set('zend.ze1_compatibility_mode', '0'); /* * Installation check, and check on removal of the install directory. */ -if (!file_exists( JPATH_CONFIGURATION . DS . 'configuration.php' ) || (filesize( JPATH_CONFIGURATION . DS . 'configuration.php' ) < 10) /* || file_exists( JPATH_INSTALLATION . DS . 'index.php' )*/) { - if( file_exists( JPATH_INSTALLATION . DS . 'index.php' ) ) { - header( 'Location: installation/index.php' ); +if (!file_exists(JPATH_CONFIGURATION . DS . 'configuration.php') || (filesize(JPATH_CONFIGURATION . DS . 'configuration.php') < 10) /* || file_exists(JPATH_INSTALLATION . DS . 'index.php')*/) { + if(file_exists(JPATH_INSTALLATION . DS . 'index.php')) { + header('Location: installation/index.php'); exit(); } else { echo 'No configuration file found and no installation code available. Exiting...'; @@ -48,36 +48,37 @@ require_once JPATH_CONFIGURATION .DS.'configuration.php'; $CONFIG = new JConfig(); if (@$CONFIG->error_reporting === 0) { - error_reporting( 0 ); + error_reporting(0); } else if (@$CONFIG->error_reporting > 0) { - error_reporting( $CONFIG->error_reporting ); - ini_set( 'display_errors', 1 ); + error_reporting($CONFIG->error_reporting); + ini_set('display_errors', 1); } -define( 'JDEBUG', $CONFIG->debug ); +define('JDEBUG', $CONFIG->debug); -unset( $CONFIG ); +unset($CONFIG); /* * Joomla! framework loading */ // Include object abstract class -jimport( 'joomla.utilities.compat.compat' ); +jimport('joomla.utilities.compat.compat'); // System profiler if (JDEBUG) { - jimport( 'joomla.error.profiler' ); - $_PROFILER =& JProfiler::getInstance( 'Application' ); + jimport('joomla.error.profiler'); + $_PROFILER =& JProfiler::getInstance('Application'); } // Joomla! library imports; -jimport( 'joomla.application.menu' ); -jimport( 'joomla.user.user'); -jimport( 'joomla.environment.uri' ); -jimport( 'joomla.html.html' ); -jimport( 'joomla.utilities.utility' ); -jimport( 'joomla.event.event'); -jimport( 'joomla.event.dispatcher'); -jimport( 'joomla.language.language'); -jimport( 'joomla.utilities.string' ); +jimport('joomla.acl.acl'); +jimport('joomla.application.menu'); +jimport('joomla.user.user'); +jimport('joomla.environment.uri'); +jimport('joomla.html.html'); +jimport('joomla.utilities.utility'); +jimport('joomla.event.event'); +jimport('joomla.event.dispatcher'); +jimport('joomla.language.language'); +jimport('joomla.utilities.string'); diff --git a/xmlrpc/includes/framework.php b/xmlrpc/includes/framework.php index bcd3635e409..4e3b55ce4eb 100644 --- a/xmlrpc/includes/framework.php +++ b/xmlrpc/includes/framework.php @@ -13,18 +13,18 @@ */ // no direct access -defined( '_JEXEC' ) or die( 'Restricted access' ); +defined('_JEXEC') or die('Restricted access'); /* * Joomla! system checks */ -@set_magic_quotes_runtime( 0 ); +@set_magic_quotes_runtime(0); @ini_set('zend.ze1_compatibility_mode', '0'); -if (!file_exists( JPATH_CONFIGURATION . DS . 'configuration.php' ) || (filesize( JPATH_CONFIGURATION . DS . 'configuration.php' ) < 10)) { +if (!file_exists(JPATH_CONFIGURATION . DS . 'configuration.php') || (filesize(JPATH_CONFIGURATION . DS . 'configuration.php') < 10)) { // TODO: Throw 500 error - header( 'Location: ../installation/index.php' ); + header('Location: ../installation/index.php'); exit(); } @@ -42,26 +42,26 @@ require_once JPATH_CONFIGURATION .DS.'configuration.php'; $CONFIG = new JConfig(); if (@$CONFIG->error_reporting === 0) { - error_reporting( 0 ); + error_reporting(0); } else if (@$CONFIG->error_reporting > 0) { - error_reporting( $CONFIG->error_reporting ); - ini_set( 'display_errors', 1 ); + error_reporting($CONFIG->error_reporting); + ini_set('display_errors', 1); } -unset( $CONFIG ); +unset($CONFIG); /* * Joomla! framework loading */ // Include object abstract class -jimport( 'joomla.utilities.compat.compat' ); +jimport('joomla.utilities.compat.compat'); // Joomla! library imports -jimport( 'joomla.environment.uri' ); -jimport( 'joomla.user.user' ); -jimport( 'joomla.event.event'); -jimport( 'joomla.event.dispatcher'); -jimport( 'joomla.plugin.helper' ); -jimport( 'joomla.utilities.string' ); -?> \ No newline at end of file +jimport('joomla.acl.acl'); +jimport('joomla.environment.uri'); +jimport('joomla.user.user'); +jimport('joomla.event.event'); +jimport('joomla.event.dispatcher'); +jimport('joomla.plugin.helper'); +jimport('joomla.utilities.string');