PDA

View Full Version : Need to remove new post link from 'forumdisplay' but not for subforums


joeschmoe
12-06-2002, 04:52 PM
Hi, I have my forums set up like this:

Main Forum
-forum 1
--subforum 1a
--subforum 1b
-forum 2
-- subforum 2a
-- subforum 2b

etcetera

I want to remove the "$newthreadlink" from the forumdisplay templates in forum 1, forum 2, etc., but NOT from the subforum x forums.

If anyone can provide any help, I'd really appreciate it!

Logician
12-08-2002, 12:13 PM
edit forumdisplay.php find:

if ($foruminfo['allowposting']==1) {
eval("\$newthreadlink = \"".gettemplate('forumdisplay_newthreadlink')."\";");
}

Replace it as:

if ($foruminfo['allowposting']==1 AND ($foruminfo[forumid]!=X OR $foruminfo[forumid]!=Y)) {
eval("\$newthreadlink = \"".gettemplate('forumdisplay_newthreadlink')."\";");
}
Replace X and Y with the forumids that you do NOT want the link be displayed..

Chris M
12-08-2002, 12:54 PM
There is a way to integrate it into the Admin CP, and make it a standard feature of the vB if you wanted;):)

Satan

joeschmoe
12-09-2002, 02:50 PM
Thanks once again Logician! :)