Immagini che si ingrandiscono al passaggio del mouse

« Older   Newer »
  Share  
glocchan.
view post Posted on 5/7/2012, 21:49     +1   -1




Il codice è questo.
CODICE
<a class="thumbnail" href=><img src=LINK IMMAGINE PICCOLA width="16px" height="53px" border="0" /><span><img src=LINK IMMAGINE GRANDE CHE COMPARE AL PASSAGGIO DEL MOUSE /><br />TESTO</span></a>


Potete mettere l'immagine piccola o mettere la stessa immagine che dovrebbe rimpicciolirsi automaticamente.
Per far si che il codice funzioni, però
Per prima cosa andate in Amministrazione -> Colori e stili e aggiungete questo codice:


CODICE
<style type="text/css">

.thumbnail{
position: relative;
z-index: 0;
}

.thumbnail:hover{
background-color: transparent;
z-index: 50;
}

.thumbnail span{ /*CSS for enlarged image*/
position: absolute;
background-color: lightyellow;
padding: 5px;
left: -1000px;
border: 1px dashed gray;
visibility: hidden;
color: black;
text-decoration: none;
}

.thumbnail span img{ /*CSS for enlarged image*/
border-width: 0;
padding: 2px;
}

.thumbnail:hover span{ /*CSS for enlarged image on hover*/
visibility: visible;
top: 0;
left: 60px; /*position where enlarged image should offset horizontally */

}

</style>


Ed è fatta! :D
 
Top
ƒ a d e
view post Posted on 6/7/2012, 09:50     +1   -1




aggiungerei che si può mettere tutto in HTML in cima al forum, in maniera tale da non dover inserire nuovamente il codice.
 
Top
glocchan.
view post Posted on 9/7/2012, 10:48     +1   -1




Yeeep °3°
 
Top
2 replies since 5/7/2012, 21:49   104 views
  Share