Re: system() Question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Dec 28, 2008 at 8:40 PM, Micah Gersten <micah@xxxxxxxxxxx> 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

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux