I’ve added a sliding menu to a site I’m working on but the sliding effect isn’t working in IE8 at all and I didn’t know if anybody had any suggestions? I know the best thing would be to drop IE8 completely, but (despite me telling the client IE8 isn’t supported anymore) they still want to use it!
JS is not my strong point either, but there are people here who know it well and should be able to help. It’s a fairly standard thing to show/hide menus. There must be plenty of examples around.
You’d need to replace the :checked pseudo-class with an actual .checked class, which you then toggle within a click handler. Here’s a fiddle. (Disclaimer: I don’t have the possibility to test it on IE, though.)
Edit: Crap. I just read that the .classList property is not supported in IE < 10. Wait, I’ll see what might work.
Ok, this could work: updated fiddle. According to the MDN, the .className property is supported by any IE.
IE* doesn’t support JavaScript - it was the last IE version that didn’;t - it only supports JScript (the IE proprietary language that looks a bit like JavaScript until you look at it more closely)