×

Loading...

em.....,. it's not I'm looking for

the actulal situation is:

I got phone number looks like 416-123-45-67-789,
I want to remove the second and third hyphens
and replace the last one with "ext".
sometimes the string comes up as 416-123-4567-789
which is almost correct, just needs to replace last
one with "ext" and replace the second "-" with "",
any general solutions?

and what about situations 416-12345-67-789?

I remember I saw very short piece of code to address this.
can not remember now.....
Report

Replies, comments and Discussions: