^[0-9]*$

N digits: ^\d{n}$

At least n digits: ^\d{n,}$

M -n digits: ^\d{m,n}$

The number of zero and non-zero start: ^ (0 | 1-9 *) $

Non-zero digits with at most two decimal digits: ^(1-9*)+(.[0-9]{1,2})? $

Positive or negative numbers with 1-2 decimal places: ^(-)? \ d + (. \ d {1, 2})? $

Positive, negative, and decimal: ^ (+) – |? \d+(.\d+)? $

Positive real numbers with two decimal places: ^[0-9]+(.[0-9]{2})? $

Positive real numbers with 1 to 3 decimal places: ^[0-9]+(.[0-9]{1,3})? $

Non-zero positive integers: ^[1-9]\d

Or ^ ([1-9] [0-9] *) {1, 3}

Or ((1-9] [0-9] ∗) 1, 3, or ^ +? 1-9

$

Non-zero negative integers: ^-[1-9][]0-9″* or ^-[1-9] \\d\*

Non-negative integers: or ^ ^ \ d + \ [1-9 \] \ \ d \ * | 0

A positive integer: ^ – [1-9] \ | 0 or d * ((+) – d ∣ (0 +)) or ^ ((\ \ d +) | (0 +)) or ((+) – d ∣ (0 +))

Non-negative floating point: ^\d+(.\d+)? Or ^ \ [1-9 \] \ \ \ d * \ \. \ \ \ d * | 0 \ \. \ \ \ d * \ [1-9 \] \ \ \ d * | 0? \ \. | 0 + 0

Non-positive float: ^((-\d+(.\d+)?) | ((. 0 0 + +)?) ) or ^ (- (\ [1-9 \] \ \ \ d * \ \. \ \ \ d * | 0 \ \. \ \ \ d * \ [1-9 \] \ \ \ d *)) | 0? \ \. | 0 + 0

Positive floating point: ^[1-9]\d

.\d

|0.\d

[1-9]\d

Or ^ ((\ [0-9 \] + \ \. \ \ [0-9 \] * \ [1-9 \] \ [0-9 \] \ *) | (\ [0-9 \] \ * \ [1-9 \] \ [0-9 \] \ * \ \. \ [0-9 \] +) | (\ [0-9 \] \ * \ [1-9 \] \ [0-9 \] \ *))

Negative floating point: ^-([1-9]\d

.\d

|0.\d

[1-9]\d

) or ^ (- ((\ [0-9 \] + \ \. \ \ [0-9 \] * \ [1-9 \] \ [0-9 \] \ *) | (\ [0-9 \] \ * \ [1-9 \] \ [0-9 \] \ * \ \. \ [0-9 \] +) | (\ [0-9 \] \ * \ [1-9 \] \ [0-9 \] \ *)))

Floating point: ^(-? \d+)(.\d+)? Or ^ -? (\[1-9\]\\d\*\\.\\d\*|0\\.\\d\*\[1-9\]\\d\*|0? \ \ | 0 + 0)

^[\ u4E00 -\u9fa5]{0,}$

English and figures: ^[A-zA-z0-9]+

Or ^ [A Za – z0-9] 40 {4}

Or [A – Za – z0-9] 4, 40

All characters from 3 to 20: ^.{3,20}$

The value is A string of 26 letters: ^[a-za-z]+$

The value contains 26 uppercase letters: ^[a-z]+$

The value is a string of 26 lowercase letters: ^[a-z]+$

The value is A string of 26 letters and digits: ^[A-za-z0-9]+$

String of digits, 26 letters, or underscores: ^\w+$or ^\w{3,20}

Chinese, English, digits including underscore: ^[\u4E00-\ U9FA5A-zA-z0-9_]+$

Chinese, English, Numbers, but not including the underline symbols such as: ^ [\ u4E00 – \ u9FA5A – Za – z0-9] + or ^ \ [\ \ u4E00 – \ \ u9FA5A – Za – z0-9 \] {2} 11

Can be entered with ^%&’,; =? \\” characters: \[^%&’,;=?\x22]+

Do not enter the character 1+ containing ~

Other.* matches any character other than \n.

/ [\ u4E00 \ u9FA5] / characters

/[\uFF00-\uFFFF]/ full Angle symbol

/ [\ u0000 \ u00FF] / half-width symbols Third, the special demand expression Email address: ^ \ w + (+ / – +. \ w)

