I have a line of code on the server that I want to move to the client page in javascript.
string ThePhone = "1234567890";
string ThisFormat = Regex.Replace(ThePhone, @"(\d{3})(\d{3})(\d{4})", "$1-$2-$3");
It's supposed to return 123-456-7890. How can I change this to javascript?
Thanks.