$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>customization - Hiding Short Description in Shop Page, WooCommerce|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

customization - Hiding Short Description in Shop Page, WooCommerce

matteradmin6PV0评论

Good morning everybody. I am trying to remove the Short Description in the Shop Page. Doing this in the Product Page was simple enough remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 20); But I have found no way to do the same in the previous Shop Page. There, I just want images, not text (or at least not the Short Description, a very long tables in this case).

Could you please help me?

Thanks anyway!

Good morning everybody. I am trying to remove the Short Description in the Shop Page. Doing this in the Product Page was simple enough remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 20); But I have found no way to do the same in the previous Shop Page. There, I just want images, not text (or at least not the Short Description, a very long tables in this case).

Could you please help me?

Thanks anyway!

Share Improve this question asked May 30, 2017 at 12:30 AlbertoAlberto 111 silver badge1 bronze badge 2
  • Sorry I don't know exactly what page you'll need to remove code from without seeing the website. Could you hide the specific div and leave the content for SEO purposes? – Ben McMahon Commented May 30, 2017 at 15:11
  • I have found a solution. Just commenting this in woocommerce/content-product.php <code> /** do_action( 'flatsome_product_box_after' ); */ </code>. This is the web: [link]speedrill/tienda – Alberto Commented May 31, 2017 at 7:15
Add a comment  | 

1 Answer 1

Reset to default 1

Try using one of the available shop loop item actions and remove call to WooCommerce template function woocommerce_template_single_excerpt using remove_action().

  • woocommerce_before_shop_loop_item (before thumbnail)
  • woocommerce_before_shop_loop_item_title (before title)
  • woocommerce_shop_loop_item_title (before price)
  • woocommerce_after_shop_loop_item_title (before "Add to cart" button)
  • woocommerce_after_shop_loop_item (after "Add to cart" button)

These actions are called in woocommerce/templates/content-product.php.

E. g. remove_action( 'woocommerce_shop_loop_item_title', 'woocommerce_template_single_excerpt' );. Make sure to match $priority with the $priority it was originally added.

Post a comment

comment list (0)

  1. No comments so far