The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
custom on/off for a forum ID
Little help here
this is the code in index.php for the on/off buttons Code:
if ($bbuserinfo['lastvisitdate']=='Never') { $forum['onoff']='on'; } else { if (isset($bbforumview[$forum['forumid']]) and $bbforumview[$forum['forumid']]>$bbuserinfo[' lastvisit']) { $userlastvisit=$bbforumview[$forum['forumid']]; } else { $userlastvisit=$bbuserinfo['lastvisit']; } if ($userlastvisit<$forum['lastpost']) { $forum['onoff']='on'; } else { $forum['onoff']='off'; } } if ((!$forumperms['canpostnew'] and $showlocks) or $forum['allowposting']==0) { $forum['onoff'].='lock'; } if forumid equals number 20 (using 20 as an example) then $forum['onoff']='20on'; ... $forum['onoff']='20off'; The idea is to have custom on/off buttons to certain forums .. is this possible ? Carlos |
#2
|
||||
|
||||
add
PHP Code:
PHP Code:
PHP Code:
Replace X with the forumid. Enjoy.. |
#3
|
||||
|
||||
I've been trying to get this to work to no avial. Can you please post the part of the code already modified (i.e. replace this with this)
Thanks in advance |
#4
|
||||
|
||||
Edit index.php, find:
PHP Code:
PHP Code:
|
#5
|
||||
|
||||
thanks for your quick reply, but i still get the same error....
Quote:
|
#6
|
||||
|
||||
try to use that:
PHP Code:
if the error occurs again, look at one line before... |
#7
|
||||
|
||||
same error....
|
#8
|
||||
|
||||
there is no error (at least no parse errors) in this code (after Xenon's correction). Try to reapply carefully..
BTW Are you using Opera as your browser? Then dont copy/paste from here, just type the code manually. |
#9
|
||||
|
||||
ok, I'm not home atm, and yes, I was using Opera. When I get home I'll copy & paste with IE. Thanks Logician.
|
#10
|
||||
|
||||
it works now, thanks Logician & Xenon
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|