MyBB Community Forums
[How To?] email php function add date - Printable Version

+- MyBB Community Forums (
+-- Forum: 1.8 Support (
+--- Forum: General Support (
+--- Thread: [How To?] email php function add date (/thread-217632.html)

email php function add date - flexen - 05-18-2018

mybb is sending emails through php (dockerrized server setup, not mine and a little too complicated 4 me 2 understand) and inserts the from field trough additional header options for phpmail in the mybb admin panel. this works good and is needet to show any from content at all:

$headers = "From: [email protected]\r\n"

is working flawlessly!

still its not sending the date. and this i cant get to work.

my current try is:

$headers = "Date: ". date("r") ."\r\n". "From: [email protected]\r\n"

but its not working out. where do i go wrong ? i really suck at coding, so i dont know when to , ; space . or whatever between arguments, etc.

i followed this hint at the botttom:

please help me...