OSDN Git Service

Now this trunk equal 3.62 without documentation. We need to test for install and...
[nucleus-jp/nucleus-jp-ancient.git] / utf8 / nucleus / index.php
index a496456..62a750b 100755 (executable)
        $CONF['UsingAdminArea'] = 1;
 
        // include the admin code
-       include('../config.php');
+       require_once('../config.php');
 
-       if ($CONF['alertOnSecurityRisk'] == 1) {
+       if ($CONF['alertOnSecurityRisk'] == 1)
+       {
                // check if files exist and generate an error if so
                $aFiles = array(
                 '../install' => _ERRORS_INSTALLDIR,
                        'convert'        => _ERRORS_CONVERTDIR\r
                );
                $aFound = array();
-               foreach($aFiles as $fileName => $fileDesc) {
+               foreach($aFiles as $fileName => $fileDesc)
+               {
                        if (@file_exists($fileName))
                                array_push($aFound, $fileDesc);
                }
                if (@is_writable('../config.php')) {
                        array_push($aFound, _ERRORS_CONFIGPHP);
                }
-               if (sizeof($aFound) > 0) {
+               if (sizeof($aFound) > 0)
+               {
                        startUpError(
                                _ERRORS_STARTUPERROR1. implode($aFound, '</li><li>')._ERRORS_STARTUPERROR2,\r
                                _ERRORS_STARTUPERROR3\r
        $bNeedsLogin   = false;
        $bIsActivation = in_array($action, array('activate', 'activatesetpwd'));
 
-       if ($action == 'logout') {
+       if ($action == 'logout')
                $bNeedsLogin = true;\r
-       }
 
-       if (!$member->isLoggedIn() && !$bIsActivation) {
+       if (!$member->isLoggedIn() && !$bIsActivation)
                $bNeedsLogin = true;\r
-       }
 
        // show error if member cannot login to admin
        if ($member->isLoggedIn() && !$member->canLogin() && !$bIsActivation) {
@@ -62,7 +63,8 @@
                $bNeedsLogin = true;
        }
 
-       if ($bNeedsLogin) {
+       if ($bNeedsLogin)
+       {
                setOldAction($action);  // see ADMIN::login() (sets old action in POST vars)
                $action = 'showlogin';
        }