jQuery(‘input[name=”_tipo”], label input[name=”_tipo”]’).on(‘change’, function() {
var mask = (jQuery(this).val() == ‘CPF’) ? ‘000.000.000-00’ : ‘00.000.000/0000-00’;
jQuery(‘input[name=”user_login”]’).mask(mask);
I’m not sure where to look for a reference guide for this kind of thing. Any help would be much appreciated!
New contributor
Convex 005 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.