mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-14 09:44:55 +02:00
Various fixes in forum
Add new access type: guest - all visitors, player will be now for logged players only Fixed default forum board access for guests
This commit is contained in:
@@ -18,6 +18,16 @@ if ($ret === false) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(!$logged) {
|
||||
$extra_url = '';
|
||||
if(isset($_GET['section_id'])) {
|
||||
$extra_url = '&action=new_thread§ion_id=' . $_GET['section_id'];
|
||||
}
|
||||
|
||||
echo 'You are not logged in. <a href="?subtopic=accountmanagement&redirect=' . BASE_URL . urlencode('?subtopic=forum' . $extra_url) . '">Log in</a> to post on the forum.<br /><br />';
|
||||
return;
|
||||
}
|
||||
|
||||
if(Forum::canPost($account_logged)) {
|
||||
$players_from_account = $db->query('SELECT `players`.`name`, `players`.`id` FROM `players` WHERE `players`.`account_id` = '.(int) $account_logged->getId())->fetchAll();
|
||||
$section_id = $_REQUEST['section_id'] ?? null;
|
||||
|
Reference in New Issue
Block a user