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 September 17th, 2005, 08:10 AM
Registered User
 
Join Date: Mar 2004
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default mail($to, $subject, $msg, $additional_headers);

when using this piece of code is there a way to get line breaks or paragraphs in the email that is sent to the recipient? atm its just one long line of text separated by full stops (periods) and commas. any work around on this?

this the response: Hello danny, thank you for your filling out this questionaire, here are your results:\n\n\nTotal number of questions: 17.Total marks: 34 \n\nRegards, \nThe Portable Group

this was the code
Code:
mail($_POST['email'],'The Portable Group','Hello '.($_POST['name']).', thank you for filling out this questionaire, here are your results:\n\n\nTotal number of questions: '.($_POST['Acc_section8questions'] = 17).'.Total marks: '.($_POST['Acc_section8complete'] = 34).' \n\nRegards, \nThe Portable Group', "From: [email protected]");
 
Old September 19th, 2005, 01:43 PM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 357
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to anshul
Default

'\n' actually means a new line, when you're writing in a file, suppose a text file.
Send an HTML e-mail by prperly setting '$headers' and use '<br />'.

Regards,

`~@#\^%&*/\.<.\/-|+|_!:;..=?>
Support Indian students' finances http://scholarship.mediasworks.com/





Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to get support on this subject! retribution All Other Wrox Books 4 January 9th, 2009 09:09 AM
subject anabnl BOOK: Beginning PHP5, Apache, and MySQL Web Development ISBN: 978-0-7645-7966-0 0 August 16th, 2007 05:35 PM
test subject tanu80 ASP.NET 1.x and 2.0 Application Design 1 June 28th, 2007 04:08 AM
component must be able to read the msg from mail schanda Pro PHP 0 August 17th, 2006 01:52 AM
E-mail Subject mani_he Pro PHP 2 April 29th, 2005 11:32 AM





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