DINH Viêt Hoà | 28 Jan 2007 16:34
Picon
Favicon

Re: newbie parsing problem

On 28 Jan 2007, at 15:56, Dave Serls wrote:

> Basically, I want to discover if the content-type of a part is NOT  
> 'text/xxxx',
>   make it 'text/plain' and replace the body with a single line of  
> text stating
>   that it has been replaced.  Then this altered message will be  
> output.
>
>   I'm using the sample code to run mailmime_parse() on the mmap'ed  
> message.
>   The single attachment test messages I've used from squirrelmail  
> parse with no
>   content-type revealed for a large jpeg attachment.
>
>   Here is the output (I can also send the input if I cloak it  
> somewhat).
>
>
> message
> part : 0xb7a86000, length : 598564
>
> MIME headers:
> content type: type: mime type:
> composite type: composite type is message
>
>
> subtype: rfc822
>
>
> headers:
> sub message 0x804e010:
> single part
> part : 0xb7a86000, length : 598564
>
> content type: type: mime type:
> discrete type: text
>
>
> subtype: plain
>
>
> 8bit
> already encoded
> data : 0xb7a86000 598564
> end of sub message 0x804e010

I don't understand the output of your sample.
Could you send me your code and the source of the message ?
and tell me where your problem is ?

--

-- 
DINH Viêt Hoà

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Gmane