Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Separate contextual images

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #1  
Old 08-26-2015, 06:06 AM
 
Martin Bishop Martin Bishop is offline
 

Advanced Member
  
Join Date: Sep 2011
Posts: 65
 

Default Separate contextual images

Hi

I'd like to find a way of adding separate contextual images to my product pages. I'd like detailed product images to contain just images showing details of the product itself with a separate set of images for contextual/lifestyle images, not just all images lumped in to one.

Anyone know of a good way/mod for doing this?

thanks
__________________
4.4.3
Reply With Quote
  #2  
Old 08-26-2015, 06:43 AM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,190
 

Default Re: Separate contextual images

This can easily be done with detailed images and their position field. Say anything below 1000 shows as detailed images and above 1000 as this separate set of images.
No need for a module. Still requires some changes to templates though.
__________________
Steve Stoyanov
CFLSystems.com
Web Development
Reply With Quote
  #3  
Old 08-26-2015, 07:11 AM
 
Martin Bishop Martin Bishop is offline
 

Advanced Member
  
Join Date: Sep 2011
Posts: 65
 

Default Re: Separate contextual images

aha yes that makes sense. Thanks for the pointer Steve...... I'll have a little delve about.
__________________
4.4.3
Reply With Quote
  #4  
Old 08-27-2015, 05:49 AM
 
Martin Bishop Martin Bishop is offline
 

Advanced Member
  
Join Date: Sep 2011
Posts: 65
 

Default Re: Separate contextual images

Hi Steve

I've been playing about and trying to use an if statement to hide images over position 40 using orderby but I can't get it to work properly. It either shows or doesn't show the whole lot depending on what I use. Any idea what I'm doing wrong? thanks

HTML Code:
{foreach from=$images item=i name=images} {if $images.order_by gt 40} <a href="{$i.image_url|amp}" class="lightbox"{if $config.Detailed_Product_Images.det_image_icons_limit gt 0 and $config.Detailed_Product_Images.det_image_icons_limit le $smarty.foreach.images.index} style="display:none;"{/if} rel="dpimages" title="{$i.alt|escape}"><img src="{$i.icon_url|amp}" alt="{$i.alt|escape}" width="{$i.icon_image_x}" height="{$i.icon_image_y}" /></a> {/if} {/foreach}
__________________
4.4.3
Reply With Quote
  #5  
Old 08-27-2015, 06:07 AM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,190
 

Default Re: Separate contextual images

Use the webmaster mode to find out the exact spelling but I think it is

orderby not order_by

and it should be

{if $i.orderby gt 40}
__________________
Steve Stoyanov
CFLSystems.com
Web Development
Reply With Quote

The following user thanks cflsystems for this useful post:
Martin Bishop (08-27-2015)
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 10:10 AM.

   

 
X-Cart forums © 2001-2020