Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #-----------------------------------------------------------------#
- # Woocommerce
- #-----------------------------------------------------------------#
- add_filter( 'woocommerce_account_menu_items', 'ag_remove_downloads', 999 );
- function ag_remove_downloads( $items ) {
- unset($items['downloads']);
- return $items;
- }
- //Remove WooCommerce Tabs - this code removes all 3 tabs - to be more specific just remove actual unset lines
- 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 tab
- return $tabs;
- }
- /** Remove short description if product tabs are not displayed */
- function dot_reorder_product_page() {
- if ( get_option('woocommerce_product_tabs') == false ) {
- remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 20 );
- }
- }
- add_action( 'woocommerce_before_main_content', 'dot_reorder_product_page' );
Add Comment
Please, Sign In to add comment