Home › Forums › Quform WordPress › Populate another form field script
- This topic has 2 replies, 2 voices, and was last updated 9 years, 1 month ago by DCM.
- AuthorPosts
- March 19, 2015 at 9:05 pm #14712DCMParticipant
Hi,
I am using the script below to populate the shipping address if its the same as the billing address. My problem is this, I am using the “inside label placement” for my fields and when the shipping address is populated it still shows the inside label text as well. How would I edit the script to clear the inside label text on population?Cheers
<script>
jQuery(document).ready(function ($) {
$('.iphorm_13_23').click(function () {
if ($(this).is(':checked')) {
$('.iphorm_13_26').val($('.iphorm_13_4').val());
$('.iphorm_13_27').val($('.iphorm_13_5').val());
$('.iphorm_13_28').val($('.iphorm_13_19').val());
$('.iphorm_13_22').val($('.iphorm_13_13').val());
$('.iphorm_13_29').val($('.iphorm_13_14').val());
$('.iphorm_13_30').val($('.iphorm_13_49').val());
$('.iphorm_13_31').val($('.iphorm_13_25').val());
$('.iphorm_13_32').val($('.iphorm_13_18').val());
$('.iphorm_13_33').val($('.iphorm_13_24').val());
$('.iphorm_13_34').val($('.iphorm_13_8').val());
$('.iphorm_13_35').val($('.iphorm_13_6').val());
$('.iphorm_13_36').val($('.iphorm_13_7').val());
} else {
$('.iphorm_13_26, .iphorm_13_27, .iphorm_13_28, .iphorm_13_22, .iphorm_13_29, .iphorm_13_30, .iphorm_13_31, .iphorm_13_32, .iphorm_13_33, .iphorm_13_34, .iphorm_13_35, .iphorm_13_36').val('');
}
});
});
</script>
March 23, 2015 at 9:50 am #14735AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
March 23, 2015 at 4:38 pm #14773DCMParticipantWorked perfect! – Five stars
Thank you - AuthorPosts
- You must be logged in to reply to this topic.