julianpuje Posted February 16, 2006 Posted February 16, 2006 Hi all I'm a little bit stuck on coding this. I have my Category name at the top of the index page when you click on that particular category. Then i have a sub cat with it's name at the top of it's page. What i want to do is on the sub cat page combine the names/heading titles. eg: category: Jump for Fun (page title is Jump For Fun) sub Cat: Trampolines (i want the page title for this to be Jump For Fun Trampolines) The code i currently use for the category is: <?php if ($category_depth == 'nested') { $category_query = tep_db_query("select cd.categories_name, c.categories_image from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and cd.categories_id = '" . (int)$current_category_id . "' and cd.language_id = '" . (int)$languages_id . "'"); $category = tep_db_fetch_array($category_query); ?> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="10" cellpadding="0"> <tr> <td align="right" class="pageHeading"><?php echo $category['categories_name']; ?></td> <td class="pageHeading" align="left"><?php echo tep_image(DIR_WS_IMAGES . $category['categories_image'], $category['categories_name'], HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td> </tr> and for the sub-cat: <td align="right" class="pageHeading"><?php echo $category['categories_name']; ?></td> Any help greatly appreciated. Thanks J A little knowledge is dangerous, I SHOULD KNOW. If Life Begins At 40, What ends????
boxtel Posted February 16, 2006 Posted February 16, 2006 Hi all I'm a little bit stuck on coding this. I have my Category name at the top of the index page when you click on that particular category. Then i have a sub cat with it's name at the top of it's page. What i want to do is on the sub cat page combine the names/heading titles. eg: category: Jump for Fun (page title is Jump For Fun) sub Cat: Trampolines (i want the page title for this to be Jump For Fun Trampolines) The code i currently use for the category is: <?php if ($category_depth == 'nested') { $category_query = tep_db_query("select cd.categories_name, c.categories_image from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.categories_id = '" . (int)$current_category_id . "' and cd.categories_id = '" . (int)$current_category_id . "' and cd.language_id = '" . (int)$languages_id . "'"); $category = tep_db_fetch_array($category_query); ?> <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0"> <tr> <td><table border="0" width="100%" cellspacing="10" cellpadding="0"> <tr> <td align="right" class="pageHeading"><?php echo $category['categories_name']; ?></td> <td class="pageHeading" align="left"><?php echo tep_image(DIR_WS_IMAGES . $category['categories_image'], $category['categories_name'], HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td> </tr> and for the sub-cat: <td align="right" class="pageHeading"><?php echo $category['categories_name']; ?></td> Any help greatly appreciated. Thanks J personally I would simply echo out the breadcrumb stripped of home/top and the separators. something like : echo str_replace("Home", " ", $breadcrumb->trail(' ')); Treasurer MFC
julianpuje Posted February 16, 2006 Author Posted February 16, 2006 Thanks Amanda That worked perfect :thumbsup: A little knowledge is dangerous, I SHOULD KNOW. If Life Begins At 40, What ends????
Recommended Posts
Archived
This topic is now archived and is closed to further replies.