Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
general-topic
Is there any way to disable the search function for guests?
Avatar
kvr28
Member
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 10:07 am

I am looking through permissions, but all I see is disable blog search

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 10:20 am

There is not a permission for searching (use case?)...  but you could check in the theme template file and no output the search form if user is a guest...

Avatar
kvr28
Member
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 10:47 am

alright, I'll take a look

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 10:50 am

something like

        sp_SearchForm($searchForm);

to

        if (!$spThisUser->guest) sp_SearchForm($searchForm);

in your spHead.php template file

Avatar
kvr28
Member
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 10:59 am

works perfect! thanks Mr. Papa!

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Oct 4, 2014 - 11:19 am

glad to help!

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 619
Members: 17361
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10127
Posts: 79625