[TYPO3-shop] Problems with additional marker
Ines Willenbrock
icybaer at web.de
Fri Jul 3 12:07:32 CEST 2009
Hello there,
I've tried to extend tt_products with some custom marker using the
provides hook getItemMarkerArray.
Fillen data to the database is working, but filling this data into the
frontend-markers isn't.
I'm not sure, where I made mistakes as I believe I followed instructions
from this group.
Could anybody please have a look and tell me what's wrong with my attempt?
Here is what I tried:
---
hooks/class.tx_ttproducts_markeradd.php
<?php
class tx_ttproducts_markeradd {
function getItemMarkerArray($this, $markerArray, $item, $catTitle,
$imageNum, $imageRenderObj, $forminfoArray, $code, $id);
{
$row = &$item['rec'];
$markerArray['###PRODUCT_OWN_MARKER1###'] =
$row['user_ttproductsown_marker1'];
$markerArray['###PRODUCT_OWN_MARKER2###'] =
$row['user_ttproductsown_marker2'];
return $markerArray;
}
}
>
---
ext_localconf.php:
<?php
if (!defined ('TYPO3_MODE')) {
die ('Access denied.');
}
$TYPO3_CONF_VARS['EXTCONF']['tt_products']['extendingTCA'][] = $_EXTKEY;
$TYPO3_CONF_VARS['EXTCONF']['tt_products']['getItemMarkerArray'][] =
'EXT:ext/user_ttproductsown/hooks/class.tx_ttproducts_markeradd.php:&tx_ttproducts_markeradd';
?>
Do I need something else?
Regards, Ines Willenbrock
More information about the TYPO3-project-tt-products
mailing list