Page 1 of 1

CSS noob question

Posted: 2007-01-02 06:40pm
by Sriad
What is the style code stuff I need to drop in my .css file so that images used as links will not have a blue border? Thanks in advance, and if I solve this should-be-easy problem before someone else does I'll say so.

Posted: 2007-01-02 06:56pm
by Sriad
Duh:

Code: Select all

a:link{
	color: white;
	}
with other selectors as needed.

Edit: I changed something and now it won't work after changing it back. Curse you cascading style sheets!

Posted: 2007-01-02 07:39pm
by Beowulf
It should be more along the lines of:

Code: Select all

a img
{
  color:white;
}
I think. Didn't actually test this.

Posted: 2007-01-03 02:50am
by Comosicus
To remove the border altogether, you must do something like this:

Code: Select all

a img {
    border:0;
}
If you want a different border color for the image, use:

Code: Select all

a img {
    border-width:1px;            /*or whatever you require*/
    border-color:#ffffff         /*it is better to stick with a hex code rather than a color name*/
}
For future reference you can take a peek at the following websites:

http://www.w3schools.com/css/css_reference.asp
http://css3.com/