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
function msk_remove_additionalinfo_tab($tabs) { | |
unset($tabs['additional_information']); | |
$tabs['description']['title'] = __('Details', 'msk'); | |
$tabs['reviews']['title'] = __( 'Clients reviews', 'msk' ); | |
$tabs['description']['priority'] = 50; | |
return $tabs; | |
} | |
add_filter('woocommerce_product_tabs', 'msk_remove_additionalinfo_tab', 10); |
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 | |
/** | |
* "I absolutely love this product" tab | |
* yourtheme/woocommerce/single-product/tabs/love-product.php | |
* @author Mosaika | |
*/ | |
if ( ! defined( 'ABSPATH' ) ) { | |
exit; // Exit if accessed directly | |
} |
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
function msk_add_love_product_tab_content() { | |
wc_get_template('single-product/tabs/love-product.php'); | |
} |
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
function msk_add_love_product_tab($tabs) { | |
$tabs['love_tab'] = array( | |
'title' => __('Popularity', 'msk'), | |
'priority' => 15, | |
'callback' => 'msk_add_love_product_tab_content' | |
); | |
return $tabs; |
NewerOlder