亚洲香蕉成人av网站在线观看_欧美精品成人91久久久久久久_久久久久久久久久久亚洲_热久久视久久精品18亚洲精品_国产精自产拍久久久久久_亚洲色图国产精品_91精品国产网站_中文字幕欧美日韩精品_国产精品久久久久久亚洲调教_国产精品久久一区_性夜试看影院91社区_97在线观看视频国产_68精品久久久久久欧美_欧美精品在线观看_国产精品一区二区久久精品_欧美老女人bb

首頁 > 編程 > Regex > 正文

javascipt 正則表達式英文版

2020-03-16 21:13:54
字體:
來源:轉載
供稿:網友
javascript 正則 原語
 
 
1. Regular-expression literal characters Character Matches
Alphanumeric character Itself
/0 The NUL character (/u0000)
/t Tab (/u0009)
/n Newline (/u000A)
/v Vertical tab (/u000B)
/f Form feed (/u000C)
/r Carriage return (/u000D)
/xnn The Latin character specified by the hexadecimal number nn; for example, /x0A is the same as /n
/uxxxx The Unicode character specified by the hexadecimal number xxxx; for example, /u0009 is the same as /t
/cX The control character ^X; for example, /cJ is equivalent to the newline character /n
 

2. Regular expression character classes Character Matches

[...] Any one character between the brackets.
[^...] Any one character not between the brackets.
.  Any character except newline or another Unicode line terminator.
/w Any ASCII word character. Equivalent to [a-zA-Z0-9_].
/W Any character that is not an ASCII word character. Equivalent to [^a-zA-Z0-9_].
/s Any Unicode whitespace character.
/S Any character that is not Unicode whitespace. Note that /w and /S are not the same thing.
/d Any ASCII digit. Equivalent to [0-9].
/D Any character other than an ASCII digit. Equivalent to [^0-9].
[/b] A literal backspace (special case).
 
3. Regular expression repetition characters Character Meaning
{n,m} Match the previous item at least n times but no more than m times.
{n,} Match the previous item n or more times.
{n} Match exactly n occurrences of the previous item.
?  Match zero or one occurrences of the previous item. That is, the previous item is optional. Equivalent to {0,1}.
+ Match one or more occurrences of the previous item. Equivalent to {1,}.
* Match zero or more occurrences of the previous item. Equivalent to {0,}.
 
4。 Regular expression alternation, grouping, and reference characters Character Meaning
| Alternation. Match either the subexpression to the left or the subexpression to the right.
(...) Grouping. Group items into a single unit that can be used with *, +, ?, |, and so on. Also remember the characters that match this group for use with later references.
(?:...) Grouping only. Group items into a single unit, but do not remember the characters that match this group.
/n Match the same characters that were matched when group number n was first matched. Groups are subexpressions within (possibly nested) parentheses. Group numbers are assigned by counting left parentheses from left to right. Groups formed with (?: are not numbered.
 
5. Regular-expression anchor characters Character Meaning
^ Match the beginning of the string and, in multiline searches, the beginning of a line.
$ Match the end of the string and, in multiline searches, the end of a line.
/b Match a word boundary. That is, match the position between a /w character and a /W character or between a /w character and the beginning or end of a string. (Note, however, that [/b] matches backspace.)
/B Match a position that is not a word boundary.
(?=p) A positive lookahead assertion. Require that the following characters match the pattern p, but do not include those characters in the match.
(?!p) A negative lookahead assertion. Require that the following characters do not match the pattern p.
 
6. Regular-expression flags Character Meaning
i Perform case-insensitive matching.
g Perform a global matchthat is, find all matches rather than stopping after the first match.
m Multiline mode. ^ matches beginning of line or beginning of string, and $ matches end of line or end of string.
 
 
string.replace(regexp, replacement)
 
Characters Replacement
$1, $2, ..., $99  The text that matched the 1st through 99th parenthesized subexpression within regexp
$&  The substring that matched regexp
$'  The text to the left of the matched substring
$'  The text to the right of the matched substring
$$  A literal dollar sign
 
name.replace(/(/w+)/s*,/s*(/w+)/, "$2 $1");
text.replace(/"([^"]*)"/g, "''$1''");
text.replace(//b/w+/b/g, function(word) {
                           return word.substring(0,1).toUpperCase( ) +
                                  word.substring(1);
                         });

