Secondary description for each forum
Destro Offline
Junior Member
**
Posts: 39
Joined: Nov 2012
Post: #1
Secondary description for each forum
Hi.

We already knew that forums in MyBB has a description ($forum['desc']).

I did a little modification in the functions_forumlist.php, to make a secondary description for each forum, for example.

I have a forum A - id 1 - main description A1 and secondary desc is A2

A2 will be defined inside global.lang.php, with the forum id like

PHP Code:
$l['forum_desc_1'] = "ABC";



In the functions_forumlist.php I want something this:

PHP Code:
$minidesc = $lang->forum_desc_$fid;


Then I can put {$minidesc} everywhere in the forumbit template...

I know about Xthread, but every forum has one template is quite silly... You know

Please give me some suggestions. Thanks in advanced.

(This post was last modified: 07-03-2013 11:25 PM by Destro.)
07-03-2013 11:23 PM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA Offline
Fag
*******
Posts: 3,357
Joined: Jan 2008
Post: #2
RE: Secondary description for each forum
I seriously don't know why you'd do this, but the syntax is

PHP Code:
$minidesc = $lang->{"forum_desc_$fid"};


My Blog
07-04-2013 10:08 AM
Find all posts by this user Quote this message in a reply
Destro Offline
Junior Member
**
Posts: 39
Joined: Nov 2012
Post: #3
RE: Secondary description for each forum
Thanks, works now.

Still need to set

PHP Code:
$fid = $forum['fid'];

07-04-2013 01:22 PM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: