I'm trying to rotate the border lines 45 degrees while keeping the img fixed when you hover over the img.
Any ideas how to do them in css?
As of now, both of my border lines and my img rotates at the same time.
HTML
<div id="button" class="rotate">
<div id="button_box_frame" class="no_rotate">
<a><img src="pics/show_window1.jpg" class="no_rotate"></a>
</div>
</div>
CSS
#button{
margin-left:200px;
margin-top:200px;
border:3px solid;
overflow:hidden;
height:200px;
width:200px;
}
#button_box_frame img{
}
#button img{
}
.rotate{
-webkit-transition-duration: 0.8s;
-moz-transition-duration: 0.8s;
-o-transition-duration: 0.8s;
transition-duration: 0.8s;
-webkit-transition-property: -webkit-transform;
-moz-transition-property: -moz-transform;
-o-transition-property: -o-transform;
transition-property: transform;
overflow:hidden;
}
.rotate:hover
{
-webkit-transform:rotate(45deg);
-moz-transform:rotate(45deg);
-o-transform:rotate(45deg);
}