Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.
-
markusrobinson #1
RTF to CFM Help
A company has desinged an application that stores information in an SQL
database. I was given the task to display this information on a webpage. Some
of the information prints out as
"{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttb l{\f0\fnil\fcharset0
Microsoft Sans Serif;}} {\colortbl ;\red255\green0\blue0;}
\viewkind4\uc1\pard\cf1\b\f0\fs29 TEST\cf0\b0\fs17\par } Text".
How do I change this into something I can work with??
markusrobinson Guest
-
TWesson #2
Re: RTF to CFM Help
If all you want is the text outside of the curly braces, you'll have to parse
out everything within the curly braces.
At first I thought maybe you could do this using a regular expression but it's
more difficult than that because there are nested curly braces.
It'll probably require a homemade parsing routine.
Unless of course they want to just have the RTF document display as a whole.
Then you could probably use CFCONTENT with the appropriate MIME setting.
Google CFCONTENT and MIME -- here is another link.
[url]http://livedocs.macromedia.com/coldfusion/6.1/htmldocs/manage18.htm[/url]
TWesson Guest



Reply With Quote

