Join Up!
104882 members and counting!

 
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links 
search for in the  
previousUnsetting ReferencesCaracterísticasnext
Last updated: Tue, 29 Oct 2002
view the printer friendly version or the printer friendly version with notes or change language to Czech | German

Spotting References

Many syntax constructs in PHP are implemented via referencing mechanisms, so everything told above about reference binding also apply to these constructs. Some constructs, like passing and returning by-reference, are mentioned above. Other constructs that use references are:

global References

When you declare variable as global $var you are in fact creating reference to a global variable. That means, this is the same as:

$var =& $GLOBALS["var"];

That means, for example, that unsetting $var won't unset global variable.

$this

In an object method, $this is always reference to the caller object.

User Contributed Notes
Spotting References
add a note about notes
There are no user contributed notes for this page.
previousUnsetting ReferencesCaracterísticasnext
Last updated: Tue, 29 Oct 2002
Copyright © 2001, 2002 The PHP Group
All rights reserved.
This mirror generously provided by: http://phpbuilder.com/
Last updated: Thu Oct 31 18:34:28 2002 EST