Archived topic
Adding content after Woocommerce shop loop
9 replies · Started by mkjj on March 27, 2023
I would like to add content on the main Woocommerce shop page. I tried a hook element with the display rule "woocommerce_after_shop_loop". Unfortunately, it doesn't change anything. For test purposes I used simple plain text. We configured a page as the main shop page in the Woocommerce settings and would prefer this over a static page (using a Woocommerce shortcode). The reason is that another plugin depends on a default shop page.
Thank you!
Hi there,
We configured a page as the main shop page in the Woocommerce settings and would prefer this over a static page (using a Woocommerce shortcode)
Not sure I understand how it is configured exactly.
If the page is not using Woo template, then the hook does NOT exist.
Hi Ying,
we use the standard Woocommerce template and set the main shop page in Woocommerce > settings > products. I refered to this post where David recommended using a static page instead of a dedicated Woocommerce page.
Hi there,
if you're using the static page then that hook does not exist there.
Why not add the content to the static page ?
Hi David,
If you’re using the static page then that hook does not exist there.
Do you mean the page that is configured in Woocommerce > settings > products?
Why not add the content to the static page ?
I'm a little bit confused as to what you mean by "static page". We have two main options for showing the main Woocommerce archive. We can either use a standard page and get the content using a Woocommerce shortcode. Or we can assign a page as the Woocommerce shop page. By default, it is possible to add content BEFORE the Woocommerce loop, but not after it.
In our case we need a page assigned as the Woocommerce shop page for a plugin to work. This is why I tried to use a hook element for it. Am I missing anything here? I read the documentation but couldn't find the answer I was looking for.
I probably misunderstand what is meant by “woocommerce_after_shop_loop”. :-)
If you're using the Woo page that you select in Woocommerce > settings > products then that hook should exist.
Can i see the shop page ?
Sure: Here it is. It's german, but this shouldn't bother you. :-)
As display rule I chose page > the assigned shop page. Is this correct? The hook is "woocommerce_after_shop_loop”.
Ah .... the Display Rule needs to be the Product Archive
Sorry, I missed the notification for your last reply. Awesome, this works perfectly fine. It's a little counter-intuitive. I would have thought that "Product Archive" would include the Woocommerce category pages. This is why I didn't even try this setting. Anyway, thank you very much for the great support.
We should probably add a sub label to that to make it clearer. Ill make a note.
Glad to be of help