When using base shipping only and putting 0.001 in shipping in the shortcode, the cart shows the right values but in Stripe the decimal point is lost so £25.20 shipping becomes £2520.
Also if you have more than ten items in the cart that 0.001 gets added up and a magic penny appears in the total too. Maybe 0.0001 will work also though it’s the £2500 shipping that’s the big problem, makes the plugin unusable.
Latest WP (6.3), latest plugin version (installed today) as of this post’s date
Thank you pointing this out. This is an issue with the newly address Stripe checkout option. We have updated the plugin to apply a fix for this. Please update the plugin when you can.
Just going to check it now, the 0.001 adding up over 10 items also seems sorted, which is great, too. It’s nice to use a plugin with a responsive dev for a change!
It would be nice to be able to turn off the Paypal button – I’ve used a display:none CSS hack to hide it but I only want to use Stripe as it’s half the fees of Paypal so I don’t offer the option to customers.
Really useful plugin, though, near-perfect for providing custom ordering pages for individual customers instead of having to wrangle a whole shop system like Woocommerce.
Actually after updating, base shipping cost of 25.20 comes out incorrectly in Stripe as 2.52. Will try it again
In a kludge I’d put into wp_shopping_cart.php before you updated the plugin I’d forced the total shipping to 2 decimals using sprintf which worked for me. Stripe seemed to have an issue with values that didn’t have precisely 2 decimal places, as if it expected a string. Giving it a float e.g. 25.2 seems to mess it up compare to ‘25.20’
It would be nice to be able to turn off the Paypal button – I’ve used a display:none CSS hack to hide it but I only want to use Stripe as it’s half the fees of Paypal so I don’t offer the option to customers.
Did you enable the following option ‘Disable Standard PayPal Checkout’ located under General Settings tab?
In regards to your other comments, I am not sure what you mean? Can you clarify what the issue is. I want to make sure I understand your issue correctly.
I hadn’t tried the ‘disable paypal’ option as it didn’t mention stripe until now, will try that.
Now, the Stripe shipping calculation. It seems as if stripe takes the string of the shipping value, strips all non \d characters from it and then treats the result of that as pennies. So 25.20 rounded to 20 decimal place becomes a float of 25.2 – Stripes takes 25.2, seems to turn it into 252 and then forces that to two decimal place giving 2.52. Similarly previously when using 0.001 shipping value in the shortcode (in the previous version) the shipping would be 25.2001 which Stripe seemed to convert to 252001 and then add £2520.01 as the shipping value. It’s very weird but I guess it’s how their validation has been built.
Hopefully this screenshot video helps to explain the current £2.52 problem.
Thank you for the details. I have updated the plugin to address this. The updated version will be able to handle the condition that you were using with the Stripe gateway.