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.





How To Send Using SMTP With Authentication


I want to write a script than can send emails using remote smtp server with authentication (TLS, SSL ,..), I tried to use PEAR Mail but it didn't work with TLS authentication, is that possible using PHP?




View Complete Forum Thread with Replies

Related Forum Messages:
Sending Mail Using Smtp Authentication To Send Emails
I need some one to help me with sending mail using smtp authentication to send emails in this script. i got this far but i do not know how to setup this to sending mail using smtp authentication to send emails. Or how do i edit this so the top script work together.

View Replies !
Smtp Authentication
I need some one to help me with sending mail using smtp authentication to send emails in this script.

i got this far but i do not know how to setup this to sending mail using smtp authentication to send emails. Or how do i edit this so the top script work together?

View Replies !
SMTP Authentication & Mail()
Being able to send emails through PHP is a fundamental part of the site, so I've been searching around and trying to come up with some code to authenticate with the SMTP server to send the email.

What I have at the moment is code found on the Internet to perform this task using the PEAR module. I assume this module is installed as the php.ini 'include_path' setting is c:php4pear. Code:

View Replies !
Mail() And SMTP Authentication
It would seem BT Internet have just turned on SMTP mail authentication although they have been talking about it for years as I now get the following error message using the mail function on my local machine which worked fine a couple of weeks ago.

Warning: mail() [function.mail]: SMTP server response: 530 authentication required - Your email could not be sent. To fix this you must make a simple change to your email (known as SMTP authentication). For advice visit www.btyahoo.com/smtp or call 0800 328 9968

Needless to say "Advice" relates to Outlook Express and little else, certainly not PHP.
Anyone know the changes I need to make and where, parameters for the mail() function or in the php.ini file perhaps. Naturally I know the information relating to mail username and password.

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

View Replies !
Apache2Triad SMTP Authentication Problem
You know now a days all ISP using SMTP authentication for sending and
receiving email through them.

so we also need to configure Apache2Triad SMTP Authentication for
sending mail but how?

View Replies !
Email: SMTP Authentication - PHP Warning: Mail()
I am running Apache/PHP on Windows 2000. How do we set up authentication for outgoing mail, since my yahoo server requires that? My current settings in php.ini are the following:

SMTP=smtp.mail.yahoo.com
smtp_port=25
sendmail_from=me@myemail.com
;sendmail_path=
Call the mail() function:
mail("the@ddress.com", "Test", "Message");

And finally, the error message output when it fails:

[02-Mar-2003 12:01:31] PHP Warning: mail() [http://www.php.net/function.mail]: SMTP server response: 530 authentication required - for help go to http://help.yahoo.com/help/us/mail/pop/pop-11.html in c:apachehtdocsmail.php on line 11

View Replies !
How Can I Set PHP To Send Email Through SMTP?
I'm gonna setup a page where i can send email to anybody as an anonymous user. it's just for education purposes keep in mind.

I already have made a form which tries to email using the action mailto:myemailaddress@whatever.com but if that person sending uses Hotmail on Linux, that simply does not work.

how do i change this form to make it work with PHP?
-i know my ISP's SMTP server (my Linux didn't come with sendmail for some stupid reason)
-the SMTP server does NOT require a name or password

View Replies !
How To Send Mail With SMTP
What I want to do, is create an email form, where the user can select emails by groups from a database. So based on what group the user selects, I'm guessing I'll use SQL select query to select the appropriate user emails and print them out to the address line of the form. But I need to know the actual coding for SMTP. Is it much more complicated than the mail() function?

View Replies !
Send Mail But No Smtp
I would like to send mail from my php script. I have all that set up etc and works when i use on a server with smtp configured, however the server i am going to use this on does not have access to any smtp server, local or remote. Are there any alternatives options that i can use or is smtp the only way?

View Replies !
Send An Email Through A SMTP Server
Anyone got a block of code that will send an email through a SMTP server using php? Keep in mind this SMTP server requires a username and password.

View Replies !
Send Email To An External Smtp Server ?
I am running VBulletin board, the web forum on a linux machine running apache. How to config php so that it can send email thru an external smtp server instead of local sendmail. My external smtp server is running on an NT machine.

View Replies !
Use Yahoo SMTP Server To Send Mails
how to know yahoo SMTP server to send mails from my website, i don't mean the code, everything is fine with it but i get this message when i send:

SMTP server response: 530 authentication required - for help go to http://help.yahoo.com/help/us/mail/pop/p... in E:MYDOMAINwwwindex.php on line 24

i tried going to the website but didn't help, i also tried to change port to 465 but didn't work too

SMTP: smtp.mail.yahoo.com
PORT: 25

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 !
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 !
Use External SMTP Server (like Google Apps) To Send Email
Is it possible to configure an external SMTP server to route all of
your outgoing mail through on Linux?

I know in php.ini there is a parameter, but it says its only for
windows? Can I do this on Linux?...

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 !
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 !
HTTP Authentication .vs. Session Authentication
I am designing a PHP application (yes, I have
investigated using existing applications). I cannot use HTTPS
for reasons I shall not disclose. I must authenticate users
against a database (MySQL) before granting them access. There
are two methods I am considering: HTTP authentication, and session
authentication. My webpage is spread across multiple scripts, and
the user must not have to repeatedly reauthenticate him/herself.
It does not matter, however, if the login session remains or is
destroyed when the browser closes, although destruction is
preferred.

To my knowledge, PHP only supports Basic HTTP authentication.
This would be easier, and if it matches session authentication in
security, I would prefer to use it. Session authentication would
be accomplished via a hashed password supplied in a form, sent via
POST, after which the userid or another identifying piece of data
would be stored in a session variable. My webserver does host other
websites, and I cannot adjust its configuration. It seems to me,
however, that Basic HTTP authentication sends the username and
password in plaintext at the opening of every page. Is this true?

View Replies !
How To Send Email Automaticly To Admin When Users Send A Form?
how to send email automaticly to admin when users send a form....example...a booking form..therefore the admin will alert of the booking..

View Replies !
Free SMTP Server Called Free SMTP Server
I downloaded a free SMTP server called Free SMTP server. And I have a PHP script that looks like this:

$to="My Email Address";
$subject="Yo!";
$message="Hi!";
mail($to, $subject, $message) or die("Failed");

View Replies !
Send This Page Script Used To Send Spam.
I had installed a simple php script (obtained for free from the web) that allows a visitor to forward a page to a friend. It worked great but now a spammer is using it to send thousands of emails. I have deleted the feature and also the php file but no successs. What can I do? Please help. While I have some responsibilities of a webmaster, my technical abilities are very limited.

View Replies !
Help About POP/SMTP
I want to develop a mail interface for my client. Clinet will provide
mail server and my php pages will get mails from that server and show
to individual users

please tell me what library should i use to enable POP/SMTP, as my web
is AJAX based and i am using XOAD and NAJAX as development tool.


View Replies !
SMTP In PHP 4 And 5
Right now I use an SMTP library to send out automated e-mails from my
applications. We're looking to upgrade to PHP 5, and PHP 5 doesn't like
the SMTP library I'm using. Anyone have an SMTP library that they like
to use, that's compatible in PHP 4 and 5? It needs to be able to do
authentication and attachments.

View Replies !
PHP 5 & SMTP
Anyone know if PHP 5 has built in support for communicating with SMTP
servers that require a username and password?

Right now, as everyone knows, PHP 4 has built in support for
communicating with SMTP servers that do not require a username and
password, but in order to communicate with those that do, one needs to
do a lot of extra stuff ... and publically available classes to handle
the communication do exist.

View Replies !
POP Before SMTP
a friend using Windows wanted to send mail, but he got timeout errors
after editing php.ini Mail section

smtp = smtp.server.com
sendmail_from = friend@server.com

I realized that was because of the need to "POP before SMTP",
so I made him a function. It's working ... for his server (and
hopefully other servers too).

Can this function be improved?
Is it ok to fsockopen in blocking mode?
What about timeout values?

Here it is, hope it suits more Windows people without a mail server
and the need to POP before SMTP

