Don't use "typeof(window.postMessage)" to determine whether a browser supports the HTML5 postMessage feature - both Internet Explorer 6 and 7 return a value of "function" as the type!
It appears as though IE6 and IE7 have some sort of undocumented function called postMessage that has a completely different purpose. It could cause conflicts if you're not careful when calling this function.