new paragraphs in php mysql

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vierow
    New Member
    • Apr 2007
    • 1

    #1

    new paragraphs in php mysql

    new paragraphs in php mysql

    I have a php form to upload stories into a mysql database

    when I retrieve the file "print $row[story]';
    all the paragraphs run together.

    How do I get carriage returns and new paragraphs to carry through. I works fine in the bulletin board I installed, but I can't find the code in all those files.

    J
  • JMathews
    New Member
    • Apr 2007
    • 10

    #2
    Have you tried the nl2br() funcion in PHP?

    This function will insert <br> in front of the \n normally associated with a line break, so it should look proper in HTML

    Comment

    Working...