note 56108 added to migration5.oop

From: Date: Tue, 23 Aug 2005 20:30:09 +0000
Subject: note 56108 added to migration5.oop
Groups: php.notes 
Request: Send a blank email to php-notes+get-94096@lists.php.net to get a copy of this message
I making some efficient library load in my site engenie. The idea was to load small "function Declararation class" and if one of functions is accesed load full functions from file. SO i bumped in redefine class var from same class fnc :) PHP5 <? function wap(&$txt) { var_dump ($txt);$txt=new cAction_Full();var_dump ($txt); } class cAction_Full extends cAction{ function say() { echo "\nDO AS YOU PLEASE";}}; class cAction { function say() { echo "\nNO !!!!";} function say2() { GLOBAL $cAction_Full; wap($this); // heh partial workaround :) var_dump($this); } }; $bar=new cAction(); $bar->say(); $bar->say2(); $bar->say(); ?> and output C:\PHP>php.exe ttes.php NO!!! object(cAction)#1 (0) { } object(cAction_Full)#2 (0) { <-YEPP!! } object(cAction_Full)#2 (0) { <-YEPP!!C'Mon } NO!!! <- You B$@#$$#@H!!!! Any workaround would make me very HaPPy please send any notes to beebop@mail.ru :) ---- Manual Page -- http://www.php.net/manual/en/migration5.oop.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+56108 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56108&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+56108&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#94096) next »