【发布时间】:2014-07-06 18:08:42
【问题描述】:
在我的应用程序的索引页面上工作,由于某种原因,我添加的 bg-image 没有呈现。但是我调用的所有其他图像文件都可以(但是在 CSS 中没有调用,就像这个一样)
它在开发中完美显示,但在生产中却没有。
我的 heroku 日志中出现以下错误:
ActionController::RoutingError (No route matches [GET] "/assets/ctabackground.png"):
我的 CSS:
#cta {
text-align:center;
height:600px;
width:100%;
background:url('ctabackground.png') no-repeat $light-green;
h1, h2 {
color:#fff;
}
h2 {
letter-spacing:2px;
font-weight:300;
}
}
文件位于 assets/images/ 作为 ctabackground.png
这里有什么问题?
【问题讨论】:
标签: html css ruby-on-rails heroku