summaryrefslogtreecommitdiff
path: root/program/steps
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2009-08-27 08:09:00 +0000
committerthomascube <thomas@roundcube.net>2009-08-27 08:09:00 +0000
commit6c2d7ed24343e510c2e0bd3e754436c48a4623a8 (patch)
tree4158ff02e92e7b6eb8249deaca8ee333901ea7b8 /program/steps
parent0816567dac1beb14bd5abc95a67f915583a99f33 (diff)
Strip xmlns attributes from html tag
Diffstat (limited to 'program/steps')
-rw-r--r--program/steps/mail/func.inc2
1 files changed, 2 insertions, 0 deletions
diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc
index 784b8f399..87f7bc42f 100644
--- a/program/steps/mail/func.inc
+++ b/program/steps/mail/func.inc
@@ -676,11 +676,13 @@ function rcmail_wash_html($html, $p = array(), $cid_replaces)
'/(<\/nobr>)(\s+)(<nobr>)/i', // space(s) between <NOBR>
'/<title>.*<\/title>/i', // PHP bug #32547 workaround: remove title tag
'/^(\0\0\xFE\xFF|\xFF\xFE\0\0|\xFE\xFF|\xFF\xFE|\xEF\xBB\xBF)/', // byte-order mark (only outlook?)
+ '/<html\sxmlns:[a-z]=[^>]+>/i', // washtml/DOMDocument cannot handle xml namespaces
);
$html_replace = array(
'\\1'.' &nbsp; '.'\\3',
'',
'',
+ '<html>',
);
$html = preg_replace($html_search, $html_replace, $html);