@\w+([-.]\w+)

.\w+([-.]\w+)*$

Domain: a zA – Z0-9 on conversion {0} (/. A zA – Z0-9 on conversion {0}) + /.?

InternetURL: [a zA – z] + : / / 2

Or ^ (http:// -] [\ w +.) +[\w-]+(/[\w-./?%&=]

)? $

Mobile phone number: ^ (13 [0-9] | | 5 | [7] 14 15 [0 | 1 | 2 | 3 | 5 6 7 8 | | | | 9] | 18 [0 | 1 | 2 | 3 | 5 6 7 8 | | | | 9]) \ d {8} $

Phone number (” XXX – XXXXXXX “, “XXXX – XXXXXXXX”, “XXX – XXXXXXX”, “XXX – XXXXXXXX”, “XXXXXXX” and “XXXXXXXX) : ^ ((\ d {3, 4} -) | \ d {} 3.4 -)? \ d {7, 8} $

Home phone number (0511-4405222, 021-87888822) : \ d {3} – \ d {8} | \ d {4} – \ d {7}

Id number (15, 18 digits) : ^ \ d {15} | \ d {and} $

Short id number (Numbers, the letter “x” at the end) : ^ ([0-9] {7, 17} (x | x)? Or ^ \ \ d {8} 16 | \ [0-9 x \] {8} 16 | \ [0-9 x \] {8} 16?

Whether the account is valid (starting with a letter, 5-16 bytes allowed, alphanumeric underscore allowed) : ^ a-za-z {4,15}$

Password (must start with a letter and contain only letters, digits, and underscores (_).) : ^[a-za-z]\w{5,17}$

Strong password (must contain uppercase and lowercase letters and digits, cannot use special characters, and is between 8 and 10 characters in length) : ^(? =.

\d)(? =.

[a-z])(? =. * [a-z]). 8, 10 {} $

Date format: ^\d{4}-\d{1,2}-\d{1,2}

The twelve months of the year (01 ~ 09 and 1 ~ 12) : ^(0? [1-9] [2-0]) $| 1

31 days of a month (01 ~ 09 and 1 ~ 31) : ^((0? [1-9]) | | 2 (1) ([0-9]) | | 31) $30

Money input format There are four money representations we can accept :”10000.00″ and “10,000.00”, and “10000” and “10,000” without “points” : ^1-9*$

This means that any one does not begin with 0, but it also means that a character “0” is not through, so we use the form below: ^ (0 | 1-9 *) $

A 0 or a number that doesn’t start with 0. We can also allow the beginning there is a minus sign: ^ (0 | -? $1-9 *)

4. This represents a 0 or a potentially negative number that does not begin with a 0. Let the user start with 0. Let’s get rid of the minus, because money can’t be negative. ^[0-9]+(.[0-9]+)? $

Must be clear, decimal point should be at least 1 digit, so it is not through “10.”, but “10” and “10.2” is through: ^ [0-9] + (. [0-9] {2})? $

So we provisions of decimal point must be two, if you think that is too harsh, it can be: ^ [0-9] + (. [0-9] {1, 2})? $

This allows the user to write only one decimal place. Below we should consider a comma in the digital, we can be like this: ^ [0-9] {1, 3} ([0-9] {3}), * (. [0-9] {1, 2})? $

1 to 3 Numbers, followed by any comma + 3 Numbers, commas become optional, rather than having to: ^ ([0-9] + | [0-9] {1, 3} ([0-9] {3}), * (. [0-9] {1, 2})? $

Note: This is the final result, remember that + can be replaced with * if you think empty strings are acceptable (strange, why?). Finally, don’t forget to get rid of the backslash when you use the function. The usual error is in the XML file: ^([a-za-z]+-?) +[a-zA-Z0-9]+\.x|X[l|L]$

Regular expressions for Chinese characters: [u4e00-u9fa5]

Double-byte characters: 3(including Chinese characters, which can be used to calculate the length of a string (a double-byte character length is 2, ASCII character length is 1))

Regular expression for blank lines: \n\s*\r (can be used to delete blank lines)

Regular expressions for HTML tags: <(\S

?). 4

>.

? < 1 > / \ | <.

? /> < span style = “max-width: 100%; clear: both; min-height: 1em;

Regular expression for beginning and ending whitespace: ^\s

|\s

Or (^ \ \ s \ *) | (\ \ s \ *), can be used to delete rows first line of white space characters (including Spaces, tabs, form-feed character, etc.), very useful expressions)

Tencent QQ ID: 1-9{4,}(Tencent QQ ID starts from 10000)

China Postcode: [1-9]\d{5}(? ! \d)(6-digit Postal code for China)

IP address: \d+.\d+.\d+.\d+.

IP address :((? : (? :25[0-5]|2[0-4]\d|[01]? \d? \d)\.) {3} (? :25[0-5]|2[0-4]\d|[01]? \d? \d))

Ip-v4 address: \b(? : (? : 25 [0 to 5) | | 20-4 [01]? 0-9? \.) {3} (? : 25 [0 to 5) | | 20-4 [01]? 0-9? \b (useful for extracting IP addresses)

Check the IP – v6 address: (([0-9 a – fA – F] {1, 4} {7, 7}) [0-9 a – fA – F] {1, 4} | ([0-9 a – fA – F] {1, 4} {1, 7}) : | ([0-9 a – fA – F] {1, 4} {1, 6}) : [0-9 a – fA – F] {1, 4} | ([0-9 a – fA – F] {1, 4} {1, 5}) (: [0-9 a – fA – F] {1, 4}, {1, 2} | ([0-9 a – fA – F] {1, 4} {1, 4}) (: [0-9 a – fA – F] {1, 4}, {1, 3} | ([0-9 a – fA – F] {1, 4} {) 1, 3} (: [0-9 a – fA – F] {1, 4}, {1, 4} | ([0-9] a – fA – F {1, 4}} {1, 2) (: [0-9 a – fA – F] {1, 4}, {1, 5} | [0-9 a – fA – F] {1, 4} : ((: [0-9 a – fA – F] {1, 4}, {1, 6}) | : ((: [0-9 a – fA – F] {1, 4}, {1, 7} | 🙂 | fe80: : [0-9 a – fA – F] {0, 4}) {0, 4} % [0-9 a zA – Z] {1} | : : (FFFF (: 0 {1, 4}) {0, 1} {0, 1}) ((25 [0 to 5] | (2 [0 to 4 {0, 1] | 1} [0-9]) {0, 1} [0-9]) \.) {3} (25 [0 to 5) | (2 [0 to 4] | 1 {0, 1} [0-9]) {0, 1} [0-9]) | ([0-9 a – fA – F] {1, 4} {1, 4}) : ((25 [0 to 5) | (2 [0 to 4] | 1 {0, 1} [0-9]) {0, 1} [0-9]) \.) {3} (25 [0 to 5) | (2 | 1 [0-4] [0-9] {0, 1}) [0-9] {0, 1}))

Subnet mask :((? : (? :25[0-5]|2[0-4]\d|[01]? \d? \d)\.) {3} (? :25[0-5]|2[0-4]\d|[01]? \d? \d))

Calibration date :^(? : (? ! 0000) [0-9] {4} – (? : (? : 0 | [1-9] [0-2] 1) – (? : 0 [1-9] [0-9] | | 1 2 [0 to 8]) | (? : 0 [9] 13 – | [0-2] 1) – (? 30) : 29 | | (? : 0 [13578] 1 [02]) – 31) | | (? : [0-9] {2} (? : 0 [48] | 2468 | 13579) | (? : 0 [48] | 2468 | 13579) 00) – 02-29) $(” yyyy – mm – dd “format date check, has been considered a leap year.)

Extract notes:

Find the CSS property :^\s

[a-zA-Z\-]+\s

[:]{1}\s[a-zA-Z0-9\s.#]+[;] {1}

Extract page hyperlinks :(]

)(href=”https? ((: \ \ /)? ! (? : (? :www\.) ? ‘.implode(‘|(? :www\.) ? ‘, $follow_list).’))5+)”((? ! .

\brel=)4

(?) 4:

) >

Extract page image :\<

[img]6

[src]

=

[\ ‘\’] {0, 1} (7 *)

To extract the color code page: ^ # ([A – Fa – f0-9] {6} | [A – Fa – f0-9] {3}) $

File extension efficacy: ^ (\ [a zA – Z] : | \ \) \ \ (8 + \ \) * 9 + \. TXT (l)? $

Judge IE version: ^.

MSIE 5-8? (? ! .

Trident\/[5-9]\.0).*$

Schedule: