Web Analytics Made Easy -
StatCounter How to break line in Textarea - CodingForum

Announcement

Collapse
No announcement yet.

How to break line in Textarea

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to break line in Textarea

    hi,


    can anybody tell me that how to break line in textarea.

    i m doing like this but it shows <br> as string.


    <textarea name="recreation_programs" readonly rows="10" cols="35">
    Code:
         $x = 0; 
        while($x < $no_of_dang_community){
            print $result_dang_community[$x]['recreation_programs'].'<br/>';
            $x++;
        }
    </textarea>

    Output:

    tryt <br/> rtyryry5464 <br/> dasdaaaaaaaaa <br/> dasdaaaaaaaaa <br/>



    I have also tried this :
    Code:
         $x = 0; 
        while($x < $no_of_dang_community){
            print $result_dang_community[$x]['recreation_programs'].'\r\n';
            $x++;
        }
    but it doesnot work
    Last edited by eshban; Sep 27, 2006, 08:16 AM.

  • #2
    nl2br

    Comment


    • #3
      Sorry dear,

      nl2br doesnot work as i want.

      Comment


      • #4
        nl2br doesnot work as i want

        Comment


        • #5
          Put double quotes around the /r/n.

          Comment


          • #6
            do not use nl2br before writing to database or file, use it when you take info from your's databse (not in textarea)
            Free php image upload script
            Personal web developing blog

            Comment

            Working...
            X