Inputmask is a javascript library that creates an input mask. Inputmask can run against vanilla javascript, jQuery, and jqlite.
Inputmask documentationCopy-paste the stylesheet <link> into your
<head> to load the CSS.
Copy-paste the following <script> and
Function near the end of your pages.