Allowed only first name in first name fields

Home Forums Quform WordPress Allowed only first name in first name fields

This topic is: resolved

This topic contains 5 replies, has 2 voices, and was last updated by  beingo 6 days, 6 hours ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #28482

    beingo
    Participant

    Allowed only first name in first name fields (for exemple)

    I want permission for example in the field: First name
    What real name.
    If the user enters the form, first name fields, for example: Orange or Apple …. (in upper or lower case) the form is not valid. An error message appears.

    I tried to do it with “Regex” in advanced setting “form fields, reversing the control.
    I put names allowed / Aladin | Antoni | Karim / but the list is very long.
    moreover I must write the first name with a majusucle (Aladin) and in lower case (aladin). If not, it is misleading.

    Please, help me to make a quicker and easier solution.

    #28501

    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #28502

    beingo
    Participant

    Superb!
    thank you so much
    it works ! I am happy

    I already have a plugin that was created:
    Quform-custom.php
    I insert here all the code relating to the change of the form and also the imput mask, validator 18 years …)

    For this code (allow first names in the list)
    I need a specific .php page

    Can I create a new .php file (example Quform-firstname.php) add this code and integrate this new .php file with the plugin “Quform-custom”?

    #28503

    beingo
    Participant

    I wanted to embed the value in the error message.
    I put this code: $element->addError(‘%value% The name is not valid’);

    He does not take into account.

    #28505

    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #28512

    beingo
    Participant

    excellent
    works
    thank you so much
    Subject solved 🙂

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

You must be logged in to reply to this topic.

Be inspired. © 2018 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy