Re: I a list of PHP 5 reserved words please!
| From: | Jordi Canals | Date: | Tue, 11 May 2004 09:13:27 +0000 |
| Subject: | Re: I a list of PHP 5 reserved words please! | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-23666@lists.php.net to get a copy of this message | ||
Sonia Desbiens wrote:
I have a few clients that have upgraded to PHP 5 for development projects and I am running into problems with class object naming for all my classes and COM objects that use.... '$this->' $this = new COM ( 'ibmTransate.Server' ); $this->MimeType = 'text/' . ( $key->type == '1' ? 'text' : 'html' ); PHP Fatal error: Cannot re-assign $this in j:\www\docs\www\sys\lib\functions.php on line 2189 I have been using '$this->' for a long time in 1000's of projects that I have worked on and sold! This really worries me because I will have to spend many hours changing '$this->' in all my class files and scripts that use this + I will have to contact each client and fix this, this will involved more time because many projects are encoded. I would have never thought that a common word as 'this' would be labeled as a 'PHP' reserved word! Anyway could you please post a list of all words that will be deemed 'reserved' in PHP 5!Hi Sonia, You have a quick view for the changes in http://www.php.net/zend-engine-2.php But you will see that $this-> is not a change. $this has been a reserved word in PHP 4, so it is not a new reserved word. $this is ALREADY a reserved word and you shouldn't be using it the way you are. I think a hard work is waiting for you to fix it... Regards, Jordi.