1

I want to hide or remove the Shipping Method from cart page.
The reason to hide is we are giving free delivery on order above 15 pound. but since magento save the users shipping method in session it show the shipping and handling charge as 3 pound even though the order amount is greater than 15 pound (should be Free delivery).

Or way to unset shipping method from session.

Please refer the image.

Remove shipping from Cart

3

Unset current shipping method

$quote = Mage::helper('checkout/cart')->getCart()->getQuote();
$shippingMethod = $quote->getShippingAddress()->getShippingMethod();
if($shippingMethod){
    $quote->getShippingAddress()->setShippingMethod(null);  //setting method to null
    $quote->save(); 
}
2

Second option is best .

Unset current shipping method using below code at Cart page:

if($shippingMethod=Mage::getSingleton('checkout/session')->getQuote()->getShippingAddress()
            ->getShippingMethod()){
Mage::getSingleton('checkout/session')->getQuote()->getShippingAddress()
            ->unsetShippingMethod($shippingMethod);
}
  • i have applied the code in /template/checkout/cart.phtml but shipping still shows up. – Arun Karnawat Dec 18 '15 at 10:01
  • thank you @amit-bera for pointing me to right direction. I have got the solution that worked for me. – Arun Karnawat Dec 18 '15 at 12:22
1

Login to adminpanel,

admin > system > configuration > sales > shipping methods > select your desire method here and put enabled as Yes. And remaining all select enable as No.

  • thanks for your answer but this is not what i want as i have 3 method Free( for 15 pound+) Flat rate(for < 15 pound) and Next Day delivery(optional). and i want free/Flat rate(any one depending on order amount) and Next day delivery together. – Arun Karnawat Dec 18 '15 at 8:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.