Log in

View Full Version : Conditional in bbcode_code help


CarcaBot
01-08-2009, 04:30 PM
Hello,

Why i cannot insert conditionals in bbcode_code template ??

For example:
if i want to show threadid or postid , don't show.

but if i want to show it in footer template work like a charm..

thanks,
/CarcaBot

Digital Jedi
01-08-2009, 06:12 PM
What conditionals are you putting in the bbcode_template? What are trying to make condition based?

CarcaBot
01-08-2009, 08:52 PM
In template bbcode_code i wanna put some informations like
$post[postid] - id of actual post ,
thread and others.

when i insert , it doesn't show me anything.

Dismounted
01-09-2009, 05:13 AM
Those variables are not available when the BB code is evaluated.

CarcaBot
01-09-2009, 08:29 AM
So i have no chance to insert variables in that place ?

Dismounted
01-09-2009, 09:24 AM
You will have to do some PHP coding of your own. (Namely, changing the callback, and slightly redoing the function.)

CarcaBot
01-09-2009, 02:04 PM
Just give me a small example, i don't know where to start...

CarcaBot
01-10-2009, 05:05 PM
So i cannot to anything to insert some php in that section ??

Dismounted
01-11-2009, 04:48 AM
Just give me a small example, i don't know where to start...
Start at the bottom of class_bbcode.php - this is where vBulletin specifies which function tag "X" uses for parsing.
So i cannot to anything to insert some php in that section ??
No, you cannot use PHP in templates.