It was really easy and still works on one of my machines.
The most important part is getting the php.ini file correct. You should have your ISP's SMTP server also handy, as you will enter this info into the php.ini file.
There are better ways to send mail using phpmailer(but this is object oriented but I found that it is quite logical and easy to configure too.)
The following explanation is for when you want to send mail from you own local computer, so sending mail through php is even easier if you have a good web host, since they have(should have) the mail server configured correctly.
Anyway for your home pc you need to configure php first.. Use the php.ini file and follow these steps. Further instructions on how to send mail can be found at:
Before you can send email with PHP, you need to set it up to do so, just as you need to set up your email program before it can send messages. Configuration for sending email in PHP is done with the php.ini file, so open up your Web server's php.ini in whichever editor you normally use.
If you don't run your own server, but instead have a PHP-equipped Web host, you can safely assume that everything in this section has been done for you, and skip ahead.
In the section entitled [mail function] in the php.ini file, you'll find three settings: SMTP, sendmail_from, and sendmail_path. If your server runs on a Windows machine, you'll want to set the SMTP option to point to your SMTP server (or your ISP's SMTP server, if you're setting up PHP on your home machine). If instead you're setting up PHP on a Linux (or other Unix-based OS) server, you'll want to set the sendmail_path option to point to the sendmail program on your server, passing it the -t option. You can use the SMTP option in Linux instead if you don't have sendmail set up.
In either case, you'll want to set the sendmail_from option to your email address, or whichever address you'd like to appear as the default 'from' address for emails sent from PHP scripts.
Here's how the section might look on a typical Windows server, or on a Linux server without sendmail:
[mail function]
; Setup for Windows systems
SMTP = smtp.my.isp.net
sendmail_from = me@myserver.com
And here's how it might look on a Linux server with sendmail:
[mail function]
; Setup for Linux systems
sendmail_path = /usr/sbin/sendmail -t
sendmail_from = me@myserver.com
With those settings in place, restart your Web server and you're ready to go!