#native_company# #native_desc#

Creating a PHP Script for Web Mail Posting and Notification Page 4

By Jochen Staerk
on May 17, 2004

Unfortunately the script was a little slow for our use: On a
Loop-Back-Ethernet of a somewhat unused Apache 2 with 512 MB Ram and 2.5
Ghz, a process took approximately 15 seconds. Appearantly it wasn’t the
submitting that was slow, but rather it was waiting for the response for
that long. However, if you are ignoring the answer of the HTTP server the
script ran in less than 0.01 seconds:


if (!$discard_return)


    while (!
feof($fp))  $res.= fgets($fp1024);



The script can be used in .forward files, simply write:

|"postinput.php http://yourdomain.com/yourscript.php"

in the .forward-Datei in the home-directory of the user, which mail you
wish to receive. Your email will literally post this: (to

Your .forward does not have to stop here however:

|"postinput.php http://yourdomain.com/yourscript.php"
|"postinput.php http://mydomain.com/yourscript.php"
[email protected]

sends an incoming mail to yourdomain and mydomain, puts a copy in the
mailbox of the user jstaerk and forwards one copy to Scipio Africanus.