Jump to content

Server not sending email with php


Lee

Recommended Posts

Hi, I hope you don't mind me asking here.
Can anyone give me an idea why my server won't send emails through php?

I have set php.ini like this & re-booted..
[code]
[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

; For Win32 only.
sendmail_from = lee@mydomain.com

; For Unix only. You may supply arguments as well (default: "sendmail -t -i").
sendmail_path = /usr/sbin/sendmail -t -i[/code]

Is there anything else I could try to get it to work?

Thanks.
Link to comment
Share on other sites

I'm not sure if this is it, but it IS something at least seems out of place.

It says "For Win32 [b]only[/b]" and "For Unix [b]only[/b].  But neither line is commented out.

Are you on Win32?  Or are you on Unix?  Are you using SMTP to send?  Or sendmail?  If using SMTP, have you specified your username and PW?

Also, what does the code look like that you're using to send the message?  Maybe there's something wrong with THAT?
Link to comment
Share on other sites

Its a unix server, and I am trying to use sendmail.

Its definately not a code problem because it works fine on another server, and also, I have a CH-phpBB board which is also not sending mail.


[code]
//sending sign-up e-mail (validation notice)
$val_key=$email.time();
$val_key=md5($val_key);
$sql_query="insert into validate (email,password,val_key) values ('$email','$password','$val_key')";
sql_execute($sql_query,'');
$data="<a href='$main_url/index.php?mode=join&act=val&val_key=$val_key&inv_id=$inv_id'>Verify Email</a>";
messages($email,'0',$data);
[/code]

Thanks :)
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.