From: ("bchris999")
Date:  21 Jul 2015 23:13:18 Hong Kong Time

[PEAR-BUG] Doc #18538 [Com]: Fatal Error w/ Mail_mimedecode 1.5.5 and php 5.2.17

NNTP-Posting-Host:  null

Edit report at

 ID:               18538
 Comment by:       bchris999
 Reported By:      bchris999 at gmail dot com
 Summary:          Fatal Error w/ Mail_mimedecode 1.5.5 and php 5.2.17
 Status:           Feedback
 Type:             Documentation Problem
 Package:          Mail_mimeDecode
 Operating System: CentOS 5.6
 Package Version:  1.5.5
 PHP Version:      5.2.12
 New Comment:

Same problem here with PHP 5.3.3 on CentOS 5.6.

The documentation only mentions and shows examples of calling getXML

$decoder->getXML(); doesn't work, however
$decoder->getXML($decodeoutput); does work!

Previous Comments:

[2011-05-15 12:40:02] doconnor

-Status: Open +Status: Feedback -Type: Bug +Type: Documentation Problem
Alex, if you think about it; you already have an instantiated $decoder variable containing a Mail_mimeDecode object - why would you need to call a static method? I'll agree that perhaps there is a doc bug or it might need more examples - where did you expect to find usage examples & didn't?. ------------------------------------------------------------------------ [2011-05-15 04:37:07] aldug Description: ------------ Calling the getXML () method statically, the only way I can find documentation to call it, throws a fatal error. php 5.2.17 Test script: --------------- $params['include_bodies'] = true; $params['decode_bodies'] = true; $params['decode_headers'] = true; $decoder = new Mail_mimeDecode (file_get_contents ($filename)); $structure = $decoder->decode ($params); $xml = Mail_mimeDecode::getXML($structure); Expected result: ---------------- To get an xml document Actual result: -------------- Fatal error: Using $this when not in object context in /usr/local/php5/lib/php/Mail/mimeDecode.php on line 486 ------------------------------------------------------------------------ -- Edit this bug report at