Or, you could rewrite the function without recursion. Just thought I'd mention it as another alternative.
-- Mosh Teitelbaum evoch, LLC Tel: (301) 625-9191 Fax: (301) 933-3651 Email: [EMAIL PROTECTED] WWW: http://www.evoch.com/ > -----Original Message----- > From: Dave Watts [mailto:[EMAIL PROTECTED]] > Sent: Thursday, September 12, 2002 2:23 PM > To: CF-Talk > Subject: RE: Recursion > > > > I wrote this really neat recursive function using the > > <cffunction> tag on my development system which is running > > CFMX on WindowsXP Pro. When I ported to the operational host > > (third party), I discovered that they were running a previous > > version of CF (I do not know which) which does not support > > the new tag. Does anybody know how to do recursion without > > the <cffunction> tag? > > If your recursive function is relatively simple, you can probably write it > as a CF 5-compliant user-defined function, using CFSCRIPT. > CFSCRIPT is a tag > in which you can write CF commands using a JavaScript-like language, which > uses the same syntax and control flow structures as JavaScript, but uses > CFML operators and expressions. You can't use CFML tags within a CFSCRIPT > tag, though, and CFSCRIPT doesn't support all the things you can do with > CFML tags, such as querying a database. Keep in mind that the host would > have to be using CF 5 or higher for this to work. > > Alternatively, you could write a recursive custom tag. However, > this is the > least desirable alternative, as custom tags don't provide any built-in > ability to return values (you can write that ability into your > code, though) > and they tend to negatively affect performance. Nevertheless, if you need > recursion and you're using a version of CF prior to 5, that's the only way > you can do it within CFML. > > Dave Watts, CTO, Fig Leaf Software > http://www.figleaf.com/ > voice: (202) 797-5496 > fax: (202) 797-5444 > > ______________________________________________________________________ Get the mailserver that powers this list at http://www.coolfusion.com FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists