blog | bio | agenda | jobs | ajaxCFC

ajaxCFC: DWR AddRows function improvement

I just released a small modification, but largely requested by the community: cell Renderers....

As the matter of fact, Kenton Gray came back to the rescue, he modified utils.js and wddx.js, so if you're upgrading, you only need to load those two files. You can check the new use with the same Query Example I posted before, but this time it adds some custom cell functions. Now you can send queries back from CF and easily populate tables with any custom code.

This is the true spirit of open source. Thanks Kenton! if anyone else has any suggestions or contributions, do not hesitate to drop me an email.

TrackBacks
There are no trackbacks for this entry.

Trackback URL for this entry:
http://www.robgonda.com/blog/trackback.cfm?E26AF0F2-3048-7431-E474502E3C09FC4C

Comments
I've been trying for.. 4 hours, to get ajaxcfc to work correctly for me. I dont think its a problem with your program itself, I guess i just cant seem to grasp the entire concept. Example, I want to return a query object and display it inside a div container, I cant use the table AddRows loop (which works great btw) becasue it will break other scripting I have around it. I can get this to work Great with simple things, but I am clueless on how to display that query object, but then looping it afterwards and trying to get it right and.. I'm just lost, if anyone could explain how to use complex objects with this, please do.
# Posted By Don Q | 3/10/06 4:22 AM
Ho can I assign value to a coldfusion variable returned from callBackFunction?
Suppose callBackFunction returned a query, and based on query result value, I need to do some business logic using CFM.
Inorder to do that, I need to assign the query result to a coldfuson variable. How can I do that?
# Posted By shimju | 3/10/06 8:47 AM
Hi Don Q,

I use the familiar CFOUTPUT in my AJAX functions to build my table, rows and cells. I then assign the CFOUTPUT to a variable using CFSAVECONTENT and return the variable set by CFSAVECONTENT to the JS function. Works like a charm.

Hope this helps to put you in the right direction.

-Antonio
# Posted By Antonio Russo | 3/18/06 6:17 PM
Don, I second Antonio's post. I tend to leave all my logic in the server, construct the view, and send it parsed to the presentation layer.
# Posted By Rob Gonda | 3/18/06 7:18 PM
Can someone post an example of using cfsavecontent to pass a formatted table back to the callbackfunction? Thanks!
# Posted By Mitch Rubin | 4/18/06 9:10 PM
Is there a way to attach events to rows using the addRows function. E.g. cellfuncs row.attachEvent('onclick',dosomething)... Thanx for any input.
# Posted By Michael | 11/16/06 1:00 AM
BlogCFC was created by Raymond Camden. This blog is running version 5.1.004.