squizlabs/HTML_CodeSniffer — pull request #16 by lwright-sq (2012-07-04 06:52:36+00:00)
Title: Fix IE8 bug with issue handling in Auditor for iframe document elements

Fix an IE8 error in cases where the element affected is a document object, but not the top-level document.

We already have a short-circuit for the top-level document (as IE does not like document objects being the parameter of a contains call) but this doesn't work for frames. Instead, check for a defined documentElement property.