Php catchable致命错误:第2334行的wp-includes / taxonomy.php中无法将类WP_term的对象转换为字符串 [英] Php catchable fatal error: object of class WP_term could not be converted to string in wp-includes/taxonomy.php on line 2334

查看:170
本文介绍了Php catchable致命错误:第2334行的wp-includes / taxonomy.php中无法将类WP_term的对象转换为字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试添加新帖子:



出现此错误:

 PHP Catchable致命错误:无法将类WP_Term的对象转换为第2334行的wp-includes / taxonomy.php中的字符串





我是什么尝试过:



i检查第2334-2336行中的代码



 if($ delete_tt_ids){
$ in_delete_tt_ids ='。 implode(',',$ delete_tt_ids)。 ;
$ delete_term_ids = $ wpdb-> get_col($ wpdb-> prepare(SELECT tt.term_id FROM $ wpdb-> term_taxonomy AS tt WHERE tt.taxonomy =%s AND tt.term_taxonomy_id IN($ in_delete_tt_ids) ),$ taxonomy));
$ delete_term_ids = array_map('intval',$ delete_term_ids);

解决方案

delete_tt_ids){


in_delete_tt_ids ='。 implode(',',


delete_tt_ids)。 ;

i try to add new post :

this error appear :

PHP Catchable fatal error:  Object of class WP_Term could not be converted to string in wp-includes/taxonomy.php on line 2334



What I have tried:

i checked the code in lines 2334-2336

if ( $delete_tt_ids ) {
			$in_delete_tt_ids = "'" . implode( "', '", $delete_tt_ids ) . "'";
			$delete_term_ids = $wpdb->get_col( $wpdb->prepare( "SELECT tt.term_id FROM $wpdb->term_taxonomy AS tt WHERE tt.taxonomy = %s AND tt.term_taxonomy_id IN ($in_delete_tt_ids)", $taxonomy ) );
			$delete_term_ids = array_map( 'intval', $delete_term_ids );

解决方案

delete_tt_ids ) {


in_delete_tt_ids = "'" . implode( "', '",


delete_tt_ids ) . "'";


这篇关于Php catchable致命错误:第2334行的wp-includes / taxonomy.php中无法将类WP_term的对象转换为字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