> <[EMAIL PROTECTED]> wrote:
>> You have output disabled with CFSETTING? If so, you'll
>> need to wrap the
>> CFSAVECONTENT in a CFOUTPUT if you want the text to
>> display.
>>
>> Cheers,
>> barneyb
>>
> Thanks Barney, that was it. Out of curiosity, isn't that a
> bit
> counter-intuitive? I mean, the whole purpose (in this
> case, at least)
> is to write the contents to a variable to pass back from
> my CFC. If
> I'm not writing anything to the output stream in
> cfsavecontent call
> itself, why do I need the cfoutputs? Just curious.
It does that because the features (cfsetting and cfsavecontent) are
encapsulated from each other... cfsavecontent in particular doesn't do
anything other than examine what's put into the output buffer and
capture it out into a variable. So when you have cfsetting set to
disable content to the buffer outside of cfoutput, no data reaches the
buffer and therefore cfsavecontent doesn't "see" anything to capture.
It is the same as if you were to put this in a custom tag:
<cfif thistag.executionmode is "end">
<cfset "caller.#attributes.variable#" = thistag.generatedcontent>
<cfset thistag.generatedcontent = "">
</cfif>
If nothing reaches the server's output buffer, then the
thistag.generatedcontent variable would be empty, and cfsavecontent is
the same way.
hth
s. isaac dealey 954.927.5117
new epoch : isn't it time for a change?
add features without fixtures with
the onTap open source framework
http://www.sys-con.com/story/?storyid=44477&DE=1
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

