Hello,
I have a made a forum like page where a user can submit a thread and the information gets stored in a database. However, when I try to output the data it outputs it without any line breaks in it, example:
The user inputs:
Hello,
This a paragraph
It would output like this:
Hello, This is a paragraph
I can confirm that in my database the line breaks are saved so I believe the problem is only in the displaying. This is my code used to output the information:
{Top of page}
<?php
session_start();
//Connected to database here
$username = $_SESSION['username'];
$query = "select * from threads3 where tableID='{$_GET['threadID']}'";
$result = mysql_query($query, $conn) or die(mysql_error());
$getinfo = mysql_fetch_row($result);
$title = $getinfo[6];
$content = $getinfo[8];
$creator = $getinfo[2];
mysql_close($conn);
?>
{output code}
<div align='center' id='threadContentZ'>
<p id='threadContent'><?php echo $content; ?></p>
</div>