This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Stylesheets > January 2007 > CSS file does not apply to border types (font/links work though)





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author CSS file does not apply to border types (font/links work though)
VincentCorp@gmail.com

2007-01-27, 11:02 pm

I have a td element in my html file:
<td class="tableborder" width="735" bgcolor="#FFFFFF" valign="top">


If I put inside the HTML file it works fine but I want a central CSS
file.
<Style> .tableborder{border-style: groove;border: 2;border-color:
#FF0000;}</style>




my CSS file which is linked in the html file:
<link href="churchCSS.css" rel="stylesheet" type="text/css">

in churchCSS.css I have:
..tableborder{border-style: groove;border: 2;border-color: #FF0000;}

Unfortunately the style is not picked up, while link styles and other
font styles DO work! I don't understand, please help i've looked
around a good bit.

Beauregard T. Shagnasty

2007-01-27, 11:02 pm

VincentCorp@XXXXXXXXXX wrote:

> I have a td element in my html file:
> <td class="tableborder" width="735" bgcolor="#FFFFFF" valign="top">
>
> If I put inside the HTML file it works fine but I want a central CSS
> file.
> <Style>


Needs to be: <style type="text/css">

>.tableborder{border-style: groove;border: 2;border-color:
> #FF0000;}</style>
>
> my CSS file which is linked in the html file:
> <link href="churchCSS.css" rel="stylesheet" type="text/css">
>
> in churchCSS.css I have:
> .tableborder{border-style: groove;border: 2; ...


2 what? Hobnobs? Slices of pizza? Meters?

You need a unit, such as 2px.

> Unfortunately the style is not picked up, while link styles and other
> font styles DO work! I don't understand, please help i've looked
> around a good bit.


When errors are encountered, browsers are free to either try to
interpret, or ignore.

Suggest you check your work here:
http://jigsaw.w3.org/css-validator/validator.html

...and here for your HTML:
http://validator.w3.org/

--
-bts
-Motorcycles defy gravity; cars just suck
Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews