I'm making use of the following code:
.c-1:first-child, .c-2:first-child, .c-1:nth-child(4n+1) { margin-left: 0; }
which is working great but I need to mimic this for browsers that do not support nth-child, like IE8.
I have tried this jQuery code to add a class but nothing happens, is this code right?
// Support nth child in IE8
$('.c-1:first-child').addClass('remove');
$('.c-2:first-child').addClass('remove');
$('.c-1:nth-child(4n+1)').addClass('remove');