Template:NameSortTest: Difference between revisions

From Tardis Wiki, the free Doctor Who reference
no edit summary
No edit summary
No edit summary
Line 22: Line 22:


{{#switch:{{#rpos:John Smith (actor)|)}}
{{#switch:{{#rpos:John Smith (actor)|)}}
|-1= <!--if there are no close parentheses, then look for spaces-->
|-1={{#switch:{{#rpos:John Smith (actor)| }}|-1=John Smith (actor)|#default={{#sub:John Smith (actor)|{{#rpos:John Smith (actor)| }}|7}}}} }}|#default = {{#explode:{{#sub:John Smith (actor)|0|{{#expr:{{#rpos:John Smith (actor)|(}}-1}}}}| |-1}} }} <!--second switch close-->
    {{#switch:{{#rpos:John Smith (actor)| }}
    |-1 = John Smith (actor) <!--if there are no spaces, then just go by the PAGENAME-->
    |#default ={{#sub:John Smith (actor)|{{#rpos:John Smith (actor)| }}|7}}}}<!-- if there are 
                                                spaces, then do something clever-->
}} <!--first switch close-->
|#default = {{#explode:{{#sub:John Smith (actor)|0|{{#expr:{{#rpos:John Smith (actor)|(}}-1}}}}| |-1}}
 
}} <!--second switch close-->




85,404

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.