Difference between revisions of "Template:Trim prefix/doc"

From Moegirlpedia
Jump to: navigation, search
(Created page with "This template is used to process series of entry strings separated by colons. By default, the entry name is taken after the colon. You can also set the second parameter to 1,...")
 
 
Line 4: Line 4:
  
 
== Example ==
 
== Example ==
<nowiki>{{Trim prefix|Water Margin:Zhang Qing}}</nowiki>
+
<nowiki>{{Trim prefix|Water Margin:Zhang Qing}}</nowiki>
  
 
{{Trim prefix|Water Margin:Zhang Qing}}
 
{{Trim prefix|Water Margin:Zhang Qing}}
  
<nowiki>{{Trim prefix|Moegirlpedia:Everything can be moe|1|}}</nowiki>
+
<nowiki>{{Trim prefix|Moegirlpedia:Everything can be moe|1|}}</nowiki>
  
 
{{Trim prefix|Moegirlpedia:Everything can be moe}}
 
{{Trim prefix|Moegirlpedia:Everything can be moe}}
  
<nowiki>{{Trim prefix|Lin Chong}}</nowiki>
+
<nowiki>{{Trim prefix|Lin Chong}}</nowiki>
  
 
{{Trim prefix|Lin Chong}}
 
{{Trim prefix|Lin Chong}}
Line 19: Line 19:
 
* The template can also be used to set other parameters
 
* The template can also be used to set other parameters
  
<nowiki>{{Trim prefix|Kantai Collection/Picture books}}</nowiki>
+
<nowiki>{{Trim prefix|Kantai Collection/Picture books}}</nowiki>
  
 
{{Trim prefix|Kantai Collection/Picture books}}
 
{{Trim prefix|Kantai Collection/Picture books}}
  
<nowiki>{{Trim prefix|Kantai Collection:Kongo#Lines}}</nowiki>
+
<nowiki>{{Trim prefix|Kantai Collection:Kongo#Lines}}</nowiki>
  
 
{{Trim prefix|Kantai Collection:Kongo#Lines}}
 
{{Trim prefix|Kantai Collection:Kongo#Lines}}
  
 
<noinclude>[[Category:Template documentation]]</noinclude>
 
<noinclude>[[Category:Template documentation]]</noinclude>

Latest revision as of 15:38, 27 September 2021

This template is used to process series of entry strings separated by colons. By default, the entry name is taken after the colon. You can also set the second parameter to 1, and take the series name. There is no colon to return the original string.

Related templates: {{Trim_suffix}}

Example

{{Trim prefix|Water Margin:Zhang Qing}}

Water Margin:Zhang Qing

{{Trim prefix|Moegirlpedia:Everything can be moe|1|}}

Moegirlpedia:Everything can be moe

{{Trim prefix|Lin Chong}}

Lin Chong

Extended usage

  • The template can also be used to set other parameters
{{Trim prefix|Kantai Collection/Picture books}}

Kantai Collection/Picture books

{{Trim prefix|Kantai Collection:Kongo#Lines}}

Kantai Collection:Kongo#Lines