thepw Posted June 15, 2007 Share Posted June 15, 2007 Hi there, I hope somebody can help me on this doozy! How do I set OScommerce to dump the cart when a customer exits the website. We do not require this feature Many thanks Link to comment Share on other sites More sharing options...
Guest Posted June 15, 2007 Share Posted June 15, 2007 you have no way of knowing when a logged-in customer closes his browser. But you can take advantage of the sessions expiry and via a cron-job or a spider visit you could clear the customers carts if their session expired or with a time difference from the customers_basket_date_added field. Link to comment Share on other sites More sharing options...
thepw Posted June 15, 2007 Author Share Posted June 15, 2007 Ok that sounds good, but is there not a way just to disable the storing of a cart? If not ... how would I go about setting up that Cron Job? Link to comment Share on other sites More sharing options...
Guest Posted June 15, 2007 Share Posted June 15, 2007 yes, if you want to disable it totally, edit your catalog\includes\classes\shopping_cart.php. You need to modify the restore_contents function so it will not update the TABLE_CUSTOMER_BASKET (2 tables one is for attributes). Then in add_cart function same file you need to remove the code that stores the products into the these 2 tables. If you have other modules that rely on these tables you may need to customize those too. In this case you shouldn't need anything else, like a cron job as you never store this info. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.