How to add a size chart Metafield to Debutify 5.0?

Hi all! Does anyone know how to add a Metafield containing a size chart to the new Debutify 5.0 update? I know how to create the Metafield and connect it to a page with the size chart itself but don’t know how to make it visible on the site.. Thank you!

Hey @SpoljaricMatija ,

Considering the size chart is in image format, a great approach would be to set up a Meta Field as a URL type. You can easily upload the images to ‘Content’ > ‘Files’ in your Shopify Admin and then gather the links.

Once your images are all set and the links are ready, head over to your theme’s code files.

Navigate to the ‘Snippets’ folder and open the ‘product-template.liquid’ file. In the spot you prefer, you can use this HTML & liquid snippet to showcase your Custom Size Chart Meta Field right on the product page.

{% if product.metafields.custom.size_chart != blank %}

{% endif %}

Remember, for the ‘source’ attribute of the image tag, you’ll need to enclose the Meta Field’s name within double curly brackets. If you’re not sure about the name, just pop over to your Shopify Admin, click on ‘Settings,’ then ‘Custom data,’ and there you can find the exact Meta Field name you’re looking for.

For reference, I created one to show you.

Hi. I have located the ‘product-template.liquid’ but it is not under the snippets folder, it is under sections. Can I still try to edit the code or will this not work? Thank you!

Hi @SpoljaricMatija

Are you using Debutify? There should be a file under the Sections and Snippets folder, however, the following instructions will only work on the file under the Snippets folder.

Please how can I add metafield to my debutify theme. I have try a lot of ways and still couldn’t get it and it stresses me out a lot