I summed up a CSS rule, any change in CSS effects, always in different states between the transition, as long as the rules of the different states of the style is good
<!DOCTYPE HTML><HTML><Head><MetaCharSet= "gb2312" /><title>Hover to display transparent text content</title><style>. xuanting{width:220px;margin:0 Auto;Height:240px;background:URL (./images/lf.jpg) No-repeat;cursor:Pointer;position:relative;Overflow:Hidden*/* Hide text content while no hover * *}. xuanting Span.neirong{width:100%;Height:100%; /*Absolute Positioning*/position:Absolute;Top:100%; Left:0; /*font Settings*/Color:#ff4d4d;background:#e5e5e5;Opacity:0.4;text-align:Center; /*animation effects*/transition:top 1s ease-out;-webkit-transition:top 2s ease-out;}. Xuanting:hover Span.neirong{Top:0;}</style></Head><Body> <Divclass= "Xuanting"> <spanclass= "Neirong">I want to be a man of the king of Thieves.</span> </Div></Body></HTML>
Hover to display transparent text content