这篇文章主要为大家详细介绍了织梦Fatal error:Call to a member function GetInnerText() on a non-object 解决方法,具有一定的参考价值,感兴趣的小伙伴们可以参考一下,有需要的朋友可以收藏方便以后借鉴。DEDE织梦自定义模型图片内容提示Fatal error:Call to a member function GetInnerText() on a non-object 解决方法。 DEDE的自定义模型,如果用来发布图片,可能会出现以下问题,在更新列表页或者点编辑文章时会提示: Fatal error: Call to a member function GetInnerText() on a non-object in E:/www/include/aglib/channelimg.lib.php on line 51 或者: Fatal error: Call to a member function GetInnerText() on a non-object in /htdocs/include/customfields.func.php on line 539 这个错误修复方法很简单。 编辑打开 include/aglib/channelimg.lib.php 查找51行左右:
将其替换为: $innerTmp = ( $arcTag == "" ) ? trim( $arcTag ) : trim( $arcTag ->GetInnerText()); 或者: if ( $arcTag == "" ){ $innerTmp = trim( $arcTag ); } else { $innerTmp = trim( $arcTag ->GetInnerText()); } 编辑include/customfields.func.php 将539行的 $fvalue = trim( $ntag ->GetInnerText()); 将其替换为: $fvalue = ($ntag=="") ? trim($ntag) : trim($ntag->GetInnerText()); 或者: if ( $ntag == "" ){ $fvalue = trim( $ntag ); } else { $fvalue = trim( $ntag ->GetInnerText()); } 然后就能正常更新列表页了,问题上解决 。 以上就是织梦Fatal error:Call to a member function GetInnerText() on a non-object 解决方法的全部内容,希望对大家的学习和解决疑问有所帮助. |