Quote:
Originally Posted by Jolt
HORRIBLE code.
Code:
<div style="width: 489px; height: 380px; overflow: scroll; border 0;">
<span style="color: #fff; font: bold 10px Verdana, san-serif;">May.27.2007</span>
<br />
</div>
You can not have a 0px border that is colored. if there's no border it's just 0, don't even need the px.
Your code is a mix of really bad HTML and some CSS. The code above is all CSS. If you REALLY want to stick to the horrible code. Add # at the beginning of the font color (#ffffff) and add closing font tags below the text <font><font><font><b>Date</b></font></font></font> Although i really woud not recommend this method of coding
|
I have to agree with Jolt, and say your css is very poorly written. It's my opinion that inserting css into your html page with the style=" " tag is very sloppy, and unorganized. I suggest making a seperate stylesheet that contains all css aspects of your html page. Then include the css stylesheet into your html page.
For example you could make a special div in a stylesheet just for your divider object. (Look below.)
Code:
#divider {
font-family: Verdana, san-serif;
font-size: 10px;
font-weight: bold;
color: #FFFFFF;
width: 489px;
height: 380px;
border: #000000 0px solid;
}
I know Jolt said that if your border was 0px there wasn't any need to write it in your code. Jolt does post many helpful, and very correct posts. But it just depends on how you organize your border, and where you put it. If you set it up just right, and enter 0px as the size it shouldn't conflict with anything.
I mentioned above about making a seperate stylesheet. Here is an example of a very simple stylesheet.
Code:
style type="text/css">
a:link {
color: #000000;
text-decoration: underline;
}
a:hover {
color: #000000;
text-decoration: none;
}
body {
color: #000000;
font-size: 12;
font-family: Verdana;
}
#divider {
font-family: Verdana, san-serif;
font-size: 10px;
font-weight: bold;
color: #FFFFFF;
width: 489px;
height: 380px;
border: #000000 0px solid;
}
</style>
To apply this stylesheet to an html page place the code below in the <head></head> section of your html page.
Code:
<link rel="stylesheet" href="style.css" type="text/css">
And for one last example... Here is an example of an html table using the #divider div tag from the example stylesheet.
HTML Code:
<table width="489" height="380" div id="divider">
<tr>
<td width="489">Table Content</td>
</tr>
</table>