WordPress Design and Development in Minneapolis, MN

WordPress body_class() Adds Browser-Specific Classes! WOW!

A common problem amongst website developers is the “IE Sucks” problem. That is, different browsers (I’m looking at you, Internet Explorer) process CSS differently. One way to get around these issues is to use a combination of javaScript and CSS to address the issue. In the past, I have used this “CSS Browser” script to manage the javaScript side of things. Well, no more!

I just learned that, as of WordPress 2.8, browser-specific classes are now included in the body_class() function. HOORAY!!!! So, feel free to start writing your CSS for specific browsers!