note 129533 added to language.oop5.visibility
| From: | shahovkit | Date: | Fri, 31 May 2024 13:22:55 +0000 |
| Subject: | note 129533 added to language.oop5.visibility | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-221341@lists.php.net to get a copy of this message | ||
It will output 'Public'
<?php
class ParentClass {
private $private = 'Private';
}
class ChildClass extends ParentClass {
public $private = 'Public';
}
$child = new ChildClass();
echo $child->private;
----
Server IP: 45.112.84.4
Probable Submitter: 80.90.5.137 (proxied: 2.132.53.144)
----
Manual Page -- https://php.net/manual/en/language.oop5.visibility.php
Edit -- https://main.php.net/note/edit/129533
Del: integrated -- https://main.php.net/note/delete/129533/integrated
Del: useless -- https://main.php.net/note/delete/129533/useless
Del: bad code -- https://main.php.net/note/delete/129533/bad+code
Del: spam -- https://main.php.net/note/delete/129533/spam
Del: non-english -- https://main.php.net/note/delete/129533/non-english
Del: in docs -- https://main.php.net/note/delete/129533/in+docs
Del: other reasons-- https://main.php.net/note/delete/129533
Reject -- https://main.php.net/note/reject/129533
Search -- https://main.php.net/manage/user-notes.php