mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-22 21:35:56 +02:00
Move forum config to settings
This commit is contained in:
@@ -11,22 +11,24 @@
|
||||
defined('MYAAC') or die('Direct access not allowed!');
|
||||
$title = 'Forum';
|
||||
|
||||
if(strtolower($config['forum']) != 'site') {
|
||||
if($config['forum'] != '') {
|
||||
header('Location: ' . $config['forum']);
|
||||
require_once LIBS . 'forum.php';
|
||||
|
||||
$forumSetting = setting('core.forum');
|
||||
if(strtolower($forumSetting) != 'site') {
|
||||
if($forumSetting != '') {
|
||||
header('Location: ' . $forumSetting);
|
||||
exit;
|
||||
}
|
||||
|
||||
echo 'Forum is disabled on this site.';
|
||||
return;
|
||||
return false;
|
||||
}
|
||||
|
||||
if(!$logged) {
|
||||
echo 'You are not logged in. <a href="?subtopic=accountmanagement&redirect=' . BASE_URL . urlencode('?subtopic=forum') . '">Log in</a> to post on the forum.<br /><br />';
|
||||
return false;
|
||||
}
|
||||
|
||||
require_once LIBS . 'forum.php';
|
||||
|
||||
$sections = array();
|
||||
foreach(getForumBoards() as $section) {
|
||||
$sections[$section['id']] = array(
|
||||
|
||||
Reference in New Issue
Block a user