Unordered lists <ul>

liunx

Guest
When working with unordered lists, is there anyway to have a font tag apply to the entire list rather then applying and closing the font tag within each <li> line? Doing it like this seems to be the only way I can get it to validate, however it seems like alot of extra work for pages with lots of lists:<br />
<br />
<ul><br />
<li><font face="arial, helvetica" size="2" color="#000000">02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.aaa.com/">aaa</a></font></li><br />
<li><font face="arial, helvetica" size="2" color="#000000">02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.bbb.com/">bbb</a></font></li><br />
<li><font face="arial, helvetica" size="2" color="#000000">02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.ccc.com/">ccc</a></font></li><br />
</ul><br />
<br />
Thanks. The actual code is at <!-- w --><a class="postlink" href="http://www.sleazeroxx.com">www.sleazeroxx.com</a><!-- w --> if you want to see the entire thing<!--content-->Try this:<br />
<STYLE TYPE="text/css"><br />
<!--<br />
A:link { text-decoration: none; color: #000000 }<br />
A:visited { text-decoration: none; color: #990000 }<br />
A:active { text-decoration: none; color: #0000FF }<br />
A:hover { text-decoration: underline; color: #FF0000 }<br />
<br />
<br />
.klgrn {background-color: #669999;}<br />
.klgl {background color: #FFCC00;}<br />
li {font-family:verdana, tahoma, arial, ms sans serif;font-size:12pt;color: #FF0000}<br />
.licol {font-family:verdana, tahoma, arial, ms sans serif;font-size:12pt;color: #FF0000}<br />
.menu {font-family:verdana, tahoma, arial, ms sans serif;font-size:9pt;}<br />
BODY { scrollbar-3d-light-color:#FFFFFF;<br />
scrollbar-arrow-color:#FFFF33;<br />
scrollbar-base-color:#e39be3;<br />
scrollbar-dark-shadow-color:#333333;<br />
scrollbar-face-color:#a40616;<br />
scrollbar-highlight-color:#999999;<br />
scrollbar-shadow-color:#cec553}<br />
--><br />
</STYLE><br />
<br />
</HEAD><br />
<br />
<br />
<ul><br />
<li>02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.aaa.com/"> <span class="licol">aaa </span></a></li><br />
<li>02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.bbb.com/">bbb</a></li><br />
<li>02/18: <a href=http://www.htmlforums.com/archive/index.php/"http://www.ccc.com/">ccc</a></li></ul><br />
<br />
:rocker:<!--content-->You can set the settings of the LI or UL elements<br />
<br />
example:<br />
<br />
<style><br />
UL { font-family: times, font-size: 20px; color: red; }<br />
</style><br />
<br />
<UL><br />
<LI>Here it is</LI><br />
<LI>Here again</LI><br />
<UL><br />
<br />
You could also create class style defintions:<br />
<br />
<style><br />
.UL1 {font-family: times, font-size 18px; }<br />
.UL2 {font-family: courier, font-size 8px;}<br />
</style><br />
<br />
<UL class="UL1"><br />
<LI>Here it is </LI><br />
<LI>Here again</LI><br />
</UL><br />
<br />
<UL class="UL2"><br />
<LI>Here it is </LI><br />
<LI>Here again</LI><br />
</UL><!--content-->In the early days of HTML I remember having to fiddle around with stuff like:<br />
<basefont face="" size="" color=""> which was supported in most browsers at that time.<br />
<br />
The <basefont> tag is deprecated in HTML 4 onwards, so can no longer be recommended.<br />
<br />
The CSS method, mentioned above, is much more flexible, and just as easy to implement, but do make sure that you check your CSS for errors by running it through: <!-- m --><a class="postlink" href="http://jigsaw.w3.org/css-validator/validator-uri.html">http://jigsaw.w3.org/css-validator/validator-uri.html</a><!-- m --><!--content-->Thanks guy...you saved me a bunch of work again!!<!--content-->damn you guys beat me to the answer again!<!--content-->hm it didnt star that out! i wonder... no i wont try, i might get banned!<!--content-->
 
Back
Top