Date mask for android

Asked

Viewed 115 times

0

I’m creating a mask in a function in jQuery, but Android does not work. On PC and iOS works normally. I have made several attempts of what were indicated in the forums, but I was not successful.

The interesting thing that worked before, but after I inserted a popup on this screen, the mask stopped working, but there were no changes in the mask. Could you please help?

<script type="text/javascript">
    jQuery(document).ready(function ($) {
        $(".mascara").mask("99/99/9999");
    });
</script>
  • And what attempts have you used? Have you tried debug the site and see if an error message appears? Does not work in the browser of smartphone or does not work in the Webview app?

  • I tried through regex, but without success. It is not possible to debug the application due to client restrictions. I generate the package and deploy it for testing. It does not work in the smartphone browser. <script type="text/javascript"> Function mdata(v){ v=v.replace(/ D/g,""); //Remove everything that is not digit v=v.replace(/( d{2})( d)/,"$1/$2"); v=v.replace(/( d{2})( d)/,"$1/$2"); v=v.replace(/( d{2})( d{2})$/,"$1$2"); Return v; } </script>

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.