View Full Version : I cant make a table cascade to page

11-26-2008, 03:01 AM
Im tring to make a cascading style sheet and cant get it to work with tables , I can get other styles to work but when I make a tabl on the page ity wont cascade to the next page Im tring to keep it simple to understand it. the code below is an example if I save it as a "main.css" then save another page
as a .html and add <link ref="stylesheet" type="text/css" href="main.css"> to the head section of the .html. everything seems to work then if I change lets say the table size on the "main.css" page it doesnt change on the copied .html

I just cant figure it out Ive been able to make this work with simple colors and fonts and it works. Basically I am tring to cascade an entire page so if i decide to change the look i can by changing one page is the a code I can place that makes this possible. I hope this make scence If not I understand Its confusing me and I wrote it...lol thanks for any help

<style type="text/css">
table-layout: automatic

<table class="one" border="1" width="100%">
<TD> one</TD>
<TD> two </TD>
<TD> three </TD>
<TD> four </TD>

11-26-2008, 03:10 AM
Hello bostonryan,
It sounds like your trying to save your table as a .css file and then link to it in an .hmtl file. That's not going to work.

-The code you quote there is not a css file. Save it as .html.
-Make an empty file called main.css (your using notepad, right?) and put the following in it:

body {
background: #ccc;
-link to your main.css inside the head of all your html files. It looks like the link you posted will work fine as long as the path points to where you put main.css

Now the html documents that are linked to main.css will have a #ccc (gray) background.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum