The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
How to call another forumbits templates
Hello!
I have a second forumbits templates... In the forumhome template I tried to change this <!-- main --> {vb:raw template_hook.forumhome_above_forums} <ol id="forums" class="floatcontainer"> {vb:raw forumbits} </ol> {vb:raw template_hook.forumhome_below_forums} <!-- /main --> To: {vb:raw secondforumbits} This not works..... What I need yo make call this variable, register? How? Thank you in advance! |
#2
|
||||
|
||||
Sounds like you need a plugin to pre-register your secondforumbits variable...
Check out this article: https://vborg.vbsupport.ru/showthread.php?t=228078 The section relevant to you is: Save into an array and preregister to use in an existing/stock template |
#3
|
|||
|
|||
Thank you very much!
I will read all! --------------- Added [DATE]1300659430[/DATE] at [TIME]1300659430[/TIME] --------------- I?m a little lost sorry.. This is my new post bit templates.. forumhome_forumbit2_level1_no post forumhome_forumbit2_level1_post forumhome_forumbit2_level2_no post forumhome_forumbit2_level2_post I want to use it in forumhome: <!-- main --> {vb:raw template_hook.forumhome_above_forums} <ol id="forums" class="floatcontainer"> {vb:raw forumbits2} </ol> {vb:raw template_hook.forumhome_below_forums} <!-- /main --> Ok: In this tutorial says I need to put into Forumhome Header that: I don,t know how i can continue... $templater = vB_Template::create('forumhome_forumbit2_level1_no post'); $templater->register('my var', $my_var); $templater->register('my_array', $my_array); $templatevalues['my_insertvar'] = $templater->render(); vB_Template:reRegister('FORUMHOME', $templatevalues); |
#4
|
||||
|
||||
That goes in a plugin, not the template.
In your Admin CP you go to Plugin Manager -> Add a New Plugin You put the php code in the plugin, I believe the hook is either parse_template or forumhome_complete, the article should say- otherwise try both. |
#5
|
|||
|
|||
Thank you, I resolved the problem!!
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|