将鼠标悬停在页面顶部显示深度列表时出现问题,请帮助我
这是html代码
<div id="mymenu" runat="server" >
<ul class="mainmenu">
<li><a>WorkFlow</a>
<ul class="submenu">
<li><a href="# >Employee Apprisail Report</a></li>
<li><a href="#">Attendance Amendment Status Report</a></li>
<li><a href="#">Employee Requisition Report</a></li>
<li><a href="#">Employee Clearance Report</a></li>
<li><a href="#">Employee Hiring Status Report</a></li>
<li><a href="#">Housing Loan Status Report</a></li>
<li><a href="#">Leave Request Annulal Leave Amendments</a></li>
<li><a href="#">Leave Request Annulal Leave Cancellation</a></li>
<li><a href="#">Mobile Allowance Status Report</a></li>
<li><a href="#">Overtime Status Report</a></li>
</ul>
</li>
<li><a>HR</a>
<ul class="submenu">
<li><a href="#">Iqama Report</a></li>
<li><a href="#>Project Time Attendance System</a></li>
<li><a href="#”>Vacation Balance Report</a></li>
<li><a href="#">Electronic Human Resource Mangment System</a></li>
</ul>
</li>
<li><a>Payroll</a>
<ul class="submenu">
<li><a href="#">Manual Attendance System/User Register</a></li>
<li><a href="#">Manual Attendance System Approve/Reject</a></li>
<li><a href="#">Check Print/Report</a></li>
<li><a href="#">Head Of Departmens Attendance Amendment</a></li>
<li><a href=”#">Overtime Payroll Application</a></li>
<li><a href="#">Salary Increment Status Report</a></li>
<li><a href="#”>Payroll Reconciliation Report</a></li>
</ul>
</li>
</ul>
</div>
这是我的CSS(问题)
ul.mainmenu:
{
list-style:none;
}
ul.mainmenu li
{
display: inline-block;
}
ul.mainmenu li a {
text-decoration: none;
background: #ff005a;
color: #fff;
padding: 0.25em;
}
ul.mainmenu li a:hover {
background: #ff00ff;
}
ul.mainmenu li ul.submenu {
list-style: none;
display: none;
}
ul.mainmenu li:hover > ul.submenu {
position: absolute;
display: inline-block;
top: 40px;
}