# This patch file was generated by NetBeans IDE
# Following Index: paths are relative to: /home/enrico/public_html/roundcubemail-trunk/roundcubemail/program/steps/mail
# This patch can be applied using context Tools: Patch action on respective folder.
# It uses platform neutral UTF-8 encoding and \n newlines.
# Above lines and this line are ignored by the patching process.
Index: get.inc
--- get.inc Base (BASE)
+++ get.inc Locally Modified (Based On LOCAL)
@@ -135,10 +135,18 @@
       header("Content-Disposition: $disposition; filename=\"$filename\"");
 
       // turn off output buffering and print part content
+      $body = null;
       if ($part->body)
-        echo $part->body;
+        $body = $part->body;
       else if ($part->size)
-        $IMAP->get_message_part($MESSAGE->uid, $part->mime_id, $part, true);
+        $body = $IMAP->get_message_part($MESSAGE->uid, $part->mime_id, $part);
+      else
+        // @todo: error?
+      
+      if($browser->ie && $browser->ver <= 8)
+        $body = preg_replace("/\<[\/]?(iframe|script|html)\>/i", "", $body);
+      
+      echo $body;
     }
 
     exit;
