Assuming you are okay with javascript:
<script type="text/javascript">
if(navigator.onLine!==true)
document.getElementsByTagName('iframe')[0].outerHTML='<img src="blah.png">';
</script>
You can use something else instead of document.getElementsByTagName('iframe')[0]
if you have more than one iframe in the page.