We sell a variety of seedlings on our website. We also sell some growing supplies. These products all use the same product template.
I have created a metafield that contains the embed link for a youtube video. I have added a collapsible row with custom liquid and the metafield for the video is in there. It is displaying correctly on products (example here https://8c4caf-34.myshopify.com/products/lettuce-starfighter).
The problem is not all of the products have a product video, so I want to hide the empty element so it doesn’t show an empty collapsible row.
Thanks! Works like a charm. I have two follow up questions.
This shows those that contain “iframe”. I have another collapsible row that displays certain metafields on the product. How can I hide the section if the product doesn’t have those metafields defined?
Adding this code is great, and gets my site where I want it, but is there an easy way to ensure it stays when updating the theme? Or do I just need to manually paste it after updating the theme?
Where is the code? I need to update my theme and add this code and I didn’t make a note of it. I can’t remember where I made this change to grab the code and copy it to the updated theme.