Author Topic: Anyone else having problems with quotes in product names?  (Read 725 times)

garyamort

  • Beginner
  • *
  • Posts: 1
  • Skype Name: bzgmort
Anyone else having problems with quotes in product names?
« on: July 01, 2014, 17:51:38 pm »
Ran into a weird problem with products with quotes in the product names.   Turned out to be be in the getNeighborProducts method in the file administrator/components/com_virtuemart/models/product.php.

I had to change line 1492 from
            $qm = ' AND '.$orderByName.' '.$op.' "'.$orderByValue.'" ORDER BY '.$orderByName.' '.$direction.' LIMIT 1';
to
            $qm = ' AND '.$orderByName.' '.$op.' "'.$this->_db->quote($orderByValue).'" ORDER BY '.$orderByName.' '.$direction.' LIMIT 1';

I was wondering if anyone else has run across this?