The correct syntax for connecting to a script is
:0
* ^To:.*@barrett\.com
| /usr/local/bin/php-5.2 -f $HOME/ticket/emailcustcheck.php
The action !will try to redirect to an email address, but, of course, a long line with the path to your PHP interpreter is not a valid email address.
(.. PHP script ), ; Procmail , , , . , - , concurrency (, script , ) , .
regex , , Cc mail, direct To:. ^TO_ , .
script ; , , , "", "body". , , PHP , .