.ww_btnWithMenu { position:relative; display:inline-block; cursor:pointer; } .ww_btnWithMenu .smart_menu_box,.ww_btnWithMenu .ww_dropdownMenu { position:absolute; min-width:80px; top:17px; left:13px; } .ww_dropdownMenu { padding:2px 0; border-radius:2px; -webkit-box-shadow:0 1px 6px 0 rgba(0,0,0,.3); box-shadow:0 1px 6px 0 rgba(0,0,0,.3); } .qui_dropdownMenu,.smart_menu_box { position:absolute; z-index:30; background:#FFF; border:none; } .qui_dropdownMenu ul,.smart_menu_box ul { padding:0; } li,ol,ul { list-style:none; text-align:center; -float:left; padding:5px 5px; } ul { /*width:120px; */ } .ww_dropdownMenu_item { text-align:left; } .ww_btnWithMenu .smart_menu_box,.ww_btnWithMenu .ww_dropdownMenu .acssv1 { color:Black; text-decoration:blink; } .acssv1:hover { cursor:pointer; text-decoration:blink; }
只是简单的利用CSS的绝对定位、相对定位、标签的显示隐藏