PHP提示:Array callback has to contain indices 0 and 1错误的原因及解决办法 0 By 董德多 on 2020年12月17日 PHP php提示:Array callback has to contain indices 0 and 1错误是因为我们使用了错误的括号来访问数组元素。 比如下面的错误示例是使用了小括号来访问数组元素,我们改成php规定的中括号即可。 $begin_date = $input('begin_date');//错误 $begin_date = $input['begin_date'];//正确 array callback