Ecommerce Shopify WordPress Discussion

Expanse Theme – Update Metafield Variant On Shopify Product

I'm working on Shopify and using Expanse theme right now, and I'm still new sorry, because most of my project is WordPress. I'm trying to create Metafields Variant with Size, Color. I already displayed the variants, but the problem, the page need to refresh before it change, is there a way on to fix this problem? Here is my code: {% for variant in product.variants %} <div class="variant__description" data-variant-id="{{}}" {% if == %} style="display: block;" {% endif %}> {% if variant.metafields.custom.variant_size %} <p><span class="font-body-bold">Dimension:</span>{{ variant.metafields.custom.variant_size }}</p> {% endif %} {% if variant.metafields.custom.variant_cubage %} <p><span class="font-body-bold">Cubage:</span>{{ variant.metafields.custom.variant_cubage }}</p> {% endif %} </div> {%- endfor -%} Change product variants metafields base on product selected size or colors
I would suggest you use the Built-in variant preset to do so. It will give you a built-in search and filter feature as well in the front end. Please check below screen-shot how you can add size and color variants for the product. ref: If any doubts please comment

December 30, 2023

TurboCommerce make the better internet purchasing globaly

Turbo Multi-language Translator

Make the better internet purchasing globaly

Turbosify SEO Speed Booster

5.0 (7) Free plan available
Get better conversions by improving store loading speed Installed

Turbo Multi-language Chat - AI Customer service in one hand

TurboCommerce make the better internet purchasing globaly
Our products

The help you need, when you need it

App by Turbo Engine

3 apps • 5.0 average rating

Turbosify Speed Booster

5.0 (7)
Get better conversions by optimizing shopify store Google page speed Installed

Turbosify Translator for Wordpress Woocommerce

5.0 (74) Free Wordpress Woocommerce Plugin
Translate your wordpress website to multiple language within 1 click, no configuration needed, no No technical required

Grow your business here

Whether you want to sell products down the street or around the world, we have all the tools you need.