0
all good? I have the following problem with mouse Hover, I started to see some html and css lessons and I am with a personal project, I made a simple code just to study mouse Hover but it doesn’t work properly, I tried display: None/block, visibility: Hidden, filter: opacity and nothing the mouse Hover does not work, being that it is from one class to another.
This is the code:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8"/>
<title>Document</title>
</head>
<body>
<div class="mapa"><a class="loja"></a></div>
<div class="descri">LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM
IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM
IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM IPSUM LOREM
IPSUM LOREM IPSUM </div>
</body>
</html>
<style type="text/css">
.mapa {
width: 500px;
height: 500px;
background: green;
float: left;
}
a.loja {
width: 20px;
height: 20px;
background: black;
position: absolute;
border-radius: 100px;
margin-top: 29px;
margin-left: 53px;
transition: 1s;
}
a.loja:hover {
cursor: pointer;
background: red;
}
a.loja:mouseover .descri{
display: block;
}
.descri {
width: 300px;
height: 300px;
float: left;
background: black;
color: white;
text-align: justify;
padding: 21px;
font-size: 10px;
display: none;
}
Would someone kindly tell me where I’m going wrong?
Grateful.
Good afternoon, there is no css mouseover. There is onmouseover but this is an HTML event and is used in the tag. Usually used to call a javascript function.
– IanMoone
In CSS what exists is Hover, but on that there is already an answer below
– IanMoone