Thanks for the further tips, James...I'm sure it'll all come clear...(eventually :o)
So, am I to understand, that after reading http://jehiah.com/projects/cfjson/ that CFJSON will translate my json-formatted javascript data returned from an ajax call into CF-formatted data, ready-to-use on my calling page without having to write js translation looping procedures, etc.? In essence, CFJSON was written to solve my problem of getting JSON-formatted data from a CFC back into CF-formatted data so I can use standard CF operations on it? Rick > -----Original Message----- > From: James Holmes [mailto:[email protected]] > Sent: Wednesday, February 04, 2009 12:58 AM > To: cf-talk > Subject: Re: This CFC function and jQuery Ajax stuff is killing me... > > > Try $.getJSON instead of $.ajax for a little more efficiency. > > cfajaxproxy is the JS way of getting to the same point, essentially. > With either method, you need to be able to write the JS you need to > use the result set. You're getting back an object with two properties: > COLUMNS and DATA. COLUMNS is an array; DATA is an array of arrays. So > yes, there's going to be some looping involved. > > mxAjax / CFAjax docs and other useful articles: > http://www.bifrost.com.au/blog/ > > > > 2009/2/4 Rick Faircloth <[email protected]>: > > > > The call that I've been using is > > > > $.ajax({ cache: false, > > type: "post", > > url: > > "../components/floor_duty.cfc?method="get_duty_schedule", > > dataType: "json", > > data: "formval", <--- form values, etc., are put into this > > variable > > success: function(response) { > > > > etc... > > > > and in the cfc method, I specify returnFormat = "json". > > > > I looked over the Adobe docs and another resource I found, > > but I've got to tell you, I couldn't figure out what to do > > with the information. > > > > Am I supposed to make use of "cfajaxproxy" tag or Spry or what? > > From looking at the example in the docs for using an asynchronous > > CFC proxy, it's quite complicated. Will I have to learn how > > to loop over the data from the ajax call using javascript to be > > able to use the data on my calling page? > > > > I hope there's a much simpler answer than what I'm suspecting. > > I was just hoping I'd be able to use the struct (structSchedule > > in my code) much like I would a cfquery. > > > > Rick > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:318868 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

