Add text to single product quantity form

This topic has 9 replies, 3 voices, and was last updated 2 months, 4 weeks ago ago by Andrew Mitchell

  • Avatar: Applesandcider
    Applesandcider
    Participant
    July 8, 2024 at 09:20

    Hi,

    I am currently following the steps that you provided for another client in this ticket – https://www.8theme.com/topic/add-text-to-single-product-quantity-form/

    I would like the same thing except I’d like the “Test Text” to be on the left of the quantity field and the button to be below, not on the right of the quantity field.

    However regardless of my slight change, I have tried testing out the code you provided to the other client (see attachment) and the text does not appear next to the quantity field.

    I will be wanting the same thing as the previous client where the text changes depending on what category product is being viewed on the single product page. I believe I will be able to do that just fine, but please check out why the code isn’t working for me?

    Thanks!

    Please, contact administrator
    for this information.
    Files is visible for topic creator and
    support staff only.
    8 Answers
    Avatar: Justin
    Luca Rossi
    Support staff
    July 8, 2024 at 12:01

    Hi @Applesandcider,

    Please try adding this custom CSS under XStore > Theme Options > Theme Custom CSS > Global CSS:

    
    .elementor-widget-etheme_wc_add_to_cart .etheme-wc-add-to-cart-wrapper .quantity::after {
        content: 'Your Custom Text';
        margin-left: 10px;
    }
    .elementor-widget-etheme_wc_add_to_cart .etheme-wc-add-to-cart-wrapper .single_add_to_cart_button {
        margin-top: 15px !important;
    }
    

    Hope it helps!

    Avatar: Applesandcider
    Applesandcider
    Participant
    July 8, 2024 at 12:41

    Hi Luca so that worked great thanks.

    What I want to do is add the same thing to other single product pages that have different categories, where the “Your Custom Text” section will be different.

    Your colleague said in the previous ticket…

    Upon reviewing the screenshots you provided, it is evident that the code has been added globally to the site settings, which is why it is affecting all products. The correct approach would be to apply the code specifically to a certain template. Please refer to the following link for guidance: https://prnt.sc/5a6slg-IrnKO

    So if I want to add different “Your Custom Text” to other single product pages that have different categories, should I have added the code to the global CSS section or do I need to add it on a template level?

    Thanks

    Avatar: Applesandcider
    Applesandcider
    Participant
    July 8, 2024 at 13:24

    Hi Luca,

    Okay I have figured out how to make it work, please ignore the above comments..

    However, please see attached and take a look at my header section.

    I have no idea how I did this when I was trying to make the single product tempaltes, any chance you know how to change it back?

    Thanks

    Files is visible for topic creator and
    support staff only.
    Avatar: Justin
    Luca Rossi
    Support staff
    July 8, 2024 at 14:31

    Hi @Applesandcider,

    When you added this custom CSS code:

    
    body .etheme-product-grid-bordered:not(.type-slider)>div {
        -webkit-border-start: 1px solid #e1e1e1 !important;
        border-inline-start: 1px solid #e1e1e1 !important;
    }

    You forgot to add the closed bracket(}). We’ve already fixed it for you.

    Please check now.

    Thank you!

    Avatar: Applesandcider
    Applesandcider
    Participant
    July 8, 2024 at 14:58

    Thank you so much Luca.

    Last question relating to all of this…

    First off, I realise that what I’m about to ask would be better suited for some sort of booking plugin but I just want to make sure there is no way to do it with just your theme and woocommerce…

    Please see attachment. There are some products that are to be sold at different prices, based on the age of the people who are using the product. For example adult prices will be different to child prices.

    I would like another quantity box for child prices but only one add to cart button. So the user can add 1 “product” as an adult and 1 “product” as a child and once you press add to cart, then both prices are added together which can be seen in the cart and checkout section.

    Do let me know if that’s possible at all.

    Thanks!

    Is this possible with the theme if I use the variable product option?

    Files is visible for topic creator and
    support staff only.
    Avatar: Justin
    Luca Rossi
    Support staff
    July 8, 2024 at 15:02

    Hi @Applesandcider,

    It’s not possible in our XStore & WooCommerce by default.

    You can try with the 3rd party plugins:

    https://woocommerce.com/products/woocommerce-bookings/
    https://wordpress.org/plugins/mwb-bookings-for-woocommerce/

    Please also note that the issue related to the 3rd party plugins must be directed to the plugin’s author, they fall out of scope our support standard.

    Thanks for understanding!

    Best regards,
    The 8Theme Team

    Avatar: Applesandcider
    Applesandcider
    Participant
    July 8, 2024 at 15:06

    Thanks so much for your excellent responses and quickness!

    Avatar: Andrew Mitchell
    Andrew Mitchell
    Support staff
    July 8, 2024 at 15:06

    Dear Applesandcider,

    As we continue our mission to exceed expectations, your insights become increasingly valuable. Could we, with all due respect, request your thoughtful feedback by giving our theme a deserved 5-star rating on ThemeForest?

    Click here to share your valuable perspective: https://themeforest.net/downloads

    Your time and trust are highly appreciated!

    Best Regards,
    The 8Theme Team

  • Viewing 9 results - 1 through 9 (of 9 total)

The issue related to '‘Add text to single product quantity form’' has been successfully resolved, and the topic is now closed for further responses

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.