0

I needed to use CSS3 rounded corners in a recent project, but it also needed to work in IE7+. I ended up using jQuery Corners which works great. It simply applys CSS3 if it is available, or does other magic if not. The problem is, it doesn't always like to work on hidden elements, layered things, etc etc. The project now requires box-shadow as well which leads me to the question.

Are there any good widely used "hacks" to get the basic CSS3 properties in IE7+ ? Javascript based hacks are fine, but CSS based would be great. Thanks!

Shane Reustle
  • 8,633
  • 8
  • 40
  • 51

2 Answers2

3

You should check out CSSPIE. It does rounded corners using IE proprietary stuff under the covers.

Michael Mullany
  • 30,283
  • 6
  • 81
  • 105
0

Modernizr (http://www.modernizr.com/) might be what you're after. Selectivizr (http://selectivizr.com) is also pretty handy.

DaveN
  • 140
  • 11
  • Thanks! I have used modernizr once or twice, but was hoping to find some popular ways to get the actual CSS3 features in IE7+. I know I've seen them before, just not sure what is popular. – Shane Reustle Dec 10 '10 at 22:45
  • Modernizr is included with a ton of HTML5 templates, including the Boiler Plate ones, so it's not surprising that it's popular. I've seen a few other libraries too, but none as complete. – DaveN Dec 10 '10 at 22:51
  • But on Modernizrs website, in the "What Modernizr Doesn't Do", it says "Modernizr does not add missing functionality to browsers". That is what I'm looking for. – Shane Reustle Dec 10 '10 at 22:55
  • I wasn't entirely sure, that's why I suggested Selectivizr too. Is there something specific you're after that those two don't cover? – DaveN Dec 10 '10 at 22:59
  • Selectivizr only does css3 selectors, not effects like border-radius and box-shadow – Shane Reustle Dec 10 '10 at 23:01
  • Ah, well, Selectivizr is great for working out which features aren't available - and then it's over to you to implement. I'm not aware of any libraries which plug-up the feature gaps comprehensively. There is however a good post on here about getting CSS3 features in IE7 (including rounded corners) http://stackoverflow.com/questions/2687804/emulating-css3-border-radius-and-box-shadow-in-ie7-8 – DaveN Dec 10 '10 at 23:09