Re: Problem with references

From: Date: Thu, 04 Dec 2003 17:29:22 +0000
Subject: Re: Problem with references
Groups: php.general 
Request: Send a blank email to php-general+get-171862@lists.php.net to get a copy of this message
> On Thu, 4 Dec 2003 11:16:10 -0000, you wrote: > >I wonder if there is a simple techique to help me here. I wish to return > 2 > >references to objects from a function. > > > >The following code describes what I want to do but obviously will not > work > >(and I understand why): > > > >function Test (&$P1, &$P2) > >{ > > $Object = new Thing(); > > $P1 =& $Object; > > $P2 =& $Object->Property; > >} It probably is possible if , but IF AND ONLY IF your property is encapsulated in another object. Try it is possible for you. But as David said, it looks a litle bit insane.... :-) Att, Eduardo R. Maciel __________________________________ Do you Yahoo!? Free Pop-Up Blocker - Get it now http://companion.yahoo.com/

« previous php.general (#171862) next »