您现在的位置是:网站首页 > 网站建设 > 建站教程建站教程

【原】Uncaught Error: Call to a member function attributes() on bool

不忘初心 不忘初心 2021-12-08 围观() 评论() 点赞() 建站教程

简介:在解决了ereg_replace()这个方法的问题之后,页面总算是能出来了,但是又出了一个新的错误,盲猜又是因为php版本升级导致的bug。详细错误信息如下:Uncaught Error: Call to a member function attributes() on bool in D:\phpstudy_pro\WWW\wordpress\wp-content\themes\D8_3.0\functions.php

在解决了ereg_replace()这个方法的问题之后,页面总算是能出来了,但是又出了一个新的错误,盲猜又是因为php版本升级导致的bug,我就纳闷儿了,高版本php怎么就废弃了这么多api吗?

Uncaught Error: Call to a member function attributes() on bool

详细错误信息如下:

Uncaught Error: Call to a member function attributes() on bool in D:\phpstudy_pro\WWW\wordpress\wp-content\themes\D8_3.0\functions.php:212
Stack trace:
#0 D:\phpstudy_pro\WWW\wordpress\wp-content\themes\D8_3.0\modules\excerpt.php(17): deel_thumbnail()
#1 D:\phpstudy_pro\WWW\wordpress\wp-content\themes\D8_3.0\index.php(21): include('D:\\phpstudy_pro...')
#2 D:\phpstudy_pro\WWW\wordpress\wp-includes\template-loader.php(106): include('D:\\phpstudy_pro...')
#3 D:\phpstudy_pro\WWW\wordpress\wp-blog-header.php(19): require_once('D:\\phpstudy_pro...')
#4 D:\phpstudy_pro\WWW\wordpress\index.php(17): require('D:\\phpstudy_pro...')
#5
{main} thrown in D:\phpstudy_pro\WWW\wordpress\wp-content\themes\D8_3.0\functions.php on line 212

在之前解决Uncaught Error: Call to undefined function ereg_replace()问题的时候,提到过两种解决方案:

1、更换api方法;

2、降低php版本;

这一次,我查了一圈资料也没发现合适的解决方案,为节省时间,我就直接选择第二种解决方案了。

WordPress

看完文章,有任何疑问,请加入群聊一起交流!!!

很赞哦! ()

文章评论

  • 请先说点什么
    人参与,条评论

请使用电脑浏览器访问本页面,使用手机浏览器访问本页面会导致下载文件异常!!!

雨落无影

关注上方公众号,回复关键字【下载】获取下载码

用完即删,每次下载需重新获取下载码

若出现下载不了的情况,请及时联系站长进行解决

站点信息

  • 网站程序:spring + freemarker
  • 主题模板:《今夕何夕》
  • 文章统计:篇文章
  • 标签管理标签云
  • 微信公众号:扫描二维码,关注我们