Home Forums WoodMart support forum how to remove “coupon code” from CART

how to remove “coupon code” from CART

Viewing 30 posts - 1 through 30 (of 34 total)
  • Author
    Posts
  • #541940

    kamilskawinski97
    Participant

    How can i remove the “coupon code” from the cart page?
    check image

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

    kamilskawinski97
    Participant

    i want to rmeove the entire thing .. together with the button “apply coupon”

    #541943

    kamilskawinski97
    Participant

    also, i wish to remove this:

    “Shipping options will be updated during checkout.
    Calculate shipping”


    because the shipping is free ALWAYS, in any case, so there is nothing to calculate. this might stop people from buying and abandon the cart

    thank you!

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

    Hello,

    Please add the below code to the functions.php file into the Child theme.

    add_filter( 'woocommerce_coupons_enabled', 'pk_disable_coupons_cart_page' );
     
    function pk_disable_coupons_cart_page() {
       if ( is_cart() ) return false;
       return true;
    }

    Navigate to WooCommerce > Settings > General“> “Shipping Location(s)“. Then select the “Disable shipping & shipping calculations” option. This will effectively remove the shipping address field from your checkout page.

    Best Regards

    #545520

    kamilskawinski97
    Participant

    as your reply does not match with my question:

    when i am at the CART page of the website, on the right side, where the shipping charges are, i can read this:
    “Shipping options will be updated during checkout.
    Calculate shipping”


    i want to delete this text: Shipping options will be updated during checkout.
    Calculate shipping

    because the shipping is free ALWAYS in this website, in any case, so there is nothing to calculate. this might stop people from buying and abandon the cart.

    since there is no shipping to calculate or taxes, i wish to compeltely remove it.

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

    Hello,

    Please try using the below Custom CSS code and paste it to Dashboard >> Theme Settings >> Custom CSS >> Global CSS section:

    .cart-totals-inner .woocommerce-shipping-destination,.cart-totals-inner .shipping-calculator-button {
     display: none;
    }

    Best Regards.

    #547142

    kamilskawinski97
    Participant

    hello i need to show the reviews with images first. how can i do that? i see that there is the “filter option” but i dont want the customer to use that. i want it to be automatically showed first.
    please advise.

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

    Hello,

    Navigate to Theme Settings > Single Product > reviews and check the available option about product reviews.
    Please check this manual:
    https://xtemos.com/docs-topic/product-reviews/

    Best Regards.

    #547508

    kamilskawinski97
    Participant

    thank you for the reply. but is not helping me i guess.

    i already went to the settings reviews. what i need to do it:
    to show the reviews with images first. how can i do that? i see that there is the “filter option” but i dont want the customer to use that. i want it to be automatically showed first. this has to be done automatically when you visit the page.

    #547613

    Hello,

    You need to click on the “only with images” option to see the images related to reviews. Sorry there are no options in theme settings to show them in the top of the section. You need to find a plugin for this purpose that best suits your needs. We have not tested any plugin in this regard.
    https://ibb.co/pL3PMWz

    Best Regards.

    #548628

    kamilskawinski97
    Participant

    how can i remove the button “view cart” and only leave the button “checkout” please?

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

    Hello,

    Please add this code to the Theme Settings > Custom CSS > Global:

    body .woocommerce-mini-cart__buttons .btn-cart {
    display:none;
    }

    Best Regards

    #548775

    kamilskawinski97
    Participant

    amazing thank you

    how can i put the “you have (percentage) and euros” in the price space in the product page please?

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

    Hello,

    Try to add the following PHP code in the function.php of the child theme.

    add_filter( 'woocommerce_get_price_html',     'change_displayed_sale_price_html', 10, 2 );
    function change_displayed_sale_price_html( $price, $product ) {
         // Only on sale products on frontend and excluding min/max price on variable products
        if( $product->is_on_sale() && ! is_admin() && ! $product->is_type('variable')){
             // Get product prices
             $regular_price = (float) $product->get_regular_price(); // Regular price
             $sale_price = (float) $product->get_price(); // Active price (the "Sale price" when on-sale)
    
             // "Saving Percentage" calculation and formatting
             $precision = 1; // Max number of decimals
             $saving_percentage = round( 100 - ( $sale_price / $regular_price * 100 ), 1 ) . '%';
    
             // Append to the formated html price
             $price .= sprintf( __('<p class="saved-sale">You Save: %s</p>', 'woocommerce' ), $saving_percentage );
        }
        return $price;
    }

    Best Regards.

    #548889

    kamilskawinski97
    Participant

    omg you are great!

    it’s totally working!

    one thing: can i change the color? and, can you also display the “amount of money saved”, besides the percentage?

    so it would be like:
    €129.90 – €99.90
    You Save: 23.1% (euro symbol 30.2)

    please, master

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

    Hello,

    Please add this code to the Theme Settings > Custom CSS > Global:

    p.saved-sale {
        color: #005efb
    }

    Please remove the previous code and add this new code.

    add_filter( 'woocommerce_get_price_html', 'change_displayed_sale_price_html', 10, 2 );
    function change_displayed_sale_price_html( $price, $product ) {
         // Only on sale products on frontend and excluding min/max price on variable products
        if( $product->is_on_sale() && ! is_admin() && ! $product->is_type('variable')){
             // Get product prices
             $regular_price = (float) $product->get_regular_price(); // Regular price
             $sale_price = (float) $product->get_price(); // Active price (the "Sale price" when on-sale)
    
             // Calculate the saving percentage
             $saving_percentage = round( 100 - ( $sale_price / $regular_price * 100 ), 1 );
             
             // Calculate the amount of money saved
             $amount_saved = $regular_price - $sale_price;
             
             // Format the saving percentage and amount saved
             $saving_percentage_text = sprintf( __('%.1f%%', 'woocommerce'), $saving_percentage );
             $amount_saved_text = wc_price( $amount_saved );
    
             // Append to the formatted HTML price
             $price .= sprintf( __('<p class="saved-sale">You Save: %s (%s)</p>', 'woocommerce' ), $saving_percentage_text, $amount_saved_text );
        }
        return $price;
    }

    Best Regards.

    #551853

    kamilskawinski97
    Participant

    How can I change the size of this?
    As it is too big (the money saved part)
    thank you

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

    Hello,

    Please add this code to the Theme Settings > Custom CSS > Global:

    .wd-rs-65f0c09de564f .amount, .wd-rs-65f0c09de564f .price, .wd-rs-65f0c09de564f  {
       font-size: 20px;
    }

    Best Regards.

    #552435

    kamilskawinski97
    Participant

    hello, it is still the same, after insering the code three days ago – could you please advise?

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

    Hello,

    Please add this code to the Theme Settings > Custom CSS > Global and check the issue after completely clearing the browser cache.

    .wd-rs-65f0c09de564f .amount, .wd-rs-65f0c09de564f .price, .wd-rs-65f0c09de564f  {
       font-size: 10px !important;
    }

    Best Regards.

    #552895

    kamilskawinski97
    Participant

    it is now changing, but the problem is now that the price also changed
    please check picture attached

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

    Hello,

    You want to change the font size of price only with the euro currency price which is in brackets?

    Best Regards.

    #553970

    kamilskawinski97
    Participant

    yes exactly. i want to chage the part in brakets ( ).
    i want the price of 119.90 to be as it is right now in the picture.

    and i want that the price of euro 30 in between brakets, is the same as the part that sayins: You Save: 20.0% (€30)

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

    Hello,

    You are using the php code for this. To change the font size of only the amount saved (€10.00) within the curly braces, you can modify the PHP code to wrap it with a tag and apply a CSS class specifically to that span.

    Here’s how you can do it:

    add_filter( 'woocommerce_get_price_html', 'change_displayed_sale_price_html', 10, 2 );
    function change_displayed_sale_price_html( $price, $product ) {
        // Only on sale products on frontend and excluding min/max price on variable products
        if( $product->is_on_sale() && ! is_admin() && ! $product->is_type('variable')){
            // Get product prices
            $regular_price = (float) $product->get_regular_price(); // Regular price
            $sale_price = (float) $product->get_price(); // Active price (the "Sale price" when on-sale)
    
            // Calculate the saving percentage
            $saving_percentage = round( 100 - ( $sale_price / $regular_price * 100 ), 1 );
    
            // Calculate the amount of money saved
            $amount_saved = $regular_price - $sale_price;
    
            // Format the saving percentage and amount saved
            $saving_percentage_text = sprintf( __('%.1f%%', 'woocommerce'), $saving_percentage );
            $amount_saved_text = wc_price( $amount_saved );
    
            // Append to the formatted HTML price
            $price .= sprintf( __('<p class="saved-sale">You Save: %s (<span class="amount2">%s</span>)</p>', 'woocommerce' ), $saving_percentage_text, $amount_saved_text );
        }
        return $price;
    }

    After that add this custom css code in Theme Settings > Custom CSS:

    .amount2 {
        font-size: 20px; 
      }

    Best Regards.

    #554286

    kamilskawinski97
    Participant

    i changed the php code and css but nothing – it is the same as it was.. can you please suggest?

    #554454

    Hello,

    Can you please share the WP admin login details of your site so I will check and give you the possible solution.

    Best Regards.

    #555308

    kamilskawinski97
    Participant

    please check the admin log in – please check the image – the one with the number 50 €, i would like to make it smaller, preferably the same size of where it says: You Save: 27.8% (€50.00)

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

    Hello,

    Your issue has been resolved. I have added the following PHP code in the function.php of the child theme.

    add_filter( 'woocommerce_get_price_html', 'change_displayed_sale_price_html', 10, 2 );
    function change_displayed_sale_price_html( $price, $product ) {
        // Only on sale products on frontend and excluding min/max price on variable products
        if( $product->is_on_sale() && ! is_admin() && ! $product->is_type('variable')){
            // Get product prices
            $regular_price = (float) $product->get_regular_price(); // Regular price
            $sale_price = (float) $product->get_price(); // Active price (the "Sale price" when on-sale)
            // Calculate the saving percentage
            $saving_percentage = round( 100 - ( $sale_price / $regular_price * 100 ), 1 );
            // Calculate the amount of money saved
            $amount_saved = $regular_price - $sale_price;
            // Format the saving percentage and amount saved
            $saving_percentage_text = sprintf( __('%.1f%%', 'woocommerce'), $saving_percentage );
            $amount_saved_text = wc_price( $amount_saved );
            // Append to the formatted HTML price
            $price .= sprintf( __('<p class="saved-sale">You Save: %s (<span class="saveprice">%s</span>)</p>', 'woocommerce' ), $saving_percentage_text, $amount_saved_text );
        }
        return $price;
    }

    Also, I have added the below custom CSS code in the theme settings >> Custom CSS >> Global CSS section:

    span.saveprice span.woocommerce-Price-amount.amount bdi {
        font-size: 15px;
    }

    Best Regards.

    #555527

    kamilskawinski97
    Participant

    im seeing a small problem – when adding a new product, the “savings price in €” doesnt show up.

    please check picture n.1
    there is a product discount, but it doesnt show.

    please check picture n.2
    there is a discount, and it shows, with the savings in green color.

    could you help please sir?

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

    Hello,

    Please deactivate all the 3rd party plugins and activate only theme-required plugins on the site and then check the issue. I am sure your issue will be solved. Then Activate the 3rd party plugins one by one and check which plugin is creating the issue for you.

    Otherwise, if the issue still exists then keep the 3rd party plugins deactivated and let me know I will further check on your site and give you a possible solution.

    Best Regards.

Viewing 30 posts - 1 through 30 (of 34 total)