Browse Source

admin-page: more friendly if XCache isn't loaded

git-svn-id: svn://svn.lighttpd.net/xcache/trunk@133 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
1.1
Xuefer 15 years ago
parent
commit
47e7def006
  1. 13
      admin/xcache.php

13
admin/xcache.php

@ -82,6 +82,19 @@ function switcher($name, $options)
return implode(' ', $html);
}
if (!extension_loaded('XCache')) {
echo '<h1>XCache is not loaded</h1>';
ob_start();
phpinfo();
$info = ob_get_clean();
if (preg_match('!<td class="v">(.*\\.ini)!', $info, $m)) {
echo "Please check $m[1]";
}
else {
echo "You don't even have a php.in yet?";
}
exit;
}
$pcnt = xcache_count(XC_TYPE_PHP);
$vcnt = xcache_count(XC_TYPE_VAR);

Loading…
Cancel
Save