Jump to content
xt:Commerce Community Forum

Herstellerlogo in Produktbeschreibung darstellen


Reisecenter

Recommended Posts

in der includes/modules/product_info.php

nach

} else {

if ($product_info['products_date_added']!='0000-00-00 00:00:00') $info_smarty->assign('PRODUCTS_ADDED',sprintf(TEXT_DATE_ADDED, xtc_date_long($product_info['products_date_added']))); }

folgendes hinzufügen.

if (isset($_GET['products_id'])) {

    $manufacturer_query = xtc_db_query("select m.manufacturers_id, m.manufacturers_name, m.manufacturers_image from " . TABLE_MANUFACTURERS . " m left join " . TABLE_MANUFACTURERS_INFO . " mi on (m.manufacturers_id = mi.manufacturers_id and mi.languages_id = '" . (int)$_SESSION['languages_id'] . "'), " . TABLE_PRODUCTS . " p  where p.products_id = '" . (int)$_GET['products_id'] . "' and p.manufacturers_id = m.manufacturers_id");

    if (xtc_db_num_rows($manufacturer_query)) 


 {

      $manufacturer = xtc_db_fetch_array($manufacturer_query);

      $info_smarty->assign('H_NAME',$manufacturer['manufacturers_name']);

   $info_smarty->assign('H_LOGO',$manufacturer['manufacturers_image']);


    } 

 }

Jetzt kannst du in der product_info_v1.html den Herstellernamen mit {$H_NAME} und das Logo mit {$H_LOGO} ansprechen.

:)

Link to comment
Share on other sites

Hallo!

Das funzt nicht. Aber bei mir steht in der Datei auch eine etwas andere Syntax:

	
} else {
if ($product->data['products_date_added'] != '0000-00-00 00:00:00')
$info_smarty->assign('PRODUCTS_ADDED', sprintf(TEXT_DATE_ADDED, xtc_date_long($product->data['products_date_added'])));
}[/PHP]

Wenn ich den Code darunter platziere und ann die Ergänzungen in der product_info.php mache, erscheint kein Logo.

Henning

Link to comment
Share on other sites

sorry... die lößung hatte ich für nen 3.03 shop verwendet. mittlerweile hat sich die produkt_info.php ja doch gewaltig geändert....:rolleyes:

setz mal das

<img src="images/{php}echo ($GLOBALS[manufacturer][manufacturers_image]);{/php}" alt="{php}echo ($GLOBALS[manufacturer][manufacturers_name]);{/php}" /> [/CODE]

in deine product_info.html

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
  • Create New...