Get value from a text field inside group

Home Forums Quform WordPress Get value from a text field inside group

This topic is: resolved
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #33975
    oivanr
    Participant

    Hi,
    I need to get a value from a text field but the problem is that this field is inside a group o fields I had try with this code, but I really don’t have an idea of how to refer properly to the field text inside a group

    $(‘.quform-element-39_18 .quform-field-39_27’).change(function () {
    $(‘.quform-field-39_28’).val(‘Omarcito’);
    var $telefono = $(this).val();
    var $pais = $(‘.quform-field-39_7 option:selected’);
    var resultado = consultaTelefonos($telefono, $pais);
    });

    I try this, where the element-39_18 is the group and the field-39_27 is the text field

    Thanks for your help in advance.
    Regards,
    Omar

    #33977
    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.

    #33981
    oivanr
    Participant

    Hi Ally,
    Thanks for your help. I found my mistake. In the second line I did not include the .quform-element reference, now it seem to work fine.
    $(‘.quform-element-39_18 .quform-field-39_27’).change(function () {
    $(‘.quform-field-39_28’).val(‘Omarcito’);
    Thanks a lot.
    Regards,

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2024 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy