[Tickets #10674] Re: HTML <head> tag attributes displayed

bugs at horde.org bugs at horde.org
Mon Oct 24 10:53:21 UTC 2011


DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.

Ticket URL: http://bugs.horde.org/ticket/10674
------------------------------------------------------------------------------
  Ticket             | 10674
  Updated By         | roborg at hotmail.com
  Summary            | HTML <head> tag attributes displayed
  Queue              | IMP
  Version            | 5.0.14
  Type               | Bug
  State              | Feedback
  Priority           | 1. Low
  Milestone          |
  Patch              |
  Owners             |
------------------------------------------------------------------------------


roborg at hotmail.com (2011-10-24 10:53) wrote:

I've tracked it down a little more... it's in Horde_Mime_Viewer_Html  
(called from IMP_Mime_Viewer_Html - imp/Mime/Viewer/Html.php line 184)

$data = $this->_cleanHTML($data, array(
             'noprefetch' => ($inline && (IMP::getViewMode() != 'mimp')),
             'phishing' => $inline
         ));

to test it you can add this line in before, then var_dump($data) after:
  $data = 'test <html this="a test"><body>HTML part</body></html>';

Expected:

string(246) "<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0  
Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html><head><meta http-equiv="x-dns-prefetch-control"  
value-equiv="off"></head><body>HTML part</body></html>
"

Actual:

string(246) "<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0  
Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html><body><p>test </p> this="a test"&gt;HTML  
part</body></html><head><meta http-equiv="x-dns-prefetch-control"  
value-equiv="off"></head>
"





More information about the bugs mailing list