bomfonk
03-13-2008, 09:45 PM
First some general things I've been wondering about:
1. What is the best way to set font size? And what should it be set to? I've seen websites with body font size as 100% and others 70%.
2. What's the difference in using ul#id or #id ul?
3. Why is Opera text always seem to come out smaller then IE and Firefox?
4. When should lists be used? Footers, links, or just plain old lists?
If you have any tips or tricks when using CSS please let me know.
On to my menu question:
I have the following menu, and it works just fine in Firefox however in IE and Opera the right border isn't displayed properly(the left padding isn't applied)
What is the best way to do and fix this type of thing?
URL: http://testwebsite54.bravehost.com/index.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<link href="testcss.css" rel="stylesheet" type="text/css" />
</head>
<body>
<ul id="ala">
<span class="border">1</span>
<li>lorem</li>
<span class="border">2</span>
<li>ispum</li>
<span class="border">4</span>
<li>alabala</li>
</ul>
</body>
</html>
ul#ala {
margin-top: 11px;
font-size: 90%;
line-height: 20px;
}
#ala li {
padding-left: 6px;
}
.border {
float: left;
color: #666666;
border-right-width: 1px;
border-right-style: solid;
border-right-color: #D8D8D8;
padding-right: 6px;
}
ul {
margin: 0px;
padding: 0px;
list-style-type: none;
}
1. What is the best way to set font size? And what should it be set to? I've seen websites with body font size as 100% and others 70%.
2. What's the difference in using ul#id or #id ul?
3. Why is Opera text always seem to come out smaller then IE and Firefox?
4. When should lists be used? Footers, links, or just plain old lists?
If you have any tips or tricks when using CSS please let me know.
On to my menu question:
I have the following menu, and it works just fine in Firefox however in IE and Opera the right border isn't displayed properly(the left padding isn't applied)
What is the best way to do and fix this type of thing?
URL: http://testwebsite54.bravehost.com/index.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<link href="testcss.css" rel="stylesheet" type="text/css" />
</head>
<body>
<ul id="ala">
<span class="border">1</span>
<li>lorem</li>
<span class="border">2</span>
<li>ispum</li>
<span class="border">4</span>
<li>alabala</li>
</ul>
</body>
</html>
ul#ala {
margin-top: 11px;
font-size: 90%;
line-height: 20px;
}
#ala li {
padding-left: 6px;
}
.border {
float: left;
color: #666666;
border-right-width: 1px;
border-right-style: solid;
border-right-color: #D8D8D8;
padding-right: 6px;
}
ul {
margin: 0px;
padding: 0px;
list-style-type: none;
}