0

I am trying in a form to format a SSN ,that each time I enter a key it must change to "*" within 2 seconds while leaving the last digit shown. It also should be masked with (999-99-999) format. For example the final value should be like: " ***-**-***9 " in the input field.

I have tried with Masked input plugin but it's not turning into "password" like within 2 seconds.

How do you do this with jQuery?

I looked for other Stackoverflow questions like this, but I couldn't find anything like my issue or expectation. Especilally this question SSN Masking

 $("#ssnId").unmask().maskSSN('999-99-9999', {maskedChar:'*', maskedCharsLength:10});

this is my form

<input type="text" id="ssn"   class="form-control" required="required" autocomplete="off" />
Community
  • 1
  • 1
Sanshayan
  • 1,076
  • 1
  • 11
  • 16
  • Why downvote please explain – Sanshayan Mar 10 '16 at 07:02
  • I didn't downvote, but it is a bad question. Anyway, here is a jquery plugin that masks the last digit after time: https://github.com/timmywil/password123 Maybe you can combine it with one of the other plugins. – Gerald Schneider Mar 10 '16 at 07:33
  • What is that last bit of code you posted? Is that what you have tried to do? Perhaps explain a bit more what you have tried already. – willdanceforfun Mar 11 '16 at 05:47
  • @willdanceforfun I have tried https://github.com/mishraas/jQuery-SSN-Field-Masking/blob/master/Demo.html this plugin, and it's working well with masking and formatting but i need is, after i enter a value it should shown for a moment and replace with "*" within 2 seconds. i don't know how to do that with this plugin. – Sanshayan Mar 11 '16 at 07:31
  • You should make a working demo with jsfiddle or codepen. It will help get a better idea of what is and what isn't working. – willdanceforfun Mar 11 '16 at 08:09

0 Answers0