align list dropdown - HTML CSS CSS Widget

HTML CSS examples for CSS Widget:UL Alignment

Description

align list dropdown

Demo Code

ResultView the demo in separate window

<html>
 <head> 
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
  <style id="compiled-css" type="text/css">
li {<!--from  w w  w.  j  a va2s.com-->
   padding:11px 21px;
}

.dropdown {
   position:relative;
   display:block;
   background-color:Chartreuse;
   width:121px;
}

.dropdown-menu {
   position:absolute;
   top:100%;
   left:0;
   z-index:1001;
   display:block;
   width:100%;
   padding:0;
   margin:0;
   list-style:none;
   background-color:yellow;
}
</style> 
 </head> 
 <body> 
  <li class="dropdown"> <a class="dropdown-toggle" data-toggle="dropdown" data-target="#" href="#">Lorem ips<b class="caret"></b> </a> 
   <ul class="dropdown-menu"> 
    <li> <a href="#">Lorem ipsum </a> </li> 
    <li> <a href="#">Lorem ipsum dolo</a> </li> 
   </ul> </li>  
 </body>
</html>

Related Tutorials