Re: system() Question

From: Date: Mon, 29 Dec 2008 05:16:35 +0000
Subject: Re: system() Question
References: 1 2 3 4 5 6  Groups: php.general 
Request: Send a blank email to php-general+get-285179@lists.php.net to get a copy of this message
On Sun, Dec 28, 2008 at 8:40 PM, Micah Gersten <micah@onshore.com> wrote: > Nathan Nobbe wrote: > > good point dan, and just to add further clarification, thats b/c the > > function specifies $return_var is passed by reference in the formal > > parameter. when you include the & along w/ an actual parameter (during > > function invocation) thats referred to as call-time-pass-by-reference in > > php, and its typically frowned upon. in fact, i think its being removed > > from a future version of php. > > > > -nathan > > > > > You don't call system using the ampersand. The reference is declared in > the function definition. There's no reason for this to be frowned > upon. well i dont think they deprecated it for shits-&-giggles. http://us.php.net/manual/en/language.references.pass.php its disabled by default in php.ini; wonder why.. ;) > What you are referring to is the old PHP4 style of explicit > pass-by-reference in function usage which is frowned upon. no im referring to call-time-pass by reference, which works just as well in php5; as long as you enable it in php.ini (or one of the other various ways). and also, for clarification, marking parameters as pass-by-reference works during method definition in php4 as well, of course. -nathan

« previous php.general (#285179) next »