Move news config to settings

This commit is contained in:
slawkens 2023-07-20 21:01:33 +02:00
parent ed7daf9482
commit 1b2fd39ea7
3 changed files with 34 additions and 6 deletions

View File

@ -113,12 +113,6 @@ $config = array(
//'Some Quest Two' => 456, //'Some Quest Two' => 456,
), // quests list (displayed in character view), name => storage ), // quests list (displayed in character view), name => storage
// news page
'news_limit' => 5, // limit of news on the latest news page
'news_ticker_limit' => 5, // limit of news in tickers (mini news) (0 to disable)
'news_date_format' => 'j.n.Y', // check php manual date() function for more info about this
'news_author' => true, // show author of the news
// gifts/shop system // gifts/shop system
'gifts_system' => false, 'gifts_system' => false,

View File

@ -23,6 +23,10 @@ $deprecatedConfig = [
'outfit_images_wrong_looktypes', 'outfit_images_wrong_looktypes',
'item_images_url', 'item_images_url',
'account_country', 'account_country',
'news_author',
'news_limit',
'news_ticker_limit',
'news_date_format',
'highscores_groups_hidden', 'highscores_groups_hidden',
'highscores_ids_hidden', 'highscores_ids_hidden',
'online_record', 'online_record',

View File

@ -564,6 +564,36 @@ Sent by MyAAC,<br/>
'type' => 'category', 'type' => 'category',
'title' => 'Pages', 'title' => 'Pages',
], ],
[
'type' => 'section',
'title' => 'News Page',
],
'news_author' => [
'name' => 'News Author',
'type' => 'boolean',
'desc' => 'Show author of the news',
'default' => true,
],
'news_limit' => [
'name' => 'News Limit',
'type' => 'number',
'min' => 0,
'desc' => 'Limit of news on the latest news page (0 to disable)',
'default' => 5,
],
'news_ticker_limit' => [
'name' => 'News Ticker Limit',
'type' => 'number',
'min' => 0,
'desc' => 'Limit of news in tickers (mini news) (0 to disable)',
'default' => 5,
],
'news_date_format' => [
'name' => 'News Date Format',
'type' => 'text',
'desc' => 'Check php manual date() function for more info about this',
'default' => 'j.n.Y',
],
[ [
'type' => 'section', 'type' => 'section',
'title' => 'Forum' 'title' => 'Forum'