Re: error cannot instantiate non-existent class
| From: | CPT John W. Holmes | Date: | Fri, 12 Sep 2003 19:37:58 +0000 |
| Subject: | Re: error cannot instantiate non-existent class | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-162463@lists.php.net to get a copy of this message | ||
From: "Golawala, Moiz M (IndSys, GE Interlogix)" <Moiz.Golawala@ge.com>
> I am newbie with php and I am trying to instantiate a
> class.
Welcome to PHP.
> this->$config = $config;
$this->config = $config;
> Parse error: parse error, unexpected T_OBJECT_OPERATOR
> in C:\Program Files\Apache Group\Apache2\htdocs
> \Alarms\AddConfigs.inc on line 7
>
> Fatal error: Cannot instantiate non-existent class: addconfigs in
C:\Program Files\Apache Group\Apache2\htdocs\Alarms\test1.php on line 4
That first error is being caused by your syntax error above. Since there is
parse error in the class file, the second file cannot create an instance of
the class, hence the second error. Fix that line above and both will go
away.
---John Holmes...