Note: There may be a better solution using import, but it does not seem to work when the VML elements are injected into the page. See the ticket on Microsoft Connect.
This is a workaround for using canvas/vml in IE8 Standards mode. If viewed with a version of Internet Explorer greater than 7 then the canvas element is injected into an iframe. Even though the canvas is in an iframe you can still access and draw on it from the parent document.
The source file for the iframe has an empty body. In the head the document mode is set to IE7 Standards and the Mootools and Moocanvas scripts are loaded.
This workaround makes it possible to continue to use canvas/vml in IE8 while not being locked out of the new CSS features in IE8 that can only be accessed in IE8 Standards mode.
This example is using Moocanvas. Something similar could probably be done with Excanvas, though in my initial tests Excanvas worked in only one of the 8 IE8 mode combinations where Moocanvas works in 6.