|
Verify the regular expression of the phone number:(\ D {3}-) (\ d {8}) $ | (\ d {4}-) (\ d {7 }) $ | (\ d {4}-) (\ d {8}) $
(The new phone number is used here)
Verify the regular expression in the email address:\ W + ([-+.] \ w +) * @ \ w + ([-.] \ w + )*\. \ w + ([-.] \ w + )*
\ W any case English letter 0-9 digit underline + at least 1 character or more
[-+.] \ W + any combination of-+. and \ w characters appears 0 or multiple times
@ Fixed symbol
\ W + contains at least 1 x w character
[-.] \ W + contains zero or multiple character combinations
\. Fixed symbol
Anyway, the combination of \ w + ([-.] \ w +) * requires that it start with a letter of the \ w type, and then follow the combination of \ w and-dashes and dots.
Email regex verificationThat is
The email address must start with a letter (uppercase or lowercase), a number, or an underscore,
It can be followed by any \ w character and a hyphen plus sign (+ ).@Start with any \ w character and hyphen plus sign (+).Start with any \ w character and hyphen plus sign (+) |