PDA

View Full Version : Show only to logged in users BBCODE?


Virtualshiner
09-26-2010, 11:58 PM
When I make a bbcode of

<if condition="$show['member']">
{param}
</if>

No matter what, it shows. Is there any way to make this work? Also, how would I make a bbcode that uses php? When I do, all that shows is that code for it.

kh99
09-27-2010, 12:51 AM
You can't use template conditionals or PHP in a bbcode definition. The only way to make that kind of thing work would be to write a plugin.

Virtualshiner
09-28-2010, 11:18 PM
How would I do that?

kh99
09-29-2010, 12:09 AM
I don't know offhand. But I was thinking about this - it seems like it wouldn't be too hard to make a mod that allows a BBCode definition to be PHP code (and use templates if you wanted). Does anyone else know if it's been done before?

BirdOPrey5
10-02-2010, 02:04 PM
There is a "[hide]" mod available that can do this. There are several "Hide" mods, at least one should be able to do what you want.

But to kh99- there is no mod I've ever seen to allow php or templates in bb code.

kh99
10-02-2010, 02:55 PM
There is a "[hide]" mod available that can do this. There are several "Hide" mods, at least one should be able to do what you want.

Even better, they probably have acp options and such...

But to kh99- there is no mod I've ever seen to allow php or templates in bb code.

...but I still might do this just for the heck of it.

iask
10-02-2010, 04:00 PM
For vb 4

<vb:if condition="$show['member']"> you code </vb:if>

BirdOPrey5
10-02-2010, 09:09 PM
...but I still might do this just for the heck of it.

If you can get php and templates to work in BB Code it would quickly become my favorite mod.:up: