phpbar.de logo

Mailinglisten-Archive

[php] Klassen - Referenz in Konstruktor

[php] Klassen - Referenz in Konstruktor

Björn Hoffmann lists1 at h-s-products.de
Fre Mai 28 12:50:09 CEST 2004



Christian Ruetgers schrieb:


> Autsch, dummer Fehler von mir! In der Funktionsdefinition von c2() kann 
> man sich natürlich das '&' einsparen, wichtig ist die Zuweisung der 
> Referenz an die Eigenschaft.
> 
> 
> Danke dir!
> 
>
In dem Zusammenhang noch ein Auszug aus der php.ini (PHP Version 4.2.3):

; Whether to enable the ability to force arguments to be passed by reference
; at function call time.  This method is deprecated and is likely to be
; unsupported in future versions of PHP/Zend.  The encouraged method of
; specifying which arguments should be passed by reference is in the 
function
; declaration.  You're encouraged to try and turn this option Off and make
; sure your scripts work properly with it in order to ensure they will work
; with future versions of the language (you will receive a warning each time
; you use this feature, and the argument will be passed by value instead 
of by
; reference).
allow_call_time_pass_reference = On/Off

björn

php::bar PHP Wiki   -   Listenarchive