Since WordPress 6.7 a lot of plugins provoke this message and the “Product quantity for WooCommerce” plugin is among them. Full message that gets logged:
[23-Nov-2024 10:43:31 UTC] PHP Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the product-quantity-for-woocommerce
domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init
action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in …\wp-includes\functions.php on line 6114
[23-Nov-2024 10:43:31 UTC] PHP Stack trace:
[23-Nov-2024 10:43:31 UTC] PHP 1. {main}() …\wp-admin\admin-ajax.php:0
[23-Nov-2024 10:43:31 UTC] PHP 2. require_once() …\wp-admin\admin-ajax.php:22
[23-Nov-2024 10:43:31 UTC] PHP 3. require_once() …\wp-load.php:50
[23-Nov-2024 10:43:31 UTC] PHP 4. require_once() …\wp-config.php:108
[23-Nov-2024 10:43:31 UTC] PHP 5. do_action($hook_name = ‘plugins_loaded’) …\wp-settings.php:559
[23-Nov-2024 10:43:31 UTC] PHP 6. WP_Hook->do_action($args = [0 => ”]) …\wp-includes\plugin.php:517
[23-Nov-2024 10:43:31 UTC] PHP 7. WP_Hook->apply_filters($value = ”, $args = [0 => ”]) …\wp-includes\class-wp-hook.php:348
[23-Nov-2024 10:43:31 UTC] PHP 8. alg_wc_pq(”) …\wp-includes\class-wp-hook.php:324
[23-Nov-2024 10:43:31 UTC] PHP 9. Alg_WC_PQ::instance() …\wp-content\plugins\product-quantity-for-woocommerce\product-quantity-for-woocommerce.php:353
[23-Nov-2024 10:43:31 UTC] PHP 10. Alg_WC_PQ->construct() …\wp-content\plugins\product-quantity-for-woocommerce\product-quantity-for-woocommerce.php:111 [23-Nov-2024 10:43:31 UTC] PHP 11. Alg_WC_PQ->admin() …\wp-content\plugins\product-quantity-for-woocommerce\product-quantity-for-woocommerce.php:149 [23-Nov-2024 10:43:31 UTC] PHP 12. Alg_WC_PQ->move_wc_settings_tab_to_wpfactory_menu() …\wp-content\plugins\product-quantity-for-woocommerce\product-quantity-for-woocommerce.php:197 [23-Nov-2024 10:43:31 UTC] PHP 13. ($text = ‘Product Quantity’, $domain = ‘product-quantity-for-woocommerce’) …\wp-content\plugins\product-quantity-for-woocommerce\product-quantity-for-woocommerce.php:290
[23-Nov-2024 10:43:31 UTC] PHP 14. translate($text = ‘Product Quantity’, $domain = ‘product-quantity-for-woocommerce’) …\wp-includes\l10n.php:306
[23-Nov-2024 10:43:31 UTC] PHP 15. get_translations_for_domain($domain = ‘product-quantity-for-woocommerce’) …\wp-includes\l10n.php:194
[23-Nov-2024 10:43:31 UTC] PHP 16. _load_textdomain_just_in_time($domain = ‘product-quantity-for-woocommerce’) …\wp-includes\l10n.php:1408
[23-Nov-2024 10:43:31 UTC] PHP 17. _doing_it_wrong($function_name = ‘_load_textdomain_just_in_time’, $message = ‘Translation loading for the product-quantity-for-woocommerce
domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init
action or later.’, $version = ‘6.7.0’) …\wp-includes\l10n.php:1378
[23-Nov-2024 10:43:31 UTC] PHP 18. wp_trigger_error($function_name = ”, $message = ‘Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the product-quantity-for-woocommerce
domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init
action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.)’, $error_level = uninitialized) …\wp-includes\functions.php:6054
[23-Nov-2024 10:43:31 UTC] PHP 19. trigger_error($message = ‘Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the product-quantity-for-woocommerce
domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init
action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.)’, $error_level = 1024) …\wp-includes\functions.php:6114
Hola, estoy usando el plugin, está muy bueno! Felicitaciones!
Estoy usando para productos variables donde seteo cantidad máxima y mínima, hasta ahíiiiiciona.Lo que no estaría funcionando es el paso de cantidad, en el link que envié el paso es de 5 en 5 pero no funciona, alguna solución?
muchas gracias
]]>Hi. I’m selling ebooks and I want to limit the quantity to one. I checked the “Sold individually” checkbox and I find it quite useful. As a result of that if I try to add the second item to cart, I get a message: “You cannot add another product to your cart.” Can I have a “Go to cart” link or button here as well?
]]>I get the following fatal error on the cart page while using your plugin on the latest WooCommerce themes (Bookix, Eben, etc.).
Fatal error: Uncaught TypeError: Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits::limit_to_multiple(): Argument #1 ($number) must be of type int, string given, called in /wp-content/plugins/woocommerce/src/StoreApi/Utilities/QuantityLimits.php on line 58 and defined in /wp-content/plugins/woocommerce/src/StoreApi/Utilities/QuantityLimits.php:72 Stack trace: #0 /wp-content/plugins/woocommerce/src/StoreApi/Utilities/QuantityLimits.php(58): Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits->limit_to_multiple(”, ”, ‘ceil’) #1 /wp-content/plugins/woocommerce/src/StoreApi/Schemas/V1/ProductSchema.php(487): Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits->get_add_to_cart_limits(Object(WC_Product_Simple)) #2 [internal function]: Automattic\WooCommerce\StoreApi\Schemas\V1\ProductSchema->get_item_response(Object(WC_Product_Simple)) #3 /wp-content/plugins/woocommerce/src/Blocks/BlockTypes/AbstractProductGrid.php(114): array_map(Array, Array) #4 /wp-content/plugins/woocommerce/src/Blocks/BlockTypes/AbstractBlock.php(97): Automattic\WooCommerce\Blocks\BlockTypes\AbstractProductGrid->render(Array, ”, Object(WP_Block)) #5 /wp-includes/class-wp-block.php(463): Automattic\WooCommerce\Blocks\BlockTypes\AbstractBlock->render_callback(Array, ”, Object(WP_Block)) #6 /wp-includes/class-wp-block.php(443): WP_Block->render() #7 /wp-includes/class-wp-block.php(443): WP_Block->render() #8 /wp-includes/class-wp-block.php(443): WP_Block->render() #9 /wp-includes/class-wp-block.php(443): WP_Block->render() #10 /wp-includes/blocks.php(1705): WP_Block->render() #11 /wp-includes/blocks.php(1743): render_block(Array) #12 /wp-includes/block-template.php(260): do_blocks(‘<!– wp:templat…’) #13 /wp-includes/template-canvas.php(12): get_the_block_template_html() #14 /wp-includes/template-loader.php(106): include(‘/www/sundayscho…’) #15 /wp-blog-header.php(19): require_once(‘/www/sundayscho…’) #16 /index.php(17): require(‘/www/sundayscho…’) #17 {main} thrown in /wp-content/plugins/woocommerce/src/StoreApi/Utilities/QuantityLimits.php on line 72
]]>Hi,
I’m trying to redesign cart and checkout with WooCommerce Blocks.
The Min Max Default Quantity for WooCommerce plugin is configured to restrict the cart total quantity to steps of 6.
The issue is if the condition on the cart page is not met and you try to proceed to checkout, unfortunately no error message is displayed.
On the advanced plugin settings I activated “Woocommerce block compatibility”.
When I try to use the classic cart (shortcode), the error message is displayed.
Do you have a solution on that?
Thanks and kind regards
]]>Hi, my hosting contacted that php error log is full. I get this error. What is it related to? Line 65 seems to be related to variations but I don’t have variations in my store. What should I do or check?
PHP Warning: A non-numeric value encountered in /htdocs/wp-content/plugins/product-quantity-for-woocommerce-pro/includes/templates/global/quantity-input.php on line 65
We are getting the following error message on our install of v4.6.2 and 4.6.3 Warning: strpos(): Empty needle in?/home/xxxxx.net/public_html/wp-content/plugins/product-quantity-for-woocommerce/includes/class-alg-wc-pq-core.php?on line?979. Have rolled back to v4.6.0 and the error is gone.
]]>Hi
How can I hide the quantity field error messages at the admin order page with an php or css code, if the quantity input values are wrong?
Best regards
Siegfried
]]>Hi!
First of all thanks for this great plugin ??
I’ve updated the PHP version on my server from 7.4 to 8.1 and after this if i like to add a product to the cart on the category page it loads the product page and writes this Notice: Please choose the quantity of item add to cart. It should be more than zero
If i switch off your plugin or switch back to PHP version 7.4 it adds the product to the cart.
Could you please check what should be the problem?
Thanks in advance!
]]>Hello. I was hoping to use your plugin to be able to use drop-down selections for purchasing products on my site. The plugin worked for a few weeks. However, the plugin is now causing my cart page to continually refresh every 3-5 seconds. Any suggestions?
]]>Hi, How to hide the text (Price unit: per unit) in the quantity table received in the WooCommerce order email from the Min Max Default Quantity for WooCommerce plugin
]]>Thanks for this very handy plugin! Been using it for a while on a site which runs on PHP 7.4. My hosting provider is upgrading to PHP 8.2, which is more strict about dynamic classes.
when loading a category or product page, I’m getting the following php notice:
Deprecated: Creation of dynamic property Alg_WC_PQ_Core::$is_wc_version_below_3 is deprecated in /nas/content/live/devukbambooltd/wp-content/plugins/product-quantity-for-woocommerce/includes/class-alg-wc-pq-core.php on line 2643
This is appearing despite disabling wp_debug. Do you have a fix for this to endure it’s fully compatible with PHP 8.2?
]]>The tech on WordPress chat told me to send you this code for the error we keep getting. I have to have decimal quantities on my website. This error comes up on all site editor themes in WordPress/Woo Commerce. Is there anyway to correct it??
atal error:? Uncaught TypeError: Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits::limit_to_multiple(): Argument #1 ($number) must be of type int, string given, called in /wordpress/plugins/woocommerce-accelerated-frequency/8.4.0.10/packages/woocommerce-blocks/src/StoreApi/Utilities/QuantityLimits.php on line 58 and defined in /wordpress/plugins/woocommerce-accelerated-frequency/8.4.0.10/packages/woocommerce-blocks/src/StoreApi/Utilities/QuantityLimits.php:72 Stack trace: #0 /wordpress/plugins/woocommerce-accelerated-frequency/8.4.0.10/packages/woocommerce-blocks/src/StoreApi/Utilities/QuantityLimits.php(58): Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits->limit_to_multiple(”, ”, ‘ceil’) #1 /wordpress/plugins/woocommerce-accelerated-frequency/8.4.0.10/packages/woocommerce-blocks/src/StoreApi/Schemas/V1/ProductSchema.php(487): Automattic\WooCommerce\StoreApi\Utilities\QuantityLimits->get_add_to_cart_limits(Object(WC_Product_Simple))
]]>Hello,
the quantity does not work correctly for variable products, it is correct in the backend, but is not displayed correctly in the frontend.
The direct selection of the variation works, i.e. the first display of the correct quantity. However, if you change the sizes in the dropdown selection in the product, the quantity does not change.
Example:
Variation A has minimum quantity of 50
Variation B has minimum quantity of 10
If I select aariation A in the dropdown it shows 50, but when I switch to variation B then still 50 is displayed.
How can we fix this?
Best regards
]]>Hi!
I have set my product quantity step to 0.1. When I try to add 0.1 products to cart when I have 0.1 products left it gives me error. However when I try to add 0.1 products to cart when I have 0.2 products this works fine. Same error happens when I have 0.2 products left and try to add 0.2 products to cart. What causes this issue?
You can test it out here.
https://kangasemu.ee/toode/elsa-ja-anna-trikotaaz-digital-print/
All the plugins I try to do this with seem to fail including this one. What I need is to automatically add the default quantity I want when Add to Cart is clicked (in this case, a qty of 2) right away to the cart (from either a product archive page OR a single product page).
For most users, we don’t even want to show them the quantity in the Cart page, just force it to be 2. (Already using CSS to do this.) When you get to the cart, it DOES say 2, but the quantity field actually has a value=”1″ and min=”2″ – and when you proceed to checkout, you get a qty only of 1. (We do not want most users to update their cart with the button, which we will also be hiding–presumably Update Cart would then update to the 2).
I just can’t seem to find any answers, anywhere. We’re trying to launch next week!
]]>Hello, the arrows to the right of the quantity field disappear on Google Chrome but not on Firefox
]]>Hello, I have the following problem in WC. Namely, the webshop sells fabrics and other stuff by piece or by length, i.e. quantities less than a meter. So far I have used the Quantities and Units for WooCommerce plugin to be able to put decimal numbers and put min/max quantity and step value (eg 0.5m). But the plugin is no longer updated nor has support, and since the last few updates of WC, the plugin does not work properly. Now products that are in stock with less than 1 m are displayed as OUT OF STOCK, even though the min quantity is 0.5 m, and the stock is, for example, 0.9 m. I have installed your Min Max Default Quantity for WC plugin, but unfortunately it’s not working on my page somehow. It shows decimal numbers as this is general setting but when I enable min quantity setting it breaks my page…shows 404 error. Also with general settings enabled still showing all products with stock less than 1 m as out of stock which is not true…this got to be some problem with WC. Any recommendations or solutions?
]]>Hello
I have activated the plugin but the settings do not appear in the product
How can enable this?
]]>hi
You have typo in first sentence of plugin description.
Description
Control your WooComemrce product quantities the way you want
]]>Hello, it appears that in WordPress v6.3 (or Woocommerce 8.0.1) this plugin causes an error page upon Duplicating or Deleting a product. The error page lists the following error caused by this plugin:WC_Product::__construct()
/bitnami/wordpress/wp-content/plugins/product-quantity-for-woocommerce/includes/class-alg-wc-pq-core.php:1604
This error does not occur if I disable the plugin, delete/duplicate, then re-enable.
many thanks
Hi,
when I update the plugin to the newest version (4.5.10), the price unit defined on the product details page disapears next to the product price on the archive page.
How can I fix that?
]]>In early August, WooCommerce plans to switch to High-Performance Order Storage as the standard method of storing order details and potentially discontinuing the old method (source below).
We would like to prepare for the change ahead of time, but WC blocks the setup saying, “This feature shouldn’t be enabled: the All in One Product Quantity for WooCommerce Pro plugin is active and isn’t compatible with it.”
As we approach the slated goal for WC to standardize the new storage method, I am wondering if work has begun to ensure WPWhale plugins will be compatible in time. When can we expect your Quantity Control plugin to support HPOS?
https://developer.woocommerce.com/2022/09/14/high-performance-order-storage-progress-report/
]]>Max. quantity works well on product page, but the customer can trick it.
If the max. quantity is 2, then the customer can put 2 items in the cart in one step, and another 2 items in another step. There is no any message to the customer., and the customer can repeat it until reaching the stock level. Or my settings are wrong?
When we try to place an order I get the message The quantity step for PRODUCT TEST STEP QUANTITY is 6. Your current quantity is 12. What does this mean, where is the error? What is the relationship between the quantity step being 6 and the total order quantity being 12? (The error occurs with 12 or any other number that is a multiple of that quantity step of 6)
We have been working with this plugin for almost a year and it is the first time it has happened. We haven’t changed any of the settings.
You can check it by trying to place an order with this product https://petitsanimals.com/producto/producto-prueba-paso-cantidad/.
Thank you. Regards, ángel.
]]>Plugin used to ask user to enter required quantity when they clicked the add to cart button from shop page but that function is gone now for some reason. They can choose the desired quantity from product page and from cart. Is there a setting or a way to enable this back please? (flatsome theme)
]]>It appears that Version 4.5.6 breaks the Quantity box on product pages and removes the + & – buttons from either side of the quantity box. I have had to revert back to 4.5.5 which works perfectly. For reference, I am using the Flatsome theme and have tried disabling all other plugins in case there was a conflict.
]]>Hello, when I try to create or duplicate a product I get an alert. Unfortunately it flashes for a moment and then disappears. So I could only take a screenshot.
See here: https://prnt.sc/GS0NAxkpM5P7
Can anyone help understand what does it mean and how to fix it?
]]>Hello, first I want to say that your plugin is excellent.
How do I reset the minimum quantity per product (1) using the quantity that is placed in the product register?
I’ve tried everything but to no avail. In the product registration, I applied 100 in the Minimum Quantity field, but on the product page, I put the shortcode to pull the minimum amount and it only shows 1.
Please help me, I don’t know what I’m doing wrong.
awaiting
]]>Hi there, my issue is that, when adding an item to the cart, I get a critical error with no more error information.
After deactivating your plugin, I can add items to the card without any problems or errors. Can you help me with that?
Regards
]]>