943,693 Members | Top Members by Rank

Ad:
  • PHP Discussion Thread
  • Unsolved
  • Views: 3525
  • PHP RSS
Jan 26th, 2008
0

Send email through php?

Expand Post »
How do I send an email...

I have WAMP (windows xp apache, mysql and php).

But what do I do now. Explain...
Similar Threads
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Jan 26th, 2008
0

Re: Send email through php?

PHP has a function made for this exact purpose.

Mail($to, $subject, $body)

Do some research on it, it's not hard to use.
Reputation Points: 31
Solved Threads: 1
Newbie Poster
inzomniac is offline Offline
23 posts
since Feb 2007
Jan 26th, 2008
0

Re: Send email through php?

I'm afraid that didn't work, anyone else?
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Jan 26th, 2008
1

Re: Send email through php?

Click to Expand / Collapse  Quote originally posted by iamthwee ...
I'm afraid that didn't work, anyone else?
If you didn't set up the smtp settings in your php.ini file, it won't work. Check the SMTP and smtp_port settings.

If you're determined not to use the mail function or need something more advanced, try phpMailer.

Good luck,
- Walkere
Reputation Points: 29
Solved Threads: 5
Junior Poster in Training
Walkere is offline Offline
57 posts
since Jan 2008
Jan 26th, 2008
0

Re: Send email through php?

Thank you for your reply, but what do I put for the smtp settings. Would it have something to do with my Internet service provider, would it be localhost? I'm confused

btw (I don't have an email client on windows)
Last edited by iamthwee; Jan 26th, 2008 at 11:16 am.
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Jan 26th, 2008
0

Re: Send email through php?

Click to Expand / Collapse  Quote originally posted by iamthwee ...
Thank you for your reply, but what do I put for the smtp settings. Would it have something to do with my Internet service provider, would it be localhost? I'm confused
I've never set one up on a windows server, but I would assume you would use your ISP's SMTP server. This is usually "smtp.isp.com" or "mail.isp.com" or some such thing. For example, mine is "mail.optonline.net" for Optimum Online.

This would be the same server you'd use to set up an e-mail client... if you used one =)

- Walkere
Reputation Points: 29
Solved Threads: 5
Junior Poster in Training
Walkere is offline Offline
57 posts
since Jan 2008
Jan 26th, 2008
0

Re: Send email through php?

Crap, is this a lot simpler to set up using linux then?
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Jan 26th, 2008
0

Re: Send email through php?

No I'm not getting anywhere with this.

I think my mail SMTP is mail.btinternet.com

It returned successful when I did a telnet on port 25.

Start > run > (type in cmd)
telent mail.btinternet.com 25
I changed my php.ini file to match this, restarted the services yet I still get an authentication problem. I think it is because I don't have an email client....
Last edited by iamthwee; Jan 26th, 2008 at 5:51 pm.
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005
Jan 27th, 2008
0

Re: Send email through php?

OK if I use a linux server, which is feasible, although my mom is gonna screw at me for wiping off windows LOL, does this avoid the problems regarding SMTP setting etc?

Thanx in advance.
Featured Poster
Reputation Points: 1536
Solved Threads: 431
Posting Expert
iamthwee is offline Offline
5,865 posts
since Aug 2005

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in PHP Forum Timeline: get the value from derived table
Next Thread in PHP Forum Timeline: multi-file Class in PHP





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC