Support the VirtueMart project and become a member

Main Menu

Product with slashes / in name not added to cart

Started by WebStuff, November 21, 2023, 14:53:03 PM

Previous topic - Next topic


Joomla! 3.10.12
VirtueMart 4.2.4 10922
PHP 8.1.9

Just upgraded to 4.2.4 a week or so ago and a customer informed me today that they couldn't add a product to cart.

I checked and indeed when the "add to cart" was pressed the page jumped to the cart page and displayed the "product removed" message instead of displaying the fancybox popup.
The product concerned had a slash in it's name e.g. "Mirroview 75/20 Generation Two". I changed it to "75-20" and all worked again.
Not sure whether this was introduced with this update or a previous one and I just haven't noticed but the product has been order-able before.

I tried it with the Beez template and disabled any plugins I could think of but still have the site work and the fancybox message popup does appear but the message reads "0 x Mirroview 75/20 Generation Two added".
So the popup is firing but the added amount is zero which would remove the product.

I assume it's either a regex or delimiter problem.

Tried to replicate with a new test product with a slash in the name but that added fine it seems to be a weird combination of letters or numbers in this particular product name.

Wondered if anyone else can replicate this?

Any further information required please let me know.