多媒体管理bug
-
打开“媒体”-》“媒体库”即wp-admin/upload.php 提示如下:
Warning: explode() expects parameter 2 to be string, array given in E:\theme\wp-includes\query.php on line 2390
Warning: in_array() expects parameter 2 to be array, null given in E:\theme\wp-includes\query.php on line 2399
…….解决方法:
修改 \wp-includes\query.php 第2390行:
原代码为:$q_status = explode(',', $q['post_status']);
修改为:
$q_status =is_array($q['post_status'])? $q['post_status']:explode(',', $q['post_status']);
修改原因,调试代码显示$q[‘post_status’]本身就是array,不做判断就explode会出错进而导致后面的错误。
- 话题 ‘多媒体管理bug’不再接受新回复。