Is it possible to parallax an img tag rather than background image in a div?

Matt picture Matt · Jun 30, 2013 · Viewed 8.6k times · Source

I've come across a number of parallaxing tutorials (this one in particular I'm looking at now: http://net.tutsplus.com/tutorials/html-css-techniques/simple-parallax-scrolling-technique/); however, they all seem to involve a background image in a <div> that's fixed. Is is possible to achieve a similar parallax effect if my image is in a <img> tag?

Answer

Web Develop Wolf picture Web Develop Wolf · Jun 30, 2013

Provided you use the same attributes then yeah sure it can

An example of this can be seen here: http://webdesign.tutsplus.com/tutorials/complete-websites/create-a-parallax-scrolling-website-using-stellar-js/