Jump to content

CSS3 Background Image Scale


biggieuk

Recommended Posts

Hi all,

 

I have a background image which I would like to animate as a 'pulse' effect using CSS3. Is it possible to animate the background image only ans not the container div?

 

I would usually use this code but it will only scale the div not the bg image.

 

@-webkit-keyframes pulse {
from {
	-webkit-transform: scale(1.0);
	opacity: 0.75;
}
50% {
	-webkit-transform: scale(1.1);
	opacity: 1.0;
}
to { 
	-webkit-transform: scale(1.0);
	opacity: 0.75;
}
}

.pulse:hover { 
-webkit-animation-name: pulse; 
-webkit-animation-duration: 0.5s; 
-webkit-animation-iteration-count: 10; 
}

 

Any ideas?

Link to comment
https://forums.phpfreaks.com/topic/225866-css3-background-image-scale/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.