Created
August 26, 2024 02:13
-
-
Save DeoThemes/b23d06e55ed4063a6f3143ec74d332b4 to your computer and use it in GitHub Desktop.
Edit WooCommerce description product tab with Elementor
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
<?php | |
add_filter('woocommerce_product_tabs', 'custom_woocommerce_product_description_tab', 98); | |
function custom_woocommerce_product_description_tab($tabs) { | |
if (isset($tabs['description'])) { | |
$tabs['description']['callback'] = 'custom_woocommerce_product_description_content'; | |
} | |
return $tabs; | |
} | |
function custom_woocommerce_product_description_content() { | |
if ( did_action( 'elementor/loaded' ) ) { | |
echo \Elementor\Plugin::instance()->frontend->get_builder_content_for_display(780); // Elementor template ID | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment