marek Posted July 18, 2006 Share Posted July 18, 2006 I'm sure it's an easy one.I can't use mail function. I get an error message: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini.But I work locally only. All I did was changing "sendmail_from = " in php.ini file.Do I have to change smtp and smtp_port settings also? If so, what parameters should I give there?Thanksmarek Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/ Share on other sites More sharing options...
Tandem Posted July 18, 2006 Share Posted July 18, 2006 To use the mail function you need an smtp server. You can either get your own, or use the one of your isp. Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60013 Share on other sites More sharing options...
scheols Posted July 18, 2006 Share Posted July 18, 2006 yo whats a smtp server? and how would u get one because my validate emails dont work on my forums -_- Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60016 Share on other sites More sharing options...
wildteen88 Posted July 18, 2006 Share Posted July 18, 2006 To use mail you'll need to point it to an actual SMTP server. If you dont have an SMTP installed on your local machine it will not send an email. See if you can find a public SMTP server which does require authentication in order to send an email, as mail does support this. You shouldn't have to change the port number as SMTP servers run on port 25 Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60018 Share on other sites More sharing options...
marek Posted July 18, 2006 Author Share Posted July 18, 2006 Ok. So I changed SMTP settings for the same as in MS Outlook. I left smtp_port = 25. Restarted server.Still doesn't work. Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60029 Share on other sites More sharing options...
wildteen88 Posted July 18, 2006 Share Posted July 18, 2006 Does the smtp server you are using require you to login? If it does you cannot use this SMTP Server as mail doesnt support authentication requests - loggin. Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60032 Share on other sites More sharing options...
marek Posted July 18, 2006 Author Share Posted July 18, 2006 Yes. My e-mail smtp server requires me to login.So what can I do to use mail function? Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60035 Share on other sites More sharing options...
wildteen88 Posted July 18, 2006 Share Posted July 18, 2006 You cant use that smtp server with mail then. If you want to use that smtp server I think you'll have to use imap which allows you to login to mail servers. Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60038 Share on other sites More sharing options...
marek Posted July 18, 2006 Author Share Posted July 18, 2006 So I guess I just skip mail function for some timethanks anywaymarek Quote Link to comment https://forums.phpfreaks.com/topic/14955-mail/#findComment-60041 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.