php - Why can't you define a constant named EMPTY

后端 未结 4 994
无人及你
无人及你 2021-01-22 01:07

So... This is more of a curiosity, not a real problem. I don\'t get this:

Results in: Pars

4条回答
  •  情书的邮戳
    2021-01-22 01:26

    empty is a reserved keyword in PHP. You cannot use any reserved words as constants, class names, function or method names as these words have special meaning in PHP. Use any other name as constant.

提交回复
热议问题