Mail not sending

I just moved my site up to dreamhost and am having some issues with sending mail via php. Is there anything you need to do on DH to make mail(); work? Or should I use some other system?


It’s a fairly typical setup. Are you getting an error message?

No error messages. Are there logs anywhere I can check. I get access denied on the mail.log when I SSH into the host. This is my function I’m using… I shortened it for this post but it’s pretty basic:

function sendWelcome($user, $email, $pass, $file){
  $from = "From: ".NAME." <".ADDR.">";
  $subject = "Welcome!";
  $body = $user.",\n\n"

That should work, shouldn’t it?

Your problem looks like it is because these two lines are formatted incorrectly:

[php]$body = $user.",\n\n"

Do this:
[php]$body = $user.",\n\n

The problem turned out to be… well… not sure! :wink:

I opened a support case with DH. They tested it and said it was fine. And it was… my code worked.