Zoom of product images in HikaShop

  • Posts: 15
  • Thank you received: 0
13 years 7 months ago #15053

I just have a small question. I'm trying to use Art Zoom in Hikashop product page. The only way I got it work is in product description. But I was wondering there is any possibilities to use it with product images. It will make my job much easier.

Thank you

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

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
13 years 6 months ago #15065

You would have to edit the file show of the view product and change the code displaying the image so that it displays your images using art zoom.
Here is something which should do the trick (not tested) if you replace the code generating the images by it in the div <div id="hikashop_main_image_div"> there:

$config =& hikashop::config();
		$uploadFolder = ltrim(JPath::clean(html_entity_decode($config->get('uploadfolder'))),DS);
		$uploadFolder = rtrim($uploadFolder,DS).DS;
		$uploadFolder_url = str_replace(DS,'/',$uploadFolder);
		$thumbs = array();
		$images = array();
		foreach($this->element->images as $image){
			$thumbs[] = 	$uploadFolder_url.'thumbnails/'.$image->file_path;
			$images[] = 	$uploadFolder_url.$image->file_path;
		}
		echo JHTML::_('content.prepare','{artzoomin tinyImage="'.implode(',',$thumbs).'" smallImage="'.implode(',',$thumbs).'" bigImage="'.implode(',',$images).'"/}');

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

  • Posts: 15
  • Thank you received: 0
13 years 6 months ago #15069

Unfortunately, it's not working.. Or I'm doing smth wrong. Well, that's ok. I'll try to figure smth out. Thank you.

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

Time to create page: 0.052 seconds
Powered by Kunena Forum