Prevent Spaces in Fields without Input Mask Limitiations

  • Profile Image
    evoltolini
    Asked on February 24, 2023 at 1:19 PM

    I currently want to prevent word spacing in fields. I understand I can use an input mask but the text may vary. So I may not always use all of the specified characters. For instance, sometimes the campaign name might be CampaignOne, other times it might be CampaignOneTwoThree. How can i limit word spacing without having a specified limitation?

  • Profile Image
    Reymar_M
    Replied on February 24, 2023 at 1:43 PM

    Hi Ethan,

    Thank you for reaching out to Jotform Support. Can you explain a bit more about the issue so I can get a better idea of what you are trying to achieve so we can provide you with exact the solution you will need. You do not want spaces/limit the spaces when a user is filling out the fields on your form. Please confirm.

    After we hear back from you, we’ll have a better idea of what’s going on and how to help.

  • Profile Image
    evoltolini
    Replied on February 27, 2023 at 10:11 AM

    Hi Reymar - I want to prevent spaces in a text field. See below. The drop downs and text field all calculate into a final field that generates a UTM. I can control the drop down fields to not have space between them, however I cannot do that with the text field (Campaign Name). Interestingly I can input a mask in that field which will prevent spaces, but the characters have to be the exact fit of the mask or I get an error. I just want to be able to limit spaces in a field, but the values could be different. The current output is

    EMEAFranceEventConferenceMicrosoft Hyperion Campaign.

    I want to achieve EMEAFranceEventConferenceMiscrosftHyperionCampaign.

    Is there a way to limit spaces in a field? Is there way to creat a mask but have it be variable (not filling all spaces in the specified mask)?


    1677510520 63fcc7786b10e  Screenshot 10

  • Profile Image
    Danilo Enterprise Support
    Replied on February 27, 2023 at 10:58 AM

    Hi Ethan,

    Thanks for getting back to us. You can prevent adding space by using Input Masking. You can easily shape the input format in order to prevent the user from typing wrong formats. You can follow the instructions to apply input masking

    1677513095 63fcd187eb318  Screenshot 10

    You can use our Autocomplete Widget to display all of the Campaing names for the user to easily select from the list once they type the initial letter of your Campaing.

    1677513441 63fcd2e19cf5b  Screenshot 21

    Please let us know, If you need further help. 

  • Profile Image
    evoltolini
    Replied on February 27, 2023 at 4:52 PM

    Ok - thank you. What I'm saying is that the input mask requires a specified amount of letters. So if I have an input mask that specifies @@@@@@ and someone puts in Microsoft, it will only allow for Micros. Conversely, if I put in several more @, then it would be Microsoft____ and I get an error. How can I choose a mask but not have a limitation allowing for longer or shorter campaign names. The names are not all known as multiple users add them.

  • Profile Image
    Mary JotForm Support
    Replied on February 27, 2023 at 11:05 PM

    Hi Ethan,

    I'm afraid what you are trying to do is not currently possible. If you will be using input masking, the input should be exactly as how the input masking is set up. I went ahead and escalated your request to our Developers. but when or if it's developed depends on their workload, how viable it is, and how many other users also request it. If there are any updates, we’ll circle back to this thread and let you know.

    Thanks for your patience and understanding, we appreciate it.

  • Profile Image
    kreetoone786
    Replied on February 27, 2023 at 11:28 PM

    Thanks for your great information