Personalized checkout and custom promotions with Shopify Scripts
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
In Shopify in the Dawn theme, I want to automatically change the color of a shirt or sweater on a product page, so that the product title and product description also change automatically. How do I do that?
Hi @RikandMoniek,
You could do this with variant Metafields and a custom script.
1. For each color variant you'd create a title and description metafield.
Settings > Metafields and metaobjects > Variants > Add definition.
2. The script would then select your product title and description and replace this with the value of your variant metafield.
The exact code here would be theme specific
Hope that at least points you in the right direction,
Jake
Hi Jake, thanks for your response. I'll get to work on this! Greetings Rik
Awesome! if you need help there is a link in my bio
Hi @RikandMoniek 👋 It's an advanced theme customization to have a dynamic title based on interaction such as variant or option selection.
That said, some themes may have the title for the PDP(product description page) as a dynamic source setting AND reload the entire product-info area.
So for themes that have that specific behavior you could add some liquid, like {{ product.selected_variant.title }}, to the title setting; 💣 test thoroughly for when there is no variant selected.
If you need this customization added to a theme then contact me for services.
Contact info in forum signature below ⬇ ⬇ ⬇.
ALWAYS please provide context, examples: store url, theme name, post url(s) , or any further detail in ALL correspondence.
Contact paull.newton+shopifyforum@gmail.com for the solutions you need
Save time & money ,Ask Questions The Smart Way
Problem Solved? ✔Accept and Like solutions to help future merchants
Answers powered by coffee Thank Paul with a ☕ Coffee for more answers or donate to eff.org
Hi Paul, from all the responses it is indeed clear that I need to do some liquid coding to get a dynamic PDP. I will look further in this direction and try with instructions and codes that I have found. Grt, Rik