Pure CSS Pull-down Menu implementation code

Source: Internet
Author: User
Tip: You can modify some of the code before running

<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <ptml xmlns=" http://www.w3.org/1999/xhtml "> <pead> <meta http-equiv=" Content-type "content=" text/html; Charset=iso-8859-1 "/> <title>horizontal drop-down CSS menu</title> <style> body {Behavior:url (CS SHOVER.HTC); font-size:11px; Font-family:arial, Helvetica, Sans-serif; } p a {color: #000; Text-decoration:underline!important; a{color: #000; Text-decoration:none; } p a:hover{text-decoration:none!important;} Ul#nav {list-style:none; padding:0; margin:0; } Ul#nav li a {display:block; Font-weight:bold; PADDING:2PX 10px; Background: #f9f9f9; Ul#nav li a:hover{background: #888; Color: #fff; } ul#nav li {float:left; position:relative; width:100px; Text-align:center; margin-right:5px; border:1px solid #ccc; Ul#nav li.current a{background: #ddd; } Ul#nav li.current a:hover{ Background: #888; Li ul {display:none; Position:absolute; width:100px; top:0; left:0; Font-weight:normal; padding:1px 0 10px 0; margin-left:-1px; } ul#nav li Ul.sub li{border-width:0 1px 1px 1px!important; Ul#nav Li Ul.sub li a{font-weight:normal!important; } li>ul {Top:auto; Left:auto; Li:hover ul, Li.over ul {display:block;} </style> </pead> <body> <p>more script and CSS St Yle:www.111cn.net </p> <ul id= "nav" > <li class= "current" >Home</li> <li>services <ul class= "Sub" > <li> webdesign ">Webdesign</li> <li> developement" >d evelopment</li> <li> Illustration ">Illustration</li> <li> Search Engine" >s Earch engine</li> <li> Wordpress ">Wordpress</li> </ul> </li> <l I>blog <ul class= "sub" > <li> ThemEs ">Themes</li> <li> Plugins" >Plugins</li> </ul> </li> <li>c ontact</li> </ul> <p> </p> </body> </ptml> </td> </tr> </tabl E>
Tip: You can modify some of the code before running
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.