TP5 未定义数组索引如何解决

 

因为没有判断值是否存在,所以要重新设置下:

$type=isset($_POST["type"])?$_POST["type"]:0;

 

posted @ 2019-06-04 16:37  微联云  阅读(31275)  评论(0编辑  收藏  举报