Last active
October 12, 2021 12:50
-
-
Save reachkamrul/9ce6e66b324b3555f96c3002091f6f58 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Remove WooCommerce Variable Add to cart System | |
function removeVariableCart(){ | |
var linkText = 'Read More'; // Give your read more text | |
$table.find('.ninja_clmn_nm_woo_product_buy').each(function(){ | |
jQuery(this).find('.nt_woo_attribute').hide(); | |
jQuery(this).prev('.ninja_clmn_nm_woo_product_quantity').find('.quantity').hide(); | |
jQuery(this).find('.wc_product_variable').css('opacity', '1'); | |
var linkVal = jQuery(this).find('#ntb_woo_product_variation').attr('href'); | |
jQuery(this).find('#ntb_woo_product_variation').replaceWith('<a href="'+linkVal+'" class="nt_button_woo button">'+linkText+ '</a>'); | |
}) | |
}; | |
$(document).ready(function(){ | |
removeVariableCart(); | |
}); | |
$table.on('after.ft.filtering', function() { | |
removeVariableCart(); | |
}); | |
$table.on('after.ft.paging', function() { | |
removeVariableCart(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment