Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 $forum['fid'] in forumdisplay_newthread
Jordan L. Offline
Junior Member
**
Posts: 3
Joined: Jan 2013
Post: #1
$forum['fid'] in forumdisplay_newthread
Hey there.

Currently I'm having issues trying to alter the text of the forumdisplay_newthread templates based on the FID. Here's my code, I've been altering it and searching the forums on here trying to understand why it is not working without any lucky. From what I understand I don't appear to be doing anything wrong?

PHP Code:
<if $forum['fid'] == '2' then>
<a href="newthread.php?fid={$fid}"><span class="button">Support Thread</span></a><br />
<else>
<a href="newthread.php?fid={$fid}"><span class="button">New Thread</span></a><br />
</if>


Any help would be great. Thanks.

01-01-2013 03:15 AM
Find all posts by this user Quote this message in a reply
RateU Offline
Administrator
*******
Posts: 2,350
Joined: Mar 2010
Post: #2
RE: $forum['fid'] in forumdisplay_newthread
You can use $foruminfo['fid'] or $fid in that template.

01-01-2013 03:30 AM
Find all posts by this user Quote this message in a reply
Jordan L. Offline
Junior Member
**
Posts: 3
Joined: Jan 2013
Post: #3
RE: $forum['fid'] in forumdisplay_newthread
Ugh, can't believe I didn't think of that. Thanks! Is there any documentation as to what variables to use in each template set?
01-01-2013 10:25 AM
Find all posts by this user Quote this message in a reply
Sama34 Offline
Senior Member
****
Posts: 490
Joined: May 2011
Post: #4
RE: $forum['fid'] in forumdisplay_newthread
Open the php file (forumdisplay.php) -> search the template being eval'd (forumdisplay_newthread) -> read code above it.

Pretty much all the variables above are the ones you can use in that template.

Support PM's will be ignored. Yipi
Plugins: Announcement Bars - Custom Reputation - Mark PM As Unread
01-01-2013 10:38 AM
Visit this user's website Find all posts by this user Quote this message in a reply
Jordan L. Offline
Junior Member
**
Posts: 3
Joined: Jan 2013
Post: #5
RE: $forum['fid'] in forumdisplay_newthread
Ahh, I see now. Thanks a ton. Smile
01-01-2013 11:19 AM
Find all posts by this user Quote this message in a reply

« Next Oldest | Next Newest »

 Standard Tools
Forum Jump: