ID: 19439 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Feedback +Status: No Feedback Bug Type: Scripting Engine problem Operating System: Windows 2000 PHP Version: 4.2.3 New Comment:
No feedback was provided for this bug for over 2 weeks, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to "Open". Previous Comments: ------------------------------------------------------------------------ [2002-12-08 10:51:59] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php4-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-latest.zip Can't reproduce with PHP 4.3.0-dev. Although I might have misunderstood what script actually is causing it. If it still happens with the latest snapshot, please include a really NOT working example script here. ------------------------------------------------------------------------ [2002-09-16 12:59:08] [EMAIL PROTECTED] Here are two classes: <?php class myBase { function g() { return 'haha'; } function output() { $x = new myBar($this); echo $this->g(); } } class myBar { var $container; function myBar(&$obj) { $this->container = $obj; } } // this work echo myBase::g(); ?> But when I copy the code of myBase::output() method outside the class defination, without changing the reference to $this variable passed to '$x = new myBar($this)' carelessly, that is <?php $x = new myBar($this); echo myBase::g(); // this issue warning ?> PHP gives a message to me: Warning: Problem with method call - please report this bug in xxx on line xx It should not be a normal case to work with $this outside a class, but as the message 'define' this as a bug, I just drop a message here. :) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19439&edit=1