Don't display threads in forum if forum is not open

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Matafleur
    New Member
    • Aug 2005
    • 11
    • 3.6.x

    Don't display threads in forum if forum is not open

    How do I not display the whole "Threads in Forum" block if the forum is not open?

    I've been trying to find the appropriate template conditional for days now, I'm quite frustrated by the lack of documentation or a list of template conditionals...
  • daemon
    Senior Member
    • Jun 2003
    • 2351
    • 3.5.x

    #2
    Go to:

    Admin CP --> Styles & Templates --> Style Manager --> « » --> Forum Display Templates --> FORUMDISPLAY

    Find:

    HTML Code:
    <if condition="$show['threadslist']">
    Replace it with:

    HTML Code:
    <if condition="$show['threadslist'] AND ($foruminfo['options'] & $_FORUMOPTIONS['allowposting'])">
    Now the thread list won't be displayed if the Forum is Open setting is set to No.

    As for there not being a list of conditionals, it would be near impossible to build a complete list as you can write just about any condition you want into them. Most common ones, however, are documented in the quick tips forum.
    Bugdar: PHP bug tracking software that is beautiful, fast, and robust.

    Comment

    • Matafleur
      New Member
      • Aug 2005
      • 11
      • 3.6.x

      #3
      Thank you very much for the help and the tip, I'll be sure to check out the quick tips forum.

      Comment

      widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
      Working...