Searching for phone numbers in mysql
I have a table which is full of arbitrarily formatted phone numbers, like this
I have a table which is full of arbitrarily formatted phone numbers, like this
I want to mark up a phone number as callable link in an HTML document. I have read the microformats approach, and I know, that the tel:
scheme would be standard, but is quite literally nowhere implemented.
I am working on an SMS app and need to be able to convert the sender’s phone number from +11234567890 to 123-456-7890 so it can be compared to records in a MySQL database.
EDIT: I’ve mixed and modified two of the answers given below to form the full function which now does what I had wanted and then some… So I figured I’d post it here in case anyone else comes looking for this same thing.
I’m trying to remove everything from a string but just numbers (0-9).