<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://sapph.group/wiki/index.php?action=history&amp;feed=atom&amp;title=Template%3AStr_find%2Fdoc</id>
	<title>Template:Str find/doc - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://sapph.group/wiki/index.php?action=history&amp;feed=atom&amp;title=Template%3AStr_find%2Fdoc"/>
	<link rel="alternate" type="text/html" href="https://sapph.group/wiki/index.php?title=Template:Str_find/doc&amp;action=history"/>
	<updated>2026-05-17T20:20:55Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://sapph.group/wiki/index.php?title=Template:Str_find/doc&amp;diff=3768&amp;oldid=prev</id>
		<title>Bryan: 1 revision</title>
		<link rel="alternate" type="text/html" href="https://sapph.group/wiki/index.php?title=Template:Str_find/doc&amp;diff=3768&amp;oldid=prev"/>
		<updated>2013-09-03T22:34:21Z</updated>

		<summary type="html">&lt;p&gt;1 revision&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Documentation subpage}}&lt;br /&gt;
{{lua|Module:String}}&lt;br /&gt;
&amp;lt;!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Usage ===&lt;br /&gt;
&amp;lt;nowiki&amp;gt;{{Str find|&amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;text&amp;#039;&amp;#039;|&amp;#039;&amp;#039;sub_string&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;}}&amp;lt;/nowiki&amp;gt; = Position of first appearance of &amp;#039;&amp;#039;sub_string&amp;#039;&amp;#039; in &amp;#039;&amp;#039;text&amp;#039;&amp;#039;.&lt;br /&gt;
&lt;br /&gt;
=== Examples ===&lt;br /&gt;
In the examples, the string to be searched is {{code|1=Abcdefghijklm}}:&lt;br /&gt;
* A; {{str find|Abcdefghijklm|A}}&lt;br /&gt;
* a; {{str find|Abcdefghijklm|a}}&lt;br /&gt;
* def; {{str find|Abcdefghijklm|def}}&lt;br /&gt;
* klm; {{str find|Abcdefghijklm|klm}}&lt;br /&gt;
* zyx; {{str find|Abcdefghijklm|zyx}}&lt;br /&gt;
* empty;klm;{{str find||klm}}&lt;br /&gt;
* empty;empty; {{str find||}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* Case sensitive.&lt;br /&gt;
* Returns -1 if &amp;#039;&amp;#039;sub_string&amp;#039;&amp;#039; not found&lt;br /&gt;
* Character position is 1 based (not 0 based as usual in calculations).&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Warning&amp;#039;&amp;#039;&amp;#039;: if &amp;#039;&amp;#039;sub_string&amp;#039;&amp;#039; is empty, then this routine will return 1 !!! This case will often have to be handled specially.&lt;br /&gt;
&lt;br /&gt;
=== TemplateData ===&lt;br /&gt;
{{TemplateDataHeader}}&lt;br /&gt;
&amp;lt;templatedata&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
        &amp;quot;description&amp;quot;: &amp;quot;A template to find the numeric position of first appearance of &amp;#039;&amp;#039;sub_string&amp;#039;&amp;#039; in &amp;#039;&amp;#039;text&amp;#039;&amp;#039;&amp;quot;,&lt;br /&gt;
        &amp;quot;params&amp;quot;: {&lt;br /&gt;
                &amp;quot;1&amp;quot;: {&lt;br /&gt;
                        &amp;quot;label&amp;quot;: &amp;quot;Text&amp;quot;,&lt;br /&gt;
                        &amp;quot;description&amp;quot;: &amp;quot;The text to search within&amp;quot;,&lt;br /&gt;
                        &amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
                        &amp;quot;required&amp;quot;: true&lt;br /&gt;
                },&lt;br /&gt;
                &amp;quot;2&amp;quot;: {&lt;br /&gt;
                        &amp;quot;label&amp;quot;: &amp;quot;Sub_string&amp;quot;,&lt;br /&gt;
                        &amp;quot;description&amp;quot;: &amp;quot;The string to be searched within the text&amp;quot;,&lt;br /&gt;
                        &amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
                        &amp;quot;required&amp;quot;: true&lt;br /&gt;
                }&lt;br /&gt;
        }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/templatedata&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{navbox string handling templates}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;includeonly&amp;gt;&lt;br /&gt;
&amp;lt;!-- CATEGORIES AND INTERWIKIS HERE, THANKS --&amp;gt;&lt;br /&gt;
[[Category:String manipulation templates]]&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/includeonly&amp;gt;&lt;/div&gt;</summary>
		<author><name>Bryan</name></author>
	</entry>
</feed>