Announcement

Collapse
No announcement yet.

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

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • 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...

  • #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


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

      Comment

      Loading...
      Working...
      X