mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-14 09:44:55 +02:00
* replace "$twig->render()" with "$this->display"
This commit is contained in:
@@ -47,7 +47,7 @@ $tmp = '';
|
||||
if(fetchDatabaseConfig('site_closed_message', $tmp))
|
||||
$closed_message = $tmp;
|
||||
|
||||
echo $twig->render('admin.dashboard.html.twig', array(
|
||||
$twig->display('admin.dashboard.html.twig', array(
|
||||
'is_closed' => $is_closed,
|
||||
'closed_message' => $closed_message,
|
||||
'status' => $status
|
||||
@@ -60,7 +60,7 @@ function clearCache()
|
||||
$tmp = '';
|
||||
if($cache->fetch('status', $tmp))
|
||||
$cache->delete('status');
|
||||
|
||||
|
||||
if($cache->fetch('templates', $tmp))
|
||||
$cache->delete('templates');
|
||||
|
||||
@@ -90,7 +90,7 @@ function clearCache()
|
||||
|
||||
if($cache->fetch('news' . $template_name . '_' . TICKER, $tmp))
|
||||
$cache->delete('news' . $template_name . '_' . TICKER);
|
||||
|
||||
|
||||
if($cache->fetch('template_ini' . $template_name, $tmp))
|
||||
$cache->delete('template_ini' . $template_name);
|
||||
|
||||
|
@@ -13,7 +13,7 @@ $title = 'Load items.xml';
|
||||
require LIBS . 'items.php';
|
||||
require LIBS . 'weapons.php';
|
||||
|
||||
echo $twig->render('admin.items.html.twig');
|
||||
$twig->display('admin.items.html.twig');
|
||||
|
||||
$reload = isset($_REQUEST['reload']) && (int)$_REQUEST['reload'] == 1;
|
||||
if($reload) {
|
||||
|
@@ -19,5 +19,5 @@ if(isset($errors)) {
|
||||
}
|
||||
}
|
||||
|
||||
echo $twig->render('admin.login.html.twig');
|
||||
$twig->display('admin.login.html.twig');
|
||||
?>
|
@@ -30,14 +30,14 @@ $preview_done = false;
|
||||
if($preview) {
|
||||
if(!empty($mail_content) && !empty($mail_subject)) {
|
||||
$preview_done = _mail($account_logged->getCustomField('email'), $mail_subject, $mail_content);
|
||||
|
||||
|
||||
if(!$preview_done)
|
||||
error('Error while sending preview mail: ' . $mailer->ErrorInfo);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
echo $twig->render('admin.mailer.html.twig', array(
|
||||
$twig->display('admin.mailer.html.twig', array(
|
||||
'mail_subject' => $mail_subject,
|
||||
'mail_content' => $mail_content,
|
||||
'preview_done' => $preview_done
|
||||
|
@@ -101,7 +101,7 @@ if(isset($_REQUEST['template'])) {
|
||||
echo '<input type="button" class="button" value="Cancel" onclick="window.location = \'' . ADMIN_URL . '?p=menus&template=' . $template . '\';">';
|
||||
echo '</form>';
|
||||
|
||||
echo $twig->render('admin.menus.js.html.twig', array(
|
||||
$twig->display('admin.menus.js.html.twig', array(
|
||||
'menus' => $menus,
|
||||
'last_id' => $last_id
|
||||
));
|
||||
@@ -115,7 +115,7 @@ else {
|
||||
}
|
||||
}
|
||||
|
||||
echo $twig->render('admin.menus.form.html.twig', array(
|
||||
$twig->display('admin.menus.form.html.twig', array(
|
||||
'templates' => $templates
|
||||
));
|
||||
}
|
||||
|
@@ -27,7 +27,7 @@ else
|
||||
$_content = $notepad_content;
|
||||
}
|
||||
|
||||
echo $twig->render('admin.notepad.html.twig', array('content' => isset($_content) ? $_content : null));
|
||||
$twig->display('admin.notepad.html.twig', array('content' => isset($_content) ? $_content : null));
|
||||
|
||||
class Notepad
|
||||
{
|
||||
|
@@ -84,7 +84,7 @@ if(!empty($action))
|
||||
}
|
||||
|
||||
if(!empty($errors))
|
||||
echo $twig->render('error_box.html.twig', array('errors' => $errors));
|
||||
$twig->display('error_box.html.twig', array('errors' => $errors));
|
||||
}
|
||||
|
||||
$query =
|
||||
@@ -100,7 +100,7 @@ foreach($query as $_page) {
|
||||
);
|
||||
}
|
||||
|
||||
echo $twig->render('admin.pages.form.html.twig', array(
|
||||
$twig->display('admin.pages.form.html.twig', array(
|
||||
'action' => $action,
|
||||
'id' => $action == 'edit' ? $id : null,
|
||||
'name' => $name,
|
||||
@@ -111,7 +111,7 @@ echo $twig->render('admin.pages.form.html.twig', array(
|
||||
'access' => $access
|
||||
));
|
||||
|
||||
echo $twig->render('admin.pages.html.twig', array(
|
||||
$twig->display('admin.pages.html.twig', array(
|
||||
'pages' => $pages
|
||||
));
|
||||
|
||||
|
@@ -12,7 +12,7 @@ $title = 'Plugin manager';
|
||||
|
||||
require LIBS . 'plugins.php';
|
||||
|
||||
echo $twig->render('admin.plugins.form.html.twig');
|
||||
$twig->display('admin.plugins.form.html.twig');
|
||||
|
||||
if(isset($_REQUEST['uninstall'])){
|
||||
$uninstall = $_REQUEST['uninstall'];
|
||||
@@ -118,7 +118,7 @@ foreach(get_plugins() as $plugin)
|
||||
}
|
||||
}
|
||||
|
||||
echo $twig->render('admin.plugins.html.twig', array(
|
||||
$twig->display('admin.plugins.html.twig', array(
|
||||
'plugins' => $plugins
|
||||
));
|
||||
?>
|
@@ -28,7 +28,7 @@ $total_houses = $query['how_much'];
|
||||
|
||||
$points = $db->query('SELECT `premium_points`, `' . (USE_ACCOUNT_NAME ? 'name' : 'id') . '` as `name` FROM `accounts` ORDER BY `premium_points` DESC LIMIT 10;');
|
||||
|
||||
echo $twig->render('admin.statistics.html.twig', array(
|
||||
$twig->display('admin.statistics.html.twig', array(
|
||||
'total_accounts' => $total_accounts,
|
||||
'total_players' => $total_players,
|
||||
'total_guilds' => $total_guilds,
|
||||
|
@@ -28,7 +28,7 @@ function compare($a, $b) {
|
||||
$tmp = $visitors->getVisitors();
|
||||
usort($tmp, 'compare');
|
||||
|
||||
echo $twig->render('admin.visitors.html.twig', array(
|
||||
$twig->display('admin.visitors.html.twig', array(
|
||||
'config_visitors_counter_ttl' => $config['visitors_counter_ttl'],
|
||||
'visitors' => $tmp
|
||||
));
|
||||
|
Reference in New Issue
Block a user