Home › Forums › WoodMart support forum › tabs description
tabs description
- This topic has 5 replies, 2 voices, and was last updated 3 years, 2 months ago by
Elise Noromit.
-
AuthorPosts
-
December 4, 2021 at 5:02 pm #336912
loraloraParticipantHello
Help, I want to insert a shortcode with the content of the html block on the product description page with a description of the product.I copied the template to my child theme, yourtheme/woocommerce/single-product/tabs/description.php.
I have a shortcode with a content grid ready [html_block id="8188"]._______________
defined( ‘ABSPATH’ ) || exit;global $post;
$heading = apply_filters( ‘woocommerce_product_description_heading’, __( ‘Description’, ‘woocommerce’ ) );
?>
<?php if ( $heading ) : ?>
<h2><?php echo esc_html( $heading ); ?></h2>
<?php endif; ?><?php the_content(); ?>
__________
how to insert the shortcode there correctly?
thanks a lotDecember 4, 2021 at 5:46 pm #336923
Elise NoromitMemberHello,
You would better save this template and then insert it into the product: https://xtemos.com/docs/woodmart/html-blocks-2/
If you have any questions please feel free to contact us.
Best Regards
December 4, 2021 at 8:02 pm #336948
loraloraParticipantI’m trying to display fields ACF in the product description (tab). And I need to do it with column breakdown (3 or 4 columns).
1.column is the description itself (fieldACF)
2.column (all possible parameters such as how to wash or what material the product is made of)
3. column – additional photo.I don’t think the template will help me …
now I made a html block with three columns and brought the necessary values there through the widget to WPBakery Page Builder.
I wrote about this in a post https://xtemos.com/forums/topic/product-description-acf-product-page-template/
________and another question, is there any way to close the description field from editing (the standard one in which I will display a block with columns) from editing by user role?
December 6, 2021 at 10:50 am #337143
Elise NoromitMemberHello,
This is the code to display HTML block:
<?php echo do_shortcode( '[html_block id="8188"]' ); ?>
You can insert this code in any place.
If you have any questions please feel free to contact us.
Best Regards
December 6, 2021 at 5:35 pm #337250
loraloraParticipanthello, thank you very much, everything worked out.
I added the code to the very end, after all the contentOnly it is displayed if I add something to the description. If there is nothing there, then the tab is not displayed.
Maybe you have a solution to permanently display the “description” tab, regardless of whether there is something there or not?
Maybe I missed some setting?
your theme support is really the best!
December 6, 2021 at 10:23 pm #337309
Elise NoromitMemberHello,
Yes, this tab disappears if it is empty and we cannot change that, unfortunately. Try to add a space or something else into the description with a builder.
If you have any questions please feel free to contact us.
Best Regards
-
AuthorPosts
- You must be logged in to create new topics. Login / Register