Difference between revisions of "Template:Str right"
m |
m (Added to Category:Auxiliary templates) |
||
Line 4: | Line 4: | ||
{{{{{|safesubst:}}}#Invoke:String|sub|s={{{1}}}|{{{{{|safesubst:}}}#expr:{{{2|0}}}+1}}|nocategory={{{nocategory|}}}}} }} | {{{{{|safesubst:}}}#Invoke:String|sub|s={{{1}}}|{{{{{|safesubst:}}}#expr:{{{2|0}}}+1}}|nocategory={{{nocategory|}}}}} }} | ||
}}</includeonly><noinclude> | }}</includeonly><noinclude> | ||
− | {{Documentation}}[[Category: | + | {{Documentation}}[[Category:String manipulation templates]][[Category:Auxiliary templates]] |
</noinclude> | </noinclude> |
Latest revision as of 12:26, 30 January 2021
This template was originally from Template:Str right in English Wikipedia.
Usage
{{str right|<string>|<offset>}}
Gives the characters from <offset> to the end of the string.
A negative <offset> is treated the same as zero, which simply returns the original string.
If <offset> is longer than <string> then this returns an empty string.
If <offset> is invalid, empty or undefined, this template goes berserk, so please avoid.