Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > PHP How-To
PHP How-To Post your "How do I do this with PHP?" questions here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the PHP How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old August 13th, 2007, 03:38 AM
Registered User
Join Date: Jul 2007
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to send mail

Warning: mail() [function.mail]: "sendmail_from" not set in php.ini or custom "From:" header missing in C:\Domains\sachalsoft.com\wwwroot\nabibux\index1.p hp on line 9
I m facing the above error when try to run the code to send email
please visit this url where i place the code

where i put the script to
see my smtp server info
by usiing above link you can see the configuration of sever where i host my site
i dont have permission to chage any thing in the sever now please tell how i send mail using php script
 i have the following code


$to_addr = 'nabibux@sachalsoft.com';

if (isset($_REQUEST['submit'])) {
   $mail_body = 'Name: '.$_REQUEST['name'];
   $mail_body .= "\nEmail: ".$_REQUEST['email'];
   $mail_body .= "\nMessage: ".$_REQUEST['message'];
   mail($to_addr,'Form Feedback',$mail_body);
   print "Thank you for the feedback.";
} else {
<form method="POST" action="$_SERVER[PHP_SELF]">
   <tr><td>Name:</td><td><input type="text" name="name"></td></tr>
   <tr><td>Email:</td><td><input type="text" name="email"></td></tr>
   <tr><td>Message:</td><td><textarea name="message"></textarea></td></tr>
   <tr><td colspan="2"><input name="submit" type="submit"></td></tr>


Thanks please help

Nabi bux

Similar Threads
Thread Thread Starter Forum Replies Last Post
Send mail and attachments with PHP mail function Lofa Beginning PHP 1 June 2nd, 2008 03:24 PM
send mail chavakoti BOOK: Professional SQL Server 2005 Integration Services ISBN: 0-7645-8435-9 1 September 4th, 2007 05:03 AM
Cannot send mail rajanikrishna JSP Basics 3 March 17th, 2006 01:39 AM
how to send a mail ashokparchuri General .NET 2 March 24th, 2005 07:55 AM
The mail can't be send jabby General .NET 2 September 8th, 2004 05:14 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.