Wednesday, May 23, 2007

Best use for CF custom tags?

It's been quite a while, so I thought I'd post a question about how and if folks use custom tags in ColdFusion. I work in a mixed environment of designers and developers. The developers in our group (myself included) have found that a good way to deliver reusable snippets of functionality to our designers is to encapsulate them in custom tags, then add them to Dreamweaver's tag libraries via an extension. If there's any interest, I'll write up a post on how this is done.

I feel like I should state at this point that we are very careful about what tags become global tags and what tags need to be imported before use via . We currently have fewer than 6 global custom tags, however those that we have are heavily used. As an example we've written a "replacment" for , that functions exactly like with the exception that it effectively defaults a lot of the values in that are specific to our LDAP. Another example is a login tag that can be placed into an Application.cfm that will authenticate the user againts our LDAP. This tag utilizes the same cfc as the previous tag for it's ldap functionality.

So do you use custom tags? How?

Labels: , ,

posted by Luis

2 Comments:

Blogger AndrewPowell said...

IMO, custom tags are best used by being implemented as encapsulated, reuseable pieces of UI functionality that are generated by CF. Something like LDAP functionality sounds like functionality that I would put into a CFC.

Further reading:

http://www.infoaccelerator.net/index.cfm?event=showEntry&entryId=A046E87B-FF30-C9A3-AD3CE051D9207404

3:45 PM  

Blogger Luis said...

@Andrew
The LDAP functionality described is in a cfc. We simply wrap it in a tag so that it is more familiar for our design folks, and so that it can be documented easily within Dreamweaver.

4:10 PM  

Post a Comment

Links to this post:

Create a Link

<< Home

Template design by MLP Design
Licensed under CC-NC 3.0