Testing in IE on OS X
Recently I realised that this site was badly broken on Internet Explorer. I guess I'd been working under the assumption that if it works in Chrome, Firefox, Safari and Opera, then it's probably OK in IE as well. Whoa, bad assumption.
Admittedly, some - OK, all of it was my fault. Part of it was that I had non-standard // comments in my css. In my version of Vim, css syntax highlighting shows a //'d line as a comment, so I assumed they were standard. Just quietly, I'm not really a web developer. Turns out that while adding // at the start of the line is not a valid comment, it does cause most browsers to discard the line as invalid. Except IE.
Another problem I ran into was that I hadn't been sending the
<!DOCTYPE html... thingy at the start. This meant IE decided I clearly didn't know what I was doing (arguably true, but a bit rich from IE). Hence it wasn't parsing in 'strict' mode but in 'quirks' mode, which basically seems to mean it does what it likes. Anyway, for some unknown reason this was messing with the jQuery menu in the left sidebar, among other things.
Also, IE8 at least seems to be easily confused by floating divs. It had a problem with me having floated divs inside a parent div without an explicit min-width set on the parent.
Anyway, in order to fix all this stuff I had to test on IE, which is easier said than done on a mac. Luckily there is a way, though, using Oracle's VirtualBox and some free VM's from Microsoft. I also needed to point the VM hosts file to localhost. So now I can use IE on my mac. Goody.