I don't know that including UDFs slows anything down. I used to have
this site with probably over 50 on some pages with no slowdown
whatsoever. However, if you want to speed it up even more, after all
cf still has to load and instantiate every function you write as a
separate object, then put your UDFs in a CFC and instantiate the CFC
into your application scope.

Ba-da-bing, any slowdowns from too many UDFs on a page have to be history.

-nathan strutz
http://www.dopefly.com/


On 10/14/05, Johnny Le <[EMAIL PROTECTED]> wrote:
> How's about UDFs?  If you include too many UDFs in a page, will it slow down? 
>  It does, right?  Is there another way to include UDFs besides <cfinclude>?
>
> Johnny
>
> > On 10/14/05, Johnny Le <[EMAIL PROTECTED]> wrote:
> > > Hi,
> > >
> > > If you have a library of custom tags, should you use <cfimport
> > prefix='ct'/> to import the whole library in?  This way, I can use
> > <ct:tagName> like in Java instead of <cf_tagName>.  I thought it is a
> > neat idea, but I wonder if the site would take a performance hit.
> > >
> >
> > No, and, if anything, it's actually might improve the page
> > performance
> > (though it's really negligible), as cfimport is a compile-time
> > directive and the other methods of invoking custom tags are run-time
> > directives. So while you might have a fractional hit upon first
> > compiling the page, all requests after it are using the compile-time
> > mapping to the custom tag.
> >
> > The only downsides to using cfimport are:
> >
> > 1) Can't use dynamic mappings (i.e., #pathToMyCTs#)
> > 2) cfimport must be put at the top of the actual page that uses the
> > tag. So if you use the custom tag in both a template and an included
> > page in that template, the cfimport directive must be in both the
> > parent template *and* the included template.
> >
> > Regards,
> > Dave.
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:221043
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=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to