- This topic is empty.
January 31, 2012 at 4:47 pm #36431oceantrainMember
Is there any hack, trick or way to get nth Child to work in in I.E. 7 & 8 ??? Or some variation of this? I need to hide certain rows in a table and nth child is not working in I.E. 7 or 8.January 31, 2012 at 4:50 pm #95826tobeeornotMember
i don’t think so.January 31, 2012 at 5:01 pm #95827TheDocMember
Here’s a write that Chris did. You’ll want to pay particular attention to the last paragraph that I quoted:
nth-child is one of those rather unfortunate CSS attributes that is caught between nearly full cross-browser compatibility, except for completely zero support in IE, even IE 8. So when it comes to it’s use, if the end result is “progressive enhancement” in some fashion (e.g. applying a cool color palette to table rows, for example), then by all means, go for it. But you probably shouldn’t use it if you are doing something more important, like relying on it for site structure. For example, removing the right margin from every third box in a three by three grid of boxes, so they will fit properly.
One saving grace here is that if you are using jQuery, which supports all CSS selector including :nth-child, the selector will work, even in Internet Explorer.January 31, 2012 at 7:48 pm #95840oceantrainMember
Thanks @TheDoc. Any links or tips on using Jquery to hide nth child elements? This is what I need if it works in old IE.February 1, 2012 at 1:51 am #95855jamygoldenMemberFebruary 2, 2012 at 1:23 pm #96005rifatlasMember
Check the links for a simple workaround:
Poor man’s nth-child selector for IE 7 and 8February 3, 2012 at 1:23 am #96077jamygoldenMember
@cnwtx did you do anything special or just link to the library? :p
I don’t know why this wasn’t working last time I tried. I’ve also had problems trying to get web-pages to be responsive in IE with Modernizr ( after respond.js was added ).October 16, 2012 at 4:57 am #111968Historical Forums UserParticipant
I think this maybe useful http://www.thebrightlines.com/2010/01/04/alternative-for-nth-of-type-and-nth-child/
- The forum ‘CSS’ is closed to new topics and replies.