Template:Convert: Difference between revisions

From Zoophilia Wiki
Jump to navigationJump to search
meta>Plastikspork
Simplify and improve sortable code using ntsh per Droll's suggestion and sandbox edits (revert if it causes new problems)
meta>Plastikspork
Add a reverse number format before sort key generation per Droll's suggestion on the talk page.
Line 1: Line 1:
<includeonly>{{#ifeq:{{{sortable|}}}|on|{{ntsh|{{{1}}}}}}}{{convert/{{#if:1|{{{2}}}}}|{{FORMATNUM:{{{1}}}|R}}|{{#ifeq:{{#expr:{{{3|0}}}*0}}|0|0}}|{{{3|}}}|{{{4|}}}|{{{5|}}}|{{{6|}}}|{{{7|}}}|{{{8|}}}|r={{#ifeq:{{{sp}}}|us|er|re}}|d=L{{{lk|off}}}A{{{abbr|off}}}D{{{disp|b}}}S{{{adj|{{{sing|off}}}}}}|s={{{sigfig|}}}}}</includeonly><noinclude>{{Documentation}}</noinclude><!--testing code follows-->{{#ifeq:{{{disp}}}|/|{{convert/und}}}}{{convert/test/A{{{abbr|}}}}}
<includeonly>{{#ifeq:{{{sortable|}}}|on|{{ntsh|{{FORMATNUM:{{{1}}}|R}}}}}}{{convert/{{#if:1|{{{2}}}}}|{{FORMATNUM:{{{1}}}|R}}|{{#ifeq:{{#expr:{{{3|0}}}*0}}|0|0}}|{{{3|}}}|{{{4|}}}|{{{5|}}}|{{{6|}}}|{{{7|}}}|{{{8|}}}|r={{#ifeq:{{{sp}}}|us|er|re}}|d=L{{{lk|off}}}A{{{abbr|off}}}D{{{disp|b}}}S{{{adj|{{{sing|off}}}}}}|s={{{sigfig|}}}}}</includeonly><noinclude>{{Documentation}}</noinclude><!--testing code follows-->{{#ifeq:{{{disp}}}|/|{{convert/und}}}}{{convert/test/A{{{abbr|}}}}}

Revision as of 15:14, 29 July 2011

Template:Convert/test/A