Clicking on the email from the list view lead to a blank page

When opening an email in SuiteCRM for the first time, the email details initially appears empty. If I refresh the page or re-open the email, the body content loads correctly. This issue occurs consistently with every email I open.

I think i have issue with Date header
Fri Nov 15 15:10:06 2024 [32330][1][FATAL] Exception handling in /var/www/suite/public/legacy/include/MVC/Controller/SugarController.php:397
Fri Nov 15 15:10:06 2024 [32330][1][FATAL] Exception in Controller: Expected header Date to comply with RFC882 or RFC2882, but actual is β€œβ€

In InboundEmail.php

$parsedFullHeader = $this->getImap()->rfc822ParseHeaders($fullHeader);
dd($parsedFullHeader->date);

First time show null

This is after page refresh

Hi @VaheGh ,
I am facing same issue. Were you able to fix the issue?

If problem with multipart/mixed content type in public/legacy/modules/InboundEmail/InboundEmail.php method
getMessageTextWithUid() i added this if content type not β€˜text/plain’

if (empty($emailMessage)) {
   // Fallback to plain text if HTML content is not available
   $emailMessage = $this->mailParser->parse($emailBody, false)->getTextContent();
}

If problem with datetime format in returnNonImportedEmail() method i added

$possibleFormats = [
   DateTime::RFC2822 . '+',
   str_replace(['D, '], '', DateTime::RFC2822),
   // day-of-week is optional
   str_replace([':s'], '', DateTime::RFC2822),
   // seconds are optional
   str_replace(['D, ', ':s'], '', DateTime::RFC2822),
   // day-of-week is optional, seconds are optional
   DateTime::RFC822,
   str_replace(['D, '], '', DateTime::RFC822),
   // day is optional
   str_replace([':s'], '', DateTime::RFC822),
   // seconds are optional
   str_replace(['D, ', ':s'], '', DateTime::RFC822),
   // day is optional, seconds are optional
   "D, d M Y H:i:s",
   "d M Y H:i:s",
   "D, d M Y H:i",
   "d M Y H:i",
   "D, d M y H:i:s",
   "d M y H:i:s",
   "D, d M y H:i",
   "d M y H:i",
];