| | |
PHP mail()
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Oct 2009
Posts: 1
Reputation:
Solved Threads: 0
I have been using class.phpmailer.php script for sending mail from localhost without smtp server.
Everytime i try to send mail from my localhost then following error is generated:
Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\send email\not working scripts\class.phpmailer.php on line 213
there was a problem sending this mail! Could not instantiate mail function.
in my php.ini SMTP is set to localhost and smtp_port is set to 25 without ";"
when using gmail smtp server with the same settings in php.ini then evrything works perfectly alright but this error is generated when not using smtp server.
Problem is that when i'm not connecting to SMTP server then why there is need to verify settings in php.ini
link: php mailer script @ http://phpmailer.sourceforge.net
Please anyone give solution to my problem.
Thanks.
Everytime i try to send mail from my localhost then following error is generated:
Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\send email\not working scripts\class.phpmailer.php on line 213
there was a problem sending this mail! Could not instantiate mail function.
in my php.ini SMTP is set to localhost and smtp_port is set to 25 without ";"
when using gmail smtp server with the same settings in php.ini then evrything works perfectly alright but this error is generated when not using smtp server.
Problem is that when i'm not connecting to SMTP server then why there is need to verify settings in php.ini
link: php mailer script @ http://phpmailer.sourceforge.net
Please anyone give solution to my problem.
Thanks.
0
#2 Oct 9th, 2009
Unless you have a mailserver running on localhost, port 25, PHP cannot send emails. You either need to change the SMTP ports or mail function.
SMTP remotely connects to a remote mail server, allowing you to email from it.
SMTP remotely connects to a remote mail server, allowing you to email from it.
CodeJoust! Design + Development - Proud User of Ubuntu
![]() |
Similar Threads
- PHP Mail Error (PHP)
- Sending HTML email via PHP mail function (PHP)
- PHP mail() (Sendmail) Problem :( (PHP)
- PHP mail Help (PHP)
- PHP Mail with Sender ID (PHP)
- Problems with PHP mail function. (PHP)
- php mail form - need to redirect to new page (PHP)
- how do you setup php mail()? using sendmail and yellowdog linux w/apache and php4 (*nix Software)
Other Threads in the PHP Forum
- Previous Thread: display image sequentially in PHP and MySQL
- Next Thread: How to Display PDF yet restrict copy and print?
| Thread Tools | Search this Thread |
.net access ajax ajaxcode ajaxhelp archive array asp autosuggest beginner class close cms combobox cookies curl data database developer display dynamic eclipse ecommerce email errorlog execute fatalerror files flash flex form forms function gmail google href html httppost if...loop iframe image include integration java javascript joomla jquery lamp limit link linux login mail menu multiple mysql navigation news nodes oop outofmemmory paging paypal php play popup post programmer python query root schools script search security select server session sms smtp snippet soap source spam sql traffic trouble tutorial unicode upload validation vbulletin video web webdesign windowsserver2008 xml yahoo youtube zend






