Disqus 抛出错误
我正在尝试使用 disqus。我遵循的步骤是
gem install disqus
application.rb
中的配置块
config.after_initialize do
Disqus::defaults[:account] = "youraccountname"
# so that the comments will load up in development environment
Disqus::defaults[:developer] = true
Disqus::defaults[:container_id] = "disqus_thread"
Disqus::defaults[:show_powered_by] = false
end
在视图中
> <%= post.body %><% end %> <%= disqus_thread %> </div> <script
> type="text/javascript"
> src="http://disqus.com/forums/rapexegesis/embed.js"></script>
我收到以下错误
undefined local variable or method `disqus_thread' for #<#<Class:0x2e5a560>:0x2e5dc50>
Extracted source (around line #13):
11: <p>
12: <%= post.body %><% end %>
13: <div id ="disqus_thread">
14: <%= disqus_thread %>
15: </div>
16: <script type="text/javascript" src="http://disqus.com/forums/rapexegesis/embed.js"></script>
我在这里缺少任何内容?谢谢
I am trying to use disqus. The steps I have followed are
gem install disqus
config block in application.rb
config.after_initialize do
Disqus::defaults[:account] = "youraccountname"
# so that the comments will load up in development environment
Disqus::defaults[:developer] = true
Disqus::defaults[:container_id] = "disqus_thread"
Disqus::defaults[:show_powered_by] = false
end
In the view
> <%= post.body %><% end %> <%= disqus_thread %> </div> <script
> type="text/javascript"
> src="http://disqus.com/forums/rapexegesis/embed.js"></script>
I get the following error
undefined local variable or method `disqus_thread' for #<#<Class:0x2e5a560>:0x2e5dc50>
Extracted source (around line #13):
11: <p>
12: <%= post.body %><% end %>
13: <div id ="disqus_thread">
14: <%= disqus_thread %>
15: </div>
16: <script type="text/javascript" src="http://disqus.com/forums/rapexegesis/embed.js"></script>
I am missing anything here?Thank you
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
如果您位于 Passenger、apache 或任何服务器后面,请尝试重新启动它。
If you are behind Passenger, apache or whatever server, try to restart it.