Search

Rss Posts

Rss Comments

Login

 

Posts from May, 2009

Detecting Browser CSS Style Support

May 3, 2009

Now I’d normally be the first one to speak out in favour of unobtrusive JavaScript and attempting to keep CSS styling out of JavaScript. Rarely should you need to directly impose CSS styles on an element via the style object, after all that is what class names are for. However there are some styles that are commonly and justifiably manipulated within JavaScript; display, visibility, width, height, top, and left are just a few of the styles often directly manipulated within JavaScript typically for some type of UI component. Of course, some of these styles are not supported in all the mainstream browsers, such as opacity in IE and -moz-transform in Firefox < 3.5. read more »