Hi, I'm not much good in css. I want to create a page where after clickin on a menu option, that option's border-bottom becomes blue. My current code is working for mouse hover and active but not after I leave the mouse.
CSS Code:
body
{
background-image: url("images/temp1.jpg");
background-size: 100% 100%;
background-attachment: fixed;
}
.container
{
text-align: center;
}
.center_div
{
margin-left: 12%;
width: 75%;
height: 100%;
background-color: #ffffff;
}
td.mainmenu
{
border-style: hidden;
width: 15%;
height: 10%;
border-collapse: separate;
border-spacing: 3%;
padding:20px;
padding-left:60px;
}
a.mainmenu
{
text-decoration:none;
color: black;
}
td.mainmenu:hover
{
border-bottom-style:solid;
border-bottom-color:blue;
}
HTML code:
<html>
<head>
<link rel="stylesheet" href="admin_template.css">
</head>
<body>
<div class="container">
<div class="center_div">
<table class="mainmenu">
<tr>
<td class='mainmenu'><a class='mainmenu' href="">Sales</a></td>
<td class='mainmenu'><a class='mainmenu' href='out_of_stocks.php'>Out of Stocks</a></td>
<td class='mainmenu'><a class='mainmenu' href='refill_stock.php'>Refill Stocks</a></td>
<td class='mainmenu'><a class='mainmenu' href='enter_product.php'>New products</a></td>
<td class='mainmenu'><a class='mainmenu' href='admin_so.php'>Sign Out</a></td>
</tr>
<table>
<hr/>
</div>
</div>
</body>
</html>
`