Doctor Who Cuttings Archive

Difference between revisions of "Template:InvertName"

From The Doctor Who Cuttings Archive
Jump to navigationJump to search
Line 1: Line 1:
 
{{#vardefine:temp | {{{author}}} }}
 
{{#vardefine:temp | {{{author}}} }}
 +
Var temp = {{#var:temp}}
 
{{#vardefine:pos | {{#rpos:{{#var:temp}} | " " }} }}
 
{{#vardefine:pos | {{#rpos:{{#var:temp}} | " " }} }}
 
{{#if: {{#expr: {{#var:pos}} > 0}}  
 
{{#if: {{#expr: {{#var:pos}} > 0}}  
Line 5: Line 6:
 
       {{#vardefine:firstName | {{#sub: {{#var:temp}} | 0 | {{#expr: {{#var:pos}} - 1 }} }} }}
 
       {{#vardefine:firstName | {{#sub: {{#var:temp}} | 0 | {{#expr: {{#var:pos}} - 1 }} }} }}
 
       {{#var:lastName}}, {{#var:firstName}}
 
       {{#var:lastName}}, {{#var:firstName}}
     | {{#var:temp}}
+
     | {{{author}}}
 
}}
 
}}

Revision as of 12:56, 20 October 2013

Var temp = {{{author}}}

{{{author}}}, {{{author}