php mail()

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
User avatar
jamiller
Forum Commoner
Posts: 26
Joined: Mon Mar 12, 2007 12:25 pm

php mail()

Post by jamiller »

Let me start out by saying that I'm fairly new to this "other" side of php, mysql, apache, where I'm setting all this up for production.

I'm building a website for my company and we are hosting it ourselves. I used XAMPP to install all the services. Yes, I know all about the security of using this method and when I learn more about installing it all myself I will do that (this week), but for now we need the site up quickly. We have a mail server (Microsoft Exchange Server) and I have set that server in the php.ini file. But when I test my form it keeps giving me the error "Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set()" even after I changed this line and restarted my services. I read somewhere to test my port 25 by typing telnet localhost 25 which returned an error then I replaced localhost with our mailserver and it says its ready to use and everything appears alright.

So why isn't this working?!

I thought that I may be updating the wrong php.ini file so I found all php.ini files and changed all of them, XAMPP installs php 4 and php 5, but uses 5 by default. Still didn't work...

Any ideas?

Thanks,

Jeff
User avatar
Zoxive
Forum Regular
Posts: 974
Joined: Fri Apr 01, 2005 4:37 pm
Location: Bay City, Michigan

Post by Zoxive »

Sounds like your not editing the right file. When you do edit it, are you (re)starting the server to apply the changes?

phpinfo(); will tell you what php.inf file it is reading.

You should also check out swiftmailer.
Last edited by Zoxive on Mon Dec 17, 2007 11:35 am, edited 1 time in total.
User avatar
jamiller
Forum Commoner
Posts: 26
Joined: Mon Mar 12, 2007 12:25 pm

Post by jamiller »

:P

Should have known... but now i know where to find what ini file is being used.

Thanks!
Post Reply