mail() function not available in PHP???

Discussion in 'Programming/Scripts' started by dirk, May 23, 2005.

  1. dirk

    dirk New Member

    I've a big problem. I want to use PHP's mail() function to send emails, but my PHP tells me that this function isn't available... :( I thought the mail() function is built-in in PHP!? :confused:

    Dirk
     
  2. joe

    joe New Member HowtoForge Supporter

    AFAIK, it is a built-in function. What distribution and version of PHP are you using?
     
  3. jojo

    jojo New Member HowtoForge Supporter

    I've had this phenomenon once before. It happens when you compile PHP from the sources and there's no sendmail binary on the system (doesn't matter if Sendmail/Postfix or any other MTA is installed, as long as there is a sendmail binary...). Took me a few days to find out... :(
    So if you try to compile PHP from the sources make sure that you have an MTA installed on your system...

    Jojo
     
  4. dirk

    dirk New Member

    SuSE 9.2 and PHP 4.3.11 (which I compiled from the sources).
    I'll try to find out if Jojo's hints apply to my system...

    Dirk
     
  5. dirk

    dirk New Member

    Ok, jojo is right. There was no sendmail binary on my system, so I've installed Postfix and re-compiled my PHP, and now the mail() function is working. :)

    Dirk
     

Share This Page