bootstrap字型圖示的參照方法:首先建一個fonts資料夾;然後放在和js、css檔案同級目錄下;最後通過「src: url('font/glyphicons-halflings-regular.eot');」方式參照字型圖示即可。
推薦:《》
該方法適用於任何品牌的電腦。
Bootstrap正確參照字型圖示:
其實不需要下面這麼麻煩,只需要建一個fonts資料夾放在和js,css檔案同級目錄下,就可以正確參照,關鍵是下面這幾個檔案得有:
<style type="text/css"> @font-face { font-family: 'Glyphicons Halflings'; src: url('font/glyphicons-halflings-regular.eot'); src: url('font/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('font/glyphicons-halflings-regular.woff') format('woff'), url('font/glyphicons-halflings-regular.ttf') format('truetype'), url('fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg'); }
<!--<style type="text/css"> @font-face { font-family: 'Glyphicons Halflings'; src: url('font/glyphicons-halflings-regular.eot'); src: url('font/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('font/glyphicons-halflings-regular.woff') format('woff'), url('font/glyphicons-halflings-regular.ttf') format('truetype'), url('font/glyphicons-halflings-regular.svg#glyphicons_halflingsregular') format('svg'); }
注意:用font-size屬性調整字型圖示的大小,且不會失真。
以上就是bootstrap字型圖示怎麼參照的詳細內容,更多請關注TW511.COM其它相關文章!