inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 14, 2017 5:01:30 GMT -8
summitoflegends.net/Is there a way to hide the chat box on certain pages? A couple of my custom pages would be nicer without it.
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on May 14, 2017 7:22:04 GMT -8
|
|
inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 14, 2017 7:35:25 GMT -8
I do not understand this at all O.O
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on May 14, 2017 10:33:57 GMT -8
Is this something you are trying to do yourself?
|
|
inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 15, 2017 9:52:37 GMT -8
Yes, I am the only person available to work on it. But I know very little about coding XD
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on May 16, 2017 7:18:54 GMT -8
First step is to decide which method you want to use.
1. JavaScript to hide / show the shoutbox on certain pages.
or
2. Modify the layout template to have it show / hide on specific pages.
Number 2 looks the easier solution if you don't know JavaScript very well. However, it depends on how many pages you want it to show and hide on, as requires you to know the route names. It also depends on if the page is a real page or not (e.g., plugin created the page (Monetary Shop))).
Examples (layout template "Forum Wrapper", replace $[shoutbox] with the example code):
- Show on all pages apart from custom pages that you created in the admin area.
{if $[route.name] != "page"} $[shoutbox] {/if}
- Show on all pages about from a specific custom page with the ID of "mycustompage" (set in the admin area when creating a custom page).
{if $[route.name] != "mycustompage"} $[shoutbox] {/if} - Show on all pages apart from user profiles pages / tabs (not complete).
{if $[route.name] != "user" && $[route.name] != "show_user_activity" && $[route.name] != "show_user_following" && $[route.name] != "show_user_friends" && $[route.name] != "show_user_groups" && $[route.name] != "show_user_notifications" && $[route.name] != "show_user_gift"} $[shoutbox] {/if}
|
|
inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 16, 2017 9:12:38 GMT -8
So if I want to hide the shoutbox from all of my custom pages, what exactly do I need to use, and where exactly do I put it?
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on May 16, 2017 9:20:22 GMT -8
Keen - Summit of Legends, Example 1 from my post. All the instructions are in my post, including which template, and what to replace.
|
|
inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 16, 2017 10:24:53 GMT -8
|
|
inherit
2671
0
May 14, 2013 14:40:03 GMT -8
Peter
🐺
10,615
February 2002
peter3
|
Post by Peter on May 16, 2017 10:37:41 GMT -8
Not sure what to say, it works fine for me. I tested again just now to be 100% sure, and the shoutbox is not there on my custom page.
Can you post your template?
|
|
inherit
243515
0
Jun 7, 2017 14:51:24 GMT -8
Keen - Summit of Legends
142
April 2017
keenbean
|
Post by Keen - Summit of Legends on May 16, 2017 11:25:45 GMT -8
You mean all of the html from the forum wrapper section? If so its this after i changed (I think) what you said to change: <!DOCTYPE HTML> $[tag.html.open] <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <title>$[title] | $[forum.name]</title> $[head] </head> <body> {if $[maintenance_mode]} <div class="maintenance-header"> {if $[can.disable_maintenance]}<p>Finished with maintenance? $[disable_maintenance_link].</p>{/if} </div> {/if} <div id="wrapper"> <header> <div id="banner-container" role="banner"> <h2 id="banner"> $[forum.title] </h2> </div> <a id="navigation-skip" href="#content" accesskey="s" class="aria-hidden" title="Skip Navigation">Skip Navigation</a> <a href="#" accesskey="d" title="Open Menu" onclick="proboards.hotkeys.activate(Keys.d); return false;"></a> <div id="navigation-menu" class="ui-helper-clearfix"> <ul role="navigation"> {foreach $[navigation.menu]} <li> <a{if $[navigation.menu.active]} class="state-active"{/if} href="$[navigation.menu.href]"{if $[navigation.menu.accesskey]} accesskey="$[navigation.menu.accesskey]"{/if}> $[navigation.menu.name] {if $[navigation.menu.notification.total]} <div class="tip-holder" onclick="window.location='$[navigation.menu.notification.href]'; return false;"> <div class="tip-number">$[navigation.menu.notification.total]</div> <span class="tip"></span> </div> {/if} </a> </li> {/foreach} </ul> <p id="welcome"> {if !$[current_user.is_member]} Welcome Guest. {if $[login_link] || $[register_link]} Please $[login_link]{if $[login_link] && $[register_link]} or {/if}$[register_link]. {/if} {else} <span>Welcome $[current_user.name].</span> $[logout_link] {/if} </p> </div> </header> $[participated_threads_link] {if $[navigation.tree]} <div id="navigation-tree"> $[navigation.tree] </div> {/if} $[header] <div id="content" role="main"> {if $[notice]} <div class="container"> <div class="title-bar"><h2>$[notice.title]</h2></div> <div class="content pad-all cap-bottom"> $[notice.message] </div> </div> {/if} $[content] {if $[route.name] != "page"} $[shoutbox] {/if} </div> $[footer] </div> {if $[is_mobile_browser]} <br /><p class="center">Switch to the $[mobile_switch_link].</p> {/if} </body> </html>
|
|