1(function($) { 2 $(document).on('click touch', '.wpccb_copy', function(e) { 3 if (wpccb_vars.confirm === 'yes') { 4 if (confirm(wpccb_vars.confirm_message)) { 5 wpccb_copy(); 6 } 7 } else { 8 wpccb_copy(); 9 } 10 11 e.preventDefault(); 12 }); 13 14 function wpccb_copy() { 15 $('[name^="billing_"]').each(function() { 16 var $this = $(this); 17 var name = $this.attr('name'); 18 var val = $this.val(); 19 var s_name = name.replace('billing_', 'shipping_'); 20 21 $('[name="' + s_name + '"]').val(val).trigger('change'); 22 $(document).trigger('wpccb_field_copied', [name, val]); 23 }); 24 25 $(document.body).trigger('update_checkout'); 26 $(document).trigger('wpccb_copied'); 27 } 28})(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.