LiveWire Peer Support Network

Printable Version of Topic "CSS (No Border on Images)"

- LiveWire Teen Forums & College Forums (http://www.golivewire.com)
-- (http://www.golivewire.com/forums/support-technical.html)
--- Web Design & Search Engine Optimization (http://www.golivewire.com/forums/forum-200-s-0.html)
---- CSS (No Border on Images) (http://www.golivewire.com/forums/peer-ybiaioy-support-a.html)


-- Posted by August Rush at 3:58 pm on May 27, 2009

Internet Explorer and Firefox both place borders around certain images on my blog.

http://www.jamesvarnham.supportbuddies.net/

This does not happen in Chrome and I understand I can fix this by setting a css value to border: 0

How do I set a global stylesheet class / id to fix this?


-- Posted by Trendz at 4:00 pm on May 27, 2009

http://www.htmlcodetutorial.com/images/images_famsupp_216.html


-- Posted by August Rush at 4:04 pm on May 27, 2009

Quote: from trendsetta at 12:00 am on May 28, 2009


http://www.htmlcodetutorial.com/images/images_famsupp_216.html

Thanks, but I need to find how to do this with CSS as i'm using a wordpress template and I need to fix this problem for the whole site.

Thanks though..


-- Posted by Trendz at 4:15 pm on May 27, 2009

Quote: from August Rush at 7:04 pm on May 27, 2009


Quote: from trendsetta at 12:00 am on May 28, 2009

http://www.htmlcodetutorial.com/images/images_famsupp_216.html

Thanks, but I need to find how to do this with CSS as i'm using a wordpress template and I need to fix this problem for the whole site.

Thanks though..


Here's a wizard I found. It should help you.

http://www.somacon.com/p141.php


-- Posted by anonomouse at 1:42 am on June 29, 2009

First--I love that design. It looks really professional. It looks like you've gotten it fixed, though. I can't see any borders in any browser I use. Anyway, it's always good practice to use a CSS Reset whenever you start designing a web page because different browsers have different defaults. I know you didn't design the template, so I'm just posting this to show you how whoever designed it should have fixed it. Apparently they didn't throughly test it...


-- Posted by Daveh at 3:14 am on July 2, 2009

Looks fine, you got it fixed i assume. Here's the code anyway.

Code:

img {
border: 0px;
}

This tells the browser that anything with an image tag shouldn't have a border.

you can remove the border completly on all images using the above code.

The line is most likely caused or can be caused because the image is hyperlinked. So you can set CSS styling to links. which will effect only the image.

Code:
A img{
border: 0px;
}

Any hyperlinked image won't have a border

Code:
A {
border: 0px;
}

all links won't have a border.

Using the below code you can select a certain type of link, which makes it possible for you to change CSS based on the users interaction with the link. This is the best way yo have css effects on text/images such as rollovers.
Code:

A:link
A:visited
A:active
A:hover


www.golivewire.com