Jump to content

Template:Cite book: Difference between revisions

updated from User:Gracefool/cite book. Backwards compatibility with {{book reference}} is broken.
m>Ligulem
(reverted to Gracefool's last revision)
m>Gracefool
(updated from User:Gracefool/cite book. Backwards compatibility with {{book reference}} is broken.)
Line 1: Line 1:
<cite style="font-style:normal" {{qif
<cite class="book" style="font-style:normal">{{qif
   |test={{{ref}}}
   |test={{{author|{{{authorlast|}}}}}}
   |then={{qif
   |then={{qif
      |test={{booleq
    |test={{{authorlink|}}}
            |{{{ref}}}
    |then={{wikilink
            |none
      |1={{{authorlink}}}
          }}
      |2={{qif
      |then=
        |test={{{authorlast|}}}
      |else=id="{{{ref}}}"
        |then={{{authorlast}}}{{qif
    }}
          |test={{{authorfirst|}}}
  |else={{qif
          |then=, {{{authorfirst}}}
    |test={{booland
        }}
      |1={{{last|}}}
        |else={{{author}}}
      |2={{{year|}}}
      }}
     }}
     }}
     |then=id="Reference-{{{last}}}-{{{year}}}"
     |else={{qif
  }}
       |test={{{authorlast|}}}
}}
       |then={{{authorlast}}}{{qif
}}>{{qif
         |test={{{authorfirst|}}}
  |test={{{authorlink|}}}
         |then=, {{{authorfirst}}}
  |then={{wikilink
    |1={{{authorlink}}}
    |2={{qif
       |test={{{author|}}}
       |then={{{author}}}
      |else={{{last|}}}{{qif
         |test={{{first|}}}
         |then=, {{{first}}}
       }}
       }}
      |else={{{author}}}
     }}
     }}
   }}
   }}
  |else={{qif
}}{{qif
    |test={{{author|}}}
  |test={{{authorlast|}}}
    |then={{{author}}}
  |then={{qif
     |else={{{last|}}}{{qif
     |test={{{author2|}}}
       |test={{{first|}}}
    |then={{qif
       |then=, {{{first}}}
       |test={{{author3|}}}
       |then=,&#32;
      |else=&#32;&amp;&#32;
     }}
     }}
   }}
   }}
}}{{qif
}}{{qif
   |test={{{coauthors|}}}
   |test={{{authorlast|}}}
   |then=<nowiki>,</nowiki> {{{coauthors}}}
   |then={{qif
    |test={{{author2link|}}}
    |then={{wikilink
      |1={{{author2link}}}
      |2={{qif
        |test={{{author2|}}}
        |then={{{author2}}}
      }}
    }}
    |else={{{author2|}}}
  }}{{qif
    |test={{{author2|}}}
    |then={{qif
      |test={{{author3|}}}
      |then={{qif
        |test={{{author4|}}}
        |then=,&#32;
        |else=&#32;&amp;&#32;
      }}
    }}
  }}{{qif
    |test={{{author3link|}}}
    |then={{wikilink
      |1={{{author3link}}}
      |2={{qif
        |test={{{author3|}}}
        |then={{{author3}}}
      }}
    }}
    |else={{{author3|}}}
  }}{{qif
    |test={{{author2|}}}
    |then={{qif
      |test={{{author3|}}}
      |then={{qif
        |test={{{author4|}}}
        |then={{qif
          |test={{{author5|}}}
          |then=,&#32;
          |else=&#32;&amp;&#32;
        }}
      }}
    }}
  }}{{qif
    |test={{{author4link|}}}
    |then={{wikilink
      |1={{{author4link}}}
      |2={{qif
        |test={{{author4|}}}
        |then={{{author4}}}
      }}
    }}
    |else={{{author4|}}}
  }}{{qif
    |test={{{author2|}}}
    |then={{qif
      |test={{{author3|}}}
      |then={{qif
        |test={{{author4|}}}
        |then={{qif
          |test={{{author5|}}}
          |then=&#32;&amp;&#32;
        }}
      }}
    }}
  }}{{qif
    |test={{{author5link|}}}
    |then={{wikilink
      |1={{{author5link}}}
      |2={{qif
        |test={{{author5|}}}
        |then={{{author5}}}
      }}
    }}
    |else={{{author5|}}}
  }}
}}{{qif
}}{{qif
   |test={{{date|}}}
   |test={{{date|}}}
Line 53: Line 123:
   }}
   }}
}}{{qif
}}{{qif
   |test={{{author|{{{last|{{{year|}}}}}}}}}
   |test={{{authorlast|{{{year|}}}}}}
   |then=.
   |then=.
}}{{qif
}}{{qif
Line 116: Line 186:
   }}
   }}
}}.</cite><noinclude>
}}.</cite><noinclude>
This template replaces the deprecated {{tl|book reference}}.
This template replaces the deprecated {{tl|book reference}}.
{{esoteric}}
{{esoteric}}
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.