X-Git-Url: http://git.shiar.nl/minimedit.git/blobdiff_plain/1900f80a9ab5fe401d6901b8e17ee82131b1170d..b3e01444d0f6253ae14d6223daa325686718fb63:/mail/index.php
diff --git a/mail/index.php b/mail/index.php
index b4846cc..d4d4c29 100644
--- a/mail/index.php
+++ b/mail/index.php
@@ -17,13 +17,17 @@ if ($msgid) {
$filename = "$mailbox/$msgid";
list ($headerdata, $rawbody) = explode("\n\n", file_get_contents($filename), 2);
$head = parsemailhead($headerdata);
+ $head['date']->setTimezone(new DateTimeZone(date_default_timezone_get()));
$Page->title = 'Mailbericht ' . $head['date']->format('Y-m-d H:i');
printf("
%s
\n", htmlspecialchars($head['Subject'] ?? 'Mailbericht zonder onderwerp'));
- print '';
- printf('- Ontvangen:
- %s
', $head['date']->format('c'));
- printf('- Verzender:
- %s
', htmlspecialchars($head['From']));
+ printf(''."\n",
+ htmlspecialchars($head['From']),
+ htmlspecialchars(implode(', ', array_column($head['from'], 'display'))),
+ htmlspecialchars($head['Date']),
+ showdate(preg_split('/\D/', $head['date']->format('c')))
+ );
print '
';
if (preg_match('{^text/plain}', $head['Content-Type'] ?? 'text/plain')) {
@@ -71,10 +75,12 @@ foreach (array_reverse($rows) as $filename) {
$head = parsemailhead($headerdata);
print $head['Subject'];
- printf(' %s',
+ printf(' %s',
+ htmlspecialchars($head['Date']),
showdate(explode('-', $head['date']->format('Y-m-d')))
);
- printf(' %s',
+ printf(' %s',
+ htmlspecialchars($head['From']),
htmlspecialchars(implode(', ', array_column($head['from'], 'display')))
);
print "\n";