even if you're a solo developer, creating components that are truly
"black-boxed" (e.g. they know nothing of the world outside them), you're
creating components that you can potentially reuse yourself.  Also, by
passing in the information explicitly (rather than referring to outside
scopes from within the CFC), you potentially worry less about having to
refactor those CFCs.  What if in the future, you're not using form
variables, but you change to URL variables?  The way you have it set up now,
you have to make changes to the CFC.  if you pass all of the variables in
explicitly, it doesn't matter if you're passing form vars, URL vars, session
vars, etc.  your CFC is still built to work and function properly in any
given environment.

On Wed, Oct 22, 2008 at 8:39 AM, Rick Faircloth <[EMAIL PROTECTED]>wrote:

> I think I'm beginning to understand your reasoning.
> It's just taking some time for me to get to the "best practices" of CFC
> usage.
> Trying to get "anything" to work at first keeps my projects moving, while
> beginning to employ different coding techniques.  I'm basically trying to
> learn by writing code for projects that are going live with these updates
> as soon as I can get them working...too busy for much practice.
>
> Also, I'm a solo developer and never plan to code while working for anyone
> else..so as far as sharing code or compensation, it doesn't matter.  My
> client's
> don't care, as long as the correct data shows up on their pages.
>
> But I am trying to figure out the best way to do all of this.
>
> Thanks,
>
> Rick
>
> Dawson, Michael wrote:
> > Technically, they both will work.
> >
> > However, what if you have a different process of calling the same
> > function that doesn't use the form scope?
> >
> > What if you want to call the same method as a web service?
> >
> > Your current system will fail at that time.
> >
> > <realitycheck>
> > Of course, if you fully control your code and no one else will ever use
> > it, then do what you think works best for you.
> >
> > I have some code that might not pass the approval of several people, but
> > it works for me and I can understand it.
> >
> > If your code is not being compared to others, nor are you being judged
> > as part of your compensation, it really doesn't matter.
> >
> > However, at some point, you will find that following these accepted
> > principals will become beneficial.  That is when it "clicks" and you see
> > the light.
> > </realitycheck>
> >
> >
> >
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:314239
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to