We would like to know how to hove to add border in a div.
<!DOCTYPE html>
<html>
<head>
<style type='text/css'>
div {<!-- ww w.j a v a 2 s . co m-->
background: pink;
width: 300px;
height: 200px;
}
div:hover {
border: 4px solid #000;
}
</style>
</head>
<body>
<div>
<span></span>
</div>
</body>
</html>
The code above is rendered as follows: