note 46501 added to language.oop.constructor
| From: | sirinus at excite dot com | Date: | Wed, 13 Oct 2004 13:42:21 +0000 |
| Subject: | note 46501 added to language.oop.constructor | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-78486@lists.php.net to get a copy of this message | ||
【译者注】这
里似乎有问题
,实际输出的
结果,并不象
这里说的那样
。实际输出的
内容是
I am a regular function named B in class
A......,输出的是 B()
的内容。也就
是说,例子中
的注释This will call B() as a
constructor是正确的。
如果从 A
类中移除函数
B(),那么将输出
A() 的内容。
Please take off this notes of the translators from the Manul. It is wrong! The original explaination
is correct!
----
Manual Page -- http://www.php.net/manual/en/language.oop.constructor.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+46501
Delete -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes
Reason: bad code -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes&reason=bad+code
Reason: spam -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes&reason=spam
Reason: useless example -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes&reason=useless+example
Reason: contains commercial links -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes&reason=contains+commercial+links
Reason: useless note -- http://master.php.net/manage/user-notes.php?action=delete+46501&report=yes&reason=useless+note
Reject -- http://master.php.net/manage/user-notes.php?action=reject+46501&report=yes
Search -- http://master.php.net/manage/user-notes.php