note 9107 added to Classes and Objects

From: Date: Tue, 17 Oct 2000 08:48:59 +0000
Subject: note 9107 added to Classes and Objects
Groups: php.notes 
Request: Send a blank email to php-notes+get-6559@lists.php.net to get a copy of this message
CORRECTION FROM THE PREVIOUS POST I noticed the following: <PRE> class a { function something() { echo "class a something"; } } class SomeThing extends a { function SomeThing (){ echo "SomeThing constructor"; } } mySomeThing=new SomeThing; mySomeThing->something(); </PRE> would output SomeThing cunstructor SomeThing cunstructor instead of SomeThing cunstructor class a something I had to rename the function in class a to aSomething and call it with mySomeThing->aSomething() to get it to work properly. I am using php3, and I don't know if this was fixed in php4 http://www.php.net/manual/language.oop.php

« previous php.notes (#6559) next »