Last active
December 31, 2015 14:19
-
-
Save claudiosanches/7999681 to your computer and use it in GitHub Desktop.
WooCommerce - Remove default product tabs.
This file contains 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
<?php | |
/** | |
* Remove default product tabs. | |
*/ | |
function cs_woocommerce_remove_default_tags( $tabs ) { | |
// Remove description tab. | |
if ( isset( $tabs['description'] ) ) { | |
unset( $tabs['description'] ); | |
} | |
// Remove additional information tab. | |
if ( isset( $tabs['additional_information'] ) ) { | |
unset( $tabs['additional_information'] ); | |
} | |
// Remove reviews tab. | |
if ( isset( $tabs['reviews'] ) ) { | |
unset( $tabs['reviews'] ); | |
} | |
return $tabs; | |
} | |
add_filter( 'woocommerce_product_tabs', 'cs_woocommerce_remove_default_tags' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment