View Full Version : get forum id in showthread?
Hi,
how can i check the forum id in showthread?
if ($forumid!=298){
eval("dooutput(\"".gettemplate("showthread_new")."\");");
}
else {
eval("dooutput(\"".gettemplate("showthread")."\");");
}
the $forumid!=298 does not work so, because all forums use than the showthread_new template! :(
thanks for help! :)
Freddie Bingham
11-17-2002, 02:25 AM
Try $foruminfo[forumid]
thanks for help! :)
but does not work :(
still the same in all forums than :confused: :confused:
Freddie Bingham
11-17-2002, 02:25 PM
Well, it would be $foruminfo[forumid] OR $threadinfo[forumid] in vB3, but I haven't looked at vB2 in such a long time. Sounds like to me, you have other issues as a forumid will never be the same in all forums. Doesn't make much sense does it?
Xenon
11-17-2002, 02:38 PM
in vb2 i think it's $thread[forumid] ;)
Originally posted by Exo
Hi,
how can i check the forum id in showthread?
if ($thread['forumid'] == value) {
eval("dooutput(\"".gettemplate('showthread_new')."\");");
} else {
eval("dooutput(\"".gettemplate('showthread')."\");");
}
ahhh thanks $thread[forumid] does now work! :))
Xenon
11-18-2002, 03:54 PM
you're welcome ;)
Floren, it seems we know the code of vb2 better than some devs ;)
another way to write it is:
if ($thread['forumid'] == value)
{
eval('dooutput("' . gettemplate('showthread_new') . '");');
}
else
{
eval('dooutput("' . gettemplate('showthread') . '");');
}
That is more elegant because it doesn't use the ole slashes.
That's how I have coded my vbHome (lite) script.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.