Permanently protected template

Difference between revisions of "Template:Forum/header"

From Yugipedia
Jump to: navigation, search
(move the whole check to the subtemplates)
Line 2: Line 2:
 
| style = height: 3.5em; width: 100%; margin: 0;
 
| style = height: 3.5em; width: 100%; margin: 0;
 
| image = '''Forums:'''
 
| image = '''Forums:'''
| imageright = {{ #ifexpr: {{ #if:{{{sticky|}}}{{{demo|}}}|1<0|{{ #time: U }} - {{ #time: U | {{REVISIONTIMESTAMP}} }} > 3456000 }}
+
| imageright = {{
    | <!-- no post button in old threads -->
+
    #ifexpr: {{
     | <span class="{{ #if: {{{index|}}} | hide }}" style="white-space: nowrap;">[{{fullurl:{{FULLPAGENAMEE}}|action=edit&section=new}} http://images.wikia.com/anime/en/images/4/4e/Forum_new.gif] [{{fullurl:{{FULLPAGENAMEE}}|action=edit&section=new}} Post]</span>
+
      #if: {{{sticky|}}}{{{demo|}}}<!-- bypass time check for stickied and demo uses -->
 +
      | 1
 +
      | {{ #time: U }} - {{ #time: U | {{REVISIONTIMESTAMP}} }} < 3456000
 +
    }}<!-- only forum pages edited in the last 40 days get the "post" button -->
 +
     | {{
 +
      #if: {{{index|}}}<!-- no "post" button on forum index pages -->
 +
      || <span style="white-space: nowrap;">[{{fullurl:{{FULLPAGENAMEE}}|action=edit&section=new}} http://images.wikia.com/anime/en/images/4/4e/Forum_new.gif] [{{fullurl:{{FULLPAGENAMEE}}|action=edit&section=new}} Post]</span>
 +
    }}
 
   }}
 
   }}
 
| text  = [[Forum:Index|Index]] '''''→''''' {{
 
| text  = [[Forum:Index|Index]] '''''→''''' {{
Line 19: Line 26:
 
}}<includeonly>{{<!-- topic cats -->
 
}}<includeonly>{{<!-- topic cats -->
 
   #if: {{{demo|}}}
 
   #if: {{{demo|}}}
   | <!-- No categories for demonstration usage -->
+
   | <!-- no categories for demo uses -->
 
   | [[Category:{{
 
   | [[Category:{{
 
     #if: {{{index|}}}
 
     #if: {{{index|}}}
Line 35: Line 42:
 
}}</includeonly>{{
 
}}</includeonly>{{
 
   #ifeq: {{ #titleparts: {{FULLPAGENAME}} | 1 | 1 }} | Template:Forum
 
   #ifeq: {{ #titleparts: {{FULLPAGENAME}} | 1 | 1 }} | Template:Forum
    | <!-- no maintenance cats for Template:Forum or any subtemplates, though we are going to do a bit else here -->{{
+
  | <!-- no maintenance cats for Template:Forum or any subtemplates, though we are going to do a bit else here -->{{
 
     #switch: {{PAGENAME}}
 
     #switch: {{PAGENAME}}
 
     | Forum/header  | Forum/header/doc  | Forum/header/sandbox  | Forum/header/testcases | Forum =  
 
     | Forum/header  | Forum/header/doc  | Forum/header/sandbox  | Forum/header/testcases | Forum =  
 
     | #default = [[Category:Forumheader preload templates|{{SUBPAGENAME}}]]<!-- keep track of the preload templates -->
 
     | #default = [[Category:Forumheader preload templates|{{SUBPAGENAME}}]]<!-- keep track of the preload templates -->
 
   }}
 
   }}
   | {{<!-- maintenance cats -->
+
   | <!-- maintenance cats -->{{Forum/header/move notice}}<!-- wrong namespace check
    #ifeq: {{NAMESPACE}} | {{NS:110}}
+
 
    | <!-- page is in the Forum: namespace -->
+
     -->{{Forum/header/archived notice|index={{{index|}}}|sticky={{{sticky|}}}}}<!-- necrobumping
     | [[Category:Forumheader transclusions to be checked|N]]<div class="sysop-show" style="display: none;">{{Forum/header/move notice}}</div><!-- page is not in the Forum: namespace -->
+
 
  }}{{
+
    -->{{
    #if: {{{index|}}}{{{sticky|}}}{{{demo|}}} <!-- no necro check on forum indexes, sticky threads and demonstrations -->
 
    | | {{ <!-- stop necrobumping on threads unedited for 40+ days -->
 
      #ifexpr: {{ #time: U }} - {{ #time: U | {{REVISIONTIMESTAMP}} }} > 3456000
 
      | <div id="archived-edit-link"></div>{{Forum/header/archived notice}}__NOEDITSECTION__ __NONEWSECTIONLINK__
 
      | __NEWSECTIONLINK__<!-- new section link for non-ancient threads -->
 
    }}
 
  }}{{
 
 
     #if: {{{3|}}}{{{4|}}}{{{5|}}}
 
     #if: {{{3|}}}{{{4|}}}{{{5|}}}
 
     | [[Category:Forumheader transclusions to be checked|P]]<!-- see if {{{3}}}-{{{5}}} are used anywhere and if so how -->
 
     | [[Category:Forumheader transclusions to be checked|P]]<!-- see if {{{3}}}-{{{5}}} are used anywhere and if so how -->
 
   }}{{
 
   }}{{
 
     #if: {{{index|}}}{{{demo|}}}
 
     #if: {{{index|}}}{{{demo|}}}
     | <!-- forum index or demonstration page; no further parameter checking necessary -->
+
     | <!-- forum index or demo; no further parameter checking necessary -->
 
     | {{
 
     | {{
 
       #switch: {{{1|¬}}}
 
       #switch: {{{1|¬}}}

Revision as of 04:18, 1 March 2011