横向列表菜单
<!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=gb2312" /> <style type="text/css"> body { font-family: Verdana; font-size: 12px; line-height: 1.5; } a { color: #000; text-decoration: none; } a:hover { color: #F00; } #menu { border: 1px solid #CCC; height:26px; background: #eee;} #menu ul { list-style: none; margin: 0px; padding: 0px; } #menu ul li { float: left; padding: 0px 8px; height: 26px; line-height: 26px; } </style> </head> <body> <div id="menu"> <ul> <li><a href="#">首页</a></li> <li><a href="#">网页版式布局</a></li> <li><a href="#">div+css教程</a></li> <li><a href="#">div+css实例</a></li> <li><a href="#">常用代码</a></li> </ul> </div> </body> </html>