-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
168 lines (159 loc) · 6.5 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<!--
RegexPal 0.1.4c
(c) 2007-2008 Steven Levithan <stevenlevithan.com>
GNU LGPL 3.0 license
-->
<!-- This is the HTML content from index.cfm. This copy does not support permalinks. -->
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Regex Tester – RegexPal</title>
<link href="./assets/regexpal.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="header">
<img src="./assets/regexpal.gif" alt="RegexPal"/>
<h1><a href="./"><span class="t1">Regex</span><span class="t2">Pal</span>
<span id="version">0.1.4</span>
<span id="subtitle">— a JavaScript regular expression tester</span></a>
</h1>
<ul id="nav">
<li><a href="http://blog.stevenlevithan.com/archives/regexpal">Help</a></li>
<li><a href="./history/">Version History</a></li>
<li><a href="mailto:steves_list@hotmail.com">Feedback</a></li>
<li><a href="http://blog.stevenlevithan.com">Blog</a></li>
</ul>
</div>
<div id="options">
<ul>
<li class="hidden"><input id="flagG" type="checkbox" checked="checked"/><label for="flagG">Global</label> <span class="flag">(g)</span></li>
<li><input id="flagI" type="checkbox"/><label for="flagI">Case insensitive</label> <span class="flag">(i)</span></li>
<li><input id="flagM" type="checkbox"/><label for="flagM">^$ match at line breaks</label> <span class="flag">(m)</span></li>
<li><input id="flagS" type="checkbox"/><label for="flagS">Dot matches all</label> <span class="flag">(s<span class="plain">; via <a href="http://stevenlevithan.com/regex/xregexp/">XRegExp</a></span>)</span></li>
<li class="optGroup" id="quickReferenceDropdown">Quick Reference</li>
<li class="optGroup" id="optionsDropdown">Options
<ul>
<li><input id="highlightSyntax" type="checkbox" checked="checked"/><label for="highlightSyntax">Highlight regex syntax</label></li>
<li><input id="highlightMatches" type="checkbox" checked="checked"/><label for="highlightMatches">Highlight matches</label></li>
<li><input id="invertMatches" type="checkbox"/><label for="invertMatches" title="Match any text not matched by the regex">Invert results</label></li>
</ul>
</li>
</ul>
</div>
<div id="quickReference" class="hidden">
<h2>JavaScript Regex Quick Reference</h2>
<img src="./assets/pin.gif" class="pin" alt="pin" title="pin"/>
<img src="./assets/close.gif" class="close" alt="close" title="close"/>
<table cellspacing="0" summary="Regular expressions reference">
<tbody>
<tr>
<td><code>.</code></td>
<td>Any character except newline.</td>
</tr>
<tr class="altBg">
<td><code>\.</code></td>
<td>A period (and so on for <code>\*</code>, <code>\(</code>, <code>\\</code>, etc.)</td>
</tr>
<tr>
<td><code>^</code></td>
<td>The start of the string.</td>
</tr>
<tr class="altBg">
<td><code>$</code></td>
<td>The end of the string.</td>
</tr>
<tr>
<td><code>\d</code>,<code>\w</code>,<code>\s</code></td>
<td>A digit, word character <code>[A-Za-z0-9_]</code>, or whitespace.</td>
</tr>
<tr class="altBg">
<td><code>\D</code>,<code>\W</code>,<code>\S</code></td>
<td>Anything except a digit, word character, or whitespace.</td>
</tr>
<tr>
<td><code>[abc]</code></td>
<td>Character a, b, or c.</td>
</tr>
<tr class="altBg">
<td><code>[a-z]</code></td>
<td>a through z.</td>
</tr>
<tr>
<td><code>[^abc]</code></td>
<td>Any character except a, b, or c.</td>
</tr>
<tr class="altBg">
<td><code>aa|bb</code></td>
<td>Either aa or bb.</td>
</tr>
<tr>
<td><code>?</code></td>
<td>Zero or one of the preceding element.</td>
</tr>
<tr class="altBg">
<td><code>*</code></td>
<td>Zero or more of the preceding element.</td>
</tr>
<tr>
<td><code>+</code></td>
<td>One or more of the preceding element.</td>
</tr>
<tr class="altBg">
<td><code>{<em>n</em>}</code></td>
<td>Exactly <em>n</em> of the preceding element.</td>
</tr>
<tr>
<td><code>{<em>n</em>,}</code></td>
<td><em>n</em> or more of the preceding element.</td>
</tr>
<tr class="altBg">
<td><code>{<em>m</em>,<em>n</em>}</code></td>
<td>Between <em>m</em> and <em>n</em> of the preceding element.</td>
</tr>
<tr>
<td><code>??</code>,<code>*?</code>,<code>+?</code>,<br/><code>{<em>n</em>}?</code>, etc.</td>
<td>Same as above, but as few times as possible.</td>
</tr>
<tr class="altBg">
<td><code>(</code><em>expr</em><code>)</code></td>
<td>Capture <em>expr</em> for use with <code>\1</code>, etc.</td>
</tr>
<tr>
<td><code>(?:</code><em>expr</em><code>)</code></td>
<td>Non-capturing group.</td>
</tr>
<tr class="altBg">
<td><code>(?=</code><em>expr</em><code>)</code></td>
<td>Followed by <em>expr</em>.</td>
</tr>
<tr>
<td><code>(?!</code><em>expr</em><code>)</code></td>
<td>Not followed by <em>expr</em>.</td>
</tr>
</tbody>
</table>
<p><a href="http://developer.mozilla.org/en/docs/Core_JavaScript_1.5_Reference:Global_Objects:RegExp#Special_characters_in_regular_expressions">Near-complete reference</a></p>
</div>
<div id="body">
<div id="search" class="smartField">
<textarea cols="100" rows="3" tabindex="1">Enter regex here.</textarea>
</div>
<div id="input" class="smartField">
<textarea cols="100" rows="10" tabindex="2">Enter test data here.</textarea>
</div>
</div>
<div id="footer" class="small">
<p><strong>Need more power?</strong> Get <a href="http://www.regexbuddy.com/cgi-bin/affref.pl?aff=SteveL">RegexBuddy</a> from <abbr title="Just Great Software">JGsoft</abbr>, a powerful regex tester & builder that inspired many of this application's features.</p>
<p id="copyright">© 2008 <a href="http://blog.stevenlevithan.com">Steven Levithan</a> — <a href="http://code.google.com/p/regexpal/">Google Code</a></p>
</div>
<script src="./assets/build-0.1.4.js"></script>
<!-- Build file includes:
<script src="./assets/xregexp.js"></script>
<script src="./assets/helpers.js"></script>
<script src="./assets/regexpal.js"></script>
-->
<!-- Stats by Mint <haveamint.com> -->
<script src="/mint/?js"></script>
</body>
</html>