1

有谁知道如何在 Joomla 的 VirtueMart 中将产品与其图片相关联?

我试过了 :

$query = "选择 a. , c. "。“ FROM #__virtuemart_products_pl_pl 作为”。" LEFT JOIN #__virtuemart_medias as c ON c.virtuemart_media_id = a.virtuemart_product_id" ;

但它并不好,图片和产品不匹配。

我看不出他们之间有任何联系。

4

1 回答 1

1

尝试以下方法:

select p.virtuemart_product_id,m.virtuemart_media_id,md.file_url 
  from #__virtuemart_products as p,
       #__virtuemart_product_medias as m,
       #__virtuemart_medias  as md
 WHERE p.virtuemart_product_id = m.virtuemart_product_id
   AND m.virtuemart_media_id = md.virtuemart_media_id
于 2012-09-12T13:12:44.620 回答