Skip to content

$message->getTextBody() retrieves whole source, not just the plain text message #413

Open
@TonyMarston

Description

@TonyMarston

I have a message containing plain text, no html and no attachments, but when I use ->getTextBody() it returns the entire source code and not just the message text. The source code is as follows:

Return-Path: Delivered-To: gmx@tonymarston.co.uk Received: from ion.dnsprotect.com by ion.dnsprotect.com with LMTP id oPy8IzIke2Rr4gIAzEkvSQ (envelope-from ) for ; Sat, 03 Jun 2023 07:29:54 -0400 Return-path: Envelope-to: gmx@tonymarston.net Delivery-date: Sat, 03 Jun 2023 07:29:54 -0400 Received: from [::1] (port=48740 helo=ion.dnsprotect.com) by ion.dnsprotect.com with esmtpa (Exim 4.96) (envelope-from ) id 1q5PSF-000nPQ-1F for gmx@tonymarston.net; Sat, 03 Jun 2023 07:29:54 -0400 MIME-Version: 1.0 Date: Sat, 03 Jun 2023 07:29:54 -0400 From: radicore To: gmx@tonymarston.net Subject: Test Message User-Agent: Roundcube Webmail/1.6.0 Message-ID: X-Sender: radicore@radicore.org Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-From-Rewrite: unmodified, already matched

This is just a test, so ignore it (if you can!)

Tony Marston

I expect it to return just the plain text message, not the entire email.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions