Difference between revisions of "Template:String"

From TED Notepad
Line 4: Line 4:
 
A filter for text files would look like this: {{string|Text Files <nowiki>|</nowiki> *.txt}}.
 
A filter for text files would look like this: {{string|Text Files <nowiki>|</nowiki> *.txt}}.
  
Search for phrase {{string|john}} within string {{string|hi johnny}} will fail, if {{feature|Whole Words}} is turned on.
+
Search for phrase {{string|john}} within string {{string|hi johnny}} will fail, if
 +
{{feature|Whole Words}} is turned on.
 
= Usage =
 
= Usage =
 
<pre>
 
<pre>
 
A filter for text files would look like this: {{string|Text Files &lt;nowiki&gt;|&lt;/nowiki&gt; *.txt}}.
 
A filter for text files would look like this: {{string|Text Files &lt;nowiki&gt;|&lt;/nowiki&gt; *.txt}}.
  
Search for phrase {{string|john}} within string {{string|hi johnny}} will fail, if {{feature|Whole Words}} is turned on.
+
Search for phrase {{string|john}} within string {{string|hi johnny}} will fail, if
 +
{{feature|Whole Words}} is turned on.
 
</pre>
 
</pre>
 
Note: The &lt;nowiki&gt;|&lt;/nowiki&gt; part is there because templates use pipes to distinguish parameters. We need to override that, as we want the pipe to be treated as a plain text.
 
Note: The &lt;nowiki&gt;|&lt;/nowiki&gt; part is there because templates use pipes to distinguish parameters. We need to override that, as we want the pipe to be treated as a plain text.
 
</noinclude><noinclude>[[Category:Templates]]</noinclude>
 
</noinclude><noinclude>[[Category:Templates]]</noinclude>

Revision as of 13:07, 24 February 2006

This template is to be used within documentation for string values and phrases. Especially to express that a string like this is what the user should have chosen somewhere within TED Notepad.

Preview

A filter for text files would look like this: Text Files | *.txt.

Search for phrase john within string hi johnny will fail, if Whole Words is turned on.

Usage

A filter for text files would look like this: {{string|Text Files <nowiki>|</nowiki> *.txt}}.

Search for phrase {{string|john}} within string {{string|hi johnny}} will fail, if
{{feature|Whole Words}} is turned on.

Note: The <nowiki>|</nowiki> part is there because templates use pipes to distinguish parameters. We need to override that, as we want the pipe to be treated as a plain text.