I would like to have a regular expression which returns only the numbers and the white space which I’ve inserted. i.e.
012 345 678
or
012 345 678 910.
Any suggestion please?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You could remove any other character except digits and white space. Here’s an example in PHP:
Then the remaining string does only consist of digits and white space characters.