<?php
function POP_authenticate($username, $password, $server) {
$socket = fsockopen($server, 110); // POP3 port
if (!$socket) {
return "Couldn't connect to $server:110
";
}

$res = fgets($socket, 512); // read +OK
if (substr(trim($res), 0, 3) != "+OK") {
return $res; // return the error
}
fputs($socket, "USER $username
"); // send user
$res = fgets($socket, 512); // read +OK
if (substr(trim($res), 0, 3) != "+OK") {
return $res;
}
fputs($socket, "PASS $password
"); // send pass
$res = fgets($socket, 512); // read +OK
if (substr(trim($res), 0, 3) != "+OK") {
return $res;
}
fputs($socket, "QUIT
"); // quit

### I don't care for errors after quitting :-)

fclose($socket);
return false;
}
?>

and this is an example on how you can use it:

<?php
$username = "netuser";
$password = "pAzw04D";
$POPserver = "pop.server.com";
### php.ini's SMTP must correspond to this server
### and sendmail_from must be from this server (??)

$msg = POP_authenticate($username, $password, $POPserver);
if ($msg === FALSE) {
mail("someone@somewhere.com", "PHP test", "Line 1
Line 2");
$msg = "mail (probably) sent.
";
}
exit($msg);
?>

View Replies !
PHP.ini And SMTP
it seems this has been discussed various times. Although I cannot
find a solution.
Ebvironment:
Win 2k
Apache 2
PHP 4.3.7

I use the module mode and not the cgi mode.
I cannot send email from this setup.
php.ini is in winnt
It has the following lines:
[mail function]
; For Win32 only.
SMTP = mailhost.where.am.com
smtp_port = 25

I tried this and I get:
SYSTEM WARNING: mail(): Failed to connect to mailserver at
&quot;localhost&quot; port 25, verify your &quot;SMTP&quot; and
&quot;smtp_port&quot; setting in php.ini or use ini_set()
PROBLEMS SENDING MAIL TO:
it takes localhost.
Apache restart
No change
Log out and log in
No change
Reboot
no change

now I search the entire harddisk for another php.ini.
No other php.ini found than the one in winnt
Now I run out of options.

View Replies !
SMTP/TLS
Does anybody know the simple way to send mail via SMTP/TLS? I know that
I can use fsockopen with "tls://" and send SMTP command manually but I
hope there is more simple manner.

View Replies !
SMTP
my php.ini setting is
SMTP = mail.aaa.com.my
smtp_port = 25
sendmail_from= xxx@aaa.com.my

$email = "xxxxx@yahoo.com";
$subject = "my subject!";
$message = "My Message!";

mail($email, $subject, $message, "From: $email");

echo "The email has been sent.";

my problem is i can only send mail to? @aaa.com.my, i cant send email to others like yahoo or hotmail.

View Replies !
Using My ISP SMTP
im sure this is a novice problem and ive found it hard to find similar sources that integrate with my form. All i want to do is link my form to send to my specified email using my ISP smtp. Here is my code:

<?php
$firstname=$_POST['FirstName'];
$lastname=$_POST['LastName'];
$email=$_POST['Email'];
$comment=$_POST['Comment'];

$toaddress = 'myemail@hotmail.com'
$subject = 'You Have A New COmment'
$mailcontent = 'First Name: '.$firstname. "" .'Last Name: '.$lastname. "" .'Email: '.$email. "" .'Comments: '.$comments. ".....

View Replies !
Send Header Info To A Page, Retrieve Response And Send That As Header
I am sending a header to page.html from sender.php using fgets(). I am then trying to retrieve that page's response, and set that as a header in sender.php in order to set any cookies etc.... that page.html might want to set. Right now I am using the following code:

View Replies !
Send Email - Page Where You Enter An Email Address And Click Send.
I am interested in creating an "email -this" type ability for a website. I am sure most people have seen an "email -this story" type link that is standard on most news web sites. You click such a link and then it takes you to a page where you enter an email address and click send. The link for the story and the title are not editable. Does anyone know where I can find example code of how to do this with php, and any explanation of how this works.

View Replies !
Setting Up Php.ini For Smtp Using Iis
I'm trying to make my web server a mail server and web server in one, kind of. I wan't my server to send out emails when requested by php using the smtp server of Microsoft iis. But one problem, I don't know how to set up IIS or php.ini to work with eachother.

I set up iis so I can recieve email through my server from a domain. But I don't know how to get it so that php uses IIS to send emails out with smtp. Does anyone know how to do this? If not, does anyone know how to make my server a windows smtp mail server that works with php?

View Replies !
Mail - SMTP ?
1) Does anyone know where we can d/load the smtp.php file ?

2) if you scroll down that screen - Theres a few examples that suggest SMTP.. however theyre either too little information - or too much information (Makes it complex, or too much info so I miss the important bits..)

View Replies !
Different SMTP On Linux
I read that you can specify a nonlocal SMPT host, for the "mail()" function, when running windows.

View Replies !
SMTP Issues
For some reason my (IIS WinXP SP2) SMTP server doesnt send messages, everything comes through from php alright, the email is generated and so on, then all the mails endup in the: C:InetpubmailrootBadmail folder, ive tried all sorts on this one and it doesnt seem to work. I have had this setup before and worked fine but i belive i was using a bundled package of apache, php and mysql, at present im using standalone installations of the above mentioned.

View Replies !
SMTP And PHP Problems
Running php version +5 and using win2k sp4 iis smtp server, set it up on port 245 cos thought isp was blocking it..? doesnt seem to be, tested scripts on another server, work fine...

So whats the problem, ive setup php.ini like so:

View Replies !
Php Mail() And SMTP
Is there any way to set up the php mail() function so that it sends a
username and password to the server? I'm on a winXP machine, and I have an
SMTP provider, but it requires me to login to use it, and for some reason I
can't find anything about it in the php.ini file.

View Replies !
Mail Via SMTP
I was wondering how I could send an email via SMTP using php.

View Replies !
Smtp Name In Php With Linux
Iam working with php on Linux, I want the Mail Server name to be changed dynamically irrespective of the php.ini settings, I tried couple of scripts from forum, it is not working instead always it is taking local host as the mail server Does any one has any clue.

View Replies !
NT4 SMTP Server
anyone know where I can get one? A imap/pop3 server would be gr8 too..

View Replies !
Smtp Connection
I am having difficulty connection to an smtp host. I am using the
following code but I don't think I fully understand what smtp host can
be used.

function setSMTPParams($host = null, $port = null, $helo = null, $auth
= null, $user = null, $pass = null)
{
if (!is_null($host)) $this->smtp_params['host'] = $host;
if (!is_null($port)) $this->smtp_params['port'] = $port;
if (!is_null($helo)) $this->smtp_params['helo'] = $helo;
if (!is_null($auth)) $this->smtp_params['auth'] = $auth;
if (!is_null($user)) $this->smtp_params['user'] = $user;
if (!is_null($pass)) $this->smtp_params['pass'] = $pass;
}

I don't fully understand that the $helo parameter is needed for.

Should I be able to access any smtp host which I own. I have two ISP
account and each have an smtp service. I use them for email. I notice
I can only use the smtp service associated with the ISP I am currently
connected to. Is that a common restriction which is the same reason I
am prevented from accessing the service from my php script?

Maybe the question I should this. What type of smtp account do I need
in order to send an email from my php script?

View Replies !
Mailing With Php, But Not Via SMTP
I have to send ALOT of emails at once, but media temple limits it to 500 emails per hour, which is why i dont want to use SMTP. is this going to take forever using just PHP, or is there a faster way?

View Replies !
Remote Smtp
I have an account registered with a free server. It's kind of like those free ones that you can register for, like hyperPHP for instance, that have PHP and MySQL. I need to use a remote gmail SMTP account to send mail, however. As you know, the default for the mail() function  is to use localhost. How can I change this so that the mail() function uses my gmail account's smtp server (smtp.gmail.com)?

I have the outgoing port, username and password. All I need to know is how to change the settings. Also, note that since this is a free server registration, I don't have access to the internal software running the server. All I have is the account.

View Replies !
How Can I Detect SMTP?
How can I detect SMTP? I have a php script that wont send out an email, no errors, so I think the SMTP is disabled? I'm not sure how that part works. This script isn't for me, and I don't know if there server will have the capabilities to send php email. So, before I tell php to send the email, I want to see if it can send an email.

So I have a few questions:

1.) How can I detect SMTP settings?
2.) How do I enable or install SMTP?
3.) Is there a way to turn SMTP on from a PHP script?

