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

float:left image on product detail

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 11-20-2004, 05:19 AM
 
pinnacle pinnacle is offline
 

Member
  
Join Date: Oct 2004
Posts: 17
 

Default float:left image on product detail

Has anyone had success with breaking the product image out of the seperate table cell and float:left so that the description flows around it? I have set it up to do so and the text wraps fine but if I use css to color a background or have a border those appear behind the image.

Here is an example: http://www.adaappliances.com/product.php?productid=16135&cat=0&page=1

And another: http://www.adaappliances.com/product.php?productid=16156&cat=0&page=1

Code snippet of the product_thumbnail.tpl

Code:
<p style="float:left; margin:0px, 12px, 12px, 0px; padding:0px, 10px, 0px, 0px;">{* $Id: product_thumbnail.tpl,v 1.14 2004/06/24 09:53:29 max Exp $ *} {if $config.Appearance.show_thumbnails eq "Y"} [img]{if $tmbn_url}{$tmbn_url}{else}{if $full_url}{$http_location}{else}{$xcart_web_dir}{/if}/image.php?productid={$productid}{if $file_upload_data.file_path}&tmp=y{/if}{/if}[/img]{/if} </p>

I can specify a margin-left in the description html or use tables but this is tedious and has some adverse effects. I was hoping there was something that could be done on the template to compensate.

The site is not live so please do not attempt to order anything!
__________________
First ever x-cart site:
http://www.adaappliances.com
X-Cart version 4.1.10

http://www.pinnacledesigns.tv
working on version 2 of site, please stand by...
Reply With Quote
  #2  
Old 11-22-2004, 04:54 AM
 
pinnacle pinnacle is offline
 

Member
  
Join Date: Oct 2004
Posts: 17
 

Default Workaraound

OK I gave up on making that work. I just contained everything in a table with a non-specified width for the ones next to the image and 100% width on the lower tables. I was hoping someone had a solution but I have a deadline to meet
__________________
First ever x-cart site:
http://www.adaappliances.com
X-Cart version 4.1.10

http://www.pinnacledesigns.tv
working on version 2 of site, please stand by...
Reply With Quote
  #3  
Old 11-25-2004, 06:58 AM
 
mikebo mikebo is offline
 

Advanced Member
  
Join Date: Feb 2004
Location: Ohio
Posts: 72
 

Default

Hi Pinnacle

Try taking the floatleft out of your

tag and putting it in your <img> tag.

<IMG style="float: left; margin: .2em; border: .4em; border-color: ffe;" id="{$id}" src="{if $tmbn_url}{$tmbn_url ............

I did not try this but hope it helps you out.
__________________
Mike
X-Cart Gold
Version 4.6.0 PHP 5.2.17
Reply With Quote
  #4  
Old 11-27-2004, 05:57 PM
 
jmell jmell is offline
 

Senior Member
  
Join Date: Sep 2003
Posts: 127
 

Default If that works please post.

I've been wanting that on my site. If it works please post the code.
__________________
X-Cart 4.1.9
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



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 02:02 PM.

   

 
X-Cart forums © 2001-2020