Local bootstrap 3.1 glyphicons not loading in Firefox

試著忘記壹切 提交于 2019-12-06 14:27:46

问题


I'm creating a local HTML UI font icons from bootstrap don't load in Firefox, they do in Chrome and IE.

Not working/does not apply: https://superuser.com/questions/446001/firefox-cannot-render-icons-from-font-awesome-webfont-set

glyphicons are not loading

Bootstrap 3 cdn glyphicons not loading in firefox only

Glyphicons from bootstrap 3 not rendering on Firefox

https://github.com/MaxCDN/bootstrap-cdn/issues/196


回答1:


The problem is apparently https://developer.mozilla.org/en/docs/HTTP/Access_control_CORS

What works for me is:

"If you have a page at file:////pages/mypage.html, then you can only load fonts located in file:////pages or below. So, for example, if the fonts are in file:////fonts, they won't load, but if they are in file:///pages/fonts, then they should work. At least, that's how it seems to work for me." posted by freixas @ https://support.mozilla.org/en-US/questions/956597

So basically I put my resources dir (contains scripts, images etc) in the root directory where I have the web pages.



来源:https://stackoverflow.com/questions/21680700/local-bootstrap-3-1-glyphicons-not-loading-in-firefox

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!