The sample PHP mail script has the essential elements missing. Though the same can be seen at the following link:

http://www.buildwebsite4u.com/advanced/php.shtml

Thanks.