Search code examples
productcartvirtuemart

virtuemart - can't update or delete product in cart


Question: when I try to update the amount of a product in the shopping cart, I click the 'update' button and the page goes to the url.com/index.php, it shows the base of the homepage, but not with all the modules; just the core(background, footer).

If I click 'back' on the browser and return to the shopping cart, it updated the shopping cart, so that is working fine. I don't know how to make the click for updating/deleting a product in the cart to not go to weburl.com/index.php but rather stay in the cart. I believe it has something to do with some php variable or so.


Solution

  • Go to administrator/components/com_virtuemart/html/basket.php

    Change this:

    $action_url = $mm_action_url.basename($_SERVER['PHP_SELF']);
    

    For this:

    $action_url = 'index.php?page=shop.cart&option=com_virtuemart&Itemid='.$sess->getShopItemid();
    

    Problem fixed.