I want my user to see what he added to his cart after redirecting from paypal, if his/her paypal payment gets failed or user by himself abort/cancel transaction(may be intentionally or by mistake). I want to preserve the state of cart for user.

Right now drupal commerce clears user's cart if payment gets failed. Please help.

  • Check the rules. Most things commerce does are customisable through the rules UI. – Felix Eve Apr 23 '15 at 6:06
  • Thanks! @FelixEve for your quick reply, I will look at it. – echo Apr 23 '15 at 6:14

Following solution worked for me

function custom_module_commerce_checkout_page_info_alter(&$checkout_pages) {
  $checkout_pages['payment']['status_cart'] = TRUE;

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.