我正在尝试使用一个旧插件http://wordpress.org/extend/plugins/wp-ecards/ (我不是插件作者)当我试图在网站上查看电子卡时,在php错误日志和一个空白屏幕中出现此错误:
Failed opening \'\' for inclusion (include_path=\'.:/usr/share/php:/usr/share/pear\')
in /home/public_html/demo/wp-content/plugins/wp-ecards/ft-wp-ecards.php on line 171
I don\'t know what is happening. Is this plugin trying to load the pear library? Any ideas?
第171行周围的函数如下(第171行标记为):function init_wpecards_viewcard(){
global $wp_query;
if ( isset($wp_query->query_vars[\'ft_wpecards_view\']) ){
if ( $ft_wpecards_parentpost = ft_wpecards_get_post_id($wp_query->query_vars[\'card\']) ){
if ( ft_wpecards_get_post_type($wp_query->query_vars[\'card\']) == \'post\' ) {
query_posts("p=".$ft_wpecards_parentpost."&ft_wpecards_view=1&card=".$wp_query->query_vars[\'card\']);
include(get_single_template());
//exit;
}else{
query_posts("page_id=".$ft_wpecards_parentpost."&ft_wpecards_view=1&card=".$wp_query->query_vars[\'card\']);
include(get_page_template()); //LINE 171
//exit;
}
}else{
include(get_404_template());
}
exit;
}
//die(\'tr\');
}
add_action(\'template_redirect\',\'init_wpecards_viewcard\');