开发者

How to declare public static class fields in PHP4

Do you have the solutions that public static class fields in PHP4

var static $field = nul开发者_JAVA技巧l;
Parse error: syntax error, unexpected T_STATIC, expecting T_VARIABLE 


PHP 4 didn't support static properties natively. The best you could do was implement static variables inside of your methods. Maybe the following link is useful for you:

http://adam.bregenzer.net/php/static_class_properties

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