Jesus Christ, just add an if statement for even or odd!

  • Aatube@kbin.socialOP
    link
    fedilink
    arrow-up
    8
    ·
    10 months ago

    https://en.wikipedia.org/wiki/Template:Signpost/item, if that’s what you mean.
    The JPxG person (who is not an employee of WMF for some reason; maybe they didn’t apply?) recently put this in the testing version of the template:

    
    {{#switch: {{{2}}}
      | 0 =        {{#switch: {{{1}}}
                     | 3 = <div><span>''{{{4}}}''''[[#{{{4}}}|{{{5}}}]]''</span></div>
                     }}
      | #default = {{#switch: {{{1}}}{{#expr:{{{2}}} mod 2}}
                     | 10  =
                     | 11  =
                     | 20  =
                     | 21  =
                     | 30  = <div><span>{{{4}}}</span><br>[[#{{{4}}}|{{{5}}}]]</div>
                     | 31  = <div><span>{{{4}}}</span><br>[[#{{{4}}}|{{{5}}}]]</div>
                     | 40  =
                     | 41  =
                     }}
    }}
    
    

    maybe he was rejected because of his awful date format?

    Anyway, the testing version has now been automatically protected from editing because JPxG also tested his kewl new testing version by using it in an old 2010 issue, which resulted in 827 page updates