Home Forums Basel support forum Quantity select field

Quantity select field

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #87755

    ALGO
    Participant

    Hello,

    I have the same issue as lelikletter, after added “override-loop-template-and-show-quantities-next-to-add-to-cart-button” code, the choice of the number appears, but the product is not added to cart and when I select ‘+’ or ‘-‘, the quantity order increase of 2 steps, for exemple, I have ‘1’ on quantity order and if I click on ‘+’, I have ‘3’ on quantity order.

    How can I correct that ?

    Thank you in advance.

    Have a good day !

    Benoît

    PS : my website is not yet online.

    #87781

    Artem Temos
    Keymaster

    Hi,

    Please, describe to us your problems in a bit more details. Attach some screenshots and provide us with a list of steps on how to reproduce it on your website. Unfortunately, we are not able to check it while your website is not online yet.

    Thank you in advance.

    #87818

    ALGO
    Participant

    Hi,

    As I said before, I added the following code “override-loop-template-and-show-quantities-next-to-add-to-cart-button”.
    After that, I have the quentity order next to add-to-cart button like that (img_001)img_001.
    It is ok for me, but when I want to add a product, for exemple my product “INO Essentiel”, I want 2 quantities of this product, I can’t, I have automaticly 3 quantities (img_002)img_002 and if I add another time a product, it steps from 3 to 5, …
    It is the same thing with all products.
    After when I click on add-to-cart button, the cart window on the right appears (img_003)img_003 but the number of product currently on card doesn’t change.

    If necessary I can send you editor account to see directly.

    Thank you in advance.

    Benoît

    #87832

    Artem Temos
    Keymaster

    Please, send us at least your admin access.

    #87847

    ALGO
    Participant

    My admin access in private

    #87855

    Artem Temos
    Keymaster

    Where exactly have you added this code? You need to place it to the child theme only. Be sure that the parent theme doesn’t have any code modification.

    #87967

    ALGO
    Participant

    Hi,

    I added the code on function.php on Basel theme but not the child theme.
    I created few hours ago a child theme and added this code but nothing work yet, there is no quantity select field.

    I don’t understand.

    Thank you in advance for your help.

    #87983

    Artem Temos
    Keymaster

    You should activate the child theme in Appearance -> Themes to make it work https://gyazo.com/b0077a129b29c66531269cbe7d36ff4f

    #87990

    ALGO
    Participant

    Hi,

    I activate the Child theme, know I have the add-to-cart button and the quantity select field but it still doesn’t work as I said before.
    There is an incrementation of 2 steps and it doesn’t work when I add something on the cart.
    Nothing has changed.

    Thank you

    #88001

    Artem Temos
    Keymaster

    Try to disable all external plugins that are not related to our theme first.

    #88090

    ALGO
    Participant

    Hi,

    I disabled plugin by plugin and I find a plugin which added a step, it was the ‘WooCommerce Quantity Increment’ plugin.
    So now it’s ok for the incrementation but there is always an issue to add to cart, it doesn’t work.

    Thank you

    #88091

    Artem Temos
    Keymaster

    Try to replace this line

    
    		$html .= '<button type="submit" class="button alt">' . esc_html( $product->add_to_cart_text() ) . '</button>';

    with this one

    
    		$html .= '<button type="submit" value="' . $product->get_id() . '" class="button alt">' . esc_html( $product->add_to_cart_text() ) . '</button>';
    #88453

    ALGO
    Participant

    Hi,

    It works !
    Thank you very much !

    Have a nice day !

    Benoît

    #88454

    Artem Temos
    Keymaster

    Great, you are welcome!

Viewing 14 posts - 1 through 14 (of 14 total)

The topic ‘Quantity select field’ is closed to new replies.