Beg to delete the regular expression 1, we 11, we 122, We 1. they 12. they do 133. they 3 & nbsp; you 33 & nbsp; you 234 & nbsp; you and others, such as numbers + don, numbers + points, and numbers + spaces, how can I delete a regular expression? I will only find the simplest $ c = preg _ kneeling to delete the regular expression of the number
1. we
11. We
122. We
1. they
12. they
133. they
3 You
33 You
234 You
Some of these types are numbers + pause signs, some are numbers + points, and some are numbers + spaces. how can I delete them using regular expressions?
I will only
$ C = preg_replace ("/\ d,/", "", $ yuanwen,-1 );
This operation can only delete single-digit + pause numbers.
Please help me share the following:
------ Solution --------------------
$ C = preg_replace ("/\ d + [,. \ s]/", "", $ yuanwen,-1 );
------ Solution --------------------
$ S = <TXT
1. we
11. We
122. We
1. they
12. they
133. they
3 You
33 You
234 You
TXT;
Echo preg_replace ("/\ d + (? :,
------ Solution --------------------
\.
------ Solution --------------------
\ S)/"," ", $ s );
We
We
We
They
They
They
You guys
You guys
You guys