form input to email format problem


#1

I have an input form passing info and an attachment to an email. All works fine except the format of the email which prints all text on the same line.

Code is now: [php]$strMessage="Content: “.$_POST[“txtfname”].” \n “.$_POST[“txtlname”].” \n “.$_POST[“txtDescription”].” "; [/php]

I have tried “\n” and that throws an error. What really puzzles me is there are no syntax errors but the code does NOT produce the desired results.

i.e Actual Results = John Doe Description etc etc

Desired Results:

John
Doe
Description
etc
etc

Can it be the position of the \n ? I’ve tried several different placements but keep getting syntax errors.

Help will be greatly appreciated !


#2

You can try \r\n, \n\n or just use the html