How can I change the format of the phone number in my example? : I have this sample:

[link][1]


  [1]: http://jsfiddle.net/Xxk3F/2864/

**CODE HTML:**

    <input class="" type="text" name="primary_phone" id="primary_phone" maxlength="10" placeholder="1234567890">

**CODE CSS:**

    $( "#primary_phone" ).blur(function() {
      			text = $(this).val().replace(/(\d{3})(\d{3})(\d{4})/, "$1-$2-$3");
            $(this).val(text);
    });

At this time, the format is the next phone

    123-123-1123

I want to have the next form:

    (123)456-7890

How can I change the format to whatever shape that I want?

Thanks in advance!
