News:

Looking for documentation? Take a look on our wiki

Main Menu

*** 1064 *** You have an error in your SQL syntax

Started by marvays, October 29, 2018, 16:50:56 PM

Previous topic - Next topic

marvays

Hi all.
Last days I was migrate old eshop to newest. Now, when I link from menu to virtuemart "front page" have this error. This I se for first time.

*** 1064 *** You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ') WHERE `a`.`virtuemart_media_id` = `b`.`virtuemart_media_id`' at line 3


What is it? What i can do about it?
http://www.lukysipy.cz.hyperion.blueboard.cz/eshop

I have latest joomla and VM.

GJC Web Design

And I assume fine with the standard template again?  So there's your answer...

I'm afraid we are not here to fix commercial templates....
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

marvays

You think?
Here are the problems associated with Virtuemart. It does not matter whether it's a commercial extension or my attempt. I think it's good when I buy a commercial thing and I support the Virtuemart community. You produce and sell too :)

Now to the point.
Probably the problem is from /html/com_virtuemart/sublayouts/manufacturer-logo.php


<?php
// Check to ensure this file is included in Joomla!
defined ('_JEXEC') or die('Restricted access');

$product $viewData['product'];
//$currency = $viewData['currency'];
//$params = $viewData['params'];
$gridLayout = (isset($viewData['gridLayout'])) ? $viewData['gridLayout'] : '';

  $db JFactory::getDbo();
  $query $db->getQuery(true);
  $query
  ->select($db->quoteName('a.file_url'))
  ->from($db->quoteName('#__virtuemart_medias''a'))
  ->join('INNER'$db->quoteName('#__virtuemart_manufacturer_medias''b') . ' ON (' $db->quoteName('b.virtuemart_manufacturer_id') . ' = '$product->virtuemart_manufacturer_id[0].')')
  ->where($db->quoteName('a.virtuemart_media_id') . ' = '.$db->quoteName('b.virtuemart_media_id')); 
  $db->setQuery($query);
  $results $db->loadRow();
  ?>

  <div class="manufacturerLogoContainer">
  <a title="<?php echo $product->mf_name?>" class="hoverable" href="<?php echo JRoute::_('index.php?option=com_virtuemart&view=category&virtuemart_manufacturer_id=' $product->virtuemart_manufacturer_id[0]); ?>"><?php echo (isset($results[0])) ? '<img src="'.JURI::root () . $results [0].'" alt="'.$product->mf_name.'" />':$product->mf_name?>
  </a>
  </div>

GJC Web Design

QuoteYou think?
Here are the problems associated with Virtuemart. It does not matter whether it's a commercial extension or my attempt. I think it's good when I buy a commercial thing and I support the Virtuemart community. You produce and sell too :)

But it does matter .. Flexible have sold you a product and by any measure if it has bugs or problems they must fix them...  as I do for all my extensions..

My point was this isn't your first post about display issues with this template ...  so it has to be asked, is the template fit for purpose?

It is clearly stated that we don't get involved in fixing 3rd party extensions..
http://forum.virtuemart.net/index.php?topic=108212.0

Flexible have a forum

to this issue .. there is no such file as sublayouts/manufacturer-logo.php in a std. VM install so it is Flexibles own creation

the error shows I assume that $product->virtuemart_manufacturer_id[0] doesn't exist
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation