2014-04-30 37 views
0

我在Rails應用程序中使用了gem 'twitter-bootstrap-rails'Rails twitter引導程序圖標不顯示

直到今天早上它工作正常。我刪除了另一個寶石,並做了一個bundle install

現在我的Bootstrap圖標不顯示。我正在使用本地引導程序圖標。下面是一個例子顯示:

<i class="icon-search"></i> 

此外,Rails應用程序將不會運行,直到我從application.css刪除此行

*= require bootstrap 

我嘗試添加這一行:

*= require twitter-bootstrap-static/sprites 

但是,這並沒有奏效。

我在bootstrap_and_overrides.css.scss

@import "bootstrap"; 
@import "bootstrap-responsive"; 

這些語句這是我的外部庫:

enter image description here

感謝您的幫助!

+0

任何錯誤? – CuriousMind

+0

是'GET http://ame.ndeavor2.dev/assets/glyphicons-halflings.png 404(未找到)' – Reddirt

回答

0

嘗試複製glyphicons-halflings.pngRAILS_ROOT/app/assets/images。你仍然得到404頁未找到錯誤?

+0

謝謝 - 工作。但是,我不明白爲什麼我必須向該位置添加副本。 – Reddirt

0

我也有同樣的問題。
你需要在Chrome開發者工具或Firebug的移動glyphicons-halflins.pngglyphicons-halflings-white.pngapp/public/fonts/文件夾或app/public/images文件夾下