Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Remove Category Images


shopkeper

Recommended Posts

Ooos, I've just posted about axactly the same thing. Any help would be appreciated.

I found this doing a google search posted by Bert. It does not elimiante the images but looks a little better. You can view the changes on my site at http://beveragemall.com/catalog/ and selecting either of the categories.

 

I know someone else has done this, as I remember reading the thread quite a while back, but I could not find it :oops:

 

 

 

So, my own version:

 

 

 

Open up catalog/includes/functions/general.php and add:

 

 

 

CODE

 

 

function tep_get_categories_name($cPath) {

 

$categories_query = tep_db_query("SELECT categories_name FROM " . TABLE_CATEGORIES_DESCRIPTION . " WHERE categories_id = '" . $cPath . "'");

 

$products_category = tep_db_fetch_array($categories_query);

 

 

 

return ($products_category['categories_name'] == "" ? "N/A" : $products_category['categories_name']);

 

 

 

}

 

 

 

 

 

Then, in catalog/index.php, find this line (approx line 270):

 

 

 

CODE

 

 

<td align="right" class="pageHeading">

 

<?php echo tep_image(DIR_WS_IMAGES . $image, HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>

 

 

 

 

 

Replace it with:

 

 

 

CODE

 

 

<td align="right" class="pageHeading"><?php echo tep_get_categories_name($cPath); ?></td>

 

 

 

 

 

This will get rid of the category images, and replace with the categories name. Not right for everyone of course, but on some sites using the name only looks better.

 

Hope this helps. If anyone knows how to get rid of the category names across the top please let me know.

 

Thanks,

Matt

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...