Help:Templates/Regexp

From TED Notepad
< Help:Templates
Revision as of 10:26, 19 November 2013 by Jsimlo (talk | contribs) (Created page with "This template is to be used within the documentation for regular expressions. See the Regular expressions chapter for more details. Note: Use <nowiki>|</nowiki> ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

This template is to be used within the documentation for regular expressions. See the Regular expressions chapter for more details.

Note: Use <nowiki>|</nowiki> to add a pipe into the regexp. Other characters may need the <nowiki> and </nowiki> as well.

Examples

Search pattern like {{regexp|<nowiki>abc|xy</nowiki>}} can search for both {{string|abc}} and {{string|xy}} at the same time.

Search pattern like abc|xy can search for both abc and xy at the same time.


Pattern {{regexp|c{3,5<nowiki>}</nowiki>}} matches triple {{string|ccc}} or {{string|cccc}} or {{string|ccccc}}.

Pattern c{3,5} matches triple ccc or cccc or ccccc.