PDA

View Full Version : Email piping - is it possible to set up through the control panel?



switch
02-23-2008, 10:01 AM
Hi all,

I've found a few (http://www.directadmin.com/forum/showthread.php?t=8417) posts (http://www.directadmin.com/forum/showthread.php?s=&threadid=976) on this forum about email piping, but nothing too recent.

The problem I'm having is setting up a forwarder to point to my php script (to WHMCS), but I get an error stating the email is invalid. DA is complaining because the pipe command is an invalid email (which is exactly what it's supposed to be doing):

Error creating forwarder

Details:

String contains an invalid email address: " | /usr/local/bin/php -q /home/admin/domains/[mydomain]/public_html/billing/pipe/pipe.php"

So, to get this working, do I need to manually create a forwarder somehow? Is there a "correct" way of doing this where DA will accept it?

Thanks!

GXX
02-23-2008, 07:32 PM
You need to wrap your forward with quotes. For example:


"|/usr/local/bin/php -q /home/admin/domains/[mydomain]/public_html/billing/pipe/pipe.php"

switch
02-23-2008, 07:52 PM
Hmm... just to clarify, I was using quotes, but apparently setting up the forwarding doesn't like spaces. For the edification of the next person, this is what I tried (which did NOT work):


" | /usr/local/bin/php -q /home/admin/domains/[mydomain]/public_html/billing/pipe/pipe.php"


and this DID work:


"|/usr/local/bin/php -q /home/admin/domains/[mydomain]/public_html/billing/pipe/pipe.php"

(Note the lack of an initial space, and a space after the pipe).

Thanks GXX for setting me in the right direction!