Michael,
I don't use much JS to do something with the cfajax results. I
preformat all the data in the CF function by stuffing HTML into the
variable that gets returned. Then I just use a simple function to stuff
all the HTML and data into a div or something:
//This function does the cfajax magic
function callCFFunc()
{if (document.getElementById("tagQuery").value) {
var tagQuery = DWRUtil.getValue("tagQuery");
//this line does all the heavy lifting, with the last parameter being
the
//function that does something with the results
DWREngine._execute(_cfscriptLocation, null, 'cfTagsLookup', tagQuery,
displayResult);
}
//here I'm just dumping the results from my CF function into a <div>
called 'info'
function displayResult(result)
{
document.getElementById("info").innerHTML = result;
}
> -----Original Message-----
> From: Dawson, Michael [mailto:[EMAIL PROTECTED]
> Sent: Friday, October 14, 2005 2:16 PM
> To: CF-Talk
> Subject: RE: CFAJAX return types docco
>
> This is a good resource. IBM also has a good document about AJAX. I
> don't have the link handy, but a Google should turn it up.
>
> We have messed with it a bit, but haven't really gotten in to really
> securing the server-side scripts yet.
>
> M!ke
>
> -----Original Message-----
> From: Andy Matthews [mailto:[EMAIL PROTECTED]
> Sent: Friday, October 14, 2005 1:52 PM
> To: CF-Talk
> Subject: RE: CFAJAX return types docco
>
> I can see how AJAX returns the information. The problem I have is
> figuring out how to write the javascript to DO something with it once
> it's returned to the page.
>
> <!----------------//------
> andy matthews
> web developer
> ICGLink, Inc.
> [EMAIL PROTECTED]
> 615.370.1530 x737
> --------------//--------->
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking
application. Start tracking and documenting hours spent on a project or with a
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:221062
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54