SCRIPT3R
04-17-2005, 01:26 AM
is there an easier way to get a New Post Count to appear in the NavBar on all forum pages (rather then edit each php file)? this is where i'm at thus far, but obviously the $newposts[count] is only appearing on index.php.
forumrootdirectory/index.php
// ######################### REQUIRE BACK-END ############################
require_once('./global.php');
require_once('./includes/functions_bigthree.php');
require_once('./includes/functions_forumlist.php');
$newposts = $DB_site->query_first("
SELECT COUNT(*) AS count
FROM ".TABLE_PREFIX."post
WHERE dateline > '".$bbuserinfo['lastvisit']."'
");
breadcrumbs...
navbar
<if condition="$indexpage">
<a href="search.php?$session[sessionurl]do=getnew">$vbphrase[new_posts]</a>: $newposts[count]<br />
</if>
forumrootdirectory/index.php
// ######################### REQUIRE BACK-END ############################
require_once('./global.php');
require_once('./includes/functions_bigthree.php');
require_once('./includes/functions_forumlist.php');
$newposts = $DB_site->query_first("
SELECT COUNT(*) AS count
FROM ".TABLE_PREFIX."post
WHERE dateline > '".$bbuserinfo['lastvisit']."'
");
breadcrumbs...
navbar
<if condition="$indexpage">
<a href="search.php?$session[sessionurl]do=getnew">$vbphrase[new_posts]</a>: $newposts[count]<br />
</if>