Clean Woocommerce cart when closing the browser

1

I would like that when closing the browser I could clean the shopping cart, that the products entered can be cleaned. I managed to do it when you reach the index, but I require it to be when closing the browser.

    
asked by Walworth Industrial de Vlvulas 30.03.2018 в 23:52
source

1 answer

0

And have you tried using this fragment in your index?:

<? php
session_start();
unset($_SESSION["session"]);

It is about destroying the previous session when re-entering the page, after having closed it.

Useful links:

Based on the response of kpp in English: link

    
answered by 02.07.2018 в 12:51