Home Forums WoodMart support forum How to remove “Select Options” on mobile

How to remove “Select Options” on mobile

Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #530101

    orders-9631
    Participant

    How to remove the “Select options” button below the images on mobile version?

    Attachments:
    You must be logged in to view attached files.
    #530164

    AlexWa
    Participant

    add this in your child theme function.php

    How to change Select Options -> eg. Chose Size

    add_filter( ‘woocommerce_product_add_to_cart_text’ , ‘custom_woocommerce_product_add_to_cart_text’ );
    function custom_woocommerce_product_add_to_cart_text() {
    global $product;

    $product_type = $product->product_type;

    switch ( $product_type ) {
    case ‘simple’:
    return __( ‘Add to cart’, ‘woocommerce’ );
    break;
    case ‘variable’:
    return __( ‘Chose Size’, ‘woocommerce’ );
    break;

    }

    }

    You can change ‘Chose Size’ to your own text.

    #530469

    Hung Pham
    Keymaster

    Hi orders-9631,

    Thanks for reaching to us.

    Did you try @AlexWa Custom Code? Please let me know.

    Regards,

    #530564

    AlexWa
    Participant

    I use this code in my theme. If I have a single product without variants, I display “Add to Cart.” If the product has variants, I display options such as “chose size”.

    #531007

    Hung Pham
    Keymaster

    Hi AlexWa,

    Thanks for your help.

    I will keep this topic opening till topic author confirms his situation.

    Regards,

    #541274

    orders-9631
    Participant

    Hello,

    Sorry, but I could not get it to work. I want to completely remove the text, not change it.

    Thanks!

    #541497

    Hung Pham
    Keymaster

    Hi orders-9631,

    Please add the following Custom CSS code to Theme Settings > Custom CSS > Custom CSS for mobile:

    .wd-product.wd-hover-standard .product-wrapper .wd-add-btn {
        display: none;
    }

    Regards,

    #574105

    martin-9344
    Participant

    Hello

    I have same issue but adding the css code does not work.

    Attachments:
    You must be logged in to view attached files.
    #574119

    Hung Pham
    Keymaster

    Hi martin-9344,

    Please submit your own topic and share me your url, then I can take a look and provide better support.

    Regards,

    #583066

    Mike
    Participant

    Hellp,
    Hide select options for mobile after update woocommerce.
    CSS
    .wd-product.wd-hover-alt .wd-add-btn>a{
    display:none !important
    }
    this was working for me without functions, only CSS.

    #583093

    Hung Pham
    Keymaster

    Hi Mike,

    Thanks for sharing solutions.

    Regards,

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