赞
踩
难点:压线效果的处理(元素的层级要分清)
- <!DOCTYPE html>
- <html>
- <head>
- <meta charset="utf-8">
- <title></title>
- <style type="text/css">
- ul,li,p{
- padding: 0;
- margin: 0;
- }
- ul{
- list-style: none;
- }
- a{
- text-decoration: none;
- color: #545454;
- }
- /* 主菜单 */
- p{
- color: #545454;
- border: 1px solid #F3F3F3;
- }
- #menu{
- width: 200px;
- background-color: #f3f3f3;
- position: relative;
- }
- #menu p{
- line-height: 35px;
- text-indent: 20px;
- }
- #menu li.active p{
- border: 1px solid orange;
- border-right: 1px solid #fff;
- background-color: #fff;
- position: relative;
- z-index: 999;
- }
- /* 子菜单 */
- #submenu{
- width: 580px;
- height: 430px;
- border: 1px solid orange;
- position: absolute;
- left: 199px;
- top: 0;
- display: none;
- }
- #menu li.active #submenu{
- disp
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。