我收到以下警告:
Warning: reset() expects parameter 1 to be array, null given in /data/9/1/115/118/1767118/user/1910351/htdocs/aw/home/wp-content/themes/awthemesnew/library/sidebars.php on line 183
请记住,我正在编辑一个 wordpress .php 文件。这是第 183 行的完整代码:
function theme_print_sidebar($name, $places) {
$style = theme_get_option('theme_sidebars_style_' . $name);
$place_count = count($places);
if ($name != 'footer' && $place_count < 2) {
theme_print_widgets(reset($places), $style);
return;
}
?>
帮助。谢谢!