Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    PHP


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





Mail Function - Can Not Connect To The SMTP Server


My host did something a couple of months ago to their mail server to make it more secure. YOu now have to delare more variables or something. NOw my PHPlist will not work because it can not connect to the SMTP server or something like that.

JUst wandering if any of you have run into the same problem and could tell me how to fix it?




View Complete Forum Thread with Replies

Related Forum Messages:
Mail Problem - Warning: Mail() [function.mail]: SMTP Server Response: 550 Invalid Recipient:
Whenever the recipient's email address includes a hyphen ( - ), I get the following error message...

Warning: mail() [function.mail]: SMTP server response: 550 Invalid recipient:

I should stress that this only seems to occur when the hyphen is in the URL portion of the address, i.e example@perfect-example.com

The current code works along the lines of...

mail ($_POST['email'], 'Email subject is here', $body, $headers);

View Replies !
Mail() [function.mail]: SMTP Server Response: 550 Not Local Host Gmail.com
I do a mail() and get:

Warning: mail() [function.mail]: SMTP server response: 550 not local host gmail.com, not a gateway in C:xamppxampphtdocs estsitemail.php on line 7


<?php
ini_set("SMTP","rlwatkins.com");
ini_set("sendmail_from","hunter@rlwatkins.com");
mail("huntercjcarroll@gmail.com","hello me","spamtastic","From: hunter@rlwatkins.com");
?>

what is wrong with this, how do i set it so that i can send to something other than localhost?

View Replies !
Warning: Mail() [function.mail]: SMTP Server Response: 501 Syntax Error
When I try this under windows :

mail("User <user@example.com>",$subject, "", $headers);

I get this error :

Warning: mail() [function.mail]: SMTP server response: 501 Syntax error,
parameters in command "RCPT TO:<User <user@example.com>>" unrecognized
or missing in

It seems to add it's own <> characters. If I run the same script under Linux it works fine !?

View Replies !
Warning: Mail() [function.mail]: SMTP Server Response: 501 5.5.4 Invalid Address
I receive this error:


PHP Warning: mail() [function.mail]: SMTP server response: 501 5.5.4 Invalid Address in D:clientsebiblecommentary.comconcordia-seminary.caconcordia-seminary.ca\_demo
egister.php on line 464

Both of my mail() uses fail, and I'm not sure why. I've followed the same syntax before on this my server and not had a problem.

My code is below: ....

View Replies !
Warning: Mail() [function.mail]: SMTP Server Response: 550 5.7.1
I'm making e-mailing with php script and i setup mailtraq mailserver this thing is just a lil confusing to me first thing i want to know if i can use apache instead of this as mail server second when i wrote my script with that mail function i received an error this is it :

Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable to relay for monalisa20042006@yahoo.com in D:wampwww1stmail.php on line 2

what's that mean if this means that the mail server not configured right...SO third how to use or configure this server to use as my mail server. Code:

View Replies !
Warning: Mail() [function.mail]: SMTP Server Response: 553
my php.ini mail section is setup as follows:

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

