Thread Starter
Robin
(@robin-ho)
You can do this by adding: pattern=”\d*” to the input field.
https://i.imgur.com/DaYKLqq.png
There may be a better way, but this seems to work for me tested on iOS.
Could you please integrate this into your next update?
-
This reply was modified 3 years, 5 months ago by
Robin.
-
This reply was modified 3 years, 5 months ago by
Robin.
-
This reply was modified 3 years, 5 months ago by
Robin.
Hi @robin-ho,
Sorry for a late reply and thank you for the suggested solution. Will be adding this in next update.
Hi @robin-ho,
As promised I’ve released new plugin version 1.2.5 today. There I’ve added new Input pattern option to the plugin’s General Options section (in “WooCommerce > Settings > Product Open Pricing”). A couple of notes though:
- as there were problems with saving backslash symbol in settings, I’ve added
%backslash%
replaced value for it, so in your case you should set the option to: %backslash%d*
- just in case if anyone else will use this pattern – it only allows integer numbers to be entered by your customer, so in case if you want price step to be e.g. lower than 1 (i.e. decimal), this pattern won’t work for you
Not related to the topic, but I’ve also added Input style option (again in General Options section) for easier input field styling.
Please let me know if something is not working as expected. And if you like the plugin, please consider leaving us a rating.
Thread Starter
Robin
(@robin-ho)
Thread Starter
Robin
(@robin-ho)
I’ve left a 5* review.
Combine this with my other suggestion for optional AJAX updating of the input, it could allow Chrome Payment Request, Apple Pay and Google Pay icons from Stripe to be used on the page without having to add to the basket, resulting in a seriously slick super quick and easy payment solution for businesses 🙂