Ext

Ext.CFC – Easing Integration with Ext and Adobe ColdFusion

December 10, 2007 by ReyBango

ColdFusion developers are an inquisitive and talented bunch always looking for new ways to extend the language and make it more dynamic and fun. Web developer Brian Love is a great example of this. Brian, who loves the Ext framework, wanted to see how he could ease the usage of the framework within the ColdFusion space while still having all of the great functionality provided by the library.

“The Ext library is packed with tons of cool features, but like most CF programmers, I was initially interested in the Grid Panel. The Grid panel is implemented in ColdFusion 8 using the <cfgrid>, <cfgridcolumn>, and <cfgridrow> tags. Since I started this long before <cfgrid> was a thought, this code will obviously work in CF7.”

Brian states an important fact because ColdFusion v8, Adobe’s latest version of the application server, does in fact include the older Ext v1.0. Two main issues present themselves with this though:

  1. Ext v1.0 is is quite dated and isn’t as feature-rich as Ext v1.1.1 or Ext 2.0
  2. Users that have not upgraded to ColdFusion v8 are locked out of all of the fun provided by the Ext-based custom tags provided in this new version of ColdFusion

In it’s current state, Ext.CFC provides ColdFusion developers with a CF component that essentially wraps the Ext Grid control within an easy to use tag-based metaphor and exposes calls to the grid within easy to use CFC methods:


extobj = createobject("component",extcfc).init();
extobj.initGrid(title="messages",path='http://'&cgi.server_name&cgi.script_name&'?
action=getData',root='messages',id='id',defaultSortColumn=form.sort,defaultSortOrder=form.dir);
extobj.initGridFooter();
//extobj.setGridCol(header='Subject',width=200,name='subject',render="String.format('{0}', value)",detailRender="String.format('{0}
{1}', value, record.data['body'])");
extobj.setGridCol(header='Subject',width=200,name='subject');
extobj.setGridCol(header='Sender',width=150,name='sender');
extobj.setGridCol(header='Sent',width=150,name='datetime');

If you’re not a ColdFusion developer, you may be thinking, “I can do all of that via JavaScript”. Very true but this is all server-side code that eases the learning curve for CF developers that are just getting involved with Ext and would like to extend it out.

Brian plans to extend Ext.CFC to encompass more functionality bringing parity with CF8’s Ajax/UI tags and allowing CF developers to take advantage of the newer version of the Ext framework. Currently, Ext.CFC supports Ext v1.1 and Brian has already committed to updating it to work with Ext v2.0, the latest release of the Ext framework.

To get more information about Ext.CFC and see more demos, be sure to visit Brian’s site where he provides plenty of documentation and samples to get you going with Ext.CFC.

7 Responses to “Ext.CFC – Easing Integration with Ext and Adobe ColdFusion”

  1. Ajaxian » Ext.CFC: Easing Integration with Ext and Adobe ColdFusion

    [...] Ext.CFC isn’t about the greenhouse gasses, but instead abstracts out Ext components into the land of CFML: “The Ext library is packed with tons of cool features, but like most CF programmers, I was initially interested in the Grid Panel. The Grid panel is implemented in ColdFusion 8 using the <cfgrid>, <cfgridcolumn>, and <cfgridrow> tags. Since I started this long before <cfgrid> was a thought, this code will obviously work in CF7.” [...]

  2. Ajax Girl » Blog Archive » Ext.CFC: Easing Integration with Ext and Adobe ColdFusion

    [...] Ext.CFC isn’t about the greenhouse gasses, but instead abstracts out Ext components into the land of CFML: “The Ext library is packed with tons of cool features, but like most CF programmers, I was initially interested in the Grid Panel. The Grid panel is implemented in ColdFusion 8 using the <cfgrid>, <cfgridcolumn>, and <cfgridrow> tags. Since I started this long before <cfgrid> was a thought, this code will obviously work in CF7.” [...]

  3. Javascript News » Blog Archive » Ext.CFC: Easing Integration with Ext and Adobe ColdFusion

    [...] Ext.CFC isn’t about the greenhouse gasses, but instead abstracts out Ext components into the land of CFML: “The Ext library is packed with tons of cool features, but like most CF programmers, I was initially interested in the Grid Panel. The Grid panel is implemented in ColdFusion 8 using the <cfgrid>, <cfgridcolumn>, and <cfgridrow> tags. Since I started this long before <cfgrid> was a thought, this code will obviously work in CF7.” [...]

  4. wqtrreqb

    wqtrreqb…

    wqtrreqb…

  5. lcq

    很漂亮!做得很不错,有时间来我们中国玩。

  6. harry

    oh!it’s so great!

  7. Ext JS Blog - » Ext Growth and Server-Side Community Projects

    [...] Love, this was the first notable component that tried to provide server-side integration with Ext. We posted about Brian’s work on the Ext blog in early [...]



© 2006-2009 Ext, LLC