0

ColdFusion 8: Screencast of cfAjaxProxy, the Tag That Blurs The Line Between CF and JS

ColdFusion 8

The cfAjaxProxy tag creates all the JavaScript needed so you can call functions in a cfc directly from JavaScript.  This  3 minute screencast walks through a simple, yet powerful, example.

This was also the first time I played with the Derby database examples provided by CF (and found out its case sensative!).  The code in the screencast is below.

index.cfm:

Artists.cfc:

artists.js:

tags:
ColdFusion 8
Brian Swartzfager said:
 
Another excellent demo, Sam!

I think cfajaxproxy is really going to make it easy for folks to write their validation code once (in CFCs) and then leverage that code for both client-side validation (using cfajaxproxy) and server-side validation (to handle cases where users have JavaScript turned off).
 
posted 880 days ago
Add Comment Reply to: this comment OR this thread
 
 
Thanks!

I think form validation is an interesting potential for cfajaxproxy but would want to do some performance tests first. Users often expect validation to happen instantly
 
posted 879 days ago
Add Comment Reply to: this comment OR this thread
 
Ilir said:
 
Sam, I would like to ask you something about incorporating the above code with validate_form javascript, so beside validating for required fields, will check if the name already exists in the database. The wall I am hitting is that the validate_form returns a true if all required fields are filled out, and false if not.
how can I have the displayCount() for example return false to validate_form() javascript?

Any help will be appreciated.
thanks,
Ilir
 
posted 352 days ago
View Replies (4) || Add Comment Reply to: this comment OR this thread
 
.: HIDE REPLIES :.
samfarmer said:
 
Ilir: Take a look at how isNewName works since that is checking to see if the name exists in the database and tie that in with the other form validation code you have. HTH.
 
posted 352 days ago
Add Comment Reply to: this comment OR this thread
 
Ilir said:
 
Looks like, I can not paste code in the comments!
 
posted 351 days ago
Add Comment Reply to: this comment OR this thread
 
samfarmer said:
 
Ilir: Use the contact form to get in touch with me and then via email we should be able to get this worked out.
 
posted 351 days ago
Add Comment Reply to: this comment OR this thread
 
Ilir said:
 
Hi Sam,
My contact email is ibelba@yahoo.com, please let me know your contact info, and I will let you know the details.

Thanks,
Ilir
 
posted 349 days ago
Add Comment Reply to: this comment OR this thread
 
WOW gold said:
 
 
posted 213 days ago
Add Comment Reply to: this comment OR this thread
 

Search

Twitter
You should follow me on Twitter here
About Me
I am a 34-year old Web Developer specializing in ColdFusion. I live and work in downtown Washington, DC with my wife and two daughters. Read more About Me

2007 CFeMmy Best Newcommer winner
As voted on by fellow CF Bloggers.
CFinNC - Carolina ColdFusion / Flex / Air Conference - Oct 17-18, 2009