0

We're using Store 2.5.0 and EE 2.9.2. On the checkout page we're showing the value of any modifiers using:

{if price_mod_val}({price_mod}){/if}

It's returning the value of the modifiers ok, but it's also displaying +0.00 if the modifier is empty.

Is there a way to not show the modifier value if it's 0?

1 Answer 1

1

I would say:

{if price_mod_val && price_mod_val != "+0.00"}({price_mod}){/if}
3
  • Heeeey... this person is saying it's displaying "+0.00" .. perhaps update your answer to accommodate that? I don't want to steal it from you :p
    – jrothafer
    Aug 6, 2015 at 13:03
  • Hi, thanks for your help. {if price_mod_val && price_mod_val != "+0.00"}({price_mod}){/if} worked.
    – Mark
    Aug 6, 2015 at 13:20
  • I was assuming price_mod_val would be 0 and price_mod +0.00 because of the explanation. Thank you jrothafer for the replenishment. And you're welcome Baradat, Glad I could help. Aug 6, 2015 at 13:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.