Notice: Use of undefined constant id - assumed ‘id‘ in D:\PHPnow-1.5.1\PHPnow-1.5.1\htdocs\Zhongcaoyaocode\index.php on line 33
为了方便程序修改,可以用以下方法:
在开头加上
error_reporting(E_ALL & ~E_NOTICE); // 这句话表示提示除去 E_NOTICE 之外的所有错误信息
这样以来,Notice信息就不再显示了。
PHP中提示Notice: Undefined index 的解决方法
原文:http://blog.csdn.net/holiday1001/article/details/19087253