Display Category Text Below Product List
-
I am having some problems with displaying the category text content below my products in a category. I found a solution and placed the code in “my custom functions” plugin. This works, but only for the first page in the category. When I browse to the 2nd page the content is placed above the products again.
I want the text to display to help with SEO. I do not want a big text above my products.
I can place a copy of the code, but to be honest I do not know where or how is best practice for this.
Any help or comments is highly appreciated.
The blog I need help with is: (visible only to logged in users)
-
Hey,
Can you share the code you added to my custom functions, please? As I understand from your message, you’d like to display the description of the category right under the products list, am I right? I want to make sure that I understand exactly what you’d like to do.
Thanks,
Radu -
Het Radu,
Thank you for your reply.
This is the code
add_action('woocommerce_archive_description', 'custom_archive_description', 2 ); function custom_archive_description(){ if( is_product_category() ) : remove_action('woocommerce_archive_description', 'woocommerce_taxonomy_archive_description', 10 ); add_action( 'woocommerce_after_main_content', 'woocommerce_taxonomy_archive_description', 5 ); endif; }
This will place the category description under the products. It only works on the first page. If I scroll to the next page the description is display above the products.
Thanks for your help.
Regards,
Barry
-
Hey Barry,
As I can see, your website is not hosted on the WordPress.com platform. In this case, you should ask this on the forum section of the WooCommerce plugin here https://wordpress.org/support/plugin/woocommerce/. There are a lot of users there, ready to help you with this hook question.
Regards,
Radu -
Also just noting that if you have a paid Woocommerce subscription, you can open a ticket while logged into your account: https://woocommerce.com/my-account/create-a-ticket/
@raduconstantin1 Hi and welcome to volunteering in the community forums for sites hosted on WordPressdotcom. In case you haven’t seen it, Staff have written up a brilliant guide with lots of tips and tricks to help you get the most out of your experience helping WordPressdotcom users. You can find it here: https://en.support.wordpress.com/wordpress-com-volunteers/
Cheers! -
- The topic ‘Display Category Text Below Product List’ is closed to new replies.