#1
  1. A Change of Season
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Mar 2004
    Location
    Next Door
    Posts
    3,159
    Rep Power
    220

    php email doesnt work


    Hi

    Neither Codeitnger nor plain php mail function send emails.

    Even $this->email->print_debugger(); doesnt show any errors.

    All code gets executed and prints the code but no emails go through.

    What should I check for to debug?

    Thanks
  2. #2
  3. Lazy Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Mar 2007
    Location
    Washington, USA
    Posts
    16,270
    Rep Power
    9645
    How is mail set up? Local sendmail or SMTP server? If sendmail then you have to look at the server's configuration to see what it's doing and whether there are any problems there. For example, I've seen sendmail configurations that queue the messages locally (so mail() would always succeed) and there was a problem where the program that dequeues and actually sends the messages was not running correctly.
  4. #3
  5. A Change of Season
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Mar 2004
    Location
    Next Door
    Posts
    3,159
    Rep Power
    220
    How do you want me to check the mail set up?
    Here is the PHP library I am using.

    When I use [B]mail('caffeinated@example.com', 'My Subject', $message);/B] directly in the code, same thing happens. Nothing.

    Thanks
  6. #4
  7. Lazy Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Mar 2007
    Location
    Washington, USA
    Posts
    16,270
    Rep Power
    9645
    Check your php.ini settings first. If there's nothing special then you're using sendmail and you have to look at whatever application suite you have installed that does sendmail support ("sendmail" is mostly a generic name).
  8. #5
  9. A Change of Season
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Mar 2004
    Location
    Next Door
    Posts
    3,159
    Rep Power
    220
    Ok, I check it now.

    One thing I forgot to tell you. It used to send emails fine. It just one day stopped!

    What do you think happened?
  10. #6
  11. Lazy Moderator
    Devshed Supreme Being (6500+ posts)

    Join Date
    Mar 2007
    Location
    Washington, USA
    Posts
    16,270
    Rep Power
    9645
    Dunno. But you should find out what changed that day.
  12. #7
  13. Banned (not really)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 1999
    Location
    Caro, Michigan
    Posts
    14,760
    Rep Power
    4536
    Originally Posted by English Breakfast Tea
    Ok, I check it now.

    One thing I forgot to tell you. It used to send emails fine. It just one day stopped!

    What do you think happened?
    Something changed.
    -- Cigars, whiskey and wild, wild women. --
  14. #8
  15. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Dec 2016
    Location
    Lakewood, WA
    Posts
    196
    Rep Power
    17
    WHEN I ran my own mail server, I used Qmail, though I route everything through GMail and my ISP these days. Perhaps if it "just stopped", your ISP decided not to allow it? Where are you sending from? Is your server colocated or at home? Do you know that the proper ports are open? Is anything bouncing? Have you fiddled with ipTables?

IMN logo majestic logo threadwatch logo seochat tools logo