-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpage_modcheck.php
executable file
·109 lines (95 loc) · 3.76 KB
/
page_modcheck.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
<?php
/**
* My IPv4 or IPv6 REST Services API
*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
*
* @copyright Chronolabs Cooperative http://syd.au.snails.email
* @license ACADEMIC APL 2 (https://sourceforge.net/u/chronolabscoop/wiki/Academic%20Public%20License%2C%20version%202.0/)
* @license GNU GPL 3 (http://www.gnu.org/licenses/gpl.html)
* @package myip-api
* @since 1.0.1
* @author Dr. Simon Antony Roberts <[email protected]>
* @version 1.0.3
* @description A REST Services API that returns either or both or all IPv4, IPv6 addresses of a caller!
* @link http://internetfounder.wordpress.com
* @link https://github.com/Chronolabs-Cooperative/MyIP-API-PHP
* @link https://sourceforge.net/p/chronolabs-cooperative
* @link https://facebook.com/ChronolabsCoop
* @link https://twitter.com/ChronolabsCoop
*
*/
require_once './include/common.inc.php';
defined('API_INSTALL') || die('API Installation wizard die');
$pageHasForm = false;
$diagsOK = false;
foreach ($wizard->configs['extensions'] as $ext => $value) {
if (extension_loaded($ext)) {
if (is_array($value[0])) {
$wizard->configs['extensions'][$ext][] = xoDiag(1, implode(',', $value[0]));
} else {
$wizard->configs['extensions'][$ext][] = xoDiag(1, $value[0]);
}
} else {
$wizard->configs['extensions'][$ext][] = xoDiag(0, $value[0]);
}
}
ob_start();
?>
<h3><?php echo REQUIREMENTS; ?></h3>
<table class="table table-hover">
<tbody>
<tr>
<th><?php echo SERVER_API; ?></th>
<td><?php echo php_sapi_name(); ?><br> <?php echo $_SERVER['SERVER_SOFTWARE']; ?></td>
</tr>
<tr>
<th><?php echo _PHP_VERSION; ?></th>
<td><?php echo xoPhpVersion(); ?></td>
</tr>
<tr>
<th><?php printf(PHP_EXTENSION, 'MySQLi'); ?></th>
<td><?php echo xoDiag(function_exists('mysqli_connect') ? 1 : -1, @mysqli_get_client_info()); ?></td>
</tr>
<tr>
<th><?php printf(PHP_EXTENSION, 'Session'); ?></th>
<td><?php echo xoDiag(extension_loaded('session') ? 1 : -1); ?></td>
</tr>
<tr>
<th><?php printf(PHP_EXTENSION, 'PCRE'); ?></th>
<td><?php echo xoDiag(extension_loaded('pcre') ? 1 : -1); ?></td>
</tr>
<tr>
<th><?php printf(PHP_EXTENSION, 'filter'); ?></th>
<td><?php echo xoDiag(extension_loaded('filter') ? 1 : -1); ?></td>
</tr>
<tr>
<th><?php printf(PHP_EXTENSION, 'iconv'); ?></th>
<td><?php echo xoDiag(extension_loaded('iconv') ? 1 : -1); ?></td>
</tr>
<tr>
<th scope="row">file_uploads</th>
<td><?php echo xoDiagBoolSetting('file_uploads', true); ?></td>
</tr>
</tbody>
</table>
<h3><?php echo RECOMMENDED_EXTENSIONS; ?></h3>
<table class="table table-hover">
<caption><?php echo RECOMMENDED_EXTENSIONS_MSG; ?></caption>
<tbody>
<?php
foreach ($wizard->configs['extensions'] as $key => $value) {
echo '<tr><th>' . $value[2] . '</th><td>' . $value[1] . '</td></tr>';
}
?>
</tbody>
</table>
<?php
$content = ob_get_contents();
ob_end_clean();
include './include/install_tpl.php';