Jump to content
xt:Commerce Community Forum

Herstellernamen in product_info anzeigen???


fawad

Recommended Posts

Hallo Community,

ich würde gerne in meiner product_info_v1.html unter {$PRODUCTS_NAME} den Herstellernamen anzeigen lassen.

Allerdings habe ich {$PRODUCTS_MANUFACTURERS} eingefügt, aber leider hat es nicht geklappt!

in

include/modules/product_info_v1.php muss auch etwas geändert werden????

KANN MIR JEMAND HELFEN???

Version 304SP2

Ich danke im Voraus

Link to comment
Share on other sites

in includes/modules/product_info.php folgendes einfügen

// Trev Change - Get manufacturer name etc. for the product page

$manufacturer_query = xtc_db_query("select m.manufacturers_id, m.manufacturers_name, m.manufacturers_image, mi.manufacturers_url 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 = '" . $product->data['products_id'] . "' and p.manufacturers_id = m.manufacturers_id");

if (xtc_db_num_rows($manufacturer_query)) {

$manufacturer = xtc_db_fetch_array($manufacturer_query);

$manufacturers_image='';

if (xtc_not_null($manufacturer['manufacturers_image'])) $manufacturers_image=DIR_WS_IMAGES . manufacturer['manufacturers_image'];

$info_smarty->assign('MANUFACTURER_ID',$manufacturer['manufacturers_id']);

$info_smarty->assign('MANUFACTURER_IMAGE',$manufacturers_image);

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

}

// Man Query end

Link to comment
Share on other sites

Hallo!

Vielen Dank für deine Antwort!

Es kommt folgende Ferhlermeldung:

Parse error: parse error, unexpected '[' in /var/www/web0/html/includes/modules/product_info.php on line 146

woran ligt das?

In product_info_v1.html habe folgendes {$PRODUCTS_MANUFACTURERS} eingefügt

MfG

Link to comment
Share on other sites

Hallo!

ich habe auch natürlich so ausporbiert:

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

$manufacturer_query = xtc_db_query("select m.manufacturers_id, m.manufacturers_name 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('NAME',$manufacturer['manufacturers_name']);

}

}

aber es wird leider nicht angezeigt

Bitte XT-Commerce Version 3.04 SP2 beachten

Vielen Dank

MfG

Nemani

Link to comment
Share on other sites

Archived

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

×
  • Create New...