473,386 Members | 1,830 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

remote SMTP server

Hi, I'm trying to setup PHP so it will use a remote SMTP server.
I'm going to sound like a newbie but how? I know you need to alter
php.ini, change SMTP from localhost to the SMTP server and the address
to the correct one but I wondered about passwords? Outlook Express
needs a password so how would I do it.
Unless anyone has any other suggestions/tutorials. Oh and just so you
know my port 25 is blocked by ISP, I think that limits my choices.

Ah forgot to mention, I managed to send a test email from my home
machine to another account using Xmail server but I can't get it to
work from a PHP script.

Thanks in advance,
Jul 17 '05 #1
3 13841

"Andy Turner" <an**********@btopenworld.com> wrote in message
news:8d**************************@posting.google.c om...
Hi, I'm trying to setup PHP so it will use a remote SMTP server.
I'm going to sound like a newbie but how? I know you need to alter
php.ini, change SMTP from localhost to the SMTP server and the address
to the correct one but I wondered about passwords? Outlook Express
needs a password so how would I do it.
Unless anyone has any other suggestions/tutorials. Oh and just so you
know my port 25 is blocked by ISP, I think that limits my choices.

Ah forgot to mention, I managed to send a test email from my home
machine to another account using Xmail server but I can't get it to
work from a PHP script.

Thanks in advance,


I've not done what you want to do however Outlook Express wants a password
for your POP3 settings (ie, to read/get your email). SMTP does not need a
username/password though some ISPs have managed to implement POP3 before
SMTP as a workaround for this (roughly meaning that the password you used to
get your email gets you temporary access to the SMTP server). Typically
though ISPs just check that you are on their network to get access to the
SMTP server to reduce the potential from non-customers relaying junk email
through their servers.

If you managed to send a test email from your home machine, you should
provide php.ini the same SMTP settings that you gave to xmail and then
try...

If that doesn't work, then I *believe* (I'm not definite) that you could
create your own SMTP sending function from within PHP. It is a standard
that the mail traffic agent (that handles email in/out of a server) listens
for email on port 25 - If you only want to send email (ie not
listen/receive), you could in theory use any port (thus use sockets in PHP)
to send an email - Thus you could in theory send using your local port 50 if
you wanted, but have your script communicate with remote port 25 on the
machine receiveing the email.

I'd suggest you join the sendmail newsgroup and bounce a few technical
questions at them if you plan on following my last suggested option.
Jul 17 '05 #2
an**********@btopenworld.com (Andy Turner) wrote in message
news:<8d**************************@posting.google. com>...

I'm trying to setup PHP so it will use a remote SMTP server.
Get yourself a copy of phpMailer:

http://phpmailer.sourceforge.net/
I'm going to sound like a newbie but how? I know you need to alter
php.ini


With phpMailer, there's no need to modify anything, as you will not
be using (and, hence, needing) mail() function nor imap_*() functions.

Cheers,
NC
Jul 17 '05 #3
KAH
"Randell D." <yo**************************@yahoo.com> wrote in
news:qX*********************@news1.calgary.shaw.ca :
I've not done what you want to do however Outlook Express wants a
password for your POP3 settings (ie, to read/get your email). SMTP
does not need a username/password though some ISPs have managed to
implement POP3 before SMTP as a workaround for this (roughly meaning
that the password you used to get your email gets you temporary access
to the SMTP server). Typically though ISPs just check that you are on
their network to get access to the SMTP server to reduce the potential
from non-customers relaying junk email through their servers.


If your ISP uses POP3 auth to give you SMTP access, change ISP immediately.
There is an SMTP service extension detailing SMTP authentication [1], which
all sane mail admins should use. This is the best solution if you can't be
sure of having all users coming from a specific network.

I don't think the mail() function has support for this, although I guess
sendmail might have and that you just have to give it the right arguments.
See the sendmail docs for that.

KAH
[1]: http://ftp.isi.edu/in-notes/rfc2554.txt
Jul 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: dtblankenship | last post by:
Hello all, I am creating an application which must send an email once all has been submitted to the user with a confirmation. In my workplace, we're required to use a remote SSL SMTP server to...
9
by: Hazz | last post by:
If I were to deploy components to clients whose Windows infrastructure is unknown, ie. not sure they have Microsoft Exchange running or not, how would I set up a kind of Dr. Watson like mechanism?...
3
by: ratnesh | last post by:
hi, how can i send smtp mail from my asp.net webform. i give the smtp server name, but the server is remote and it requires authentication (login) to send mail. i dont know how to do that ...
2
by: desais | last post by:
I am using the cdo.dll to send out emails in C#. But instead of connecting to my local smtp to forward the email I am changing the smtp server to the recipients server for each email. This works...
34
by: antonyliu2002 | last post by:
I've set up the virtual smtp server on my IIS 5.1 like so: 1. Assign IP address to "All Unassigned", and listen to port 25. 2. Access Connection granted to "127.0.0.1". 3. Relay only allow...
0
by: Homer | last post by:
Hi, I got "InnerException: Unable to connect to remote server"..."No connection could be made because the target machine actively refused it" when I attempted to send an email through my...
2
by: sam | last post by:
Hi, I made asp.net website. I send e-mail via asp.net page to receiver but receiver cannot get email. I use smartertool Server SMTP. Sending and receiving to localhost is working. Sending...
3
by: =?Utf-8?B?U3JpZGhhcg==?= | last post by:
Hi, I have created a windows application to send the emails. Following is the code I am using. Dim errMsg As String Dim ToAddress As String Dim FromAddress As String Try ToAddress =...
11
by: mp- | last post by:
I want to be able to allow people to check their email from my PHP online application. Given only the users 1) email address, 2) username (if applicable) and 3) password - how can I auto detect...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.