Hi @paulagaces,
This isn’t something we typically like to do because it is a bit involved. Are you familiar with PHP and WordPress/WooCommerce? Have you customized any of the WooCommerce templates (i.e. have you used WooCommerce’s template hierarchy and replaced layouts via your theme?)
Regardless, we can certainly make the attempt!
Let us know.
Thank you,
Kevin.
Hi @yikesitskevin,
Thank you for your answer.
I am familiar with PHP and WordPress/WooCommerce. I already implemented a Storefront child template customized using snippets in the functions.php file.
I am only interested to know how to get the text of a custom tab. I know how to display information in the cart and checkout pages.
Regards
Hi @paulagaces,
Awesome!
This snippet should be enough to get you going. Our data is saved as an array in the post meta table with the key yikes_woo_product_tabs.
// Assuming the global $post object is available.
$custom_product_tabs = get_post_meta( $post->ID, 'yikes_woo_products_tabs', true );
if ( ! empty( $custom_product_tabs ) ) {
foreach( $custom_product_tabs as $tab ) {
// Assuming the tab title is called Delivery Information
if ( isset( $tab['title'] ) && $tab['title'] === 'Delivery Information' ) {
// Wrap in any markup you desire!
echo $tab['content'];
}
}
}
If you need more info, just ask.
Cheers,
Kevin.
Hi @yikesitskevin,
Great!!!
Thank you very much for your help. It is working like a charm.
Regards
Awesome! If you ever need any more help with similar customizations, you know where to find us.