PDA

View Full Version : query photopost db and output $ in vb template?


b6gm6n
07-17-2005, 08:40 PM
Hi, i wonder if you can help me...

I had a few lines of code which simply counted the amount of photos in my photopost database which i could then output via a string thus : echo $totals;

this worked well, it showed in my header when i was using IPB, now whatever i try, i.e placing that simple echo statement in my vb header it outputs nothing...

so is there an easier way or something i'm missing to achieve this correctly? - thankyou, it's something i'd like to solve and understand, cheers

(note both my vb and photopost reside in the same database)

-b6

Link14716
07-17-2005, 08:42 PM
Put $totals in your header template (and the rest of the code in phpinclude_start).

b6gm6n
07-17-2005, 08:43 PM
ok, i'll give that a try now...cheers

i'm at a loss as to where 'phpinclude_start' is... a template? or a place within the common templates i have to place my code?

-b6

i cannot find that template, i'm using 3.5b4... did they remove it i wonder...

-b6

hooks, plugins, global start?...am i on the right track... i'll see what i can do...

sussed it...

created a new plugin, added my code, chose a hook location (i chose : global_start) then simply added "serving $totalusers members with $totalphotos pictures" to my header template...

easy really once you know how :)

-b6