diff --git a/phpBB/feed.php b/phpBB/feed.php index f7349a21cf..f2d823de99 100644 --- a/phpBB/feed.php +++ b/phpBB/feed.php @@ -610,7 +610,7 @@ class phpbb_feed_base */ class phpbb_feed_post_base extends phpbb_feed_base { - var $num_items = 'feed_limit'; + var $num_items = 'feed_limit_post'; function set_keys() { @@ -651,6 +651,8 @@ class phpbb_feed_post_base extends phpbb_feed_base */ class phpbb_feed_topic_base extends phpbb_feed_base { + var $num_items = 'feed_limit_topic'; + function set_keys() { $this->set('title', 'topic_title'); @@ -1114,8 +1116,6 @@ class phpbb_feed_forums extends phpbb_feed_base */ class phpbb_feed_news extends phpbb_feed_topic_base { - var $num_items = 'feed_limit'; - function get_news_forums() { global $db, $cache; @@ -1197,8 +1197,6 @@ class phpbb_feed_news extends phpbb_feed_topic_base */ class phpbb_feed_topics extends phpbb_feed_topic_base { - var $num_items = 'feed_overall_topics_limit'; - function get_sql() { global $db, $config; diff --git a/phpBB/includes/acp/acp_board.php b/phpBB/includes/acp/acp_board.php index 6b6b59f88b..1fd2680a91 100644 --- a/phpBB/includes/acp/acp_board.php +++ b/phpBB/includes/acp/acp_board.php @@ -267,10 +267,10 @@ class acp_board 'legend1' => 'ACP_FEED_GENERAL', 'feed_enable' => array('lang' => 'ACP_FEED_ENABLE', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), 'feed_item_statistics' => array('lang' => 'ACP_FEED_ITEM_STATISTICS', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true), - 'feed_limit' => array('lang' => 'ACP_FEED_LIMIT', 'validate' => 'int:5', 'type' => 'text:3:4', 'explain' => true), + 'feed_limit_topic' => array('lang' => 'ACP_FEED_LIMIT_TOPIC', 'validate' => 'int:5', 'type' => 'text:3:4', 'explain' => true), 'feed_overall_forums' => array('lang' => 'ACP_FEED_OVERALL_FORUMS', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), 'feed_overall_topics' => array('lang' => 'ACP_FEED_OVERALL_TOPIC', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), - 'feed_overall_topics_limit' => array('lang' => 'ACP_FEED_OVERALL_TOPIC_LIMIT', 'validate' => 'int:5', 'type' => 'text:3:4', 'explain' => false), + 'feed_limit_post' => array('lang' => 'ACP_FEED_LIMIT_POST', 'validate' => 'int:5', 'type' => 'text:3:4', 'explain' => true), 'feed_overall' => array('lang' => 'ACP_FEED_OVERALL', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), 'feed_forum' => array('lang' => 'ACP_FEED_FORUM', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), 'feed_topic' => array('lang' => 'ACP_FEED_TOPIC', 'validate' => 'bool', 'type' => 'radio:enabled_disabled', 'explain' => true ), diff --git a/phpBB/install/database_update.php b/phpBB/install/database_update.php index 2f8cb53be2..6da4ab3f76 100644 --- a/phpBB/install/database_update.php +++ b/phpBB/install/database_update.php @@ -1578,6 +1578,8 @@ function change_database_data(&$no_updates, $version) // ATOM Feeds set_config('feed_overall', '1'); + set_config('feed_limit_post', (string) (isset($config['feed_limit']) ? (int) $config['feed_limit'] : 15)); + set_config('feed_limit_topic', (string) (isset($config['feed_overall_topics_limit']) ? (int) $config['feed_overall_topics_limit'] : 10)); break; } diff --git a/phpBB/language/en/acp/board.php b/phpBB/language/en/acp/board.php index 2e67ea8946..15d185df85 100644 --- a/phpBB/language/en/acp/board.php +++ b/phpBB/language/en/acp/board.php @@ -251,8 +251,10 @@ $lang = array_merge($lang, array( 'ACP_FEED_ENABLE' => 'Enable Feeds', 'ACP_FEED_ENABLE_EXPLAIN' => 'Turns on or off ATOM Feeds for the entire board.
Disabling this switches off all Feeds, no matter how the options below are set.', - 'ACP_FEED_LIMIT' => 'Number of items', - 'ACP_FEED_LIMIT_EXPLAIN' => 'The maximum number of feed items to display.', + 'ACP_FEED_LIMIT_POST' => 'Number of items in post based feeds', + 'ACP_FEED_LIMIT_POST_EXPLAIN' => 'The maximum number of feed items to display in post based feeds.', + 'ACP_FEED_LIMIT_TOPIC' => 'Number of items in topic based feeds', + 'ACP_FEED_LIMIT_TOPIC_EXPLAIN' => 'The maximum number of feed items to display in topic based feeds.', 'ACP_FEED_OVERALL' => 'Enable board-wide Feed', 'ACP_FEED_OVERALL_EXPLAIN' => 'Board-wide new posts.',