【发布时间】:2017-09-07 12:34:03
【问题描述】:
关于这个话题有一些对话,但没有人能真正帮助我。
这是我正在使用 Wordpress 修改的页面:http://www.cargo-websites.eu/demo-1/voorraad/
对于 Javascript 集成,我在 header.php 的 <head> 标记中添加了一个脚本标记:
<script type="text/javascript" src="http://voorraad.cargo-websites.eu/demo-1/voorraad/js/include.js"></script>
添加此代码后,页面立即返回以下错误:
未捕获的类型错误:无法读取 null 的属性“scrollHeight”
在 responseIt (include.js:5)
在 window.onresize (include.js:4)
在 Object.trigger (jquery.js:3)
在 Object.a.event.trigger (jquery-migrate.min.js:2)
在 jquery.js:3
在 Function.each (jquery.js:2)
在 a.fn.init.each (jquery.js:2)
在 a.fn.init.trigger (jquery.js:3)
在 theme.js:78
在 theme.js:94include.js:5 未捕获的类型错误:无法读取 null 的属性“scrollHeight”
在 responseIt (include.js:5)
在 window.onresize (include.js:4)
因此,该页面上的 header-img 消失了。
我找到了解决问题的“方法”,但这远远超出了我的知识范围。我该如何解决这个问题?
【问题讨论】:
-
表示你引用的元素不存在...
-
脚本正在寻找不存在的 id pageContent。
标签: javascript php jquery wordpress