aboutsummaryrefslogtreecommitdiffhomepage
path: root/wallabag_compatibility_test.php
diff options
context:
space:
mode:
authortcit <tcit@tcit.fr>2014-09-28 19:12:28 +0200
committertcit <tcit@tcit.fr>2014-09-28 19:12:28 +0200
commitace428669b5b52bd87f169f73901005f4ce59ccb (patch)
treea9eb45c13792eff32005b23feab42bfd2ca9b2e8 /wallabag_compatibility_test.php
parentb37110cc820df17775b208030e4744d7667b3428 (diff)
downloadwallabag-ace428669b5b52bd87f169f73901005f4ce59ccb.tar.gz
wallabag-ace428669b5b52bd87f169f73901005f4ce59ccb.tar.zst
wallabag-ace428669b5b52bd87f169f73901005f4ce59ccb.zip
fix for #758
Diffstat (limited to 'wallabag_compatibility_test.php')
-rw-r--r--wallabag_compatibility_test.php111
1 files changed, 63 insertions, 48 deletions
diff --git a/wallabag_compatibility_test.php b/wallabag_compatibility_test.php
index a1fcdc2a..3f9ff59f 100644
--- a/wallabag_compatibility_test.php
+++ b/wallabag_compatibility_test.php
@@ -14,6 +14,7 @@ $php_ok = (function_exists('version_compare') && version_compare(phpversion(), '
14$pcre_ok = extension_loaded('pcre'); 14$pcre_ok = extension_loaded('pcre');
15$zlib_ok = extension_loaded('zlib'); 15$zlib_ok = extension_loaded('zlib');
16$mbstring_ok = extension_loaded('mbstring'); 16$mbstring_ok = extension_loaded('mbstring');
17$dom_ok = extension_loaded('DOM');
17$iconv_ok = extension_loaded('iconv'); 18$iconv_ok = extension_loaded('iconv');
18$tidy_ok = function_exists('tidy_parse_string'); 19$tidy_ok = function_exists('tidy_parse_string');
19$curl_ok = function_exists('curl_exec'); 20$curl_ok = function_exists('curl_exec');
@@ -24,6 +25,7 @@ $filter_ok = extension_loaded('filter');
24$gettext_ok = function_exists("gettext"); 25$gettext_ok = function_exists("gettext");
25$gd_ok = extension_loaded('gd'); 26$gd_ok = extension_loaded('gd');
26 27
28
27if (extension_loaded('xmlreader')) { 29if (extension_loaded('xmlreader')) {
28 $xml_ok = true; 30 $xml_ok = true;
29} elseif (extension_loaded('xml')) { 31} elseif (extension_loaded('xml')) {
@@ -233,6 +235,11 @@ if (isset($_GET['from'])){
233 <td>Enabled</td> 235 <td>Enabled</td>
234 <?php echo ($iconv_ok) ? '<td class="good">Enabled' : '<td class="bad">Disabled'; ?></td> 236 <?php echo ($iconv_ok) ? '<td class="good">Enabled' : '<td class="bad">Disabled'; ?></td>
235 </tr> --> 237 </tr> -->
238 <tr class="<?php echo ($dom_ok) ? 'enabled' : 'disabled'; ?>">
239 <td><a href="http://php.net/manual/en/book.dom.php">DOM / XML extension</a></td>
240 <td>Enabled</td>
241 <?php echo ($dom_ok) ? '<td class="good">Enabled' : '<td class="bad">Disabled'; ?></td>
242 </tr>
236 <tr class="<?php echo ($filter_ok) ? 'enabled' : 'disabled'; ?>"> 243 <tr class="<?php echo ($filter_ok) ? 'enabled' : 'disabled'; ?>">
237 <td><a href="http://uk.php.net/manual/en/book.filter.php">Data filtering</a></td> 244 <td><a href="http://uk.php.net/manual/en/book.filter.php">Data filtering</a></td>
238 <td>Enabled</td> 245 <td>Enabled</td>
@@ -281,7 +288,7 @@ if (isset($_GET['from'])){
281 <h3>What does this mean?</h3> 288 <h3>What does this mean?</h3>
282 <ol> 289 <ol>
283 <?php //if ($php_ok && $xml_ok && $pcre_ok && $mbstring_ok && $iconv_ok && $filter_ok && $zlib_ok && $tidy_ok && $curl_ok && $parallel_ok && $allow_url_fopen_ok): ?> 290 <?php //if ($php_ok && $xml_ok && $pcre_ok && $mbstring_ok && $iconv_ok && $filter_ok && $zlib_ok && $tidy_ok && $curl_ok && $parallel_ok && $allow_url_fopen_ok): ?>
284 <?php if ($php_ok && $xml_ok && $pcre_ok && $filter_ok && $gd_ok && $tidy_ok && $curl_ok && $parallel_ok && $allow_url_fopen_ok && $gettext_ok && $parse_ini_ok): ?> 291 <?php if ($php_ok && $xml_ok && $pcre_ok && $dom_ok && $filter_ok && $gd_ok && $tidy_ok && $curl_ok && $parallel_ok && $allow_url_fopen_ok && $gettext_ok && $parse_ini_ok): ?>
285 <li><em>You have everything you need to run <?php echo $app_name; ?> properly! Congratulations!</em></li> 292 <li><em>You have everything you need to run <?php echo $app_name; ?> properly! Congratulations!</em></li>
286 <?php else: ?> 293 <?php else: ?>
287 <?php if ($php_ok): ?> 294 <?php if ($php_ok): ?>
@@ -298,54 +305,62 @@ if (isset($_GET['from'])){
298 <li><strong>Gettext:</strong> You have <code>gettext</code> enabled. <em>No problems here.</em></li> 305 <li><strong>Gettext:</strong> You have <code>gettext</code> enabled. <em>No problems here.</em></li>
299 306
300 <?php if ($parse_ini_ok): ?> 307 <?php if ($parse_ini_ok): ?>
308 <li><strong>Parse ini:</strong> You can parse <em>ini</em> files. <em>No problems here.</em></li>
309
310 <?php if ($dom_ok): ?>
311 <li><strong>DOM/XML:</strong> You can parse <em>ini</em> files. <em>No problems here.</em></li>
301 312
302 <?php if ($filter_ok): ?> 313 <?php if ($filter_ok): ?>
303 <li><strong>Data filtering:</strong> You have the PHP filter extension enabled. <em>No problems here.</em></li> 314 <li><strong>Data filtering:</strong> You can use the PHP build-in DOM to operate on XML documents. <em>No problems here.</em></li>
304 315
305 <?php if ($zlib_ok): ?> 316 <?php if ($zlib_ok): ?>
306 <li><strong>Zlib:</strong> You have <code>Zlib</code> enabled. This allows SimplePie to support GZIP-encoded feeds. <em>No problems here.</em></li> 317 <li><strong>Zlib:</strong> You have <code>Zlib</code> enabled. This allows SimplePie to support GZIP-encoded feeds. <em>No problems here.</em></li>
307 <?php else: ?> 318 <?php else: ?>
308 <li><strong>Zlib:</strong> The <code>Zlib</code> extension is not available. SimplePie will ignore any GZIP-encoding, and instead handle feeds as uncompressed text.</li> 319 <li><strong>Zlib:</strong> The <code>Zlib</code> extension is not available. SimplePie will ignore any GZIP-encoding, and instead handle feeds as uncompressed text.</li>
309 <?php endif; ?> 320 <?php endif; ?>
310 321
311 <?php if ($mbstring_ok && $iconv_ok): ?> 322 <?php if ($mbstring_ok && $iconv_ok): ?>
312 <li><strong>mbstring and iconv:</strong> You have both <code>mbstring</code> and <code>iconv</code> installed! This will allow <?php echo $app_name; ?> to handle the greatest number of languages. <em>No problems here.</em></li> 323 <li><strong>mbstring and iconv:</strong> You have both <code>mbstring</code> and <code>iconv</code> installed! This will allow <?php echo $app_name; ?> to handle the greatest number of languages. <em>No problems here.</em></li>
313 <?php elseif ($mbstring_ok): ?> 324 <?php elseif ($mbstring_ok): ?>
314 <li><strong>mbstring:</strong> <code>mbstring</code> is installed, but <code>iconv</code> is not.</li> 325 <li><strong>mbstring:</strong> <code>mbstring</code> is installed, but <code>iconv</code> is not.</li>
315 <?php elseif ($iconv_ok): ?> 326 <?php elseif ($iconv_ok): ?>
316 <li><strong>iconv:</strong> <code>iconv</code> is installed, but <code>mbstring</code> is not.</li> 327 <li><strong>iconv:</strong> <code>iconv</code> is installed, but <code>mbstring</code> is not.</li>
317 <?php else: ?> 328 <?php else: ?>
318 <li><strong>mbstring and iconv:</strong> <em>You do not have either of the extensions installed.</em> This will significantly impair your ability to read non-English feeds, as well as even some English ones.</li> 329 <li><strong>mbstring and iconv:</strong> <em>You do not have either of the extensions installed.</em> This will significantly impair your ability to read non-English feeds, as well as even some English ones.</li>
319 <?php endif; ?> 330 <?php endif; ?>
320 331
321 <?php if ($gd_ok): ?> 332 <?php if ($gd_ok): ?>
322 <li><strong>GD:</strong> You have <code>GD</code> support installed. <em>No problems here.</em></li> 333 <li><strong>GD:</strong> You have <code>GD</code> support installed. <em>No problems here.</em></li>
323 <?php else: ?> 334 <?php else: ?>
324 <li><strong>GD:</strong> The <code>GD</code> extension is not available. <?php echo $app_name; ?> will not be able to download pictures locally on your server.</li> 335 <li><strong>GD:</strong> The <code>GD</code> extension is not available. <?php echo $app_name; ?> will not be able to download pictures locally on your server.</li>
325 <?php endif; ?> 336 <?php endif; ?>
326 337
327 <?php if ($tidy_ok): ?> 338 <?php if ($tidy_ok): ?>
328 <li><strong>Tidy:</strong> You have <code>Tidy</code> support installed. <em>No problems here.</em></li> 339 <li><strong>Tidy:</strong> You have <code>Tidy</code> support installed. <em>No problems here.</em></li>
329 <?php else: ?> 340 <?php else: ?>
330 <li><strong>Tidy:</strong> The <code>Tidy</code> extension is not available. <?php echo $app_name; ?> should still work with most feeds, but you may experience problems with some.</li> 341 <li><strong>Tidy:</strong> The <code>Tidy</code> extension is not available. <?php echo $app_name; ?> should still work with most feeds, but you may experience problems with some.</li>
331 <?php endif; ?> 342 <?php endif; ?>
332 343
333 <?php if ($curl_ok): ?> 344 <?php if ($curl_ok): ?>
334 <li><strong>cURL:</strong> You have <code>cURL</code> support installed. <em>No problems here.</em></li> 345 <li><strong>cURL:</strong> You have <code>cURL</code> support installed. <em>No problems here.</em></li>
335 <?php else: ?> 346 <?php else: ?>
336 <li><strong>cURL:</strong> The <code>cURL</code> extension is not available. SimplePie will use <code>fsockopen()</code> instead.</li> 347 <li><strong>cURL:</strong> The <code>cURL</code> extension is not available. SimplePie will use <code>fsockopen()</code> instead.</li>
337 <?php endif; ?> 348 <?php endif; ?>
338 349
339 <?php if ($parallel_ok): ?> 350 <?php if ($parallel_ok): ?>
340 <li><strong>Parallel URL fetching:</strong> You have <code>HttpRequestPool</code> or <code>curl_multi</code> support installed. <em>No problems here.</em></li> 351 <li><strong>Parallel URL fetching:</strong> You have <code>HttpRequestPool</code> or <code>curl_multi</code> support installed. <em>No problems here.</em></li>
341 <?php else: ?> 352 <?php else: ?>
342 <li><strong>Parallel URL fetching:</strong> <code>HttpRequestPool</code> or <code>curl_multi</code> support is not available. <?php echo $app_name; ?> will use <code>file_get_contents()</code> instead to fetch URLs sequentially rather than in parallel.</li> 353 <li><strong>Parallel URL fetching:</strong> <code>HttpRequestPool</code> or <code>curl_multi</code> support is not available. <?php echo $app_name; ?> will use <code>file_get_contents()</code> instead to fetch URLs sequentially rather than in parallel.</li>
343 <?php endif; ?> 354 <?php endif; ?>
344 355
345 <?php else: ?> 356 <?php else: ?>
346 <li><strong>Data filtering:</strong> Your PHP configuration has the filter extension disabled. <strong><?php echo $app_name; ?> will not work here.</strong></li> 357 <li><strong>Data filtering:</strong> Your PHP configuration has the filter extension disabled. <strong><?php echo $app_name; ?> will not work here.</strong></li>
347 <?php endif; ?> 358 <?php endif; ?>
348 359
360 <?php else: ?>
361 <li><strong>DOM/XML:</strong> Your PHP configuration isn't standard, you're missing PHP-DOM. You may try to install a package or recompile PHP. <strong><?php echo $app_name; ?> will not work here.</strong></li>
362 <?php endif; ?>
363
349 <?php else : ?> 364 <?php else : ?>
350 <li><strong>Parse ini files function :</strong> Bad luck : your webhost has decided to block the use of the <em>parse_ini_file</em> function. <strong><?php echo $app_name; ?> will not work here.</strong> 365 <li><strong>Parse ini files function :</strong> Bad luck : your webhost has decided to block the use of the <em>parse_ini_file</em> function. <strong><?php echo $app_name; ?> will not work here.</strong>
351 <?php endif; ?> 366 <?php endif; ?>