if(window.addEventListener) { window.addEventListener('message',function(event) { if(event.origin !== 'http://celticconnections.azurewebsites.net') return; if(!event.data || isNaN(event.data)) return; var iframe = document.getElementById('WidgetFrameContainer'); var height = parseInt(event.data); iframe.height = height + 'px'; }, false); } else if(window.attachEvent) { window.attachEvent('onmessage',function(event) { if(event.origin !== 'http://celticconnections.azurewebsites.net') return; if(!event.data || isNaN(event.data)) return; var iframe = document.getElementById('WidgetFrameContainer'); var height = parseInt(event.data); iframe.height = height + 'px'; }, false); } document.write('');