Copying data from a field to another (same form)

Home Forums Quform WordPress Copying data from a field to another (same form)

This topic is: resolved
  • This topic has 2 replies, 2 voices, and was last updated 3 weeks ago by Ally.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #30261
    carlichy
    Participant

    I´m trying to copy data from these test boxes –> email=7_8, web=7_52 and phone=7_11) to these other boxes of the next page with the IDs: email=7_65, web=7_67, and phone=7_58.

    I have read this topic using a check-box,
    but I want to activate the copy clicking the next button of my first page not with a check box.

    The code I have tried is this but <b>it doesn´t work</b>. ¿Can you help me?

    jQuery(function ($) {
    $(‘.quform-field-7_2’).click(function () {
    var copy = $(this).is(‘clicked == true’);

    $(‘.quform-field-7_8’).val(copy ? $(‘.quform-field-7_65’).val() : ”);
    $(‘.quform-field-7_52’).val(copy ? $(‘.quform-field-7_67’).val() : ”);
    $(‘.quform-field-7_11’).val(copy ? $(‘.quform-field-7_58’).val() : ”);
    });
    });

    #30262
    carlichy
    Participant

    Issue solved!

    The solution in this topic

    I write my code for someone need it as an example (you have to use in the Custom JavaScript plugin option):

    jQuery(function ($) {
    $(‘.quform-field-7_8’).blur(function () {
    $(‘.quform-field-7_65’).val($(this).val());
    });
    $(‘.quform-field-7_52’).blur(function () {
    $(‘.quform-field-7_67’).val($(this).val());
    });
    $(‘.quform-field-7_11’).blur(function () {
    $(‘.quform-field-7_58’).val($(this).val());
    });
    });

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

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