Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 10-06-2012, 04:03 PM   PM User | #1
joelupet
New to the CF scene

 
Join Date: Sep 2012
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
joelupet is an unknown quantity at this point
[Help] Images product thumbs centering

I need your help..

I am not a web developer so I need somebody who's willing to help and find a solution...

here are some codings made...


http://jsbin.com/ititac/1/edit

Problem:
The images not centered

Solution:
The images should be in center of the block around red dashed....
Without changing its height and witdh..

Thanks in Advance!
joelupet is offline   Reply With Quote
Old 10-07-2012, 02:30 AM   PM User | #2
sunfighter
Senior Coder

 
Join Date: Jan 2011
Location: Missouri
Posts: 2,498
Thanks: 18
Thanked 361 Times in 360 Posts
sunfighter is on a distinguished road
If you can live with a slightly larger dashed box, so the images are not cut off, then try this:
Code:
#product_thumbs .product_thumb {
float: left;
padding-top: 9px;
border: 1px dashed #B52020;
margin: 0 10px 10px 0;
width: 120px;
height: 90px;
text-align: center;
}
sunfighter is offline   Reply With Quote
Old 10-07-2012, 02:53 AM   PM User | #3
joelupet
New to the CF scene

 
Join Date: Sep 2012
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
joelupet is an unknown quantity at this point
Quote:
Originally Posted by sunfighter View Post
If you can live with a slightly larger dashed box, so the images are not cut off, then try this:
Code:
#product_thumbs .product_thumb {
float: left;
padding-top: 9px;
border: 1px dashed #B52020;
margin: 0 10px 10px 0;
width: 120px;
height: 90px;
text-align: center;
}
Yeah, your advice really works, i appreciate it..

I have resolve the problem but, i found out that vertical image are not centered

see here http://jsbin.com/ititac/10/edit

Is there any way to fix that?

thanks for your help....
joelupet is offline   Reply With Quote
Old 10-07-2012, 02:53 PM   PM User | #4
sunfighter
Senior Coder

 
Join Date: Jan 2011
Location: Missouri
Posts: 2,498
Thanks: 18
Thanked 361 Times in 360 Posts
sunfighter is on a distinguished road
I used in-line styling
Code:
<div class="product_thumb ">
    <a href="javascript:void(0)">
    <img style="margin-top:0;" src="http://cdn.shopify.com/s/files/1/0174/5504/products/action-form-medium-144_small.jpg?4889" alt="Adjustoform Action Form Mannequin Size 16 - 22" rel="lightbox-images">
    </a>
</div>
But it would be better to add a class for vertical images that do this in the css
sunfighter is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:10 AM.


Advertisement
Log in to turn off these ads.