MySQL problem

Discussion in 'PHP' started by karl_murphy, Apr 2, 2008.

  1. #1
    Does anyone know if it is possible to insert data from an html form into a MySQL database and then retrieve this data with the formatting still preserved?

    At the moment, when I display the retrieve data it is displayed as one large block of text rather than separated paragraphs.
     
    karl_murphy, Apr 2, 2008 IP
  2. vishnups

    vishnups Banned

    Messages:
    166
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #2
    it can be done...
     
    vishnups, Apr 2, 2008 IP
  3. idabble

    idabble Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Try using:
    str_replace("\n","<br>",$dbData);
    Code (markup):
    This will give you your paragraph formatting.
     
    idabble, Apr 2, 2008 IP