Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6
This is the forum to discuss the Wrox book Beginning PHP, Apache, MySQLWeb Development by Michael K. Glass, Yann Le Scouarnec, Elizabeth Naramore, Gary Mailer, Jeremy Stolz, Jason Gerner; ISBN: 9780764557446
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 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
  #1 (permalink)  
Old September 1st, 2004, 03:06 PM
Registered User
 
Join Date: Jun 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Chp 14 e-commerce

I have this error when I attempt to check out from the shopping cart. The source code I used is identical to the book's. Can someone help me with this please?

Warning: mail(): "sendmail_from" not set in php.ini or custom "From:" header missing in C:\website\test\ecommerce\checkout3.php on line 234


  #2 (permalink)  
Old September 1st, 2004, 04:09 PM
richard.york's Avatar
Wrox Author
Points: 5,506, Level: 31
Points: 5,506, Level: 31 Points: 5,506, Level: 31 Points: 5,506, Level: 31
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Camby, IN, USA.
Posts: 1,706
Thanks: 0
Thanked 6 Times in 6 Posts
Default

Have you checked the sendmail_from directive of php.ini? php.ini is located at C:\Windows\php.ini, or whatever your system root directory.

Regards,
Rich

--
[http://www.smilingsouls.net]
[http://pear.php.net/Mail_IMAP] A PHP/C-Client/PEAR solution for webmail
  #3 (permalink)  
Old September 2nd, 2004, 06:54 AM
Registered User
 
Join Date: Jun 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I did. This is what I have in my php.ini file (extracted):

; For Win32 only.
sendmail_from = jamesA@hotmail.com

What else do I need to set? Thanks ;)


  #4 (permalink)  
Old September 3rd, 2004, 06:14 PM
richard.york's Avatar
Wrox Author
Points: 5,506, Level: 31
Points: 5,506, Level: 31 Points: 5,506, Level: 31 Points: 5,506, Level: 31
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Camby, IN, USA.
Posts: 1,706
Thanks: 0
Thanked 6 Times in 6 Posts
Default

Do you still see the same error message after setting that directive? You may have forgotten to restart Apache, which is required for ini changes to take effect if PHP is installed as an Apache module. And of course you can simply provide the 'From:' field in the call to mail.

If you've taken all of these steps, then it would perhaps be better if we could see some code.

Regards,
Rich

--
[http://www.smilingsouls.net]
[http://pear.php.net/Mail_IMAP] A PHP/C-Client/PEAR solution for webmail


Similar Threads
Thread Thread Starter Forum Replies Last Post
Why does this code work (chp.6)? wrockinator BOOK: Ivor Horton's Beginning Visual C++ 2008 ISBN: 978-0-470-22590-5 3 December 3rd, 2008 03:16 AM
Chp.5 composite control properties studen77 BOOK: Professional ASP.NET 2.0 Server Control and Component Development ISBN: 978-0-471-79350-2 1 October 6th, 2006 03:35 PM
Chapter 14 - e-commerce Funky Monk BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 1 November 20th, 2004 12:49 PM





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