Skip Navigation

[Resolved] Content Template NOT displaying via WooCommerce Views single product template

This support ticket is created 4 years, 8 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Our next available supporter will start replying to tickets in about 4.93 hours from now. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 7 replies, has 2 voices.

Last updated by jonB-5 4 years, 8 months ago.

Assisted by: Christian Cox.

Author
Posts
#1537241

I am trying to: Use a content template for designing Single Product pages
I have selected "WooCommerce Views plugin default single product template" in the WooCommerce Views settings.
I am not using the Layouts Plugin.
My theme does use the_content().

Link to a page where the issue can be seen: hidden link

I expected to see: The text "The content Template is working", which is all I have put in the "Single Product" Content Template.

Instead, I got: The standard WooCommerce product page template.

#1537807

Hi, I don't see anything set up incorrectly here. Is it okay for me to temporarily switch to a default theme and deactivate all plugins except Types, Views, WC Views and WooCommerce, or would you prefer to run those tests yourself? I would like to see if there is a conflict of some kind.

#1538743

Hi Christian,

I have tried switching to Twenty Nineteen theme and deactivating all plugins except Types, Views, WC Views and WooCommerce, but the issue persists.

I'll be working on the site until 4pm GMT today and will make a backup at that point, after which you're welcome to deactivate / test / investigate yourself.

Do let me know if that doesn't fit with your work hours and I'll find another window for you to investigate.

Thanks,

James.

#1539007

Okay thanks, this timeframe is great for me. Please let me know once you have made a backup and I will get started. If I'm not able to see anything obvious, I may need to create a clone of the site so I can install it locally and monitor code execution, inspect the database, etc., so please let me know if that's okay when you report back. I'll stand by for your update.

#1539265

I have finished my work on the site for the day and I have made a backup of my database and files, so you're clear to go ahead.

I'm happy for you to clone the site for investigation.

If you look at the product page as it is today, you'll see some page elements overlapping. The non-WooCommerce elements are in sidebar.php and I'm not sure if their positioning is related to this issue or not.

#1539535
Screen Shot 2020-03-04 at 2.57.21 PM.png

Okay I think when you switched to a default theme and turned off plugins you may not have realized the WooCommerce Views single product template was no longer selected, so the default WC template was applied to single products. I went to Toolset > WooCommerce Views and selected the WC Views single post template, which allows the Toolset Content Template to show up. Then I edited the TSN 8866 product post in wp-admin. I selected the Single Product template was applied in the Content Template panel, and now I see the CT here: hidden link

Let me try to isolate a single source of conflict. I'll update you again shortly.

#1539555

There appears to be something going on in the custom theme. For now, I have left Twenty Twenty active so you can see what I'm talking about and get a clearer picture of the problem. Please follow along with the following steps:
1. Verify the Single Product Custom Template is appearing on the product here now: hidden link
2. Twenty Twenty is currently active. Change to the Ahoy theme.
3. Go to Toolset > WooCommerce Views, re-select WooCommerce Views plugin default single product template. You must do this any time you change themes.
4. Edit Product 3732: hidden link
5. Re-apply the Single Product CT.
6. Check front-end Product again (link in #1), and see no post content or h1 title
7. Activate Ahoy fields plugin
8. Check WC Views template and Single Product CT again, usually plugins won't affect this but it's a good idea to check anyway.
9. Check the front-end product one more time, and see the default WC display even though you have the WC Views single product template selected and a Toolset Content Template applied.
10. Reapply Twenty Twenty, deactivate the custom Ahoy plugin, set the WC Views template again, and reapply the Content Template in the post editor. You should see the CT appear now on the front-end.

So you've got one issue in the custom theme and something else when the custom plugin is activated.

Can you verify the steps above are accurate and replicable on your end?

#1540993

Hi Christian,

While following your instructions I came to realise an error I had made - when I first began designing this theme (based on Underscores starter theme) I had not intended for it to be a used on a commerce platform, so I had not opted for the version of the theme that was 'WooCommerce ready'.

I have now transferred my customisations to a WooCommerce ready version of the Underscores theme and this appears to have resolved the issue.

I'm yet to fully test the custom AHOY plugin so will investigate any issues relating to that at a later date.

Thank you for your time!