PDA

View Full Version : Creating a new vb template...


b6gm6n
04-23-2004, 08:57 AM
I'm trying to make a template for vb named 'gallery_stats'

Its basically the stats of my photopost gallery, i want this to be shown at the bottom of the 'whats going on' box

My vb & pp databases are combined btw...

I created a new template named 'gallery_stats'
would i be right to call it up in my forumhome template with the line : $gallery_stats ?

I tried just altering the forumhome template to show the PP strings like this :
$totalphotos - but nothing showed up, must i somehow call upon or identify these PP strings first?

below it my gallery_stats template

Please advise
cheers
-b6

<tbody id="collapseobj_forumhome_stats" style="$vbcollapse[collapseobj_forumhome_stats]">
<tr>
<td class="alt2"><img src="$stylevar[imgdir_misc]/stats.gif" alt="<phrase 1="$vboptions[bbtitle]">Gallery
Statistics" border="0" /></td>
<td class="alt1">
<div class="smallfont">
<div>Photos- $totalphotos, comments: $posttotal, views:
$totalviews</div>
<div><phrase 1="member.php?$session[sessionurl]u=$newuserid" 2="$newusername">diskspace
: $diskspace, Views : $totalviews</phrase>
</div>
</div>
</td>
</tr></tbody>

Scrub
04-23-2004, 09:06 AM
Add this:


eval('$totalphotos = "' . fetch_template('gallery_stats') . '";');


Or this:


eval('$gallery_stats = "' . fetch_template('gallery_stats') . '";');


Above


eval('print_output("' . fetch_template('FORUMHOME') . '");');


in index.php. Then you can put $totalphotos or $gallery_stats (Depending on which one you used in the eval) anywere in forumhome template. :)

b6gm6n
04-23-2004, 09:23 PM
thankyou, i'll try it later, cheers

-b6