Difference between revisions of "Template:ReplaceNumericCharEncoding"
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
− | <includeonly>{{#vardefine: continue | true }}{{#while: | + | <includeonly>{{#vardefine: string | {{{string|}}} }}{{#vardefine: continue | true }}{{#while: |
| {{#var: continue}} | | {{#var: continue}} | ||
− | | {{#if: {{#pos: {{ | + | | {{#if: {{#pos: {{#var: string}} | ' }} |
− | | {{#sub: {{ | + | | {{#vardefine: string | {{#sub: {{#var: string}} | 0 | {{#pos: {{#var: string}} | ' }} }}'{{#sub: {{#var: string}} | {{#expr: {{#pos: {{#var: string}} | ' }} + 5}} }} }} |
− | | {{#if: {{#pos: {{ | + | | {{#if: {{#pos: {{#var: string}} | ' }} |
− | | {{#sub: {{ | + | | {{#vardefine: string | {{#sub: {{#var: string}} | 0 | {{#pos: {{#var: string}} | ' }} }}'{{#sub: {{#var: string}} | {{#expr: {{#pos: {{#var: string}} | ' }} + 8}} }} }} |
− | | {{#if: {{#pos: {{ | + | | {{#if: {{#pos: {{#var: string}} | > }} |
− | | {{#sub: {{ | + | | {{#vardefine: string | {{#sub: {{#var: string}} | 0 | {{#pos: {{#var: string}} | > }} }}>{{#sub: {{#var: string}} | {{#expr: {{#pos: {{#var: string}} | > }} + 4}} }} }} |
− | | {{#vardefine: continue|}}{{ | + | | {{#vardefine: continue|}}{{#var: string}} |
}} | }} | ||
}} | }} | ||
}} | }} | ||
− | }} | + | }}</includeonly><!-- |
− | </includeonly><!-- | ||
--><noinclude> | --><noinclude> | ||
This template has the sole purpose to replace numeric char encoding (<code><nowiki>' ;</nowiki></code> (decimal encoding) AND <code><nowiki>' ;</nowiki></code> (hexadecimal encoding) ) with the actual character ("<code>'</code>") to circumvent a bug in mediawiki which makes queries for pagename break | This template has the sole purpose to replace numeric char encoding (<code><nowiki>' ;</nowiki></code> (decimal encoding) AND <code><nowiki>' ;</nowiki></code> (hexadecimal encoding) ) with the actual character ("<code>'</code>") to circumvent a bug in mediawiki which makes queries for pagename break | ||
[[Category:Template]] | [[Category:Template]] | ||
</noinclude> | </noinclude> |
Latest revision as of 21:03, 20 March 2019
This template has the sole purpose to replace numeric char encoding (' ;
(decimal encoding) AND ' ;
(hexadecimal encoding) ) with the actual character ("'
") to circumvent a bug in mediawiki which makes queries for pagename break