Changeset 5f8686e in github
- Timestamp:
- Jun 16, 2008 5:53:33 AM (5 years ago)
- Branches:
- master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
- Children:
- ccd944e
- Parents:
- 45469db
- File:
-
- 1 edited
-
program/steps/mail/func.inc (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
program/steps/mail/func.inc
r166b615 r5f8686e 539 539 if(preg_match('/(\s+content=[\'"]\w+\/\w+;\s+charset)=([a-z0-9-]+)/i', $html)) 540 540 $html = preg_replace('/(\s+content=[\'"]\w+\/\w+;\s+charset)=([a-z0-9-]+)/i', '\\1='.RCMAIL_CHARSET, $html); 541 else 541 else { 542 // add <head> for malformed messages, washtml cannot work without that 543 if (!preg_match('/<head>(.*)<\/head>/m', $html)) 544 $html = '<head></head>' . $html; 542 545 $html = substr_replace($html, '<meta http-equiv="Content-Type" content="text/html; charset='.RCMAIL_CHARSET.'" />', intval(stripos($html, '</head>')), 0); 543 546 } 547 544 548 // clean HTML with washhtml by Frederic Motte 545 549 $body = washtml::wash($html, array( … … 701 705 { 702 706 global $CONFIG, $OUTPUT, $MESSAGE, $IMAP, $REMOTE_OBJECTS; 703 707 704 708 if (!is_array($MESSAGE->parts) && empty($MESSAGE->body)) 705 709 return ''; … … 732 736 733 737 $body = rcmail_print_body($part, $safe_mode, !$CONFIG['prefer_html']); 734 738 735 739 if ($part->ctype_secondary == 'html') 736 740 $out .= html::div('message-htmlpart', rcmail_html4inline($body, $attrib['id']));
Note: See TracChangeset
for help on using the changeset viewer.
