jQuery UI Widgets Forums Editors MaskedInput Mask not being retained

Tagged: ,

This topic contains 2 replies, has 2 voices, and was last updated by  nab054371 6 years, 10 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • Mask not being retained #56803


    Hi there,

    So I have defined jqxMaskedInput as shown below in my main form:

    $(“#workphone”).jqxMaskedInput({width: ‘90%’,height: ’20px’,mask:'(###)###-##-####’,value: 001});

    Upon form submission, if an error is encountered, I redirect the user to a failure page. At this point, user has the ability to go back to the form using browser back button. However, when the user goes back to the main form, he no longer sees the mask in maskedInput fields. I see that the placeholder is being retained on the jqxInput widget. I would expect the mask to retain itself too. Am I missing something here?

    Thanks in advance.


    • This topic was modified 6 years, 10 months ago by  nab054371.
    Mask not being retained #56805

    Peter Stoev

    Hi nab054371,

    The place holder is what is displayed when there’s no entered value. When you go back, your web page will be re-displayed and your client side scripts will run again which means that the widgets will be re-initialized as well. That’s the same as opening the page for first time unless there is some caching. So the behavior is normal. The masked input will be re-created and will display an empty mask.

    Best Regards,
    Peter Stoev

    jQWidgets Team

    Mask not being retained #56806


    So when I open the page first time, I see (001)___-___-____. However when I use the back button, I just see an empty mask. Sorry, I am still not understanding how that could be normal? I would expect the page to display (001)___-___-____ as no value has been input.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.