nl2br & BLOB field of MySQL
| From: | Jorge Pinto Leite | Date: | Fri, 30 Aug 2002 22:36:07 +0000 |
| Subject: | nl2br & BLOB field of MySQL | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-21487@lists.php.net to get a copy of this message | ||
It's probably a problem of my code, can anyone help me?
I have a BLOB field in a MySQL table. This field is filled in a php page
with a <textarea>, where I can enter it formatted, with ENTER's to split
some lines from others.
In another page, this field is seen (not updated) - so I don't have a
<textarea> tag.
As I want to see the text exactly as entered, I have put the following code:
$res="<td><font...";
$res.=nl2br($row[blobfield]);
$res.="</font></td>";
echo ($res);
and the result is that I cannot see any part of the blob field.
If I change my code to
$res="<td><font...";
$res.=$row[blobfield];
$res.="</font></td>";
echo ($res);
the complete blob field is seen, yet unformatted.
What am I doing wrong?
Thanks,
Jorge
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.384 / Virus Database: 216 - Release Date: 21-08-2002