發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
亚洲香蕉成人av网站在线观看_欧美精品成人91久久久久久久_久久久久久久久久久亚洲_热久久视久久精品18亚洲精品_国产精自产拍久久久久久_亚洲色图国产精品_91精品国产网站_中文字幕欧美日韩精品_国产精品久久久久久亚洲调教_国产精品久久一区_性夜试看影院91社区_97在线观看视频国产_68精品久久久久久欧美_欧美精品在线观看_国产精品一区二区久久精品_欧美老女人bb
91情侣偷在线精品国产| 欧美专区中文字幕| xxav国产精品美女主播| 成人精品aaaa网站| 欧美在线视频免费观看| 好吊成人免视频| 国产精自产拍久久久久久蜜| 亚州国产精品久久久| 久久久亚洲欧洲日产国码aⅴ| 欧美激情一级精品国产| 91久久国产综合久久91精品网站| 国产www精品| 欧美人交a欧美精品| 亚洲无亚洲人成网站77777| 日韩一级黄色av| 91亚洲国产成人久久精品网站| 亚洲japanese制服美女| 精品少妇一区二区30p| 国产精品久久久久久久久久| 欧美在线激情视频| 久久偷看各类女兵18女厕嘘嘘| 岛国精品视频在线播放| 亚洲精品免费网站| 亚洲精品久久久久中文字幕欢迎你| 色av中文字幕一区| 中文字幕日韩在线观看| 97色伦亚洲国产| 欧美不卡视频一区发布| 久久久久这里只有精品| 欧美夫妻性生活视频| 国产精品1区2区在线观看| 日韩性xxxx爱| 成人黄色av网| 97久久精品人人澡人人爽缅北| 欧美极品xxxx| 亚洲人成免费电影| 色偷偷91综合久久噜噜| 欧洲永久精品大片ww免费漫画| 欧美日韩午夜视频在线观看| 国产亚洲精品美女| 尤物九九久久国产精品的分类| 福利一区视频在线观看| 国产精品成人免费电影| 中文字幕亚洲欧美一区二区三区| 久久久免费av| 亚洲国产天堂网精品网站| 国产精品久久久久久久久| 欧美在线视频在线播放完整版免费观看| 国产精品第1页| 在线电影中文日韩| 亚洲97在线观看| 日韩av影片在线观看| 久久99久久亚洲国产| 欧美成人久久久| 亚洲激情在线观看视频免费| 5278欧美一区二区三区| 国产精品免费看久久久香蕉| 成人精品久久久| 成人疯狂猛交xxx| 亚洲成人久久电影| 亚洲一区二区黄| 成人国产精品久久久| 久久影视电视剧凤归四时歌| 6080yy精品一区二区三区| 91在线视频免费| 久久久久久久久久婷婷| 国产最新精品视频| 97在线视频观看| 欧美一级在线亚洲天堂| 国产精品电影在线观看| 欧美极品在线视频| 久久综合九色九九| 成人有码视频在线播放| 亚洲国产日韩欧美在线动漫| 91禁外国网站| 欧美黑人性视频| 精品久久久视频| 久久影视电视剧免费网站清宫辞电视| 奇米成人av国产一区二区三区| 97**国产露脸精品国产| 一个人看的www欧美| www.久久草.com| 久久久久国产视频| 欧美日韩激情视频8区| 亚洲大胆人体在线| 亚洲成人激情视频| 欧美激情欧美激情在线五月| 国产精品嫩草视频| 久久99精品久久久久久噜噜| 欧美日韩在线视频一区| 国内精品久久久久影院 日本资源| 91sao在线观看国产| 77777亚洲午夜久久多人| 亚洲人午夜精品免费| 日韩在线观看精品| 国产一区二区三区在线播放免费观看| 亚洲精品456在线播放狼人| 久久精品中文字幕一区| 国产美女搞久久| 久久久在线观看| 国产精品日韩电影| 欧美黑人性猛交| 欧美成人久久久| 中文字幕在线视频日韩| 国产美女搞久久| 欧美激情网友自拍| 午夜精品在线观看| 一本色道久久88精品综合| 亚洲爱爱爱爱爱| 欧美激情免费视频| 欧美高清视频在线观看| 国产精品色悠悠| 国产精品久久久| 中文一区二区视频| 奇米影视亚洲狠狠色| 成人精品一区二区三区电影免费| 精品国产视频在线| 午夜精品久久久久久久99黑人| 国语对白做受69| 国产日韩精品一区二区| 麻豆国产va免费精品高清在线| 久久久久久久久久久免费| 亚洲无av在线中文字幕| 久久久亚洲天堂| 国产精品视频精品视频| 精品久久久久久电影| 欧美一区二粉嫩精品国产一线天| 日韩av片免费在线观看| 黄色精品在线看| 国产小视频91| 91色琪琪电影亚洲精品久久| 在线电影欧美日韩一区二区私密| 亚洲国产精品专区久久| 久久久久久亚洲| 久久久久久亚洲| 黑人精品xxx一区一二区| 欧美综合激情网| 日韩在线观看免费全| 超碰97人人做人人爱少妇| 欧美亚洲国产视频小说| 伊人av综合网| 日韩精品久久久久| 国产91在线高潮白浆在线观看| 国产精品爽黄69| 亚洲第一二三四五区| 久久天天躁狠狠躁夜夜躁| 欧美国产第一页| 久久精品国产久精国产思思| 国产欧美一区二区三区四区| 亚洲精品网址在线观看| 人人爽久久涩噜噜噜网站| 亚洲国产成人精品久久久国产成人一区| 国产69久久精品成人| 国产精品极品在线| 国产精品久久久久久久久久久久| 欧美日韩一区二区三区在线免费观看| 久久这里有精品视频| 91精品啪aⅴ在线观看国产| 久久成人精品一区二区三区| 日韩久久精品成人| 国产中文日韩欧美| 亚洲美女免费精品视频在线观看| 91精品国产综合久久男男| 亚洲国产精品电影|