CaptainMorgan
Forum Replies Created
-
Autoptimize doesn’t include page caching from what I understand reading the plugin page.
I just realised I hadn’t linked to the github issue here. On further reading of that issue it looks like the solution can’t be implemented on the caching plugin side until this issue with the WooPayments plugin is resolved – https://github.com/Automattic/woocommerce-payments/issues/8130#issuecomment-2085975611
I haven’t looked at any in particular, I was just wondering if it was designed to work with others, that might get me around the caching issue.
Does WooPayments multi-currency work with other currency selector plugins?
Actually maybe that can be done on the caching plugin side… I’ll talk to the Breeze people and see what they say about it.
I think it’s a core plugin issue, your plugin does not work with any page caching plugins and this affects all of your users. If it’s not a core plugin issue then you are saying there is an issue with every caching plugin…
As we agreed above the only real solution is to have separate cache files for each currency and this can only be done on the WooPayments side, I don’t see how a third-party could implement this.
- This reply was modified 1 year, 4 months ago by CaptainMorgan.
Why has this been marked as resolved?
I don’t think a custom solution solves the problem. I might be able to get a solution that works with one particular caching plugin on my site. But this problem affects every single user of the multi-currency feature and needs to be fixed at the source, you can’t expect everyone to commission a one-off custom solution for their website. I find it very strange that you would create a system that doesn’t work with page caching from the start.WP Rocket states in their documentation that they don’t support fragment caching. They also list the multi-currency plugins they support – WooPayments isn’t in the list. They also say
> In order for currency switching to be compatible with page caching, it must rely on either AJAX (JavaScript) or set a cookie (that can be used either to exclude the page(s) from caching, or to programmatically create different cache files based on the value of that cookie).
So it looks like the solution suggested in the github issue, separate cache files for each currency is the only practical solution.
The people behind the Breeze cache plugin attempted an ajax based solution when I reported the issue to them. There were two problems though, it was really slow to update the currency between pages and of course it completely fails for any users who have Javascript disabled (not many, but they exist).Hi,
Can you tell me of any page caching plugin that allows me to exclude the parts of WooPayments multi-currency?For the custom code you have both mentioned, this would need to be part of the WooPayments plugin, right?
Hi,
Yes I opened a ticket with WooCommerce.com. The dynamic caching would have to be part of the WooPayments plugin, no?- This reply was modified 1 year, 4 months ago by CaptainMorgan.
Thanks for getting back to me.
This is what WooCommerce support suggested also. As I explained to them, the currency is shown on every page (mini cart in the header, I’m using the Storefront theme) so I can’t just exclude a page or two. Since WooPayments tracks the currency via a cookie I have to exclude the cookie, and all the page caching plugins I’ve tried will disable page caching for pages that has an excluded cookie – so in this case they essentially disable page caching entirely.
I am not aware of a page caching plugin that will allow me to exclude specific elements on a page – can you tell me of one?
WooCommerce support suggested some kind of dynamic caching and sent me a link to this page – https://github.com/Automattic/wp-super-cache/wiki/How-do-I-not-cache-part-of-my-page%3F – which as you will see from the first paragraph is information for plugin developers and not much use to me.
Have you tested the multi-currency selector with any page caching plugins and found it to work?Forum: Plugins
In reply to: [LiteSpeed Cache] WooPayments Multi-Currency Caching supportSounds like the problem we solved a while back – https://ww.wp.xz.cn/support/topic/woopayments-multi-currency-caching-support/
Forum: Plugins
In reply to: [WooCommerce] How to view order total in Taxes report?To clarify, are you referring to tax rates when mentioning “Tax Code”?
Yes that’s what I meant.
WooCommerce doesn’t currently show taxable amounts per tax rate in its reports, but you could use custom code or third-party plugins to achieve this.
This is what I’m doing currently, but since the data is already in WooCommerce it would be nice to see it in the taxes table. After all this is what needs to be reported to VAT/VAT MOSS, the actual amount of tax isn’t really very useful.
Forum: Plugins
In reply to: [LiteSpeed Cache] WooPayments Multi-Currency Caching supportThe log doesn’t give much
2024-07-19 22:49:51.211886 [NOTICE] [1975174] [server ip:HTTP2-1#librewave.com] oops! 503 Service Unavailable
2024-07-19 22:49:51.211909 [INFO] [1975174] [server ip:HTTP2-1] Content len: 0, request line: ‘GET /?currency=USD HTTP/1.1’
I’m using this line to test: curl -v –http2 “https://librewave.com/?currency=INR
If I remove this from the htaccess then the 503 goes away: RewriteRule .* – [CO=multi_currency:%1:;] but so does the caching functionality.
I’ve tried disabling the cache entirely, I also disabled my modsecurity rules just in case, those didn’t make a difference. I also tried setting the cookie via php in functions.php but no luck either.- This reply was modified 1 year, 10 months ago by CaptainMorgan.
- This reply was modified 1 year, 10 months ago by CaptainMorgan.
- This reply was modified 1 year, 10 months ago by CaptainMorgan.
Forum: Plugins
In reply to: [LiteSpeed Cache] WooPayments Multi-Currency Caching support@qtwrk Ok it’s working, except when first changing currency it triggers a 503 error, removing the htaccess block resolves the problem. This can be easily triggered by loading the site in a private browser session.