MyBB Community Forums
[How To?] Thread Options MyBB Show to group syntax | {$something} - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Community Archive (https://community.mybb.com/forum-106.html)
+--- Forum: Archived Forums (https://community.mybb.com/forum-143.html)
+---- Forum: Archived Development and Support (https://community.mybb.com/forum-155.html)
+----- Forum: MyBB 1.6 (https://community.mybb.com/forum-138.html)
+------ Forum: 1.6 General Support (https://community.mybb.com/forum-127.html)
+------ Thread: [How To?] Thread Options MyBB Show to group syntax | {$something} (/thread-129716.html)



Thread Options MyBB Show to group syntax | {$something} - hmdz - 2012-11-20

hi ive been working on a mybb forum for while i have faced 2 questions which i couldnt ind the answer on web:

1. whats is the syntax to make showing of an block level code or element conditional based on user groups and/or ids ? ( or in other words how can i limit showing a an element to specific group by editing templates&styles>template )

2. when u r editing templates in mybb u often see {$something} i assume these are shortcuts to other codes i wanna know where are their target and where i can edit those resources

thx in advance these will help alot

[ive asked this question in another forum too <snip>


RE: Thread Options MyBB Show to group syntax | {$something} - Nathan Malcolm - 2012-11-20

1. You can't use conditionals in templates without a plugin, but generally it's best to leave it to a custom plugin.

2. Those are just PHP variables. They can be found throughout MyBB. You can find a complete list here: http://crossreference.mybboard.de/_variables/index.html

Also, please do not link to forums with hacking or illegal content.


RE: Thread Options MyBB Show to group syntax | {$something} - hmdz - 2012-11-20

thx alot about the link for number 1 question i had found conditional templates which allows me to use some php in my templates, is

if($mybb->user['gid'] == 0)
{

some html  content that i want to show to specific grp like <p>hey</p>

}

gonna work? i dunno php yet Sad