3
I have a div that is part of a link that are inside another div, I wanted if it passed the cursor in any part of the div there is apply both in the text of the link and the inside div.
The Hover is working only separately and I can’t even get one to make the two work together.
Does anyone have any idea how I do it?
.pokeBolaIn{
background:grey;
color:black;
border-radius:100px;
height:20x;
width:20px;
text-align: center;
float: left;
}
.pokeBolaOut{
position:absolute;
}
.pokeBolaOut a{
color: black;
text-decoration: none;
}
.pokeBolaOut a:hover{
color: red;
}
.pokeBolaOut a .pokeBolaIn:hover{
background:red;
color:white;
}
<div class="pokeBolaOut">
<a href="#"><div class="pokeBolaIn">+</div>Confira nosso portifólio</a>
</div>
It worked perfectly, thank you!
– Jefferson Hillebrecht
Actually it was just adding the css that worked with div.
– Jefferson Hillebrecht
@Jeffersonhillebrecht It’s just weird for me to put one
div
within aa
. And I can’t confirm it, but it feels wrong.– Leon Freire
I am limited by a css done before, which applies to spans and does not get the effect I want, so I could not use it. :/
– Jefferson Hillebrecht
@Leonfreire is weird, but from HTML 5 elements began to be allowed block within an element
a
if the parent element of this allows elements block. Before HTML 5 it would be wrong, yes, to use adiv
within aa
. Vide recommendation W3C.– Woss