mirror of
https://github.com/slawkens/myaac.git
synced 2025-04-27 09:49:22 +02:00
* remove whitespaces (IDE formatting)
This commit is contained in:
parent
bd19b8665a
commit
668e4688c4
22
index.php
22
index.php
@ -46,7 +46,7 @@ define('URI', $uri);
|
||||
if(preg_match("/^[A-Za-z0-9-_%\'+]+\.png$/i", $uri)) {
|
||||
$tmp = explode('.', $uri);
|
||||
$_REQUEST['name'] = urldecode($tmp[0]);
|
||||
|
||||
|
||||
chdir(TOOLS . 'signature');
|
||||
include(TOOLS . 'signature/index.php');
|
||||
exit();
|
||||
@ -121,20 +121,20 @@ else {
|
||||
'/^spells\/[A-Za-z0-9-_%]+\/[A-Za-z0-9-_]+\/?$/' => array('subtopic' => 'spells', 'vocation' => '$1', 'order' => '$2'),
|
||||
'/^gifts\/history\/?$/' => array('subtopic' => 'gifts', 'action' => 'show_history'),
|
||||
);
|
||||
|
||||
|
||||
foreach($rules as $rule => $redirect) {
|
||||
if (preg_match($rule, $uri)) {
|
||||
$tmp = explode('/', $uri);
|
||||
foreach($redirect as $key => $value) {
|
||||
|
||||
|
||||
if(strpos($value, '$') !== false) {
|
||||
$value = str_replace('$' . $value[1], $tmp[$value[1]], $value);
|
||||
}
|
||||
|
||||
|
||||
$_REQUEST[$key] = $value;
|
||||
$_GET[$key] = $value;
|
||||
}
|
||||
|
||||
|
||||
$found = true;
|
||||
break;
|
||||
}
|
||||
@ -200,7 +200,7 @@ $hooks->trigger(HOOK_STARTUP);
|
||||
if(isset($config['anonymous_usage_statistics']) && $config['anonymous_usage_statistics']) {
|
||||
$report_time = 30 * 24 * 60 * 60; // report one time per 30 days
|
||||
$should_report = true;
|
||||
|
||||
|
||||
$value = '';
|
||||
if($cache->enabled() && $cache->fetch('last_usage_report', $value)) {
|
||||
$should_report = time() > (int)$value + $report_time;
|
||||
@ -218,11 +218,11 @@ if(isset($config['anonymous_usage_statistics']) && $config['anonymous_usage_stat
|
||||
$should_report = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if($should_report) {
|
||||
require_once(LIBS . 'usage_statistics.php');
|
||||
Usage_Statistics::report();
|
||||
|
||||
|
||||
updateDatabaseConfig('last_usage_report', time());
|
||||
if($cache->enabled()) {
|
||||
$cache->set('last_usage_report', time());
|
||||
@ -278,7 +278,7 @@ if($config['backward_support']) {
|
||||
$tickers_content = '';
|
||||
$subtopic = PAGE;
|
||||
$main_content = '';
|
||||
|
||||
|
||||
$config['access_admin_panel'] = 2;
|
||||
$group_id_of_acc_logged = 0;
|
||||
if($logged && $account_logged)
|
||||
@ -298,7 +298,7 @@ if($config['backward_support']) {
|
||||
$config['site']['download_page'] = true;
|
||||
$config['site']['serverinfo_page'] = true;
|
||||
$config['site']['screenshot_page'] = true;
|
||||
|
||||
|
||||
if($config['forum'] != '')
|
||||
$config['forum_link'] = (strtolower($config['forum']) == 'site' ? getLink('forum') : $config['forum']);
|
||||
|
||||
@ -363,7 +363,7 @@ if($load_it)
|
||||
}
|
||||
else
|
||||
$content .= $query['body']; // plain html
|
||||
|
||||
|
||||
if(hasFlag(FLAG_CONTENT_PAGES) || superAdmin()) {
|
||||
$content = $twig->render('admin.pages.links.html.twig', array(
|
||||
'page' => array('id' => $query['id'], 'hidden' => $query['hidden'])
|
||||
|
Loading…
x
Reference in New Issue
Block a user