2012-11-10 3 views

답변

0

브라우저 지원 여부에 따라 accomplished using CSS animations (example)이 될 수 있습니다.

h2 { 
    background: rgba(0, 0, 0, 0.5); 
} 

.image:hover h2 { 
    background: rgba(0, 0, 0, 0.8); 
    -moz-animation: 2s ease 0s normal none infinite pulse; 
    -webkit-animation: 2s ease 0s normal none infinite pulse; 
} 

@-moz-keyframes pulse { 
    0% { color: #000 } 
    50% { color: #FFF } 
    100% { color: #000; } 
} 

@-webkit-keyframes pulse { 
    0% { color: #000 } 
    50% { color: #FFF } 
    100% { color: #000; } 
} 

당신은 오래된 브라우저 지원이 필요한 경우는, 대신 RGBA의 알파 투명도와 PNG 배경 - 이미지를 사용하고, 대신 CSS 애니메이션의 jQuery animate().