Using argumentCollection with AJAX calls - about ajaxProxy

Just a quick note. A few weeks back I blogged about argumentCollection works with CFCs over Ajax. Stephan Duncan Jr was the smart guy who taught me that. Last night another reader ran into something a bit similar to this - however in this case it is not working correctly. To put it simply, if you use cfajaxproxy to create a proxy JavaScript class for a CFC, argumentCollection does not work. Any attempt to use it, for example, myproxy.foo(argumentCollection=ob), results in argumentCollection being passed in as whatever is defined as the first argument to the foo method. If this type of functionality is critical to you, then skip cfajaxproxy and do it ‘native’ with jQuery or some other (not as sexy) JavaScript framework.

Raymond Camden's Picture

About Raymond Camden

Raymond is a developer advocate. He focuses on JavaScript, serverless and enterprise cat demos. If you like this article, please consider visiting my Amazon Wishlist or donating via PayPal to show your support. You can even buy me a coffee!

Lafayette, LA https://www.raymondcamden.com

Comments