then in my php script:
<?php
mail("joecool@hotmail.com", "Testing", "Line 1
Line 2
Line 3", "From: tom@hotmail.com") or die("email error");
?>

i have also run mercury mail but i keep getting this error:

Warning: mail() [function.mail]: SMTP server response: 553 We do not relay non-local mail, sorry. in C:Program Filesxampphtdocsest.php on line 2

on all tutorials that i went, the mail function is written this way what is wrong?

View Replies !
Mail Function Need A SMTP Server
im using the mail function in my script. I realised that it isn't working from my laptop but when i run the script at uni it is working perfectly and emails are sent. I then did some reseach and found that i need a SMTP server. Code:

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver At "localhost" Port 25, Verify Your "SMTP" And "smtp_port" Setting In Php.ini
PHP Code:

$con = "hi monday";
mail("mymail@lala.com","test imap.dll",$con,"From: [email]other@mail.com[/email]");

and the mod_imap is loaded. but the browser show:

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 D:Apache2htdocssendmail.php on line 2

View Replies !
Code To Connect To A SMTP Server?
Is there anyway, while using the mail function in PHP, to write some code to connect to a SMTP server? I have a form for my website but it is not sending me the results when it is filled out and the only conclusion i have is that the site cannot connect because of authentication problem.

View Replies !
Connect To A Pop Server Before Use The Smtp Server
A mail sent from a host to my smtp server is refused. This happens
because you have to connect to a pop server before you can use the
smtp server. Does anybody have any code to achieve this (PHPmailer doesn't work)?

View Replies !
SMTP Server Response: 503 This Mail Server Requires Authentication
I get this any time I try to send an email to someone that IS NOT in the domain of the company:

Warning: mail() [function.mail]: SMTP server response: 503 This mail server requires authentication when attempting to send to a non-local e-mail address. Please check your mail client settings or contact your administrator to verify that the domain or address is defined for this server. in corpevent.php on line 21

I have it setup like this (I removed the email address domain...but its correct in the code):

// INI Settings //
ini_set(sendmail_from,"info@domain.com");
ini_set(SMTP,"mail.domain.com");
ini_set(smtp_port,"25");

$headersĀ  = "MIME-Version: 1.0";
$headers .= "Content-type: text/html; charset=iso-8859-1";
$headers .= "From: info@domain.com";

$to = $_POST['txtEmail'];
mail($to,"Your Email",$theEmail,$headers);

Why am I not allowed to send an email to anyone that doesn't have a "domain.com" at the end of the email?

View Replies !
Php Mail() Problem - Warning: Mail(): Failed To Connect To Mailserver At "localhost" Port 25, Verify Your "SMTP"
I used dreamweaver as a tools for php coding..and Im using php version 4.3.3, Apache 2.0.47(win32) and MySQL as database. I found a problem with php mail() and the error says like this ;-
Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set().

View Replies !
Mail() - SMTP - And Server Queue
I have made any test with high volume sent with mail() and with direct STMP connection
I monitoring under WHM of my server the QUEUE (under mail queue manager)With the first (mail()) I see only 20% in the queue, other is sent immediately With the SMTP I see 100% on the queue and I must send manually (with delivery now) and sent is really slowly.

View Replies !
Use Mail() When The SMTP Server Needs Authentication?
Is it possible to use mail() when the SMTP server needs authentication?

View Replies !
Setting Up SMTP Server And Mail()
I've never seen a clear and useful post about setting up an SMTP server and getting the mail function to work properly.

Some info about my system:
Windows XP Home (SP2)
Apache 2.0.XX
PHP 5
MySQL 4.1
ActivePerl 5.8.7 (If anyone knows how to set this up with apache, please send me a pm, thanks)

I'd really like if someone could post a few links or someinfo on how to set up php's mail stuff

From what responses I've gotten in the past, I think I need an SMTP server installed on my computer, when I googled, the only results that I seemed to get were servers I would have to pay for. I'd also like to know about configuring PHP's mail functions (php.ini options) so that it will work corectly.....

View Replies !
Mail() On Linux To Use Other Smtp Server
I have written a php site that uses the mail() on windows and i had to state in the php.ini file which smtp server to use.

have now migrated this site to a redhat 9 server, but i still want the emails to be sent via the smtp server i stated earlier.

this may infact be a sendmail question, im not sure, (perhaps changing sendmail_path in php.ini) but has anyone managed to send email via mail() in php, on a linux box, that uses an external smtp server?

View Replies !
Use Yahoo Smtp Mail Server
I have tried several ways to send mail but I hav failed and I m veryyyyyy upset. Now
I have few question about mail sending in php 1. I cant/dont use the smtp server of my ISP. Now which server I can send my mail thru?

2. I want to use yahoo smtp mail server. Now do I have to set yahoo smtp server name and port in php.ini? Cant I set these (both name and port)dynamically in php. if so, how?

3.If the server name I m using uses authenticated smtp, WHERE and how to put code for user id and password in php . If in mail header then in which format? Code:

View Replies !
PHP Warning: Mail(): SMTP Server Response: 550
I'm writing a form for my boss with a mailing option. He gave me the SMTP to use. However, I get the error:

PHP Warning: mail(): SMTP server response: 550 <blba@hotmail.com>... Relaying denied in C:websitesendMail.php on line 85

I showed him the error, he cheked the mail at the server, everything was working fine !
How can I AT LEAST check if my mailing works ? (can i use m html smtp ? How can i get it ?)

View Replies !
How To Send Mail Using Googlemail SMTP Server ?
how I can send mail through a php script, using my googlemail account..

View Replies !
Warning: Mail(): SMTP Server Response: 451
I am trying to work through some of the Wellington and Thomson book on PHP and MySQL - I am trying to process a mail feedback form and I get the following error:

Warning: mail(): SMTP server response: 451 See http://pobox.com/~djb/docs/smtplf.html. in C:Documents and SettingsRLaneMy DocumentsWeb SitesLocalhostInDevelopmentWellingtonSource4processfeedback.php on line 14 ....

View Replies !
Ensure That Mail() Generated From Php Is Sent Out Via The Smtp Server
I have a smtp server on machine 'a'. Linux machine 'b' runs php. I want to ensure that mail() generated from php is sent out via the smtp server on machine 'a'. How/where do I configure that?

View Replies !
Mail() Problem With Localhost Smtp Server
Using PHP 5.0.4/MySQL 4.1.12/IIS 6. Have setup an Microsoft SMTP virtual server which works fine when I try to send an outgoing email via "localhost" using Outlook.

However when trying to use mail(), i get an error "Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini"

I had previously tried to use my ISPs smtp server but also got the same "failed to connect" error which is why i tried going locally. Code:

View Replies !
Use Any Other Smtp Server And Port To Send My Mail
I cant send a simple mail from my pc. I dont know smtp server name and port of my ISP. Cant I use any other smtp server and port to send my mail. Wud u pls tell me the name as well as the port of such smtp server. What is the name n port of yahoo.

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver
Why do i keep getting this error:

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:wampwwwproject_upload Code:

View Replies !
Test Mail() On Development Machine W/o Smtp Server
My development machine (WinXP, Apache 2.2.4) does not have an smtp
server, and I don't really want to install one if I can help it.

Does anyone know of a simple method of testing php scripts that employ
mail() by simulating an smtp server and directing output to a text file
or to an installed text editor.

Right now I can modify the script to use something instead of mail(),
then change it when I put into production, but I would really like to
test the script in its production form w/o having to actually send email.

View Replies !
SMTP Server Response: 550 5.7.1 Unable To Relay For Any E-mail.
I am trying to use the mail() function, and I keep get the following error that says

SMTP server response: 550 5.7.1 Unable to relay for any e-mail.

I added the IP of the webserver in Exchange to allow relaying, but still I get this error. Does anyone know how to go about fixing this and allow an e-mail to be sent?

View Replies !
Mail() [function.mail]: Failed To Connect To Mailserver
i need to know how to enable my mail function i have change my ini to localhost port 25 and enabled emnail but nothing is changing anyone experienced this problem before.

View Replies !
Non-local SMTP Mail Function.
I am working on a webpage that is on a different server than the email
server that the company wants me to use to send emails.

Is it possible to change the PHP.ini file to use this non-local SMTP
server, or is it not that simple?

View Replies !
Mail Function And Smtp Problems
I'm in the process of building a web-site. The script i've written for registering an account send an e-mail to a user specified e-mail address containing instructions for account activation. My problem is that the e-mails wont send. I know this is something to do with smtp and mailservers. My knowledge in this particular area is minimal however, and i simply cannot find any competent documentation, explaining what i need to do, anywhere.

My isp is AOL and i would like to use their smtp server if possible for sending the e-mails. I've changed the configuration of php.ini to connect to them. I do know that this requires authentication, but i have no idea how to do this. At the moment i'm getting the following error:

Failed to connect to mailserver at "smpt.aol.com" port 587, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:Program FilesApache GroupApache2htdocs
egister.php on line 82

However earlier when i was doing some trial and error, downloading programs and mail servers even though i had no idea what on earth i was doing (lol) i got the AUTH erorr message, which i assume meant that everything was working, apart from i needed authentication.

View Replies !
Configure PHP To Use A Remote SMTP Server For Sending Mail On Linux
On Linux, can you configure a remote SMTP server to send mail? I set SMTP = mySMTPserver under [mail function] in PHP.ini; I also stopped sendmail service on my local machine. There are no mails send out. If I run the local sendmail service, mails are sent out.

View Replies !
SMTP Server - Create A Php Script Thazt Send An Mail
i'm trynig to create a php script thazt send an mail does someone know how to set the smtp server

smtpserver=smtp1 and it is remote server not on my machine.
Itried but i've got this[color=blue][color=green]
>>Failed to connect to mailserver at "localhost" port 25, verify your[/color][/color]
"SMTP" >>and "smtp_port" setting in php.ini or use ini_set()

View Replies !
[function Mail() Windows XP]SMTP Localhost
I'm trying to send an e-mail from a .php script and ie6 returns this error:

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:wampwwwPAMWDchap11emailsendmail.php on line 12

I checked php.ini (line 606):

[mail function]
; For Win32 only.
SMTP = localhost

OTOH I didn't find "smtp_port" in php.ini. Maybe I should add :80 as port in php.ini?

View Replies !
Connect To Mail Server
I got this script from a tutorial somewhere, its for conecting to a mail server and reading a list of the messages there. but for some reason it wont work. at all. the page just stays blank. (white). PHP Code:

View Replies !
How To Connect To A (mail) Server?
Can anyone tell me/show me how I can connect to a (mail) server?

View Replies !
Warning: Mail(): SMTP Server Response: 505 5.7.3 Must Issue A STARTTLS Command First
While using mail() function in PHP I am getting thjis error

Warning: mail(): SMTP server response: 505 5.7.3 Must issue a STARTTLS command first

I have used ini_set("SMTP","mail.subdomain.mydomain.");


But when I used this with the IP address of the MailServer (MS-Exchange server) it works. Any comments on this.

View Replies !
Connect To Pop3 Mail Server
I have a piece of code that connects to a mail server running on the same machine. It all works fine but it just takes an age to connect to the mail server, like 30 seconds or so.
Looking at the log for the mail server, I noticed the following lines at the beginning of each request:

[Date / Time] CAPA
[Date / Time] -ERR Unknown Command
[Date / Time] AUTH
[Date / Time] -ERR Unknown Command

Could this be the reason that it takes so long to connect to the mail server? And if so is it possible to suppress certain commands sent to the server if they are not required?
The PHP code I use to connect is simply:

$mbox = imap_open ("{mailserver:110/pop3}INBOX", "username", "password");

And then imap_close($mbox); to clean up.

View Replies !
Use Fsockopen To Connect To Pop3 Mail Server
I am writing a application which use fsockopen to connect to pop3 mail server and check mails. It works fine for me. But, Now i am having problem with checking same server.

I mean when i try to connect to example.com from a script running at http://www.example.com/myscript.php it doesn't connect to server gives

PHP Code:

View Replies !
Connect To The Server With A Password And Username And Then Allow Mail() Commands Normally.
It is with smtp authorization. I have been told that it is not possible. But I saw a script that made it possible. But I have users that have directories on my site and would like them to be able to use the mail() function without a complicated script.

My plan was, to find some way to connect to the server with a password and username and then allow mail() commands normally.

This file would be in the include directory so all the users would need to do is have a require('mail.php'); before their mail script and it would work. Does anyone know how to do this, Or can you refer me to a free mailer that doesnt use authorization?

View Replies !
Warning: Mail(): Failed To Connect To Mailserver At "localhost" Port 25, Verify Your "SMTP"
when i execute a mail program iam getting some error as follows:

Warning: 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:appservwwwmails.php on line 20

what is the solution to this problem Code:

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver At "localhost" Port 25
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 send.php on line 9

Warning: Cannot modify header information - headers already sent by (output started at send.php:9) in send.php on line 10

why this warning and error coming when i am using this cording help me to solve this problem.

View Replies !
Failed To Connect To Mailserver - Config Settings For The Mail Server
I am trying to send an email through a web form but I am getting an error. I am trying to use windows xp on my local machine.

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:wampwwwsendmail.php on line 19

Can someone tell me how to fix this. Here are my config settings for the mail server.....

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

View Replies !
[function.mail]: Failed To Connect To Mailserver
i am getting following error.

Warning: mail() [function.mail]: Failed to connect to mailserver at
"smtp.gmail.com" port 465, verify your "SMTP" and "smtp_port" setting
in php.ini or use ini_set() in D:LUGUBA
ootsite emp5.php on line 8

I have done the following....

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver At "localhost"
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 D:SitescsitechsorderEmail.php on line 97

View Replies !
Cannot Connect To The Mysql Server Using Php - Undefined Function Mysql_connect()
I'm surfing the net looking for answers but I thoguht I should post the question somewhere so I have something to fall back on. I am running:

Windows Xp SP2
apache2
php5
mysql4.x

The are all running fine from what I can tell. I have 1 problem, I cannot connect to the mysql server using php, it's giving me the error noted in the subject line. The error says the function is undefined but I assume it is in the .dll file that the php.ini file loads(php5apache2.dll for php to work on apache and php_mysql.dll loaded as an extension for php to talk to mysql). Everything loads fine, I don't get any errors when starting up apache, the phpinfo() page works perfectly, but it juts won't talk to mysql server.

View Replies !
Warning: Mail(): Failed To Connect To Mailserver At "localhost" Port 25, Verify Your "SMTP" And "smtp_port" Setting
may i know what the error.. i try the sending email. but it display these error:

Warning: 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 fileseasyphp1-8wwwfp2.php on line 46
Cannot send password to your e-mail address ...

View Replies !
Can't Connect To Gmail With SMTP SSL Connection
I am trying to send emails from php using a hosted gmail account.  I have PHP Version 4.3.1.0 and Apache version 2.0.55 running on Windows.  Based on code examples and information I found from other sites it seems that the only way to do this is with a SMTP SSL connection.  I tried using the Swift mailing library, but I could not get a connection. Code:

View Replies !
How To Connect Remote Site - Can't Connect To MySQL Server
Lets say, i have two php sites named Site-A and Site-B. I want to use MySql
Datbase of Site-B for Site-A.

Generally i use :

$Host="localhost";
$User="username";
$Pass="password";
$DB="databse";
mysql_connect($Host,$User,$Pass);
mysql_select_bd($DB);

When i connect to Site-B database from Site-A what will be the $Host name?
I have tried with: $Host="www.mysite.com";

but it shows the warning:
Warning: mysql_connect(): Can't connect to MySQL server on....

View Replies !
SMTP Failed To Connect To Mailserver At Localhost Port 25
I dont know what I did but now I get this message Failed to connect to
mailserver at "localhost" port 25, verify your "SMTP"...

View Replies !
Error Log Stating That It Could Not Connect To Smtp Host On Port 25
I have some code which sends an email to a recipient, but it is not working. I have checked the smtp host and port in the PHP.ini file and both are correct, I have also contacted my provider and know the smtp host and port are also the correct ones.

I am getting an error on apache's error log stating that it could not connect to smtp host on port 25. Notice that I am using the smtp host name, I can also ping it so I know I can get to it.

At one point, the emailing function worked, but it has now stopped working; not sure what the problem might be. I have actually created a mailtest.php with some very basic code to no avail.

View Replies !
Specify Server In Mail Function?
I am running a PHP script on my machine that's running mySQL. But this machine can't send mail. My script just uses the PHP mail function. I have to specify username, password, and server to be able to get into the mail server. Can the PHP mail function take those parameters somehow?

View Replies !
Warning: Mysql_connect() [function.mysql-connect]: Lost Connection To MySQL Server
I've set up a test server on an Ubuntu system. I installed and configured Apache, PHP and MySQL however, whenever I try to connect to a MySQL database I get this error:
PHP Code:

Warning: mysql_connect() [function.mysql-connect]: Lost connection to MySQL server at 'reading initial communication packet', system error: 111 in /var/www/index.php on line 8
Lost connection to MySQL server at 'reading initial communication packet', system error: 111

Does anyone know what is causing this and how I can solve the problem?

View Replies !
Warning: Mysql_connect() [function.mysql-connect]: Unknown MySQL Server Host 'sql1bravehostcom'
Warning: mysql_connect() [function.mysql-connect]: Unknown MySQL server host 'sql1bravehostcom' (1) in /misc/13/000/126/295/2/user/web/jeppers90.com/includes/fiction_mysql.inc.php on line 11
Cannot connect to server

this message is what i get when i try to upload it to a webserver..things i have done set up database put in correct information from the database in to my php form. what ever i try i can't seem to set it up .

View Replies !

Copyright © 2005-08 www.BigResource.com, All rights reserved