If you edit that function, I will cut your fingers off.
I guess you edited this part for your needs:
Code: Select all
case 'news':
$display_vars = array(
'title' => 'ACP_PORTAL_NEWS_SETTINGS',
'vars' => array(
'legend1' => 'ACP_PORTAL_NEWS_SETTINGS',
'portal_news' => array('lang' => 'PORTAL_NEWS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_news_style' => array('lang' => 'PORTAL_NEWS_STYLE', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_show_all_news' => array('lang' => 'PORTAL_SHOW_ALL_NEWS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_number_of_news' => array('lang' => 'PORTAL_NUMBER_OF_NEWS', 'validate' => 'int', 'type' => 'text:3:3', 'explain' => true),
'portal_news_length' => array('lang' => 'PORTAL_NEWS_LENGTH', 'validate' => 'int', 'type' => 'text:3:3', 'explain' => true),
'portal_news_forum' => array('lang' => 'PORTAL_NEWS_FORUM', 'validate' => 'string', 'type' => 'custom', 'explain' => true, 'method' => 'select_forums'),
'portal_news_exclude' => array('lang' => 'PORTAL_NEWS_EXCLUDE', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_news_show_last' => array('lang' => 'PORTAL_NEWS_SHOW_LAST', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_news_archive' => array('lang' => 'PORTAL_NEWS_ARCHIVE', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_news_permissions' => array('lang' => 'PORTAL_NEWS_PERMISSIONS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
'portal_show_news_replies_views' => array('lang' => 'PORTAL_SHOW_REPLIES_VIEWS', 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => true),
)
);
break;
And I guess the exact part you want to modify is this:
Code: Select all
'portal_news_forum' => array('lang' => 'PORTAL_NEWS_FORUM', 'validate' => 'string', 'type' => 'custom', 'explain' => true, 'method' => 'select_forums'),
You should change it to something like this:
Code: Select all
'portal_results_forum' => array('lang' => 'PORTAL_RESULTS_FORUM', 'validate' => 'string', 'type' => 'custom', 'explain' => true, 'method' => 'select_forums'),
A little bit further down you will have to find this line:
Code: Select all
if ($config_name == 'portal_attachments_filetype' || $config_name == 'portal_news_forum' || $config_name == 'portal_global_announcements_forum' || $config_name == 'portal_recent_forum' || $config_name == 'portal_attachments_forum_ids' || $config_name == 'portal_poll_topic_id')
Replace it with this:
Code: Select all
if ($config_name == 'portal_attachments_filetype' || $config_name == 'portal_news_forum' || $config_name == 'portal_global_announcements_forum' || $config_name == 'portal_recent_forum' || $config_name == 'portal_attachments_forum_ids' || $config_name == 'portal_poll_topic_id' || $config_name == 'portal_results_forum')
Now it is important to know what you changed this line to:
If you changed it to this:
Do this:
Find:
Code: Select all
case 'polls':
$this->store_selected_forums('portal_poll_topic_id');
break;
After Add:
Code: Select all
case 'results':
$this->store_selected_forums('portal_results_forum');
break;
Then the script will save the selected forum IDs.
I hope this helps.