The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> CSS Table Styling, Styling not being picked up
mathceleb
post Nov 16 2008, 04:33 PM
Post #1


Member
***

Group: Members
Posts: 30
Joined: 4-October 08
Member No.: 6,807



I've made some changes in my .css file, and my tables are not picking up the .css styles. I have <table id="orig"> which links to this .css file below. My tables are not showing the borders. Any assistance would be helpful:

/* V3 */

*{
list-style:none;
margin:1px;
padding:0px;
border-size: 1px;
}


#menu {
width: 200px;
float: left;
border-size: 1px;
margin-right: 2em;
}

#menu li a {
height: 32px;
voice-family: "\"}\"";
voice-family: inherit;
height: 24px;
font-weight: bold;
text-decoration: none;
}

#menu li a:link, #menu li a:visited {
color: #B40404;
display: block;
background: url(v3.JPG);
background-repeat:no-repeat;
padding: 8px 0 0 10px;
}

#menu li a:hover {
color: #0e69be;
background: url(v3.JPG) 0 -32px;
background-repeat:no-repeat;
padding: 8px 0 0 10px;
border:1px solid #000000;
}

#menu li a:active {
color: #B40404;
background: url(v3.JPG) 0 -64px;
background-repeat:no-repeat;
padding: 8px 0 0 10px;
}

p {
font-size : 12px;
font-family : times new roman;
color : #000000;
text-align : left;
margin : ;
}

h3 {
font-family : times new roman;
color : #000000;
text-align : left;
}

h2 {
font-family : times new roman;
color : #000000;
text-align : left;
}

h1 {
font-family : times new roman;
color : #000000;
text-align : left;
}

body {
font-size : 12px;
font-family : times new roman;
color : #000000;
background : #ffffff url() fixed repeat;
}

blockquote {
font-size : 10px;
font-family : arial;
color : #000000;
text-align : left;
}

a:hover {
font-weight : normal;
font-size : 12px;
font-family : times new roman;
color : #ff0000;
background : normal;
text-decoration : bold;
}

a:visited, a:link, a:active {
font-weight : normal;
font-size : 12px;
font-family : times new roman;
color : #0000ff;
text-decoration : bold;
}

table #orig
{
font-family: arial;
font-size: 12pt;
background-color: white;
border-style: solid;
border-color: blue;
padding: 3px;
}

th #orig
{
border-width: 3px;
border-style: solid;
border-color: blue;
padding:2px;
}

td #orig
{
border-width: 3px;
border-style: solid;
border-color: blue;
padding: 3px;
}

User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Nov 16 2008, 05:18 PM
Post #2


Don't like donuts. Don't do MySpace.
********

Group: WDG Moderators
Posts: 7,207
Joined: 9-August 06
Member No.: 6



Start with correcting the validation errors.
http://jigsaw.w3.org/css-validator/validat...;usermedium=all
If that doesn't help, please post the URL to the problem page.


--------------------
“Never go to excess, but let moderation be your guide.”
– Cicero
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Frederiek
post Nov 17 2008, 03:14 AM
Post #3


Programming Fanatic
********

Group: Members
Posts: 1,799
Joined: 23-August 06
From: Europe
Member No.: 9



What the W3C CSS Checker doesn't see, but what the WDG Validator (link on this page) would have noticed, is that an ID must be unique in a page. You use #orig three times. You could use it as a class instead.


--------------------
"The earth does not belong to Man, it is Man who belongs to the earth"
from Vue du ciel (in French)

"Leave scepticism to others and take action"
from HOME by Goodplanet

An inconvenient truth by Al Gore
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
pandy
post Nov 17 2008, 03:34 AM
Post #4


Don't like donuts. Don't do MySpace.
********

Group: WDG Moderators
Posts: 7,207
Joined: 9-August 06
Member No.: 6



Hmm. I also have a feeling you mean 'table#orig' and so on rather than 'table #orig'. The latter selects an element with the id 'orig' that is contained in a table. It doesn't select the table itself, not even if it has the id 'orig' (unless it's nested inside another table).

http://htmlhelp.com/reference/css/structure.html
http://www.w3.org/TR/CSS2/selector.html




--------------------
“Never go to excess, but let moderation be your guide.”
– Cicero
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
mathceleb
post Nov 17 2008, 10:10 AM
Post #5


Member
***

Group: Members
Posts: 30
Joined: 4-October 08
Member No.: 6,807



QUOTE(pandy @ Nov 17 2008, 02:34 AM) *

Hmm. I also have a feeling you mean 'table#orig' and so on rather than 'table #orig'. The latter selects an element with the id 'orig' that is contained in a table. It doesn't select the table itself, not even if it has the id 'orig' (unless it's nested inside another table).

http://htmlhelp.com/reference/css/structure.html
http://www.w3.org/TR/CSS2/selector.html


Thank you, that worked like a charm.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 21st November 2009 - 02:23 AM