Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › WP Super Cache problem
- This topic has 7 replies, 4 voices, and was last updated 9 years, 8 months ago by wzp.
-
AuthorPosts
-
March 2, 2012 at 1:34 pm #5728wordpressdesignMember
Hi, I have installed WP Super Cache using the preload mode and following the instructions here https://support.tipsandtricks-hq.com/forums/topic/using-the-plugins-together-with-wp-super-cache-plugin (that is, adding a few lines of code) but NOT following the instructions here http://www.tipsandtricks-hq.com/ecommerce/wp-shopping-cart-and-wp-super-cache-workaround-334
(that is, excluding shopping cart pages from the cache because that would defeat the purpose since all my pages have a shopping cart, plus, items get added nicely to the cart, no problems here).
However, the problem is that each product I sell has a counter, for example product-A 3 available. If a visitor makes the purchase the counter still says 3 available, it doesn’t go down to 2 (until, I guess, the next refresh). I don’t care when the quantity is >1, but when it’s 1, it doesn’t go to sold out and some visitors coming at around the same time have purchased the sold out item – which is a disaster for me because I have to refund etc.
Is there any way to fix this??
March 3, 2012 at 12:46 am #42597adminKeymasterYou can’t checkout an item with a quantity that is not available. When you go to add an item with a quantity or try to change the quantity in the cart it will check the database and make sure the requested quantity exists (Doesn’t matter if it is showing a cached version of the page which is showing an incorrect available quantity amount in the product display). Please post a link to your product page so I can go and check it. What version of eStore are you using?
March 3, 2012 at 1:28 pm #42598wordpressdesignMemberYou are correct, but, it happened to me once that two different customers bought the same item at the same time, must have been a coincidence. Now I have tested the page myself and even if it says Qty available 1, as you said you can’t check out.
The cache plugin serves the cached page that shows Qty 1 even though the quantity is zero. When they add the item to the cart eStore returns an error and says Not Available, which is good. If there was the possibility to show Sold Out rather than an error that would be fantastic. I am running v6.3.7 at ahead-hosting.com.
March 3, 2012 at 8:45 pm #42599wordpressdesignMemberAs you can see the screenshot here http://ahead-hosting.com/Screenshot-4.jpg
same webpage, after one sale.
On the left how visitors see it (cached), it shows 12 items available. On the right, how I see it (logged in, uncached), shows 11 items available, which is the actual inventory.
March 3, 2012 at 11:27 pm #42600adminKeymasterThe problem is that you are showing a cached page to your user which has dynamic content in it and you are wanting it to be dynamic. eStore can only prevent the user from purchasing out of stock items. You can’t show a cached version of the dynamic section of the web page and expect it to update dynamically. If I remember correctly, WP Super Cache has tags that you can use to place content inside it which will make it so that content doesn’t get cached. It will always dynamically render the content inside those tags. You can use that option and place your available quantity counter inside it so that section is always generated dynamically.
March 3, 2012 at 11:59 pm #42601wordpressdesignMemberCool idea thanks – the dev says something about tags in the plugin description
http://wordpress.org/extend/plugins/wp-super-cache/faq/
but he also says
“you can use a WP Super Cache tag to do the job, but you can’t use mod_rewrite mode caching. You have to switch to PHP or legacy caching.”
so no good for me.
Many others discuss the same problem
http://wordpress.org/support/topic/plugin-wp-super-cache-how-to-keep-shopping-cart-dynamic
http://wordpress.org/support/topic/plugin-wp-super-cache-exclude-specific-website-elements-possible
http://omninoggin.com/wordpress-posts/make-any-plugin-work-with-wp-super-cache/
but answers all look inconclusive and unfortunately quite above my head. Will keep searching and bookmark this thread in case a solution pops up.
March 3, 2015 at 3:11 pm #42602kennethMemberI have just uploaded the WP eStore plugin to my WordPress site and getting a notice stating to make sure we follow directions and that’s why I am here to inquire to what those directions are.
Thanks,
From: Kenneth
March 3, 2015 at 3:15 pm #42603wzpModeratorDirections for “What?” Since you posted in the WP Super Cache thread, I’m guessing you are inquiring about these directions?
-
AuthorPosts
- You must be logged in to reply to this topic.