That's fine if the CFC method is returning a string, you could argue "why not just output the string to the HTTP buffer?" But what if the method is returning a query? An array? A structure? CF *can't* just output it to the HTTP buffer...*unless* it encodes it to WDDX first! Which is why you're seeing what you're seeing...CF doesn't make distinctions on the type of the data the method is returning, it encodes all types as WDDX. That's the only consistent way it could be done.
> -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf > Of stylo~ > Sent: Wednesday, October 27, 2004 3:42 AM > To: [EMAIL PROTECTED] > Subject: RE: [CFCDev] Calling CFC method as URL always returns WDDX? - why > it bites > > > What http processor? Coldfusion? There is an http header on it already; > the > content itself doesn't need to be wrapped in xml. Whoever is doing it, and > wherever it is being done, it is Coldfusion choosing to wrap the cfc > result > in this: > > <wddxPacket > version="1.0"><header><data><string>description</string></data></header> </ > wd > dxPacket> > > which is not at all necessary http-wise, but something to do with how the > cfc interacts with browser calls. A cfc *could* output merely the text, > "description" with an http header to the browser rather than the above. A > cfm page doesn't wrap content in a wddx packet when answering over http. > Thus, the net effect is the same, but perhaps reworded as: "CF is > specifically wrapping CFC results in XML if called by a browser." > ---------------------------------------------------------- You are subscribed to cfcdev. To unsubscribe, send an email to [EMAIL PROTECTED] with the words 'unsubscribe cfcdev' in the message of the email. CFCDev is run by CFCZone (www.cfczone.org) and supported by Mindtool, Corporation (www.mindtool.com). An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]
