Doesn't make new lines
Posted: Wed May 24, 2006 1:20 pm
Hey.
This is my code:
But it doesn't make new lines where it is print "\n";
I've tryed with print "<br>"; and echo "\n"; and echo "\n"; but nothing works. Why?
Thanks
This is my code:
Code: Select all
<?php
$sql = "SELECT COUNT(id) FROM auction where status='ny'";
$result = mysql_query($sql) or die(mysql_error());
//$limit = 3; // Antal "nya" nyheter
$row = mysql_fetch_array($result);
$numrows = mysql_result($result, 0); // antal i databasen
if (mysql_result ($result , 0) <= 0)
{
print '<br>Finns inga auction ännu!<br>';
}
else
{
$result = mysql_query("SELECT * FROM auction where status='ny' ORDER BY id DESC LIMIT 1");
$row = mysql_fetch_array($result);
$text = "Denna auktion startades:". $row['datum_borja'];
print "\n";
$text .= "Auktionens namn är:". $row['auktionnamn'];
print "\n";
$text .= "Det kan vara totallt". $row['maxantalbud'];
$text .= " bud";
print "\n";
$text .= $row['info'];
print text_replace($text);
}
?>I've tryed with print "<br>"; and echo "\n"; and echo "\n"; but nothing works. Why?
Thanks