Code snippet don’t work
-
Hi. I have a problem trying to remove the reviews and additional information on product tabs via Code Snippets. I used the following code:
/**
* Remove product data tabs
*/
add_filter( ‘woocommerce_product_tabs’, ‘woo_remove_product_tabs’, 98 );function woo_remove_product_tabs( $tabs ) {
unset( $tabs[‘description’] ); // Remove the description tab
unset( $tabs[‘reviews’] ); // Remove the reviews tab
unset( $tabs[‘additional_information’] ); // Remove the additional information tabreturn $tabs;
}And although it’s active the code doesn’t work at all. I’ve already tried putting // before the unset of the tab I want to remove and it stays the same. I’ve tried it without // too, and nothing changes. What could be the problem?
- The topic ‘Code snippet don’t work’ is closed to new replies.