Adding Manufacturer Logo into Category Page

  • Posts: 100
  • Thank you received: 1
9 years 9 months ago #220152

-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.5
-- PHP version -- : 5.6.14
-- Browser(s) name and version -- : All Browsers...

Hi,

We have edited the category page to display a link to each product's manufacturer. What we would like to do is replace the manufacturer name with the manufacturer image. Please could you explain how we do this?

The current code we have used is:

<?php

$manufacturerClass = hikashop_get('class.category');
$manufacturer = $manufacturerClass->get($this->row->product_manufacturer_id);
$manufacturer_url = HIKASHOP_LIVE.'index.php?option=com_hikashop&ctrl=category&task=listing&cid='.$manufacturer->category_id.'&name='.$manufacturer->category_alias.'&Itemid=233';

echo '<a href='.$manufacturer_url.' >';
echo $manufacturer->category_name;
echo '</a>';
?>

Many thanks in advance.

Please Log in or Create an account to join the conversation.

  • Posts: 84233
  • Thank you received: 13673
  • MODERATOR
9 years 9 months ago #220158

Hi,

Here is a thread which talks about loading the image of the manufacturer:
www.hikashop.com/forum/4-how-to/20324-di...duct-page.html#20365
You should be able to easily adapt it in your own custom code.

Please Log in or Create an account to join the conversation.

  • Posts: 100
  • Thank you received: 1
9 years 9 months ago #220252

Thank you. I have one more unrelated question, but not sure if I should create a new thread?

I am just wondering if it is possible to place links to the products around the product names in the order emails?

The product titles are referenced in the emails like this: {LINEVAR:PRODUCT_NAME}

Thanks you.

Please Log in or Create an account to join the conversation.

  • Posts: 84233
  • Thank you received: 13673
  • MODERATOR
9 years 9 months ago #220280

Hi,

It's better to open new threads for new questions.

You can add such link by replacing that tag by:
<a href="{LINEVAR:product.product_canonical}">{LINEVAR:PRODUCT_NAME}</a>

This however requires that the "canonical URL" field of your products is filled with the URL of the product page.

Please Log in or Create an account to join the conversation.

Time to create page: 0.065 seconds
Powered by Kunena Forum