Log in

View Full Version : Simple question



nate51
05-29-2008, 07:22 PM
I have a feedback form that is an html page with a form in it and it goes to a php page that send the information to my email address.

Below is the code for the php page, how would I be able to drop each option onto a new line instead of having them all line up on the same line?


<?php
$to = "xxxxx@xxxxxx.com";
$subject = "Request";
$message = "Artist: " . $_POST["artist"] ." Title: " . $_POST["title"] ." Comment: " . $_POST["comment"] ."\r\n";
$sent = mail($to, $subject, $message) ;
?>

I can image this will be a super quick answer.

warderlan
05-29-2008, 09:25 PM
Before " Title:" and " Comment:", you need to put a /n for newline in there, so it should look like this;

"/nTitle:"

and

"/nComment:"


Give that a try.

boogyman
05-30-2008, 12:34 PM
Before " Title:" and " Comment:", you need to put a /n for newline in there, so it should look like this;

"/nTitle:"

and

"/nComment:"


Give that a try.

its a backslash not forward


\nCODE

nate51
05-30-2008, 02:11 PM
That did it,

I knew it was a simple answer, thanks guys.


-- Nate