Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
We have an All Products page (https://illuminatelabs.org/collections/all) which doesn't offer the opportunity in the Shopify backend to add a meta description. Is there a way to do this manually?
@IlluminateLabs
I can be wrong, though as far as I am aware the pro of metafield is being able to setup unique values per pages.
So, say you have the collections "dogs" and "cats". With metafields you can customize the value individually depending on the collection: you may have the text "dogs are nice" under the dogs' collection, and "cats are cool" under the cats' collection. (I'm using text for the sake of simplicity, it could be a file, colors, code snippet, etc.)
Taking into consideration that /all is a single page with no variations, I'd say it's better to hard code the functionality within the theme without metafields and create a custom field within settings_schema.json for the user to update the value as they wish.
Kind regards,
Diego
I appreciate your response but it's not super helpful. I'm asking how to set a meta description for one page and your response says "you should hard-code a metafield in Shopify". Yes, that's what I'm inquiring how to do.
This is a one-off case and we won't need this functionality outside of this one page so I'm trying to keep it as simple as possible.
The purpose of a meta description is to provide information to search engine results pages (and their users) about the contents of the page.
You can use the code: {{ product.metafields.global.description_tag }}
It will show metafields description: https://i.imgur.com/HWrED3f.png
Hope it helps!
@LitExtension thanks for your response. Can you specify how this code would be used? I don't see examples in my existing code with this format so I'm unsure how to specify the meta description.
As an example, if I wanted the meta-description to be "All Illuminate Labs products available for sale", would it look like this?:
{{ product.metafields.global.description_tag }}: "All Illuminate Labs products available for sale";
You really confused me, what are you trying to add?
"meta description": What does it mean, do you want to add it at the collection page or the product page?
Will it show the same for all or customize for each. Please send me a screenshot, I will check it.
@LitExtension check this out for a more succinct explanation of why this is important than I can provide: https://www.wordstream.com/meta-description
I'm just trying to add it for the All Products page I referenced above. I already have meta descriptions for all individual products pages. The description will be unique because the purpose is to describe the page contents.
By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024Thanks to everyone who participated in our AMA with 2H Media: Marketing Your Shopify St...
By Jacqui Sep 6, 2024