MyBB Central

Full Version: Adding a plugin feature to only one forum index?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have done a few searches and have scrolled through countless posts but I can not seem to find an answer to this...

I am looking to add a plugin to a specific forum on my site... More specifically the mybet upcoming bets thread ( {$bets} ) that you can put on your index page. I want to have this display in a specific forum of my site and not on the index of the forums. Is something like this possible, if so how easy/hard would it be to do?

Any help is appreciated, thanks in advance!!
Erm well, if you want to show it only in forumdisplay.php, it will be so easy and you wouldn't need to know so much about codes and others... but if you want to show it in a specific forum, you must edit the plugin and set it for just one forumdisplay id... though i think you neither need to know so much about codes.
Anyway in both cases, it will be easy
Umm...excuse me if I misread, but you want it to post results in a forum, in the form of a new thread? It already does that.
(Feb 19, 2010, 11:03 AM)Riverthief Wrote: [ -> ]Umm...excuse me if I misread, but you want it to post results in a forum, in the form of a new thread? It already does that.

Thanks riverthief and arqui for replying..I think arqui is on the right path with what I am looking to do and I guess I will dig around the php files this weekend...

riverthief here is what I have, I want the circled area to appear only in my bookie forum and not on the index. I have attached a picture of what I am talking about (if you have any ideas or help I would be most appreciative!)

[Image: screen.jpg]
Ah! Ok. All you have to do is remove the {bets} or {upcoming_bets} or whatever out of the index and then fiddle with some php files to put it in that forum. Not sure exactly how, but I definitely know it's possible.
It's possible, sure. If you have the plugin to allow PHP and Template Conditionals in themes, enable it. Then, just edit "forumdisplay" in template editor, and look for the place you want to put it (mybet, i mean).
And if the plugin works... you should put:

Code:
<if $forum['fid'] = X (X is the ID of the forum) then>
{$bets} or the variable of the table (i cant remember it)
</if>

The problem is the plugin... it doesn't usually work. Anyway, with that template conditional, you could try to edit "mybet.php" file, I think in that file, you could find the code required to edit.
You can use a line like this:

if(!$forum['fid'])
return;

Probably to the plugin itself or the function. You might have to do some global changes.
(Feb 20, 2010, 03:29 PM)labrocca Wrote: [ -> ]You can use a line like this:

if(!$forum['fid'])
return;

Probably to the plugin itself or the function. You might have to do some global changes.

Thanks arqui and labrocca, I am not too savvy with php but I will give it the old college try. You both have definitely pushed me in the right direction. Thanks Smile