SimplePortal
Support => English Support => Topic started by: steve51184 on February 19, 2010, 11:24:21 AM
-
hey how do i disable simpleportal for guests?
using latest smf2 and sp
-
Disabling SMF browsing for guests will also disable SP for guests, you can also use the edit below:
if (WIRELESS || ($standalone && (isset($_REQUEST['wap']) || isset($_REQUEST['wap2']) || isset($_REQUEST['imode']))) || !empty($settings['disable_sp']) || empty($modSettings['sp_portal_mode']) || (!empty($maintenance) && !allowedTo('admin_forum')) || isset($_GET['debug']) || (empty($modSettings['allow_guestAccess']) && $context['user']['is_guest']))
if (WIRELESS || ($standalone && (isset($_REQUEST['wap']) || isset($_REQUEST['wap2']) || isset($_REQUEST['imode']))) || !empty($settings['disable_sp']) || empty($modSettings['sp_portal_mode']) || (!empty($maintenance) && !allowedTo('admin_forum')) || isset($_GET['debug']) || (empty($modSettings['allow_guestAccess']) && $context['user']['is_guest']) || $context['user']['is_guest'])
-
but i don't want to disable browsing for guests just the portal so for a guest it looks just like smf and NOT sp+smf
-
Sources/Subs-Portal.php
$context['standalone'] = $standalone;
$context['standalone'] = $standalone;
if ($context['user']['is_guest'])
$settings['disable_sp'] = true;
-
perfect thank you ;)
-
Disabling SMF browsing for guests will also disable SP for guests, you can also use the edit below:
if (WIRELESS || ($standalone && (isset($_REQUEST['wap']) || isset($_REQUEST['wap2']) || isset($_REQUEST['imode']))) || !empty($settings['disable_sp']) || empty($modSettings['sp_portal_mode']) || (!empty($maintenance) && !allowedTo('admin_forum')) || isset($_GET['debug']) || (empty($modSettings['allow_guestAccess']) && $context['user']['is_guest']))
if (WIRELESS || ($standalone && (isset($_REQUEST['wap']) || isset($_REQUEST['wap2']) || isset($_REQUEST['imode']))) || !empty($settings['disable_sp']) || empty($modSettings['sp_portal_mode']) || (!empty($maintenance) && !allowedTo('admin_forum')) || isset($_GET['debug']) || (empty($modSettings['allow_guestAccess']) && $context['user']['is_guest']) || $context['user']['is_guest'])
Same question here...
Although the answer wasn't what i expected.
I've disabled guests from browsing the forum and when I logout, the forum button is gone, but when I click the home button, I can see the forum index, instead of a login/register box (what I was expecting).
This is with TP in front page mode.
Seems like a flaw, As I disabled guest browsing, just because I do not want them to see the forum's index page.
-
This site is not for TinyPortal (TP). ;)
Well, that is an issue with SMF, ask over at SM.org if you want to change default SMF behaviour (the allowing of guests to view the board index).
-
This site is not for TinyPortal (TP). ;)
Well, that is an issue with SMF, ask over at SM.org if you want to change default SMF behaviour (the allowing of guests to view the board index).
Aargh, my bad. That's a typo though, I am using SP :-[
I don't want guests to see anything, other then the login/register.
With SP in any other mode, it works as expected. But with SP in front page mode, when a guest clicks the home button, they can see the boards index. Trying to browse a board does take them to the login/register menu though.
-
Sources/Subs-Portal.php
$context['standalone'] = $standalone;
$context['standalone'] = $standalone;
if ($context['user']['is_guest'])
$settings['disable_sp'] = true;
this no longer works for SimplePortal 2.3.2 ???
-
For 2.3.2:
Sources/Subs-Portal.php
sportal_load_compat();
sportal_load_compat();
if ($context['user']['is_guest'])
$settings['disable_sp'] = true;
-
perfect thank you :)
-
My problem seems to be fixed in 2.3.2.
Now it's showing the login/register box instead of the forum index on the frontpage, for guests. :thumbsup:
-
also can an option to disable the postal for guests not be integrated into SP?
-
Maybe, but I'm not sure if many people would find it useful.
-
hmm.. what about disabling sp for guests in sp 2.3.5?
EDIT:
hmm.. seems i got it..
$context['SPortal']['core_compat'] = $settings['name'] == 'Core Theme';
$context['SPortal']['on_portal'] = getShowInfo(0, 'portal', '');
}
$context['SPortal']['core_compat'] = $settings['name'] == 'Core Theme';
$context['SPortal']['on_portal'] = getShowInfo(0, 'portal', '');
}
if ($context['user']['is_guest'])
$settings['disable_sp'] = true;
seems to work.. any objections?