diff options
| author | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2007-05-18 12:35:28 +0000 |
|---|---|---|
| committer | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2007-05-18 12:35:28 +0000 |
| commit | 69c1c6c417df6157811e37bd40e5cb4a044b802d (patch) | |
| tree | d40d680816ad77bcd05dd213fc9b3ae1aa4524a0 /roundcubemail/program/steps/mail/func.inc | |
| parent | 32ab9a66704ad121283037fd32f9fd503b682925 (diff) | |
Better refresh of message list; improved HTML mail display
git-svn-id: https://svn.roundcube.net/trunk@575 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/steps/mail/func.inc')
| -rw-r--r-- | roundcubemail/program/steps/mail/func.inc | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/roundcubemail/program/steps/mail/func.inc b/roundcubemail/program/steps/mail/func.inc index fc1741700..cc1187bd9 100644 --- a/roundcubemail/program/steps/mail/func.inc +++ b/roundcubemail/program/steps/mail/func.inc @@ -1207,16 +1207,18 @@ function rcmail_sanitize_html($body, $container_id) $body = preg_replace('/<a\s+([^>]+)>/Uie', "rcmail_alter_html_link('\\1');", $body); // add comments arround html and other tags - $out = preg_replace(array('/(<\/?html[^>]*>)/i', - '/(<\/?head[^>]*>)/i', - '/(<title[^>]*>.*<\/title>)/Ui', - '/(<\/?meta[^>]*>)/i'), - '<!--\\1-->', - $body); + $out = preg_replace(array( + '/(<!DOCTYPE.+)/i', + '/(<\/?html[^>]*>)/i', + '/(<\/?head[^>]*>)/i', + '/(<title[^>]*>.*<\/title>)/Ui', + '/(<\/?meta[^>]*>)/i'), + '<!--\\1-->', + $body); - $out = preg_replace(array('/(<body[^>]*>)/i', - '/(<\/body>)/i'), - array('<div class="rcmBody">', + $out = preg_replace(array('/<body([^>]*)>/i', + '/<\/body>/i'), + array('<div class="rcmBody"\\1>', '</div>'), $out); |
