Skip to main content
Inspiring
June 13, 2006
Question

Line break

  • June 13, 2006
  • 2 replies
  • 358 views
Project description is big text. I need to break the text while displaying based on user entered line breaks. How can i do this?.
    This topic has been closed for replies.

    2 replies

    Inspiring
    June 15, 2006
    If the text was entered into a storage (database?) using a text field, then you will have a carraige return and a line break to deal with. When displaying this same information back to a text field it should display correctly. However if you are displaying it to be HTML text, the browser will not detect the CR and the LB and the text will just 'runon' without line breaks.

    A solution is:
    #replace(replace(databasefield, chr(10), "<BR>"."all"), chr(13), "<BR>"."all")#

    hope this helps
    Inspiring
    June 13, 2006
    Do you mean that proj desc is a stored in a database or is a CF variable ?

    How does the user enter line breakes? In the proj desc displayed in some editable text box?

    you could store <br> tags in with the proj desc text...