Skip to main content

Product Images In Wish List

13 years 1 week ago #133148 by MyWorld
Joomla! 2.5.14
HikaShop Business: 2.2.2

How can I add the product images in the wishlist?. Currently it's only showing the name of the product.

Thank you!!

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

13 years 1 week ago #133224 by Xavier
Replied by Xavier on topic Product Images In Wish List
Hi,

The wishlist module is working like the cart module.
So you can enable the image display in the wishlist module options. :)

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

13 years 5 days ago #133622 by MyWorld
Replied by MyWorld on topic Product Images In Wish List
Hi Xavier,

Sorry but I am referring to the wishlist page not the module. On the wishlist page is shows the name of the product but it does not show an image of the product.

I would like to show an image of the product.

Thank you!!

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

13 years 5 days ago #133641 by Xavier
Replied by Xavier on topic Product Images In Wish List
Hi,

You have to edit the view "cart / showcart" via the menu Display > Views and add a column in the table.
In the body, to display the image you can use the following code:
Code:
<?php $width = (int)$this->config->get('thumbnail_x'); $height = (int)$this->config->get('thumbnail_y'); $imageHelper = hikashop_get('helper.image'); $db = JFactory::getDBO(); $db->setQuery('SELECT * FROM '.hikashop_table('file').' WHERE `file_ref_id` = '.(int)$cart->product_id.' ORDER BY `file_ordering`'); $image = $db->loadObject(); if(is_object($image)) echo '<img src="' . $imageHelper->uploadFolder_url.'thumbnail_'.$width.'x'.$height.'/'.$image->file_path . '" alt="' . $image->file_name . '" id="hikashop_main_image" style="margin-top:10px;margin-bottom:10px;display:inline-block;vertical-align:middle" />'; ?>

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

13 years 3 days ago #133788 by MyWorld
Replied by MyWorld on topic Product Images In Wish List
Hi Xavier,

I add the code in the same column as the product name but the image is not showing.
Code:
<?php $width = (int)$this->config->get('thumbnail_x'); $height = (int)$this->config->get('thumbnail_y'); $imageHelper = hikashop_get('helper.image'); $db = JFactory::getDBO(); $db->setQuery('SELECT * FROM '.hikashop_table('file').' WHERE `file_ref_id` = '.(int)$cart->product_id.' ORDER BY `file_ordering`'); $image = $db->loadObject(); if(is_object($image)) echo '<img src="' . $imageHelper->uploadFolder_url.'thumbnail_'.$width.'x'.$height.'/'.$image->file_path . '" alt="' . $image->file_name . '" id="hikashop_main_image" style="margin-top:10px;margin-bottom:10px;display:inline-block;vertical-align:middle" />'; ?> <a href="<?php echo hikashop_completeLink('product&task=show&cid='.$cart->product_id.'&name='.$cart->alias.'&Itemid='.$Itemid); ?>"> <?php if(!isset($cart->bought) || !$cart->bought){ echo $cart->product_name; }else{ echo JHTML::tooltip(implode('<br />',$cart->bought), JText::_('HIKA_BOUGHT_BY'), '',$cart->product_name); } if($this->params->get('show_code')){ echo ' ('.$cart->product_code.')'; } ?> </a>

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

13 years 1 day ago #134066 by Xavier
Replied by Xavier on topic Product Images In Wish List
Hi,

That should work, I tested it on my local version.
Are you sure that you have images for the products in the cart ?

I have added that feature on HikaShop, this will be present in the next release. So thanks to wait until the next release :)

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

12 years 11 months ago #134488 by MyWorld
Replied by MyWorld on topic Product Images In Wish List

I have added that feature on HikaShop, this will be present in the next release. So thanks to wait until the next release :)


Sorry for the late response but I will be more than happy to wait :woohoo:

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

Time to create page: 0.066 seconds
Powered by Kunena Forum