Posted by J.O. Aho on 09/28/69 11:40
noone wrote:
> Hi,
>
> I've saved some data in MySQL in a field of type LONGTEXT. How can i display
> the data in <textarea> format, ie. with the <LF> or <CR> in the original
> places?
>
> I can only display the field in <textarea> format only when i use a form,
> but i do not want to allow users to edit the data.
>
> Is there any other way to display the data correctly?
<pre>
<?PHP echo $longtext_data; ?>
</pre>
or
<?PHP echo nl2br($longtext_data); ?>
//Aho
Navigation:
[Reply to this message]
|