Topic: Stylesheet not stylin'... (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=10801" title="Pages that link to Topic: Stylesheet not stylin&amp;#039;... (Page 1 of 1)" rel="nofollow" >Topic: Stylesheet not stylin&#039;... <span class="small">(Page 1 of 1)</span>\

 
Petskull
Maniac (V) Mad Scientist

From: 127 Halcyon Road, Marenia, Atlantis
Insane since: Aug 2000

posted posted 08-30-2002 22:36

The stylesheet goes crazy on this page-

<HTML>
<HEAD>
<TITLE>Twisted Port</TITLE>
<LINK HREF="twisted.css" REL=STYLESHEET TYPE="text/css">
</HEAD>
<BODY>

<TABLE width=140px cellspacing=0 cellpadding=0 align=right border=0>
<TR>
<TD>
<TABLE border=0 width=100% cellpadding=6 cellspacing=1>
<TR height=16 valign=middle>
<TH CLASS="navHead">Lorem Ipsum</TH>
</TR>
<TR valign=top>
<TD CLASS="rightnavbod">Lorem ipsum dolor sit amet, <A href="#">consectetaur adipisicing elit</A>, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</TD>
</TR>
</TABLE>
</TD>
</TR>
</TABLE>

</BODY>
</HTML>

--- check out the following quirks:
-=-> when the style is embedded on the table or on the page, the styles work fine.
-=-> when the stylesheet is like the first one it works fine.
-=-> when the stylesheet is like the second one, it don't work
-=-> it just takes the stylesheet info from the TD style and runs with it, no paying any attention to the "rightnavbod" class.

Here the stylesheet that works:
--twisted.css---------------------
.navhead {font-size:11px;color:#FFFFFF;background-color:#2B4C66;font-family:"Verdana";}
.rightnavbod {text-indent:9px;color:#CCCCCC;background-color:#2B4C66;text-align:justify;}
.rightnavbod a{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:none;}

Here's the one that don't:
--twisted.css--------------------
a,TD a{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:none;}
a:hover,TD a:hover{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:underline;}
b,TD b{color:#333333;font-family:verdana;font-size:9px;}
p,TD p{color:#333333;font-family:verdana;font-size:9px;}
h1 {font-size:16px;color:#000000;font-family:"Verdana";}
h2 {font-size:14px;color:#000000;font-family:"Verdana";}
h3 {font-size:12px;color:#000000;font-family:"Verdana";}
h6 {font-size:10px;color:#000000;font-family:"Verdana";margin-bottom:0;}
TD {font-size:9px; color:#0000FF;font-family: "Verdana";}
TH {font-size:9px;color:#FFFFFF;font-family: "Verdana";}

.headbox {color:#CCCCCC}
.headbox a{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:none;}
.headbox a:hover{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:underline;}
.uptop{color:#9900CC}
.uptop a{color:#0000FF;font-family:verdana;font-size:9px;text-decoration:none;}
.uptop a:hover{color:#00FFFF;font-family:verdana;font-size:9px;text-decoration:none;}
.bodsubhead{color:#333333;font-family:verdana;font-weight:bold}
.maintext {font-size:9px;color:#333333;font-family:"Verdana";}
.footer {font-size:9px;color:#333333;font-family:"Verdana";}
.lpl{color:#0000FF;font-family:verdana;font-size:9px;text-decoration:none;}
.lpl:hover{color:#FF0000;font-family:verdana;font-size:9px;text-decoration:underline;}
.navhead {font-size:11px;color:#FFFFFF;background-color:#2B4C66;font-family:"Verdana";}
.navsubhead {font-size:9px;color:#000000;font-family:"Verdana";font-weight:bold;}
.bodhead {font-size:11px;color:#C19732;font-family:"Verdana";text-indent:10px;}
.bodsubhead {font-size:11px;color:#000000;font-family:Verdana";font-weight:bold;}
.rightnavbod {text-indent:9px;color:#CCCCCC;background-color:#2B4C66;text-align:justify;}
.rightnavbod a{color:#FFFFFF;font-family:verdana;font-size:9px;text-decoration:none;}

*************************

Now, if life were peaches and cream, I could simply delete the lines and everything would be fine, but I can't because the rest of the site would fuck up. Also, when I simply delete the TD{} line, I get no formatting in the table whatsoever.

Anyone have any idea what I could do?

{Edit} sorry 'bout the big ol' post, I'll "outsource" it when I get back tonight...


Code - CGI - links - DHTML - Javascript - Perl - programming - Magic - http://www.twistedport.com
ICQ: 67751342

[This message has been edited by Petskull (edited 08-30-2002).]

Phil
Bipolar (III) Mad Scientist

From: Eastbourne, UK.
Insane since: Mar 2000

posted posted 08-30-2002 22:50

Hi PS,

First thing, rectify this......

<LINK HREF="twisted.css" REL=STYLESHEET TYPE="text/css">

to this....


<LINK REL=STYLESHEET HREF="twisted.css" TYPE="text/css">

Then remove the inverted commas from the font family verdana......

example

Yours - .bodhead {font-size:11px;color:#C19732;font-family:"Verdana";text-indent:10px;}

Mine - .bodhead {font-size:11px;color:#C19732;font-family:Verdana;text-indent:10px;}


did that and got a nice dark blue/gray bg around your right nav box.....


Also I would advocate keeping everything in lower case......


Does this help??


Phil




[This message has been edited by Phil (edited 08-30-2002).]

Slime
Lunatic (VI) Mad Scientist

From: Massachusetts, USA
Insane since: Mar 2000

posted posted 08-30-2002 23:12

The line

.bodsubhead {font-size:11px;color:#000000;font-family:Verdana";font-weight:bold;}

is missing a quote before 'Verdana'. The browser thinks everything following 'Verdana"' is inside quotes, and so ignores it.

Petskull
Maniac (V) Mad Scientist

From: 127 Halcyon Road, Marenia, Atlantis
Insane since: Aug 2000

posted posted 08-31-2002 03:08

wow.... that little quote did all that, huh?

..lil' bastard...

I got rid of all the quotes in the file, replaced all 'verdana's with 'Verdana's, and replaced that <LINK> tag Phil was talking about...

...it worked fine after getting rid of the quote, but I figure a little more standards in my code might aid any further debugging...

thanks, guys.. superb as always..


Code - CGI - links - DHTML - Javascript - Perl - programming - Magic - http://www.twistedport.com
ICQ: 67751342



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu