How to Enable Email Piping in cPanel
Posted about 8 months ago 3.9kWhat is Email Piping
Process emails: Forward incoming emails to PHP script for ticketing, etc.
Create Email Forwarder
cPanel → Email → Forwarders → Add forwarder to pipe to program.
Pipe Command Example
/home/username/public_html/support/pipe.php
Script Requirements
Basic PHP Pipe Script
<?php
$fd = fopen("php://stdin", "r");
$email = "";
while (!feof($fd)) {
$email .= fread($fd, 1024);
}
fclose($fd);
// Process $email content here
?>
Use Cases Table
| Use Case | Example |
|---|---|
| Support tickets | support@ → create ticket |
| Comment by email | WordPress post by email |
| Form processing | Auto-reply + DB entry |