I want to know how we use nl2br on form_textarea??
so when we input some text on it and we press ENTER it became a newline or
so on database its save as :
some text
some textnot
some text some textplease help me
This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.
The active forums are here.
April 29, 2009 1:30am
Subscribe [2]#1 / Apr 29, 2009 1:30am
I want to know how we use nl2br on form_textarea??
so when we input some text on it and we press ENTER it became a newline or
so on database its save as :
some text
some textnot
some text some textplease help me
#2 / Apr 29, 2009 1:33am
so on database its save as :
some text some textnot
some text some textplease help me
You shouldn’t use nl2br unless you’re outputting it on the web page and not a textarea. About the saving part(saving the <br /> in the database). I don’t get why you need it there, any reason for it?
#3 / Apr 29, 2009 1:37am
what should I use?? I have news DB , on admin I put the news through form_textarea
on webpage I want display it
so when I put the news on form_textarea when I press ENTER it became
#4 / Apr 29, 2009 1:42am
what should I use?? I have news DB , on admin I put the news through form_textarea
on webpage I want display it
so when I put the news on form_textarea when I press ENTER it became
As I said in my other reply, when you’re outputting on the webpage, you can use the nl2br(). You can also use, auto_typography()
#5 / Apr 29, 2009 2:05am
I mean if the user use the admin area on the form_textarea they dont need to type
.
they just typing and when the want make a newline they just press Enter
how we make it?? what we usa to make that? nl2br??
#6 / Apr 29, 2009 2:23am
I mean if the user use the admin area on the form_textarea they dont need to type
.
they just typing and when the want make a newline they just press Enter
how we make it?? what we usa to make that? nl2br??
You don’t need to type in ‘<br />’.
#7 / Apr 29, 2009 4:18am
before using or echo value in view
use:
echo nl2br($textarea_value);Keep going