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

How to display a border on the rollover for thumbnails

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 04-08-2009, 11:40 AM
 
mmoskva mmoskva is offline
 

eXpert
  
Join Date: Aug 2005
Location: Pennsylvania
Posts: 306
 

Default How to display a border on the rollover for thumbnails

When a customer mouseOver(s) a product thumbnail, how do I get a BORDER to display on only the thumbnail image?
ps. I tried adding (ie. class=⌠borderit■ to the product_thumbnail.tpl code but on the store the border rollover is not displaying.


#####

In my skin1/product_thumbnail.tpl I have the below code:


{if $config.Appearance.show_thumbnails eq "Y"}<IMG id="{$id}" src="{if $tmbn_url}{$tmbn_url}{else}{if $full_url}{$http_location}{else}{$xcart_web_dir}{/if}/{if $extra}extra_{/if}image.php?productid={$productid}{if $file_upload_data.file_path}&tmp=y{/if}{/if}"{if $image_x ne 0} width="{$image_x}"{/if}{if $image_y ne 0} height="{$image_y}"{/if} alt="{$product|escape}" class=⌠borderit■>{/if}




In my skin1.css I have the below css:

.borderit img{
border: 1px solid #FFFFFF;
}
.borderit:hover img{
border: 1px solid #DD0D75;
}
.borderit:hover{
color: DD0D75; /* irrelevant definition to overcome IE bug */
}

#####
__________________
x-cart 4.0.16v
linux server
Reply With Quote
  #2  
Old 04-08-2009, 11:50 AM
  ElegantXMods.com's Avatar 
ElegantXMods.com ElegantXMods.com is offline
 

Advanced Member
  
Join Date: Apr 2009
Location: Stirling, UK
Posts: 94
 

Default Re: How to display a border on the rollover for thumbnails

I've only just taken a quick look over your post, so I apologise in advance if this is wrong, but perhaps your CSS for borderit should refer to <img />, rather than a class that 'encloses' the <img />, like so:

img.borderit {
border: 1px solid #FFFFFF;
}
img.borderit:hover {
border: 1px solid #DD0D75;
}
img.borderit:hover{
color: DD0D75; /* irrelevant definition to overcome IE bug */
}
__________________
John
ElegantXMods.com

QuickOrder AJAX-based search and ordering system now available
giving you complete control over how customers browse and search for your products. Click here for details.
PriceSlider - easily filter categories by price range - only $9.99 - details here

X-Cart 4.1, X-Cart 4.2 on Windows/IIS and Linux/Apache.
Reply With Quote
  #3  
Old 04-08-2009, 03:35 PM
  ARW VISIONS's Avatar 
ARW VISIONS ARW VISIONS is offline
 

X-Man
  
Join Date: Jan 2007
Location: Pensacola, FL
Posts: 2,536
 

Default Re: How to display a border on the rollover for thumbnails

i use this

class=⌠borderit■ onmouseover="this.className=''borderitover'" onmouseout="this.className='borderit'"


css
.borderit {
border: 1px solid #FFFFFF;
}

.borderitover{
border: 1px solid #DD0D75;
}
__________________
xcart 5.1.2
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 05:19 PM.

   

 
X-Cart forums © 2001-2020