Log in

View Full Version : Template Variables


rogersnm
08-13-2006, 04:53 PM
I have set up a some variables in foruhome_start that go trhough a bbcode parser: include_once(DIR . '/includes/class_bbcode.php');
global $vbulletin;

$parser =& new vB_BbCodeParser($vbulletin, fetch_tag_list());

$nick_title = $parser->do_parse($vbulletin->options[nick_announce_title], true, true, true, true, true, false);

$nick_contents = $parser->do_parse($vbulletin->options[nick_announce_conents], true, true, true, true, true, false); When i put $nick_contents or $nick_title in a template it doesn't work but if i put echo $nick_contents; at the bottom of the forumhome_start plugin code then it echo's it out as it should. Any Ideas?

Paul M
08-13-2006, 05:12 PM
1. Are you sure the option is called nick_announce_conents ?

2. You don't say which template you are putting them in.

rogersnm
08-13-2006, 05:13 PM
1. yes
2. i am putting them into a custom template - nick_announce - which is variablised and called in the FORUHOME template

Paul M
08-13-2006, 05:21 PM
Called how exactly ?

rogersnm
08-13-2006, 05:24 PM
I mean the variable is defined to fetch the template and then you put the variable in another template.

rogersnm
08-15-2006, 06:28 AM
bump

Paul M
08-15-2006, 06:35 AM
You last reply made no sense to me.

rogersnm
08-16-2006, 02:39 PM
Oh well, It made sense to other people who managed to help me.

Paul M
08-16-2006, 06:20 PM
Good for them, pity they felt no need to post in here .....

rogersnm
08-16-2006, 06:22 PM
Well Zero Tolerance didn't say it he more hinted towards it. I had set it to add the variable to the template using str replace in the hook global_start and then used bbcodalized it in forumhome_start so it had blank variables.