• Resolved kyonv2

    (@kyonv2)


    Hello,

    Would it be possible to also add price in the button alongside the attribute name without it being in the same span?

    I want to my clients to know right away what the 3 options (attributes) I offer are priced so I’d like to add price below the attribute name. Sadly if I simply add the price to the attribute name it will displays in the same span so it’s very hard to stylize them separately (I’d like to change color of a price but not the name, for example).

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi @kyonv2,

    Could you show me any example?

    Thank You

    Thread Starter kyonv2

    (@kyonv2)

    I currently have 3 attributes as buttons:

    View post on imgur.com

    But what I want to achieve is:

    View post on imgur.com

    Which is basically adding a price of an attribute to the button itself so client can see it right away. I currently just put it into attribute name (Woocommerce > Attributes) the problem is that the price and the attribute name is in the same <span> so I cannot freely stylize them.

    <span class="variable-item-span variable-item-span-button">Small 99$</span>

    What I want to achieve is (of course very roughly):

    <span class="variable-item-span variable-item-span-button">Small</span></br>
    <span>99$</span>

    Maybe there’s a way for me to stylize them separately with JavaScript but I’m not very fluent in that. Any help is appreciated.

    Hopefully now I was clear enough. Thank you!

    • This reply was modified 6 years, 7 months ago by kyonv2.
    • This reply was modified 6 years, 7 months ago by kyonv2.
    • This reply was modified 6 years, 7 months ago by kyonv2.

    Hi @kyonv2,

    We’ve noted down your feature request. When the feature will be available. I’ll notify you.

    Thank You

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Add price to buttons’ is closed to new replies.