View Replies !
Class.smtp.php / Php Smtp Class
For 5000 or 10000 emailers, should use class.smtp.php. Can anyone show me the example of use for class.smtp.php

View Replies !
Smtp Server
i can get the smtp server to work and send to outlook express however when i try and send to gmail or hotmail the emails won't send?

View Replies !
PHP Through SMTP On 2nd Server
One for websites and one for email, both are RedHat. I want to be able to use php mail() to submit emails from the webserver to the mail server.

i have tried different settings, but most of the settings i find refer to Windows boxes and not unix.

what settings do i have to change to make this work. The php.ini is set with:
SMTP = 'mail.server.com', but as i read this only is valid on windows installations and not unix.

View Replies !
SMTP Socket
I have a question regarding communicating with SMTP server trough sockets... Since PHP communicates with SQL throuqh sockets is it possible to communicate the same way with SMTP server?

View Replies !
Php.ini SMTP Errors
I have attached a zip file containing my php.ini file, my .php file and the error message that I receive back when attempting to send the form on a MAIL POST basis.

I was originally using Apache but have got rid of that and taken out the old php.ini file. I am now using WAMP and PHP Designer 2007.

If anyone could offer me some advice on this one it would be great.

I have checked and my SMTP is working all ok so there is no reason why when sending the form the email shouldnt come through.

View Replies !
Phpmailer/smtp
my phpmailer script, which emails a cart confirmation to a customer, does not work every now and then. However, I've identified when this happens, and am guessing at the problem. At work, we have wireless connectivity, and the way they have their wireless setup, I can NOT send mail, via outlook, using my websites smtp server.

The wireless connection at work FORCES me to use their smtp server in order to send mail via outlook. And this is where i have problems with phpmailer. So is this because of the same reason? Is it because the phpmailer uses smtp and the isp that i am using here at work will not allow me to use another smtp other than theirs?

View Replies !
SMTP Configuration
I'm using Wamp for php, I've little doubt to config the smtp for sending mail. I go thru by reference by wamp installation manual, still i've facing the problem. I've changed

smtpserver =mail.mydomainname.com
smpt_port=25

in both apache/bin2/php.ini file as well as php/php.ini. its working fine with in mydomain name sending to other like that gmail / yahoo or someother the following errors display. "The message could not be sent because one of the recipients was rejected by the server. The rejected email address was email-id .server response: 553 sorry you have not authenticated for relay and <emailid> is not a local address server errror 553, error number :0x0800CCc79.

View Replies !

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