note 109599 added to language.types.null
| From: | foxdie_cs at hotmail dot com | Date: | Wed, 01 Aug 2012 06:00:41 +0000 |
| Subject: | note 109599 added to language.types.null | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-189543@lists.php.net to get a copy of this message | ||
a quick note about the magic function __get() :
class Foo{
protected $bar;
public function __construct(){
$this->bar = NULL;
var_dump( $this->bar ); //prit 'NULL' but won't call the magic method __get()
unset( $this->bar );
var_dump( $this->bar ); //print 'GET bar' and 'NULL'
}
public function __get( $var ){ echo "GET " . $var; }
}
new Foo();
----
Server IP: 69.147.83.197
Probable Submitter: 86.213.211.44
----
Manual Page -- http://www.php.net/manual/en/language.types.null.php
Edit -- https://master.php.net/note/edit/109599
Del: integrated -- https://master.php.net/note/delete/109599/integrated
Del: useless -- https://master.php.net/note/delete/109599/useless
Del: bad code -- https://master.php.net/note/delete/109599/bad+code
Del: spam -- https://master.php.net/note/delete/109599/spam
Del: non-english -- https://master.php.net/note/delete/109599/non-english
Del: in docs -- https://master.php.net/note/delete/109599/in+docs
Del: other reasons-- https://master.php.net/note/delete/109599
Reject -- https://master.php.net/note/reject/109599
Search -- https://master.php.net/manage/user-notes.php