Former Member
inherit
guest@proboards.com
256971
0
Apr 18, 2024 17:55:19 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Jan 22, 2020 9:02:19 GMT -8
I have an announcement box on my board and I was wondering if I could hide it from guests?
countrycomfort.boards.net
|
|
inherit
252032
0
Apr 4, 2024 21:43:14 GMT -8
Retread
Tribbial Pursuit.
5,014
January 2018
retread
|
Post by Retread on Jan 22, 2020 9:32:49 GMT -8
I have an announcement box on my board and I was wondering if I could hide it from guests? countrycomfort.boards.net Hi @coffeelover Are you talking about the section that has the title bar: Welcome To Our Home? Where do you have the coding to create that box? Is it in the Header box within the Header/Footer tab of the Sidebar Redux plugin? If so, you could navigate from your Admin panel to: Admin Home> Plugins> Forum Plugins> Manage, then click on the Edit button in the Permissions column for the Sidebar Redux plugin. You'll get a popup. Where it says: Who can view this plugin.., use the dropdown to change Everyone to Members & Staff. Then click the Done button on the popup. If you have that coding somewhere else, we'll come up with a different plan.
|
|
inherit
96289
0
May 17, 2020 9:37:00 GMT -8
elli
1,822
January 2007
ebbymac
|
Post by elli on Jan 22, 2020 9:44:55 GMT -8
It depends where your announcement table is. If it's in a layout template, you can use template logic to check if a user is a guest. Like so:
{if $[current_user.is_member]} ... your announcement table here {/if} If it's not in a layout template, how are you displaying it?
|
|
Former Member
inherit
guest@proboards.com
256971
0
Apr 18, 2024 17:55:19 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Jan 22, 2020 9:56:11 GMT -8
Retread & elli - It's in the forum wrapper template. I added it there because it was the only way I knew how to add different images to it for each theme.
|
|
inherit
252032
0
Apr 4, 2024 21:43:14 GMT -8
Retread
Tribbial Pursuit.
5,014
January 2018
retread
|
Post by Retread on Jan 22, 2020 10:07:32 GMT -8
Retread & elli - It's in the forum wrapper template. I added it there because it was the only way I knew how to add different images to it for each theme. That being the case, elli's solution should do exactly what you need. Be sure to make that change in the Forum Wrapper layout template for all themes which might ever be used as default. Or to keep it consistent, make the change on all themes.
|
|
Former Member
inherit
guest@proboards.com
256971
0
Apr 18, 2024 17:55:19 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Jan 22, 2020 10:24:57 GMT -8
Retread - I tried it and logged out but it's still showing.
|
|
inherit
252032
0
Apr 4, 2024 21:43:14 GMT -8
Retread
Tribbial Pursuit.
5,014
January 2018
retread
|
Post by Retread on Jan 22, 2020 10:37:06 GMT -8
Retread - I tried it and logged out but it's still showing. Does it show when you ARE logged in? I think it should not, right now. I believe elli has the logic inverted and it's preventing logged-in members from seeing that section but allowing guests to see it. Change {if !$[current_user.is_member]} to {if $[current_user.is_member]}
|
|
Former Member
inherit
guest@proboards.com
256971
0
Apr 18, 2024 17:55:19 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Jan 22, 2020 10:41:31 GMT -8
Retread - It wasn't showing when I was logged in but that did the trick. Thank you!
|
|
inherit
96289
0
May 17, 2020 9:37:00 GMT -8
elli
1,822
January 2007
ebbymac
|
Post by elli on Jan 22, 2020 10:47:10 GMT -8
Whoops, I posted from my phone and missed the exclamation mark. Good catch.
|
|