Files
aowow/pages/main.php
Sarjuuk a5ae244216 removing smarty - part III
- convert first pages to extend GenericPage (Race/s; Class/es; Main)
- added new stack-rule from TC to spells
2014-06-15 23:16:10 +02:00

31 lines
667 B
PHP

<?php
if (!defined('AOWOW_REVISION'))
die('illegal access');
/*
todo (med):
- different styles for newsbox
- flags for news .. disabled, deleted, recurring, whatever..
*/
class MainPage extends GenericPage
{
protected $tpl = 'main';
protected $news = [];
protected function generateContent()
{
// load news
$rows = DB::Aowow()->select('SELECT * FROM ?_news ORDER BY time DESC, id DESC LIMIT 5');
foreach ($rows as $i => $row)
$this->news[$i]['text'] = Util::localizedString($row, 'text');
}
protected function generateTitle() {}
protected function generatePath() {}
}
?>