I'm trying to use procmail to send emails to a PHP script so the script will check a MySQL database and edit the subject line based on the sender email. I believe I've got a working procmail to do this:

```
:0:
* ^To:.*@barrett.com
! '/usr/local/bin/php-5.2 -f $HOME/ticket/emailcustcheck.php'

```

However, I'm not sure exactly how procmail executes the command. How does the email get passed to the PHP script, and therefore, how do I refer to it inside the script?