Tips and Tricks HQ Support Portal › Forums › WP eStore Forum › A non-numeric value encountered
- This topic has 25 replies, 8 voices, and was last updated 6 years, 7 months ago by admin.
-
AuthorPosts
-
October 13, 2017 at 10:03 pm #75564adminKeymaster
Can you please share the steps that I can do on your site so I can reproduce the issue to see it from my end?
October 14, 2017 at 3:29 pm #75565Paul GroutMemberHi Key Master
Thank you. Please use the below link to perform a test. The error message always appears when you add an item to the cart. The error (which appears on the top of the page) has got something to do with the cart for sure.
[http://musicenergetics.net/estore-action/downloadable-healing-music-2/]
Kind regards
Paul Grout
October 15, 2017 at 1:08 pm #75566wzpModeratorThe error message always appears when you add an item to the cart. The error (which appears on the top of the page) has got something to do with the cart for sure.
When I add the first (only) product to the cart; I receive no error, and am allowed to proceed to the PayPal (account) checkout (login) page.
October 16, 2017 at 5:25 am #75567adminKeymasterI will have to jump on your site and take a look. I have sent you an email for it.
October 18, 2017 at 8:07 pm #75568defharoSpectatorHello, I have the same problem when adding to the cart “A non-numeric value encountered” with file line 480: /wp-cart-for-digital-products/eStore_cart.php
I also get the same error in line 162 of the file: eStore-advanced-variations-ui / eStore-variations-form-addon.php
My scenario:
WP: 4.82
PHP: 7.1.10
MySQL: 5.5.46
I have seen that line 480 has to do with shipping.
I have seen that line 162 has to do with inventory.
As I only sell downloadable products I have commented both lines and the errors have disappeared.
Regards
October 18, 2017 at 11:51 pm #75569adminKeymaster@defharo, I would really like to get temporary access to a site where this is happening so I can get an idea of what condition is triggering it. I have sent you an email to organize access.
November 13, 2017 at 7:54 pm #75570LANSRADMemberThis error occurs for me as well.
It ONLY happens if you have created a new product and do NOT enter ANY amount for the shipping charge.
If you enter 0.00 (or just 0) as the shipping charge, then everything works as it should.
However it is a PITA to have to open the shipping section and enter a zero amount for every digital product created.
I understand that a blank is not the same as a zero, but it seems like you could fix this in code or at least set it up so that when a new product is created that it defaults to a value of “0” (or whatever is specified in the settings).
Thanks!
November 13, 2017 at 8:13 pm #75571LANSRADMemberHere is the solution!
Edit line 480 of the estore_cart.php file and wrap the line in conditional code like this:
if (!empty($item)) {
$item_total_shipping += $item * $item;
}
That way the line is only evaluated if there is an actual shipping amount set.
If you can get this into the next update of the plugin it would make this issue go away as far as I can see.
Charles
November 14, 2017 at 12:24 am #75572adminKeymasterThank you. I have updated the core plugin’s code.
April 12, 2018 at 2:23 pm #75573unfoldatelierMemberHelp. I have the same problem running only. I managed to work after doing this steps:
1. in wpEstore General Settings > Shipping& tax > Base shipping Cost: add 0
2. in Product edit > Shipping & tax: add 0
April 13, 2018 at 5:10 am #75574adminKeymasterWhich line does it complain about? If you can copy and paste the warning, it will help me track it.
-
AuthorPosts
- You must be logged in to reply to this topic.