靜態變量我有類的簡單的情況下,靜態變量和get函數 所有編譯好,但在運行時我收到此錯誤accesing在PHP
[Sun Jul 25 03:57:07 2010] [error] [client 127.0.0.1] PHP Fatal error: Undefined class constant 'TYPE' in .....
爲函數的getType()
這裏是我的類
class NoSuchRequestHandler implements Handler{
public static $TYPE = 2001;
public static $VER = 0;
public function getType(){
return self::TYPE;
}
public function getVersion(){
return self::VER;
}
}
謝謝大家
非常感謝你 – shay 2010-07-25 01:16:50
修復格式,我會很樂意爲+1 nswer。 – 2010-07-25 01:18:38
你去@GeorgeMarian;) – 2012-10-11 07:52:09