install/includes/stages/sysreqs.php
changeset 1227 bdac73ed481e
parent 1144 fcb2be1428e7
child 1310 41ac3758ba79
equal deleted inserted replaced
1226:de56132c008d 1227:bdac73ed481e
    12  * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
    12  * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
    13  * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for details.
    13  * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for details.
    14  */
    14  */
    15 
    15 
    16 if ( !defined('IN_ENANO_INSTALL') )
    16 if ( !defined('IN_ENANO_INSTALL') )
    17   die();
    17 	die();
    18 
    18 
    19 require_once(ENANO_ROOT . '/install/includes/libenanoinstall.php');
    19 require_once(ENANO_ROOT . '/install/includes/libenanoinstall.php');
    20 
    20 
    21 global $failed, $warned;
    21 global $failed, $warned;
    22 
    22 
    23 $failed = false;
    23 $failed = false;
    24 $warned = false;
    24 $warned = false;
    25 
    25 
    26 function run_test($code, $desc, $extended_desc, $warn = false)
    26 function run_test($code, $desc, $extended_desc, $warn = false)
    27 {
    27 {
    28   global $failed, $warned;
    28 	global $failed, $warned;
    29   static $cv = true;
    29 	static $cv = true;
    30   $cv = !$cv;
    30 	$cv = !$cv;
    31   $val = eval($code);
    31 	$val = eval($code);
    32   if($val)
    32 	if($val)
    33   {
    33 	{
    34     if($cv) $color='CCFFCC'; else $color='AAFFAA';
    34 		if($cv) $color='CCFFCC'; else $color='AAFFAA';
    35     echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc</td><td style='padding-left: 10px;'><img alt='Test passed' src='../images/check.png' /></td></tr>";
    35 		echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc</td><td style='padding-left: 10px;'><img alt='Test passed' src='../images/check.png' /></td></tr>";
    36   } elseif(!$val && $warn) {
    36 	} elseif(!$val && $warn) {
    37     if($cv) $color='FFFFCC'; else $color='FFFFAA';
    37 		if($cv) $color='FFFFCC'; else $color='FFFFAA';
    38     echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc<br /><b>$extended_desc</b></td><td style='padding-left: 10px;'><img alt='Test passed with warning' src='../images/checkunk.png' /></td></tr>";
    38 		echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc<br /><b>$extended_desc</b></td><td style='padding-left: 10px;'><img alt='Test passed with warning' src='../images/checkunk.png' /></td></tr>";
    39     $warned = true;
    39 		$warned = true;
    40   } else {
    40 	} else {
    41     if($cv) $color='FFCCCC'; else $color='FFAAAA';
    41 		if($cv) $color='FFCCCC'; else $color='FFAAAA';
    42     echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc<br /><b>$extended_desc</b></td><td style='padding-left: 10px;'><img alt='Test failed' src='../images/checkbad.png' /></td></tr>";
    42 		echo "<tr><td style='background-color: #$color; width: 500px; padding: 5px;'>$desc<br /><b>$extended_desc</b></td><td style='padding-left: 10px;'><img alt='Test failed' src='../images/checkbad.png' /></td></tr>";
    43     $failed = true;
    43 		$failed = true;
    44   }
    44 	}
    45 }
    45 }
    46 function is_apache()
    46 function is_apache()
    47 {
    47 {
    48   $r = strstr($_SERVER['SERVER_SOFTWARE'], 'Apache') ? true : false;
    48 	$r = strstr($_SERVER['SERVER_SOFTWARE'], 'Apache') ? true : false;
    49   return $r;
    49 	return $r;
    50 }
    50 }
    51 
    51 
    52 $warnings = array();
    52 $warnings = array();
    53 $failed = false;
    53 $failed = false;
    54 $have_dbms = false;
    54 $have_dbms = false;
    57 $req_apache = is_apache() ? 'good' : 'bad';
    57 $req_apache = is_apache() ? 'good' : 'bad';
    58 
    58 
    59 // Test: PHP
    59 // Test: PHP
    60 if ( version_compare(PHP_VERSION, '5.2.0', '>=') )
    60 if ( version_compare(PHP_VERSION, '5.2.0', '>=') )
    61 {
    61 {
    62   $req_php = 'good';
    62 	$req_php = 'good';
    63 }
    63 }
    64 else if ( version_compare(PHP_VERSION, '5.0.0', '>=') )
    64 else if ( version_compare(PHP_VERSION, '5.0.0', '>=') )
    65 {
    65 {
    66   $warnings[] = $lang->get('sysreqs_req_help_php', array('php_version' => PHP_VERSION));
    66 	$warnings[] = $lang->get('sysreqs_req_help_php', array('php_version' => PHP_VERSION));
    67   $req_php = 'warn';
    67 	$req_php = 'warn';
    68 }
    68 }
    69 else
    69 else
    70 {
    70 {
    71   $failed = true;
    71 	$failed = true;
    72   $req_php = 'bad';
    72 	$req_php = 'bad';
    73 }
    73 }
    74 
    74 
    75 // Test: Safe Mode
    75 // Test: Safe Mode
    76 $req_safemode = !intval(@ini_get('safe_mode'));
    76 $req_safemode = !intval(@ini_get('safe_mode'));
    77 if ( !$req_safemode )
    77 if ( !$req_safemode )
    78 {
    78 {
    79   $warnings[] = $lang->get('sysreqs_req_help_safemode');
    79 	$warnings[] = $lang->get('sysreqs_req_help_safemode');
    80   $failed = true;
    80 	$failed = true;
    81 }
    81 }
    82 
    82 
    83 // Test: MySQL
    83 // Test: MySQL
    84 $req_mysql = function_exists('mysql_connect');
    84 $req_mysql = function_exists('mysql_connect');
    85 if ( $req_mysql )
    85 if ( $req_mysql )
    86   $have_dbms = true;
    86 	$have_dbms = true;
    87 
    87 
    88 // Test: PostgreSQL
    88 // Test: PostgreSQL
    89 $req_pgsql = function_exists('pg_connect');
    89 $req_pgsql = function_exists('pg_connect');
    90 if ( $req_pgsql )
    90 if ( $req_pgsql )
    91   $have_dbms = true;
    91 	$have_dbms = true;
    92 
    92 
    93 if ( !$have_dbms )
    93 if ( !$have_dbms )
    94   $failed = true;
    94 	$failed = true;
    95 
    95 
    96 // Test: File uploads
    96 // Test: File uploads
    97 $req_uploads = intval(@ini_get('file_uploads'));
    97 $req_uploads = intval(@ini_get('file_uploads'));
    98 
    98 
    99 // Test: ctype validation
    99 // Test: ctype validation
   100 $req_ctype = function_exists('ctype_digit');
   100 $req_ctype = function_exists('ctype_digit');
   101 if ( !$req_ctype )
   101 if ( !$req_ctype )
   102   $failed = true;
   102 	$failed = true;
   103 
   103 
   104 // Writability test: config
   104 // Writability test: config
   105 $req_config_w = write_test('config.new.php');
   105 $req_config_w = write_test('config.new.php');
   106 
   106 
   107 // Writability test: .htaccess
   107 // Writability test: .htaccess
   112 
   112 
   113 // Writability test: cache
   113 // Writability test: cache
   114 $req_cache_w = write_test('cache');
   114 $req_cache_w = write_test('cache');
   115 
   115 
   116 if ( !$req_config_w || !$req_htaccess_w || !$req_files_w || !$req_cache_w )
   116 if ( !$req_config_w || !$req_htaccess_w || !$req_files_w || !$req_cache_w )
   117   $warnings[] = $lang->get('sysreqs_req_help_writable');
   117 	$warnings[] = $lang->get('sysreqs_req_help_writable');
   118 
   118 
   119 if ( !$req_config_w )
   119 if ( !$req_config_w )
   120   $failed = true;
   120 	$failed = true;
   121 
   121 
   122 // Extension test: GD
   122 // Extension test: GD
   123 $req_gd = function_exists('imagecreatefrompng') && function_exists('getimagesize') && function_exists('imagecreatetruecolor') && function_exists('imagecopyresampled');
   123 $req_gd = function_exists('imagecreatefrompng') && function_exists('getimagesize') && function_exists('imagecreatetruecolor') && function_exists('imagecopyresampled');
   124 if ( !$req_gd )
   124 if ( !$req_gd )
   125   $warnings[] = $lang->get('sysreqs_req_help_gd2');
   125 	$warnings[] = $lang->get('sysreqs_req_help_gd2');
   126 
   126 
   127 // FS test: ImageMagick
   127 // FS test: ImageMagick
   128 $req_imagick = which('convert');
   128 $req_imagick = which('convert');
   129 if ( !$req_imagick )
   129 if ( !$req_imagick )
   130   $warnings[] = $lang->get('sysreqs_req_help_imagemagick');
   130 	$warnings[] = $lang->get('sysreqs_req_help_imagemagick');
   131 
   131 
   132 $crypto_backend = install_get_crypto_backend();
   132 $crypto_backend = install_get_crypto_backend();
   133 
   133 
   134 if ( $crypto_backend == 'none' )
   134 if ( $crypto_backend == 'none' )
   135   $warnings[] = $lang->get('sysreqs_req_help_crypto_none');
   135 	$warnings[] = $lang->get('sysreqs_req_help_crypto_none');
   136 else if ( $crypto_backend == 'bcmath' )
   136 else if ( $crypto_backend == 'bcmath' )
   137   $warnings[] = $lang->get('sysreqs_req_help_crypto_bcmath');
   137 	$warnings[] = $lang->get('sysreqs_req_help_crypto_bcmath');
   138 
   138 
   139 ?>
   139 ?>
   140 
   140 
   141 <div style="float: right; padding-top: 10px;">
   141 <div style="float: right; padding-top: 10px;">
   142   <form action="install.php?stage=sysreqs" method="post">
   142 	<form action="install.php?stage=sysreqs" method="post">
   143   <?php
   143 	<?php
   144     echo '<input type="hidden" name="language" value="' . $lang_id . '" />';
   144 		echo '<input type="hidden" name="language" value="' . $lang_id . '" />';
   145   ?>
   145 	?>
   146   <button style="display: block; padding-bottom: 3px;">
   146 	<button style="display: block; padding-bottom: 3px;">
   147   <img alt=" " src="images/recheck.png" style="position: relative; top: 3px; left: -2px;" />
   147 	<img alt=" " src="images/recheck.png" style="position: relative; top: 3px; left: -2px;" />
   148     <?php echo $lang->get('sysreqs_btn_refresh'); ?>
   148 		<?php echo $lang->get('sysreqs_btn_refresh'); ?>
   149   </button>
   149 	</button>
   150   </form>
   150 	</form>
   151 </div>
   151 </div>
   152 
   152 
   153 <h3><?php echo $lang->get('sysreqs_heading'); ?></h3>
   153 <h3><?php echo $lang->get('sysreqs_heading'); ?></h3>
   154  <p><?php echo $lang->get('sysreqs_blurb'); ?></p>
   154  <p><?php echo $lang->get('sysreqs_blurb'); ?></p>
   155  
   155  
   156 <span class="menuclear"></span>
   156 <span class="menuclear"></span>
   157 
   157 
   158 <form action="install.php?stage=database" method="post">
   158 <form action="install.php?stage=database" method="post">
   159 <?php
   159 <?php
   160   echo '<input type="hidden" name="language" value="' . $lang_id . '" />';
   160 	echo '<input type="hidden" name="language" value="' . $lang_id . '" />';
   161 ?>
   161 ?>
   162 
   162 
   163 <?php
   163 <?php
   164 if ( !empty($warnings) ):
   164 if ( !empty($warnings) ):
   165 ?>
   165 ?>
   166   <div class="sysreqs_warning">
   166 	<div class="sysreqs_warning">
   167     <h3><?php echo $lang->get('sysreqs_summary_warn_title'); ?></h3>
   167 		<h3><?php echo $lang->get('sysreqs_summary_warn_title'); ?></h3>
   168     <p><?php echo $lang->get('sysreqs_summary_warn_body'); ?></p>
   168 		<p><?php echo $lang->get('sysreqs_summary_warn_body'); ?></p>
   169     <ul>
   169 		<ul>
   170       <li><?php echo implode("</li>\n      <li>", $warnings); ?></li>
   170 			<li><?php echo implode("</li>\n      <li>", $warnings); ?></li>
   171     </ul>
   171 		</ul>
   172   </div>
   172 	</div>
   173 <?php
   173 <?php
   174 endif;
   174 endif;
   175 
   175 
   176 if ( !$have_dbms ):
   176 if ( !$have_dbms ):
   177 ?>
   177 ?>
   178   <div class="sysreqs_error">
   178 	<div class="sysreqs_error">
   179     <h3><?php echo $lang->get('sysreqs_err_no_dbms_title'); ?></h3>
   179 		<h3><?php echo $lang->get('sysreqs_err_no_dbms_title'); ?></h3>
   180     <p><?php echo $lang->get('sysreqs_err_no_dbms_body'); ?></p>
   180 		<p><?php echo $lang->get('sysreqs_err_no_dbms_body'); ?></p>
   181   </div>
   181 	</div>
   182 <?php
   182 <?php
   183 endif;
   183 endif;
   184 if ( empty($warnings) && !$failed ):
   184 if ( empty($warnings) && !$failed ):
   185 ?>
   185 ?>
   186   <div class="sysreqs_success">
   186 	<div class="sysreqs_success">
   187     <h3><?php echo $lang->get('sysreqs_summary_pass_title'); ?></h3>
   187 		<h3><?php echo $lang->get('sysreqs_summary_pass_title'); ?></h3>
   188     <p><?php echo $lang->get('sysreqs_summary_pass_body'); ?></p>
   188 		<p><?php echo $lang->get('sysreqs_summary_pass_body'); ?></p>
   189   </div>
   189 	</div>
   190   <div style="text-align: center;">
   190 	<div style="text-align: center;">
   191     <input type="submit" value="<?php echo $lang->get('meta_btn_continue'); ?>" />
   191 		<input type="submit" value="<?php echo $lang->get('meta_btn_continue'); ?>" />
   192   </div>
   192 	</div>
   193 <?php
   193 <?php
   194 endif;
   194 endif;
   195 
   195 
   196 if ( $failed ):
   196 if ( $failed ):
   197 ?>
   197 ?>
   198   <div class="sysreqs_error">
   198 	<div class="sysreqs_error">
   199     <h3><?php echo $lang->get('sysreqs_summary_fail_title'); ?></h3>
   199 		<h3><?php echo $lang->get('sysreqs_summary_fail_title'); ?></h3>
   200     <p><?php echo $lang->get('sysreqs_summary_fail_body'); ?></p>
   200 		<p><?php echo $lang->get('sysreqs_summary_fail_body'); ?></p>
   201   </div>
   201 	</div>
   202 <?php
   202 <?php
   203 endif;        
   203 endif;        
   204 ?>
   204 ?>
   205 
   205 
   206 <table border="0" cellspacing="0" cellpadding="0" class="sysreqs">
   206 <table border="0" cellspacing="0" cellpadding="0" class="sysreqs">
   207 
   207 
   208 <tr>
   208 <tr>
   209   <th colspan="2"><?php echo $lang->get('sysreqs_heading_serverenv'); ?></th>
   209 	<th colspan="2"><?php echo $lang->get('sysreqs_heading_serverenv'); ?></th>
   210 </tr>
   210 </tr>
   211 
   211 
   212 <tr>
   212 <tr>
   213   <td><?php echo $lang->get('sysreqs_req_apache'); ?></td>
   213 	<td><?php echo $lang->get('sysreqs_req_apache'); ?></td>
   214   <?php
   214 	<?php
   215   if ( $req_apache ):
   215 	if ( $req_apache ):
   216     echo '<td class="good">' . $lang->get('sysreqs_req_found') . '</td>';
   216 		echo '<td class="good">' . $lang->get('sysreqs_req_found') . '</td>';
   217   else:
   217 	else:
   218     echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   218 		echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   219   endif;
   219 	endif;
   220   ?>
   220 	?>
   221 </tr>
   221 </tr>
   222 
   222 
   223 <tr>
   223 <tr>
   224   <td><?php echo $lang->get('sysreqs_req_php'); ?></td>
   224 	<td><?php echo $lang->get('sysreqs_req_php'); ?></td>
   225   <td class="<?php echo $req_php; ?>">v<?php echo PHP_VERSION; ?></td>
   225 	<td class="<?php echo $req_php; ?>">v<?php echo PHP_VERSION; ?></td>
   226 </tr>
   226 </tr>
   227 
   227 
   228 <tr>
   228 <tr>
   229   <td><?php echo $lang->get('sysreqs_req_safemode'); ?></td>
   229 	<td><?php echo $lang->get('sysreqs_req_safemode'); ?></td>
   230   <?php
   230 	<?php
   231   if ( $req_safemode ):
   231 	if ( $req_safemode ):
   232     echo '<td class="good">' . $lang->get('sysreqs_req_disabled') . '</td>';
   232 		echo '<td class="good">' . $lang->get('sysreqs_req_disabled') . '</td>';
   233   else:
   233 	else:
   234     echo '<td class="bad">' . $lang->get('sysreqs_req_enabled') . '</td>';
   234 		echo '<td class="bad">' . $lang->get('sysreqs_req_enabled') . '</td>';
   235   endif;
   235 	endif;
   236   ?>
   236 	?>
   237 </tr>
   237 </tr>
   238 
   238 
   239 <tr>
   239 <tr>
   240   <td><?php echo $lang->get('sysreqs_req_uploads'); ?></td>
   240 	<td><?php echo $lang->get('sysreqs_req_uploads'); ?></td>
   241   <?php
   241 	<?php
   242   if ( $req_uploads ):
   242 	if ( $req_uploads ):
   243     echo '<td class="good">' . $lang->get('sysreqs_req_enabled') . '</td>';
   243 		echo '<td class="good">' . $lang->get('sysreqs_req_enabled') . '</td>';
   244   else:
   244 	else:
   245     echo '<td class="bad">' . $lang->get('sysreqs_req_disabled') . '</td>';
   245 		echo '<td class="bad">' . $lang->get('sysreqs_req_disabled') . '</td>';
   246   endif;
   246 	endif;
   247   ?>
   247 	?>
   248 </tr>
   248 </tr>
   249 
   249 
   250 <tr>
   250 <tr>
   251   <td><?php echo $lang->get('sysreqs_req_ctype'); ?></td>
   251 	<td><?php echo $lang->get('sysreqs_req_ctype'); ?></td>
   252   <?php
   252 	<?php
   253   if ( $req_ctype ):
   253 	if ( $req_ctype ):
   254     echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   254 		echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   255   else:
   255 	else:
   256     echo '<td class="bad">' . $lang->get('sysreqs_req_unsupported') . '</td>';
   256 		echo '<td class="bad">' . $lang->get('sysreqs_req_unsupported') . '</td>';
   257   endif;
   257 	endif;
   258   ?>
   258 	?>
   259 </tr>
   259 </tr>
   260 
   260 
   261 <tr>
   261 <tr>
   262   <td>
   262 	<td>
   263     <?php echo $lang->get('sysreqs_req_crypto'); ?>
   263 		<?php echo $lang->get('sysreqs_req_crypto'); ?>
   264   </td>
   264 	</td>
   265   <?php
   265 	<?php
   266   if ( in_array($crypto_backend, array('bcmath', 'bigint', 'gmp')) )
   266 	if ( in_array($crypto_backend, array('bcmath', 'bigint', 'gmp')) )
   267   {
   267 	{
   268     echo '<td class="good">' . $lang->get("sysreqs_req_{$crypto_backend}") . '</td>';
   268 		echo '<td class="good">' . $lang->get("sysreqs_req_{$crypto_backend}") . '</td>';
   269   }
   269 	}
   270   else
   270 	else
   271   {
   271 	{
   272     echo '<td class="bad">' . $lang->get("sysreqs_req_notfound") . '</td>';
   272 		echo '<td class="bad">' . $lang->get("sysreqs_req_notfound") . '</td>';
   273   }
   273 	}
   274   ?>
   274 	?>
   275 </tr>
   275 </tr>
   276 
   276 
   277 <!-- Database -->
   277 <!-- Database -->
   278 
   278 
   279 <tr>
   279 <tr>
   280   <th colspan="2"><?php echo $lang->get('sysreqs_heading_dbms'); ?></th>
   280 	<th colspan="2"><?php echo $lang->get('sysreqs_heading_dbms'); ?></th>
   281 </tr>
   281 </tr>
   282 
   282 
   283 <tr>
   283 <tr>
   284   <td><?php echo $lang->get('sysreqs_req_mysql'); ?></td>
   284 	<td><?php echo $lang->get('sysreqs_req_mysql'); ?></td>
   285   <?php
   285 	<?php
   286   if ( $req_mysql ):
   286 	if ( $req_mysql ):
   287     echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   287 		echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   288   else:
   288 	else:
   289     echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   289 		echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   290   endif;
   290 	endif;
   291   ?>
   291 	?>
   292 </tr>
   292 </tr>
   293 
   293 
   294 <tr>
   294 <tr>
   295   <td><?php echo $lang->get('sysreqs_req_postgresql'); ?></td>
   295 	<td><?php echo $lang->get('sysreqs_req_postgresql'); ?></td>
   296   <?php
   296 	<?php
   297   if ( $req_pgsql ):
   297 	if ( $req_pgsql ):
   298     echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   298 		echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   299   else:
   299 	else:
   300     echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   300 		echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   301   endif;
   301 	endif;
   302   ?>
   302 	?>
   303 </tr>
   303 </tr>
   304 
   304 
   305 <tr>
   305 <tr>
   306   <th colspan="2"><?php echo $lang->get('sysreqs_heading_files'); ?></th>
   306 	<th colspan="2"><?php echo $lang->get('sysreqs_heading_files'); ?></th>
   307 </tr>
   307 </tr>
   308 
   308 
   309 <tr>
   309 <tr>
   310   <td>
   310 	<td>
   311     <?php echo $lang->get('sysreqs_req_config_writable'); ?>
   311 		<?php echo $lang->get('sysreqs_req_config_writable'); ?>
   312   </td>
   312 	</td>
   313   <?php
   313 	<?php
   314   if ( $req_config_w ):
   314 	if ( $req_config_w ):
   315     echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   315 		echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   316   else:
   316 	else:
   317     echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   317 		echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   318   endif;
   318 	endif;
   319   ?>
   319 	?>
   320 </tr>
   320 </tr>
   321 
   321 
   322 <tr>
   322 <tr>
   323   <td>
   323 	<td>
   324     <?php echo $lang->get('sysreqs_req_htaccess_writable'); ?><br />
   324 		<?php echo $lang->get('sysreqs_req_htaccess_writable'); ?><br />
   325     <small><?php echo $lang->get('sysreqs_req_hint_htaccess_writable'); ?></small>
   325 		<small><?php echo $lang->get('sysreqs_req_hint_htaccess_writable'); ?></small>
   326   </td>
   326 	</td>
   327   <?php
   327 	<?php
   328   if ( $req_htaccess_w ):
   328 	if ( $req_htaccess_w ):
   329     echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   329 		echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   330   else:
   330 	else:
   331     echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   331 		echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   332   endif;
   332 	endif;
   333   ?>
   333 	?>
   334 </tr>
   334 </tr>
   335 
   335 
   336 <tr>
   336 <tr>
   337   <td>
   337 	<td>
   338     <?php echo $lang->get('sysreqs_req_files_writable'); ?>
   338 		<?php echo $lang->get('sysreqs_req_files_writable'); ?>
   339   </td>
   339 	</td>
   340   <?php
   340 	<?php
   341   if ( $req_files_w ):
   341 	if ( $req_files_w ):
   342     echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   342 		echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   343   else:
   343 	else:
   344     echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   344 		echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   345   endif;
   345 	endif;
   346   ?>
   346 	?>
   347 </tr>
   347 </tr>
   348 
   348 
   349 <tr>
   349 <tr>
   350   <td>
   350 	<td>
   351     <?php echo $lang->get('sysreqs_req_cache_writable'); ?>
   351 		<?php echo $lang->get('sysreqs_req_cache_writable'); ?>
   352   </td>
   352 	</td>
   353   <?php
   353 	<?php
   354   if ( $req_cache_w ):
   354 	if ( $req_cache_w ):
   355     echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   355 		echo '<td class="good">' . $lang->get('sysreqs_req_writable') . '</td>';
   356   else:
   356 	else:
   357     echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   357 		echo '<td class="bad">' . $lang->get('sysreqs_req_unwritable') . '</td>';
   358   endif;
   358 	endif;
   359   ?>
   359 	?>
   360 </tr>
   360 </tr>
   361 
   361 
   362 <tr>
   362 <tr>
   363   <th colspan="2"><?php echo $lang->get('sysreqs_heading_images'); ?></th>
   363 	<th colspan="2"><?php echo $lang->get('sysreqs_heading_images'); ?></th>
   364 </tr>
   364 </tr>
   365 
   365 
   366 <tr>
   366 <tr>
   367   <td>
   367 	<td>
   368     <?php echo $lang->get('sysreqs_req_gd2'); ?><br />
   368 		<?php echo $lang->get('sysreqs_req_gd2'); ?><br />
   369     <small><?php echo $lang->get('sysreqs_req_hint_gd2'); ?></small>
   369 		<small><?php echo $lang->get('sysreqs_req_hint_gd2'); ?></small>
   370   </td>
   370 	</td>
   371   <?php
   371 	<?php
   372   if ( $req_gd ):
   372 	if ( $req_gd ):
   373     echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   373 		echo '<td class="good">' . $lang->get('sysreqs_req_supported') . '</td>';
   374   else:
   374 	else:
   375     echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   375 		echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   376   endif;
   376 	endif;
   377   ?>
   377 	?>
   378 </tr>
   378 </tr>
   379 
   379 
   380 <tr>
   380 <tr>
   381   <td>
   381 	<td>
   382     <?php echo $lang->get('sysreqs_req_imagemagick'); ?><br />
   382 		<?php echo $lang->get('sysreqs_req_imagemagick'); ?><br />
   383     <small><?php echo $lang->get('sysreqs_req_hint_imagemagick'); ?></small>
   383 		<small><?php echo $lang->get('sysreqs_req_hint_imagemagick'); ?></small>
   384   </td>
   384 	</td>
   385   <?php
   385 	<?php
   386   if ( $req_imagick ):
   386 	if ( $req_imagick ):
   387     echo '<td class="good">' . $lang->get('sysreqs_req_found') . ' <small>(' . htmlspecialchars($req_imagick) . ')</small></td>';
   387 		echo '<td class="good">' . $lang->get('sysreqs_req_found') . ' <small>(' . htmlspecialchars($req_imagick) . ')</small></td>';
   388   else:
   388 	else:
   389     echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   389 		echo '<td class="bad">' . $lang->get('sysreqs_req_notfound') . '</td>';
   390   endif;
   390 	endif;
   391   ?>
   391 	?>
   392 </tr>
   392 </tr>
   393 
   393 
   394 </table>
   394 </table>
   395 
   395 
   396 <?php
   396 <?php
   397 if ( !$failed ):
   397 if ( !$failed ):
   398 ?>
   398 ?>
   399     <table border="0">
   399 		<table border="0">
   400     <tr>
   400 		<tr>
   401       <td>
   401 			<td>
   402         <input type="submit" value="<?php echo $lang->get('meta_btn_continue'); ?>" />
   402 				<input type="submit" value="<?php echo $lang->get('meta_btn_continue'); ?>" />
   403       </td>
   403 			</td>
   404       <td>
   404 			<td>
   405         <p>
   405 				<p>
   406           <span style="font-weight: bold;"><?php echo $lang->get('meta_lbl_before_continue'); ?></span><br />
   406 					<span style="font-weight: bold;"><?php echo $lang->get('meta_lbl_before_continue'); ?></span><br />
   407           &bull; <?php echo $lang->get('sysreqs_objective_scalebacks'); ?><br />
   407 					&bull; <?php echo $lang->get('sysreqs_objective_scalebacks'); ?><br />
   408           &bull; <?php echo $lang->get('license_objective_have_db_info'); ?>
   408 					&bull; <?php echo $lang->get('license_objective_have_db_info'); ?>
   409         </p>
   409 				</p>
   410       </td>
   410 			</td>
   411     </tr>
   411 		</tr>
   412     </table>
   412 		</table>
   413 <?php
   413 <?php
   414 endif;
   414 endif;
   415 ?>
   415 ?>
   416 </form>
   416 </form>