> Sorry about that. Thanks guys for bearing with me on this one.
>
> Doesn't the cfcontent have to output the variable?
>
> <cfoutput>
> <CFSET X="document.writeln('<a href=""#qGetCurrentAdLink.link_url#""><img 
> src=""http://www.photoeye.com/magazine/ads/#qGetAd.image_filename#"";></a>');">
> <cfset x = jsStringFormat(x)>
>
> <cfcontent type="application/javascript" reset="yes" variable='#x#'>
>
> </CFOUTPUT>
>
> The cfcontent errors out as can be seen by clicking the source code of the
>
> http://www.photoeye.com/advertising/pull_ad.cfm
>
> Here's the error:
>  Attribute validation error for tag cfcontent.
>  java.lang.String is not a supported variable type. The variable is expected 
> to contain binary data.

When you use CFCONTENT by itself to return content, CF expects that
content to be binary. The VARIABLE attribute should contain a file.

If you want to use CFCONTENT to return content that you're generating
within the CF script that contains the CFCONTENT tag, you'd do it like
this:

... code to generate the string to output ...
<cfcontent type="mimetype"><cfoutput>#stringToOutput#</cfoutput>

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/
http://training.figleaf.com/

Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on
GSA Schedule, and provides the highest caliber vendor-authorized
instruction at our training centers, online, or onsit

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:337510
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to