Placeholder mask for SSN

How do you create an input mask for a social security number, similar to a mask for a phone number? I have tried this placeholder, but it doesn’t seem to do anything.

Hi Henry-

Try this posting…

What @SafetyUniversity is also really advisable for security reasons.

If you’re looking for something to mask it as they type you can do this.

  1. Add this to the footer:
<script src="https://cdnjs.cloudflare.com/ajax/libs/inputmask/4.0.9/jquery.inputmask.bundle.min.js"></script>
  1. Add this Javascript code on the page you want to Mask:
TB.render('component_3', function(data){
    $('#fieldLX6QawrZk4').inputmask("999-99-9999");
});

You must change the “#fieldXXXX” and the component_3 id to your values.

The field ID can be retrieved simply in the fields page. So you’d structure it as #field

Here’s an example;
https://localtest.tadabase.io/est/new-user
image

Here is the library this is using, keep in mind, this doesn’t work with number fields.

1 Like