aboutsummaryrefslogtreecommitdiffhomepage
path: root/wallabag_compatibility_test.php
diff options
context:
space:
mode:
Diffstat (limited to 'wallabag_compatibility_test.php')
-rw-r--r--wallabag_compatibility_test.php111
1 files changed, 69 insertions, 42 deletions
diff --git a/wallabag_compatibility_test.php b/wallabag_compatibility_test.php
index da078623..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');
@@ -22,6 +23,8 @@ $parallel_ok = ((extension_loaded('http') && class_exists('HttpRequestPool')) ||
22$allow_url_fopen_ok = (bool)ini_get('allow_url_fopen'); 23$allow_url_fopen_ok = (bool)ini_get('allow_url_fopen');
23$filter_ok = extension_loaded('filter'); 24$filter_ok = extension_loaded('filter');
24$gettext_ok = function_exists("gettext"); 25$gettext_ok = function_exists("gettext");
26$gd_ok = extension_loaded('gd');
27
25 28
26if (extension_loaded('xmlreader')) { 29if (extension_loaded('xmlreader')) {
27 $xml_ok = true; 30 $xml_ok = true;
@@ -232,10 +235,20 @@ if (isset($_GET['from'])){
232 <td>Enabled</td> 235 <td>Enabled</td>
233 <?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>
234 </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>
235 <tr class="<?php echo ($filter_ok) ? 'enabled' : 'disabled'; ?>"> 243 <tr class="<?php echo ($filter_ok) ? 'enabled' : 'disabled'; ?>">
236 <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>
237 <td>Enabled</td> 245 <td>Enabled</td>
238 <?php echo ($filter_ok) ? '<td class="good">Enabled' : '<td class="pass">Disabled'; ?></td> 246 <?php echo ($filter_ok) ? '<td class="good">Enabled' : '<td class="pass">Disabled'; ?></td>
247 </tr>
248 <tr class="<?php echo ($gd_ok) ? 'enabled' : 'disabled'; ?>">
249 <td><a href="http://php.net/manual/en/book.image.php">GD</a></td>
250 <td>Enabled</td>
251 <?php echo ($gd_ok) ? '<td class="good">Enabled' : '<td class="pass">Disabled'; ?></td>
239 </tr> 252 </tr>
240 <tr class="<?php echo ($tidy_ok) ? 'enabled' : 'disabled'; ?>"> 253 <tr class="<?php echo ($tidy_ok) ? 'enabled' : 'disabled'; ?>">
241 <td><a href="http://php.net/tidy">Tidy</a></td> 254 <td><a href="http://php.net/tidy">Tidy</a></td>
@@ -275,7 +288,7 @@ if (isset($_GET['from'])){
275 <h3>What does this mean?</h3> 288 <h3>What does this mean?</h3>
276 <ol> 289 <ol>
277 <?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): ?>
278 <?php if ($php_ok && $xml_ok && $pcre_ok && $filter_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): ?>
279 <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>
280 <?php else: ?> 293 <?php else: ?>
281 <?php if ($php_ok): ?> 294 <?php if ($php_ok): ?>
@@ -292,48 +305,62 @@ if (isset($_GET['from'])){
292 <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>
293 306
294 <?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>
295 312
296 <?php if ($filter_ok): ?> 313 <?php if ($filter_ok): ?>
297 <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>
298 315
299 <?php if ($zlib_ok): ?> 316 <?php if ($zlib_ok): ?>
300 <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>
301 <?php else: ?> 318 <?php else: ?>
302 <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>
303 <?php endif; ?> 320 <?php endif; ?>
304 321
305 <?php if ($mbstring_ok && $iconv_ok): ?> 322 <?php if ($mbstring_ok && $iconv_ok): ?>
306 <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>
307 <?php elseif ($mbstring_ok): ?> 324 <?php elseif ($mbstring_ok): ?>
308 <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>
309 <?php elseif ($iconv_ok): ?> 326 <?php elseif ($iconv_ok): ?>
310 <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>
311 <?php else: ?> 328 <?php else: ?>
312 <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>
313 <?php endif; ?> 330 <?php endif; ?>
314 331
315 <?php if ($tidy_ok): ?> 332 <?php if ($gd_ok): ?>
316 <li><strong>Tidy:</strong> You have <code>Tidy</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>
317 <?php else: ?> 334 <?php else: ?>
318 <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> 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>
319 <?php endif; ?> 336 <?php endif; ?>
320 337
321 <?php if ($curl_ok): ?> 338 <?php if ($tidy_ok): ?>
322 <li><strong>cURL:</strong> You have <code>cURL</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>
323 <?php else: ?> 340 <?php else: ?>
324 <li><strong>cURL:</strong> The <code>cURL</code> extension is not available. SimplePie will use <code>fsockopen()</code> instead.</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>
325 <?php endif; ?> 342 <?php endif; ?>
326 343
327 <?php if ($parallel_ok): ?> 344 <?php if ($curl_ok): ?>
328 <li><strong>Parallel URL fetching:</strong> You have <code>HttpRequestPool</code> or <code>curl_multi</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>
329 <?php else: ?> 346 <?php else: ?>
330 <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> 347 <li><strong>cURL:</strong> The <code>cURL</code> extension is not available. SimplePie will use <code>fsockopen()</code> instead.</li>
331 <?php endif; ?> 348 <?php endif; ?>
332 349
333 <?php else: ?> 350 <?php if ($parallel_ok): ?>
334 <li><strong>Data filtering:</strong> Your PHP configuration has the filter extension disabled. <strong><?php echo $app_name; ?> will not work here.</strong></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>
335 <?php endif; ?> 352 <?php else: ?>
336 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>
354 <?php endif; ?>
355
356 <?php else: ?>
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>
358 <?php endif; ?>
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
337 <?php else : ?> 364 <?php else : ?>
338 <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>
339 <?php endif; ?> 366 <?php endif; ?>