View RSS Feed

molendijk

A close button (and text) on top of a fluid centered image II

Rate this Entry
I learned a few things after I posted this on my blog about putting a close button on top of centered fluid images.
I used jquery and translate in CSS transforms there to do the job. But I found that it can also be done with the help of a combination of window.innerWidth/Height and element.clientWidth/Height. As window.innerWidth/Height and element.clientWidth/Height are also supported by older browser, a technique using these methods must be preferred. Demos and explanations here.

Submit "A close button (and text) on top of a fluid centered image II" to del.icio.us Submit "A close button (and text) on top of a fluid centered image II" to StumbleUpon Submit "A close button (and text) on top of a fluid centered image II" to Google Submit "A close button (and text) on top of a fluid centered image II" to Digg

Updated 04-10-2015 at 10:52 PM by molendijk

Tags: None Add / Edit Tags
Categories
Uncategorized

Comments