【发布时间】:2011-03-16 00:59:03
【问题描述】:
你好,我是一个 wordpress 主题开发者。我创建了一个主题,它在 WP_DEBUG=False 中运行良好,但在设置 WP_DEBUG=True 时出现未定义的索引错误
我的主题有一个选项页面,每当我点击保存时,我都会收到以下错误:
Notice: Undefined index: ang_temp in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_breadcrumbs in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_hide_social in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_hide_tw in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_hide_fb in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_hide_ms in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Notice: Undefined index: ang_hide_rss in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 147
Warning: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php:147) in C:\xampp\htdocs\wordpress\wp-content\themes\Angelia\functions.php on line 156
这是我的主题functions.php 我不知道我做错了什么。我对php知之甚少。希望有php知识或者wordpress主题开发知识的小伙伴可以帮忙。
【问题讨论】:
标签: wordpress wordpress-theming undefined-index