PDA

View Full Version : Finally! 1 more step to forum views, with your help...


okc
01-11-2005, 06:13 AM
I have finally (!!) gotten a value for each forum by putting code like this into my index.php, but I can't figure out how to get the $totalhitsvideo value into my forumhome_forumbit_level2_post so it will show up on the main forum index page...

This is the code I've found to get the right value:


$totalhitsvideo = $DB_site->query_first("

SELECT COUNT(*) ,

SUM(views) AS hits

FROM " . TABLE_PREFIX . "thread WHERE forumid = 6

");

$totalhitsvideo = vb_number_format($totalhitsvideo['hits']);

So close - any help would be appreciated...