c2edfe0f2e69ea589a1d0bff84f0d0d984182325
[atutor.git] / mods / wiki / tools / xt_sysinfo.php
1 <html>
2 <head>
3  <title>PHP System Information</title>
4  <link rel="stylesheet" type="text/css" href="t_config.css">
5 </head>
6 <body bgcolor="#ffffff" text="#000000">
7 <h1>compatibility check</h1>
8 <p>
9  This page only provides compatibility informations about ewiki and your
10  PHP setup/version. Check it on new installations to be aware of problems
11  and workarounds beforehand.
12 </p>
13 <table border="0" summary="info sections">
14 <tr>
15   <th>info</th>
16   <th>value</th>
17   <th>help/workaround</th>
18 </tr>
19 <?php
20    $tests = array(
21       "PHP version" => array(
22          PHP_VERSION,
23          PHP_VERSION<"4.3",
24          "ewiki requires version 4.3 or later, else a few features may not work due to lack of language functionality"
25       ),
26       "safe mode" => array(
27          ini_get("safe_mode"),
28          ini_get("safe_mode"),
29          "The so called 'Safe Mode' cripples the PHP language from a few features, and makes running it on a Unix/Linux server senseless. If your provider has Perl or Python enabled on the server, this setting is clearly dumb or only meant to squeeze additional cash from you (before you get full PHP support). 90% of ewiki plugins will run anyhow. Don't ask for support in the other cases.",
30       ),
31    );
32    foreach ($tests as $title=>$dat) {
33       if ($dat[1]) {
34          $text = $dat[2];
35          $class = "error";
36       }
37       else {
38          $text = "-";
39          $class = "ok";
40       }
41       if (is_bool($dat[0]) || !strlen($dat[0])) {
42          $dat[0] = $dat[0] ? "ON" : "OFF";
43       }
44       echo "<tr>\n"
45          . " <td>$title</td>\n"
46          . " <td class=\"$class\">$dat[0]</td>\n"
47          . " <td>$text</td>\n"
48          . "</tr>\n";
49    }
50 ?>
51 </table>
52 <br><br>
53 </body>
54 </html>