PHP Regular expression can not understand, please point
Identify the identifier [a-za-z_][a-za-z_0-9]*] from the program code certificate.
How do I write in the code? I don't know how to write this code? Please give a small example to see.
Share to: more
------Solution--------------------
[A-za-z_] [a-za-z_0-9]*
Uppercase A-Z or lowercase a-Z or underscore plus any number of uppercase A-Z or lowercase a-Z or underscore
Just look at the code of the night regular, practice more.
------Solution--------------------
Preg_match_match ('/^[a-za-z_][a-za-z_0-9]*.$/', $str, $ret);
Print_r ($ret);
------Solution--------------------
Hand Error
Preg_match_all ('/^[a-za-z_][a-za-z_0-9]*.$/', $str, $ret);
Print_r ($ret);
------Solution--------------------
Reference:
Quote: Reference:
Preg_match_match ('/^[a-za-z_][a-za-z_0-9]*.$/', $str, $ret);
Print_r ($ret);
Please advise,
("/^[a-za-z]\d{9}$/", $str) This sentence please explain to me, two A/slash what meaning? ^ What do you mean here? What do you mean, x.$/?
Are the regular basis Ah, Baidu down bar.