Forum Moderators: coopster

Message Too Old, No Replies

Can PHP recieve emails?

         

ahmedtheking

11:25 am on Apr 1, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I know that Perl can handle emails (ie you can forward emails to a perl script on your server and it can do something) but can the same be achieved with PHP? If so, how?

Habtom

12:42 pm on Apr 1, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I want to hear about this too. But could it be that receiving emails more complicated than sending them.

Habtom

ahmedtheking

12:49 pm on Apr 1, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I def think it is! I went googling (again) and came accross some Perl scripts (an osCommerce one) and I tried to understand what was going on, but couldn't really translate it into PHP! I then had a go at creating an email forwarder to pipe an email to a php script, but I either go a return email 'Could not pipe to location' or nothing happened! The PHP script was meant to take the data (I guessed POST?) and write it to a file! However, I came accross this PHP function:

mailparse() : [uk.php.net...]

I had a go, but it didn't really work!

Habtom

1:46 pm on Apr 1, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I read the ff there too.

//This extension has been moved to the PECL repository and is no longer bundled with PHP as of PHP 4.2.0

:)

ahmedtheking

1:58 pm on Apr 1, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Super lame! I'm going to download the source code of a PHP mail script, like squirrelmail and see how that works! The only problem is that I think squirrelmail and other PHP mail programmes work by connecting to a POP3 or IMAP server, instead of just handling the raw email data like we want to.