formatPhone.js is a simple standalone script which formats phone numbers as you type.