The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Include a template within another template?
Is it possible to include a template within another template?
I'm creating a mod for one of my sites that has one generic template to setup a table for display purposes, and then I'd like to include a second template that will be different according to the style. I thought of doing it this way this way to save a template, as the first thought that came to mind was splitting the display template into two, and concatenate the three together to establish what I need. Here's a code snippet to help visualize this... Code:
<table class="tborder" border="0" width="100%" align="center" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]"> <tr> <td class="tcat" align="left">blah blah blah</td> </tr> <tr> <td class="alt1"> <!-- CODE TO INCLUDE TEMPATE --> </td> </tr> </table> |
#2
|
|||
|
|||
You will need to evaluate both templates in a PHP script/plugin. Assign the value of template 1 to a variable, and use that variable in template 2.
|
#3
|
|||
|
|||
Thanks Marco, it was late and I didn't even think of that.
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|