예제 #1
0
			if($steps[STEP_MODULECHECK]['enabled'])
			{
				$page->MainTitle($steps[STEP_MODULECHECK]['title'], 'phpmodule'); 	
				$page->Paragraph('All PHP extensions must be installed in order for the Installer and/or the system to function properly.');

				// Do the module checking
				foreach($steps[STEP_MODULECHECK]['modules'] as $module)
				{
					if(IsModuleInstalled($module))
					{
						$page->SuccessBox('<b><tt>'.$module.'</tt></b> is installed!');
					}
					else
					{
						$page->ErrorBox('<b><tt>'.$module.'</tt></b> is <u>not installed!</u>');
						$phpmodules = false;
					}
				}

				// If all modules are installed
				if($phpmodules)
				{
					$page->FormStart(array('step'=>GetNextStep(STEP_MODULECHECK))); 
					$page->FormSubmit('Next');
					$page->FormClose();
				}

				// There where some errors or problems with the 
				// file IO - show "retry" button
				else
예제 #2
0
         $page->InfoBox('Please specify a name for the database');
         $msg[] = $page->PopQueue();
     } else {
         if ($dbase->DoesDatabaseExist($newdb)) {
             $page->WarningBox('There exists a database with the name <b>' . $newdb . '</b> already, please choose another one.');
             $msg[] = $page->PopQueue();
         } else {
             if (!$dbase->IsDatabaseFriendly($newdb)) {
                 $page->WarningBox('The database name <b>' . $newdb . '</b> is not valid, please choose another one.');
                 $msg[] = $page->PopQueue();
             } else {
                 if ($dbase->CreateNewDatabase($newdb)) {
                     $page->SuccessBox('The database <b>' . $newdb . '</b> has been created successfully!');
                     $msg[] = $page->PopQueue();
                 } else {
                     $page->ErrorBox('Installer was unable to create the database <b>' . $newdb . '</b>, either select database from a list or contact support.');
                     $msg[] = $page->PopQueue();
                     if ($config['show_database_error_messages']) {
                         $page->ErrorDatabaseBox($dbase->GetDatabaseError());
                         $msg[] = $page->PopQueue();
                     }
                 }
             }
         }
     }
 }
 // Main title with an icon
 $page->MainTitle($steps[STEP_DBSELECT]['title'], 'dbselect');
 // -------------------( Option A: Select database from list )-------------------//
 // Do not show success box of selection IF creating new database!
 if ($step != STEP_DBSELECT) {
예제 #3
0
			if($max === false)
				$max = 'x';

			// Get the current, lower and upper
			$bounds = GetVersionBounds($steps[$step]['phpversion'], $max);
			$CurLow = CompareVersons($bounds['current'], $bounds['lower']);
			$CurHig = CompareVersons($bounds['current'], $bounds['upper']);
			$MinMax = CompareVersons($bounds['lower'], $bounds['upper']);
			$maxStr = ($steps[$step]['maxversion']) ? ' - '.implode('.', $bounds['upper']) : '';
			$verStr = '<br />&nbsp;<br />PHP Version: '.phpversion().'<br />PHP Required: '.implode('.', $bounds['lower']).$maxStr;

			// If minimum is above maximum!
			if($MinMax == 1)
			{
				$page->ErrorBox('Minimum version requirements are higher than maximum requirements. '.
				                'This check will always fail due to incorrect configuration! <br />&nbsp;<br />'.
								'This must be corrected: [min '.$steps[$step]['phpversion'].' &gt; '.$steps[$step]['maxversion'].' max]');
			}

			// If current version is equal or higher than lower bound
			// and is below the upper bound - then accepted!
			if ($CurLow >= 0 && $CurHig < 0)
				$page->SuccessBox('Current PHP version is supported!'.$verStr);			
			else if($CurLow < 0)
				$page->WarningBox('Current PHP version is below minimum requirements!'.$verStr);
			else if($CurHig > 0)
				$page->WarningBox('Current PHP version is above maximum requirements!'.$verStr);
			else if($CurHig == 0)
				$page->WarningBox('Current PHP version is the same as the maximum requirement, which is not supported!'.$verStr);
			else
				$page->WarningBox('Current PHP version not supported!'.$verStr);