samnait
Forum Replies Created
-
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expireFLAWLESS! It worked! Thank you, Thank you.
It gave me another 24 hours after it expired where before it would not let you reorder when it expired.
So just to recap. And I think someone would find this plugin very useful.
1. it clears all the sessions in the cart that has been abandoned.
2. it will do it daily at a specified time you set and hide notification if you chose.
3. combined with the link that I found on GitHub, it will identify which category you want this applied to so not all products will expire.
4. It’s automated.
I have searched everywhere and nobody has this not even close. They can only hide or expire products but it will not clear the carts in a certain category specified and put back in inventory with or without variables.
On your next update for this should be implemented.Thanks again James
====
add_filter(‘wc_csr_expire_time’, ‘jmg_expire_time’, 10, 5);
function jmg_expire_time( $time, $expire_time_text, $item, $key, $csr) {
$now = time();
if ($now > strtotime(’22:45:00′)) {
$time = strtotime(‘tomorrow 22:45:00′);
} else {
$time = strtotime(’22:45:00’);
}
return $time;}
- This reply was modified 5 years, 10 months ago by samnait.
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expireThank you for taking the time to do this. I will test right away and get back to you!
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expirehmm I worked on this for 4 hours and can’t get it at all.
If you find a solution let me know. I’ll keep checking back.Thanks anyways.
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expireOkay found it and that did the trick.
I don’t get the logic on the time to expire settings though.
So this time…
it is 12:50 PM system time so I set the backend as 23:00:00
It says you have 3 hours and 9 minutes and sec.
based on this sample do you know what the calculations be to have it expire at 11 pm?
(what I would set the settings to have it expire at 11pm instead of 23:00:00)?Thanks again
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expireWow thank you so much! It worked ??
One last thing, because I already have a custom notification that says “if you don’t check out before 11 pm, you will lose the items in your cart”
How would I remove
Please check out within… time count down?
Thanks again.Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] selected date and time to expirehmmm I guess I’m a bit confused. How would I do this?
I wanted to modify the one that you have now. where and how I would edit this?
So just to be clear.
If customer A added an item in the cart at 10:20pm
And customer B added an item in the cart at 10:30pm
Both customers will have no items in their cart at 11pm because it will be put back in the inventory.
And wanted this to happen every day to trigger at 11pmThanks a bunch.
Forum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] Product CategoryThis was accomplished by doing this solution.
https://stackoverflow.com/questions/54033207/hide-remove-item-from-cart-for-woocommerce-product-categoryForum: Plugins
In reply to: [WooCommerce Cart Stock Reducer] Product CategoryThanks for replying ??
It would be awesome to have to trigger only the ones with a certain category setup for a product.
The reason for this is because if you only wanted to have “specials” category to be timed then it gets released from your cart if not purchased within a certain time.
If you could help in what to change in the code that would be great. If it could be placed in a child theme as a function would be awesome.