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

Detailed Product Image Mod

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #1  
Old 05-10-2005, 07:57 AM
 
ccakins ccakins is offline
 

Member
  
Join Date: May 2005
Location: Tampa, FL, US
Posts: 27
 

Default Detailed Product Image Mod

xcart version 4.0.11

I had a need to list detailed images horizontally rather than vertically, display the alt text under each image, and I had to get the images to break at a certain size.

The code below is a modified product_images.tpl. Based on image size (mine being 100 X 100 pixals) you can modify the {if $count==5} line to however many images you wished displayed horizontally.

Modified code is in green

{if $images ne ""}
{capture name=dialog}
<DIV align="center">

<table border="0" width="100" id="table1" cellspacing="0" cellpadding="0">
<tr>

{section name=image loop=$images}
{if $images[image].avail eq "Y"}

{assign var="count" value="`$count+1`"}

{if $images[image].tmbn_url}
[img]{$images[image].tmbn_url}[/img]
{$images[image].alt|escape}
{else}

<td>
<p align="center">

[img]{$xcart_web_dir}/product_image.php?imageid={$images[image].imageid}[/img]
{$images[image].alt|escape}
</td>

{if $count==5}
{assign var="count" value="0"}
</tr>
<tr>
{/if}
[/color]
{/if}

{/if}


{/section}
</DIV>

</tr>
</table>

{/capture}
{if $smarty.capture.dialog ne ""}
{include file="dialog.tpl" title=$lng.lbl_detailed_images content=$smarty.capture.dialog extra="width=100%"}
{/if}
{/if}
__________________
Dictationstore.com - Professional Dictation and Transcription Products
Jessica Clifford
Tech Support & Development
V 4.0.18
Reply With Quote
  #2  
Old 01-10-2008, 08:54 AM
 
sparcx sparcx is offline
 

Newbie
  
Join Date: Jan 2005
Posts: 3
 

Unhappy Re: Detailed Product Image Mod

Hi,

Can somebody change this code for use with 4.1.9 ?

Thanks

Selim
__________________
XCart 4.1.9
Reply With Quote
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 05:10 AM.

   

 
X-Cart forums © 2001-2020