HomeWeb HostingReseller Web HostingDedicated ServerResources & Support

Go Back   Web Hosting Technical Support Discussion Forum > General Web Hosting Discussion Forum and Support > How To's > PHP Scripts

PHP Scripts Post Only PHP Scripts in this section... Accu Web Hosting
Become a Fan

Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old 06-29-2008
Administrator
 
Join Date: Jun 2006
Age: 26
Posts: 264
Blog Entries: 8
Rep Power: 10
Shane has disabled reputation
Default How to send email via PHP code on Windows server

Hello All,

One can send email via PHP code on windows server. Please refer below mentioned sample script of PHP Mail:

<?php

$to = 'To Email account';
$from = 'From Email account';
$subject = 'Subject line of the message';

$headers = 'From: From email account’. "\r\n".
'Reply-To: Reply toe mail account'. "\r\n".
'Return-Path: Return path email account’. "\r\n".
'X-Mailer: PHP/' . phpversion();
$message = "Message of the email – body section";

mail ($to, $subject, $message, $headers, "-f $from");

?>

Thanks,

Shane G.
AccuWebHosting.Com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 06:48 PM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
http://www.accuwebhosting.com/terms.htm


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42