>- see footer for list info -< Did I? That has been said so often by so many people that I probably have it ingrained :-)
Not that I am an advocat of this, nor do I especially think it is as bad a thing as people make out, but the basic reason is. When you set this.myvalue = that It can be read/written from outside the CFC using for example, myCFCobject.myvalue = whatever But if someone can do that, then it means they must have code running in your app on your server in the first place, so I would say you have some far more serious issues in that case, like tha fact that they can delete the damn file for a start. So unless you specifically have variables that you really know should never be read/written to except from within the CFC itself, it wont hurt. But I'm sure you will get some responses from others on here saying that it is the most stupid thing ever you can do. -- Russ -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Damien Gallagher Sent: 17 May 2006 15:56 To: Coldfusion Development Subject: Re: [CF-Dev] function return >- see footer for list info -< Ah OK, all is clear now :¬) Cheers Russ By the way, I saw on your blog you mentioned using the THIS scope in a cfc is bad - got any more info? Snake wrote: >>- see footer for list info -< >> >> >Same as you would normally, as I said. > ><cfset variable = value> > >Is available from any function in the CFC. > >Only <cfset var name="value"> > >Is local to the function. > >You can return variables form one funtion to another just as you return them >form the CFC to the calling template. > >E.g. > ><cffunction name="getname"> ><cfset var myname="bob"> ><cfreturn myname> ></cffunction> > ><cffunction name="person"> ><cfset name = getname()"> ></cffunction> > >-- >russ > >-----Original Message----- >From: [EMAIL PROTECTED] >[mailto:[EMAIL PROTECTED] On Behalf Of Damien Gallagher >Sent: 17 May 2006 14:34 >To: Coldfusion Development >Subject: Re: [CF-Dev] function return > > > >>- see footer for list info -< >> >> >but how do you access the return from the innermost from the outermost? > >Adrian Lynch wrote: > > > >>>- see footer for list info -< >>> >>> >>> >>> >>Not unless you return them in the inner most function and then again in >>the outer most. >> >>Ade >> >>-----Original Message----- >>From: [EMAIL PROTECTED] >>[mailto:[EMAIL PROTECTED] Behalf Of Damien >>Gallagher >>Sent: 17 May 2006 14:12 >>To: Coldfusion Development >>Subject: Re: [CF-Dev] function return >> >> >> >> >> >> >>>- see footer for list info -< >>> >>> >>> >>> >>I mean something a bit different. >> >>The original method calls totalCart - <cfset totalCart()> >> >>I want to know if the original method can access variables (eg. an >>error >>message) set in totalCart. >> >>Damien >> >> >>Snake wrote: >> >> >> >> >> >>>>- see footer for list info -< >>>> >>>> >>>> >>>> >>>> >>>> >>>Any other functions in the component will have access to the arguments >>>sent to the original method, plus any global variables you set. >>> >>>i.e. >>> >>><cfset mystruct.variable = value> >>> >>>Will be available to all the fucntions >>> >>><cfset var name="value"> >>>Is only available to the function that set it. >>> >>>russ >>> >>>-----Original Message----- >>>From: [EMAIL PROTECTED] >>>[mailto:[EMAIL PROTECTED] On Behalf Of Damien >>>Gallagher >>>Sent: 17 May 2006 13:50 >>>To: Coldfusion Development >>>Subject: [CF-Dev] function return >>> >>> >>> >>> >>> >>> >>> >>>>- see footer for list info -< >>>> >>>> >>>> >>>> >>>> >>>> >>>When you call a function from within another function in a CFC (eg. >>><cfset TotalCart()>) can you get access to the variables set in that >>>function via the <cfreturn >? >>> >>>Thanks, Damien >>> >>> >>> >>> >>______> >> >> >> >>_______________________________________________ >> >>For details on ALL mailing lists and for joining or leaving lists, go >>to http://list.cfdeveloper.co.uk/mailman/listinfo >> >>-- >>CFDeveloper Sponsors:- >> >> >> >> >>>- Hosting provided by www.cfmxhosting.co.uk -< >>>- Forum provided by www.fusetalk.com -< >>>- DHTML Menus provided by www.APYCOM.com -< >>>- Lists hosted by www.Gradwell.com -< >>>- CFdeveloper is run by Russ Michaels, feel free to volunteer your >>>help -< >>> >>> >>> >>> >> >> >> >> >_______________________________________________ > >For details on ALL mailing lists and for joining or leaving lists, go to >http://list.cfdeveloper.co.uk/mailman/listinfo > >-- >CFDeveloper Sponsors:- > > >>- Hosting provided by www.cfmxhosting.co.uk -< >>- Forum provided by www.fusetalk.com -< >>- DHTML Menus provided by www.APYCOM.com -< >>- Lists hosted by www.Gradwell.com -< >>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help >>-< >> >> > > >_______________________________________________ > >For details on ALL mailing lists and for joining or leaving lists, go to http://list.cfdeveloper.co.uk/mailman/listinfo > >-- >CFDeveloper Sponsors:- > > >>- Hosting provided by www.cfmxhosting.co.uk -< >>- Forum provided by www.fusetalk.com -< >>- DHTML Menus provided by www.APYCOM.com -< >>- Lists hosted by www.Gradwell.com -< >>- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -< >> >> > > > > _______________________________________________ For details on ALL mailing lists and for joining or leaving lists, go to http://list.cfdeveloper.co.uk/mailman/listinfo -- CFDeveloper Sponsors:- >- Hosting provided by www.cfmxhosting.co.uk -< >- Forum provided by www.fusetalk.com -< >- DHTML Menus provided by www.APYCOM.com -< >- Lists hosted by www.Gradwell.com -< >- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -< _______________________________________________ For details on ALL mailing lists and for joining or leaving lists, go to http://list.cfdeveloper.co.uk/mailman/listinfo -- CFDeveloper Sponsors:- >- Hosting provided by www.cfmxhosting.co.uk -< >- Forum provided by www.fusetalk.com -< >- DHTML Menus provided by www.APYCOM.com -< >- Lists hosted by www.Gradwell.com -< >- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<
