• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

display formating text

New Here ,
Apr 11, 2007 Apr 11, 2007

Copy link to clipboard

Copied

How to display the formatted text from access memo field using coldfusion without loosing the formating of the text
TOPICS
Advanced techniques

Views

331

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 11, 2007 Apr 11, 2007

Copy link to clipboard

Copied

user341975 wrote:
> How to display the formatted text from access memo field using coldfusion without loosing the formating of the text

How is the text formated?

If the memo field contains HTML markup such as <h1>Hello World!</h1>,
then all you need to do is <cfoutput>#query.memoField#</cfoutput>

If it contains some other type of markup or the markup is escaped, then
other process will need to be used. But we will need to know exactly
how the data is stored in the database.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Apr 11, 2007 Apr 11, 2007

Copy link to clipboard

Copied

You can use the <pre></pre> HTML tags to maintain line breaks and spacing (though you'll probably want to do some stylesheet work with that tag because the default style is pretty ugly). On the otherhand if all you are interested in is line breaks, you can do the following:

<cfset sFormattedString = Replace(myString, "#chr(13)##chr(10)#", "<br>", "all")>

chr(13) and chr(10) are the ASCII character codes for line break and line feed (respectively).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
Apr 11, 2007 Apr 11, 2007

Copy link to clipboard

Copied

LATEST
double post (original in General Discussion forum)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation