Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    Regular Coder
    Join Date
    Oct 2009
    Posts
    438
    Thanks
    9
    Thanked 7 Times in 7 Posts

    Allowing Returns in Textarea

    All,
    I have a textarea and I want it to be like this one where when I hit enter it saves the spaces. Do I need to have a RTE or can I do something with my standard form textarea to allow it? I also use the following code to post it:
    Code:
    $story = mysql_real_escape_string(stripslashes($_POST['story']));
    Thanks in advance.

  • #2
    Regular Coder
    Join Date
    Oct 2009
    Posts
    438
    Thanks
    9
    Thanked 7 Times in 7 Posts
    If I do need to use an RTE, does anyone have any recommendations on a good one to use?

    Thanks.

  • #3
    Senior Coder kbluhm's Avatar
    Join Date
    Apr 2007
    Location
    Philadelphia, PA, USA
    Posts
    1,509
    Thanks
    3
    Thanked 258 Times in 254 Posts
    The "spaces" are saved.

    http://www.php.net/nl2br


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •