|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-09-18 07:13 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 18 09:00:01 2025 UTC |
Description: ------------ The private and protected variables ar not protected. print_f or var_dump display them without any errors. Var_dump and print_f should have access from inside, but no outside. Reproduce code: --------------- <?php class Foo { private $password='pass1'; } $foo = new Foo(); print_r($foo); ?> Expected result: ---------------- null Actual result: -------------- Foo Object ( [password:private] => pass1 )