Yes, I use CFCs for presentation of content, but only in situations where it
makes sense. For simple web pages, absolutely not, there's no point. My
main use of CFC is, for example, in a custom content management system where
almost every view is the same and only a query resultset changes what content
appears in the view. Just simple components such as PageHeader, QueryTable,
QueryList, PersistentSructForm, InterfaceBreadcrumb, etc... They have
minimal, but consistent HTML and/or CSS formatting applied to them every
time. When creating hundreds of pages, it adds up.
Would custom tags perform the same function? Of course. However, when
creating something of significant size, with many hands touching it, I like
to keep the elements used in development to a minimum.
Again, as a few people have mentioned, whatever flavor you like best is what
you should be eating. Like I've said to many people: it's a ColdFusion
Component, not a ColdFusion Business Logic Container, or ColdFusion
Transaction Processor. You can make a component out of anything you like.
And if you don't agree with me, I'll take my Property p = new
Property(Ball.Color("Red")) and Structure.Home.Go()
- Steve
-----Original Message-----
From: Michael Dinowitz [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 03, 2005 11:43 AM
To: CF-Talk
Subject: (OO) UI in CFCs
I'm starting this topic to get peoples feelings on the subject. Do you use
CFCs for UI? Do you have a good reason to do so? Do you see a reason to use
it (or not) vs. CFINCLUDEs or CFMODULEs?
According to commonly discussed practices in the community (and in part of
the Macromedia docs), UI elements should not go inside of CFCs.
According to the Macromedia CFC examples, UI can go inside CFCs.
According to the makeup of the CFCOMPONENT and CFFUNCTION tags, the ability
exists explicitly (the output attribute).
According to many of the OO books I've been reading, there's no reason for UI
not to be within an object.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
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:197301
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=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54