Product Variant: Different Value and Label?

Solved
kristobar
Shopify Partner
4 0 0

kristobar_0-1652546434162.png

 

I'd like to be able to change the value and the label separately. 

<input type="radio" name="product-include 'the beam' tube squeezer tool?" id="future-focus-vitamin-c-serum-option-include 'the beam' tube squeezer tool?-1-" value="VALUE HERE" checked="" class="product-variant__input product-variant-value" data-com.bitwarden.browser.user-edited="yes">

<label for="future-focus-vitamin-c-serum-option-include 'the beam' tube squeezer tool?-1-" class="product-variant__label">LABEL HERE
</label>

 

I want to do this because I want to shorten the label to just Yes and No, but for the shipping invoice and packaging slip it shows the value which should be more verbose and clear

Thanks very much for the help! 

 

Accepted Solution (1)

Accepted Solutions
Emirates7
Shopify Partner
45 11 9

This is an accepted solution.

You can do something like below code:

{{ label | replace: "Yes, include 'The Beam'", "Yes" }}

I am available for freelance work.
Skype: Emirates77777 | E: artur.sulkowski.1405@gmail.com

View solution in original post

Replies 3 (3)
Emirates7
Shopify Partner
45 11 9

This is an accepted solution.

You can do something like below code:

{{ label | replace: "Yes, include 'The Beam'", "Yes" }}

I am available for freelance work.
Skype: Emirates77777 | E: artur.sulkowski.1405@gmail.com
kristobar
Shopify Partner
4 0 0

Sorry to be dense, but where would I make this change? In theme.liquid?

Thanks so much

kristobar
Shopify Partner
4 0 0

woo i think i got it! 

kristobar_0-1652556633656.png