Search results
Results from the WOW.Com Content Network
The simplest operation is taking a substring, a snippet of the string taken at a certain offset (called an "index") from the start or end. There are a number of legacy templates offering this but for new code use {{#invoke:String|sub|string|startIndex|endIndex}}. The indices are one-based (meaning the first is number one), inclusive (meaning ...
This template removes the first word of the first parameter. Use |1= for the first parameter if the string may contain an equals sign (=). By default, words are delimited by spaces, but the optional parameter |sep= can set the separator to any character.
The template trims whitespace from a string. Template parameters [Edit template data] Parameter Description Type Status String 1 The string to be trimmed of whitespace String required See also {{ remove border }}
Removes all characters from string that are not a digit 0–9. Examples {{digits ... remove the first non-digit character and everything following {}, ...
A template to give the <count> substring of characters from the start of the trimmed string Template parameters [Edit template data] Parameter Description Type Status String 1 The string to be trimmed and counted String required Count 2 Gives the <count> substring of characters from the start of the trimmed string Number required See also Bugzilla:22555 (historical; need for correcting padleft ...
Template:String split is a convenience wrapper for the split function in Module:String2.. The split function splits text at boundaries specified by separator and returns the chunk for the index idx (starting at 1).
This template is used on 206,000+ pages. To avoid major disruption and server load, any changes should be tested in the template's /sandbox or /testcases subpages, or in your own user subpage.
This template returns the first word of the first parameter. Use |1= for the first parameter if the string may contain an equals sign (=). By default, words are delimited by spaces, but the optional parameter |sep= can set the separator to any character.