MyBB Community Forums

Full Version: MyBB Shoutbox
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Hello,

Can I show the shoutbox to guests but that they see NOT the contents of the shoutbox, but something like this:
Quote:Sorry, gasten mogen de shoutbox niet bekijken. Registeer een gratis account of login.

Registeer must link to the register page and login to the login page.

Thanks already.
(2013-09-02, 04:50 PM)Kroketten Wrote: [ -> ]Hello,

Can I show the shoutbox to guests but that they see NOT the contents of the shoutbox, but something like this:
Quote:Sorry, gasten mogen de shoutbox niet bekijken. Registeer een gratis account of login.

Registeer must link to the register page and login to the login page.

Thanks already.

It may be an idea to use the template conditionals plugin and use code like this
<if $GLOBALS['mybb']->user['usergroup'] == 1 then>
do nothing
<else>
display chat box
</if>
Ehm, an easier tut pleas? I don't understand it now. :/
MyShoutbox plugin has group permissions (see this reply)

if you want to notify guests that they can have access to shoutbox after logging in then you can use a group messages plugin (eg.)
(2013-09-02, 05:57 PM)Kroketten Wrote: [ -> ]Ehm, an easier tut pleas? I don't understand it now. :/

download plugin
and install it
next go to the template that the shoutbox is defined in (perhaps header or index I'm not sure as I have never used the shoutbox script) find its definition ( may be {$shoutbox} or <shoutbox> and wrap the if statement around it
example could be like
<if $GLOBALS['mybb']->user['usergroup'] == 1 then>
<div class="trow1"> Sorry, gasten mogen de shoutbox niet bekijken. Registeer een gratis account of login.</div>
<else>
{$shoutbox} or the object that shoutbox is defined as <shoutbox> or what ever
</if>

does that help ?
Thanks, is it posibole to show it as shoutbox?
Code:
<if $GLOBALS['mybb']->user['usergroup'] == 1 then>
<div class="trow1"> Sorry, gasten mogen de shoutbox niet bekijken. <a href="http://www.iksdee.nl/member.php?action=register">Registeer</a> een gratis account of <a href="http://www.iksdee.nl/member.php?action=login">login</a>.</div>
<else>
{myshoutbox_abcd}
</if>
(2013-09-02, 06:35 PM)Kroketten Wrote: [ -> ]Thanks, is it posibole to show it as shoutbox?
Code:
<if $GLOBALS['mybb']->user['usergroup'] == 1 then>
<div class="trow1"> Sorry, gasten mogen de shoutbox niet bekijken. <a href="http://www.iksdee.nl/member.php?action=register">Registeer</a> een gratis account of <a href="http://www.iksdee.nl/member.php?action=login">login</a>.</div>
<else>
{myshoutbox_abcd}
</if>

that should work but you may need to work on using a different class to trow1 this was an example
Yes that works, but can it be shown in the shoutbox style?
(2013-09-02, 06:52 PM)Kroketten Wrote: [ -> ]Yes that works, but can it be shown in the shoutbox style?

you will need to find what class shoutbox uses or just create/design a class that simulates the shoutbox style or class
(2013-09-02, 07:46 PM)JimR Wrote: [ -> ]
(2013-09-02, 06:52 PM)Kroketten Wrote: [ -> ]Yes that works, but can it be shown in the shoutbox style?

you will need to find what class shoutbox uses or just create/design a class that simulates the shoutbox style or class

Ehm, how? :$
Pages: 1 2 3