The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Change Number of Threads per Page (SPECIFIC FORUM)
I'm trying to figure out a way to change the # of threads per page, but only for a specific forum. I couldn't find a mod so I figured I'd post here and maybe someone knows of a template edit I can make.
It's already set in my vb options settings to show 20 per page, however I have one section of the forum I would like to limit to 10 per page. I was looking through the FORUMDISPLAY template but couldn't get an eye on the code that says how many threads to show in the thread list. (assuming this is even the right template) I was hoping I could wrap an if condition around some code, (where x = the forum id I want to limit to 10 threads) Code:
<vb:if condition="$GLOBALS[forumid] != x">Existing code that determines how many threads are displayed</vb:if> <vb:if condition="$GLOBALS[forumid] == x">Custom code that determines how many threads are displayed</vb:if> |
#2
|
||||
|
||||
I think you want a plugin, not a template edit.
hook - forumdisplay_start php code PHP Code:
|
Благодарность от: | ||
addamroy |
#3
|
|||
|
|||
Perfect Lynne thank you!
Now how do I turn that into an add-on so I can submit it to the mod forums? I only know how to do template edits so that's all I've ever posted there |
#4
|
||||
|
||||
It's a plugin. You may add it to a product and then turn the forumid into a setting (probably want to change the condition into an array).
|
#5
|
|||
|
|||
Sorry for the silly question but, How do I do that? I need to start somewhere I have no idea how to do plugins yet, I just have a vague understanding of the code itself at this point but definitely want to learn.
|
#6
|
||||
|
||||
<a href="http://www.vbulletin.com/docs/html/plugin_system?manualversion=40200603" target="_blank">http://www.vbulletin.com/docs/html/p...rsion=40200603</a>
|
#7
|
||||
|
||||
Is there any modules that do this yet?
Can you explain more? --------------- Added [DATE]1361113915[/DATE] at [TIME]1361113915[/TIME] --------------- Quote:
Do I need to need to make more than one plug in? |
#8
|
||||
|
||||
Just use an array.
PHP Code:
|
#9
|
||||
|
||||
Say I wanted to make world boxing 20 threads and british boxing 10 threads how do I do that?
Is that possbile? |
#10
|
||||
|
||||
Just put each condition into the same plugin.
PHP Code:
|
Благодарность от: | ||
ringnews24 |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|