Use the HTMLEditFormat() function, like this:

<cffile
   action = "write"
   file = "fullfilepath/myfile.cfm"
   output = "How can I prevent the code in my string from being
processed?<br>#HTMLEditFormat('<cfinclude template="myfile.cfm">')#<br>This
is a test."

~Dina


----- Original Message -----
From: "Andy Ewings" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Wednesday, February 26, 2003 8:50 AM
Subject: RE: Writing CF to a string


> thanks Rich
>
> -----Original Message-----
> From: Rich Wild [mailto:[EMAIL PROTECTED]
> Sent: 26 February 2003 14:37
> To: CF-Talk
> Subject: RE: Writing CF to a string
>
>
> sorry Andy, I'm not thinking straight, which is a requisite when answering
> questions.
>
> you don't even need that chr() bit.
>
> <cfset myCFStr = '<cfinclude template="myTemplate.cfm">'>
>
> will work fine and doesn't get evaluated.
>
> > -----Original Message-----
> > From: Andy Ewings [mailto:[EMAIL PROTECTED]
> > Sent: 26 February 2003 14:36
> > To: CF-Talk
> > Subject: RE: Writing CF to a string
> >
> >
> > Rich
> >
> > But won't that still be evaluated?
> >
> > Also aint it chr? - and I think  "<" is chr(60) (maybe wrong).
> >
> > -----Original Message-----
> > From: Rich Wild [mailto:[EMAIL PROTECTED]
> > Sent: 26 February 2003 13:52
> > To: CF-Talk
> > Subject: RE: Writing CF to a string
> >
> >
> > <cfset myCFstr = '#char(139)#cfinclude
> > template="mytemplate.cfm"#char(155)#'>
> >
> > > -----Original Message-----
> > > From: Andy Ewings [mailto:[EMAIL PROTECTED]
> > > Sent: 26 February 2003 13:53
> > > To: CF-Talk
> > > Subject: Writing CF to a string
> > >
> > >
> > > Does anyone know how to create a string containing CF code
> > > without it being
> > > evaluated?  i.e. I want to create a file containing the text
> > > <cfinclude
> > > template-"mytemplate.cfm">
> > >
> > > I have tried this by creating a straing containing <cfinclude
> > > template-"mytemplate.cfm"> using the DE function but when I
> > > try to look at
> > > the contents of this string all I see is double quotation marks
> > >
> > >
> > >
> > >
> >
> >
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to