Hi all,
I use PHP 4.3.10 and Apache 2.0.49 (Fedora) in a Linux system.
I use this script to send an email
When I run this script my webserver occurs a 500 Internal Server Error.
In the server’s errog_log file the below line is being added:
malformed header from script. Bad header=/home/username/dead.letter... S: php-script
This is the contents of dead.letter
From username Tue Jan 10 14:33:03 2006
Return-Path: <username>
Received: (from username@localhost)
by domain.com (8.12.11/8.12.11/Submit) id k0ACX3wX029666;
Tue, 10 Jan 2006 14:33:03 +0200
Date: Tue, 10 Jan 2006 14:33:03 +0200
From: "domain.com" <username>
Message-Id: <200601101233.k0ACX3wX029666@domain.com>
To: someone@somedomain.com
Subject: My Subject
Line 1
Of course domain.com and username are valid.
I see that there is a problem with mail headers but I don’t know what.
Thanks in advance
I use PHP 4.3.10 and Apache 2.0.49 (Fedora) in a Linux system.
I use this script to send an email
Code:
mail("someone@somedomain.com", "My Subject”, "Line 1");
In the server’s errog_log file the below line is being added:
malformed header from script. Bad header=/home/username/dead.letter... S: php-script
This is the contents of dead.letter
From username Tue Jan 10 14:33:03 2006
Return-Path: <username>
Received: (from username@localhost)
by domain.com (8.12.11/8.12.11/Submit) id k0ACX3wX029666;
Tue, 10 Jan 2006 14:33:03 +0200
Date: Tue, 10 Jan 2006 14:33:03 +0200
From: "domain.com" <username>
Message-Id: <200601101233.k0ACX3wX029666@domain.com>
To: someone@somedomain.com
Subject: My Subject
Line 1
Of course domain.com and username are valid.
I see that there is a problem with mail headers but I don’t know what.
Thanks in advance