2013-08-24 65 views
3

由於某些原因,當我使用twitter bootstrap 2.3.2時,圖標無法加載圖像。我有默認結構 CSS/ IMG/ JS/glyphicons未加載

其他一切作品,我也嘗試添加一個簡單的圖標一樣<span class="icon icon-ok">OK</span>,並且也適用

任何人都可以看到最新錯了嗎?

<!DOCTYPE HTML> 
<html> 
<head> 
    <title>Fixed layout example with Twitter Bootstrap</title> 
    <meta name="viewport" content="width=device-width, initial-scale=1.0"> 
    <!-- Bootstrap --> 
    <link href="resources/css/bootstrap.css" rel="stylesheet" media="screen"> 
</head> 
<body> 
<div class="container"> 

<form class="form-horizontal"> 

     <fieldset> 
      <legend>Create a new question</legend> 
      <div class="control-group"> 
      <label class="control-label" for="questionTitle">Title</label> 
      <div class="controls"> 
       <input type="text" class="input-xlarge" id="questionTitle">    
      </div> 
      </div> 
      <div class="control-group"> 
      <label class="control-label" for="questionText">Question</label> 
      <div class="controls"> 
       <textarea class="input-xlarge" id="questionText" rows="4"></textarea> 
      </div> 
      </div>   
      <div class="control-group"> 
      <label class="control-label" for="questionTypes">What type of answer are your looking for?</label> 
      <button type="button" class="btn btn-default btn-lg"> 
       <span class="glyphicon glyphicon-align-justify"></span> Multiple choice 
      </button> 
      <button type="button" class="btn btn-default btn-lg"> 
       <span class="glyphicon glyphicon-adjus"></span> Yes/No 
      </button> 
      <button type="button" class="btn btn-default btn-lg"> 
       <span class="glyphicon glyphicon-text-width"></span> Text input 
      </button> 
      </div>     
      <div class="form-actions"> 
      <button type="submit" class="btn btn-primary">Save changes</button> 
      <button class="btn">Cancel</button> 
      </div> 
     </fieldset> 
</form> 
</div> 
    <script src="http://code.jquery.com/jquery.js"></script> 
    <script src="resources/js/bootstrap.js"></script> 
</body> 
</html> 
+0

參見[這個答案](HTTP://計算器。 COM /問題/ 18222849 /自舉-3- glyphicons-CDN?RQ = 1)。也許它有幫助 – doru

回答

4

嘗試使用的標籤是這樣的:

<i class="icon-star icon-white"></i> 

來源:http://getbootstrap.com/2.3.2/base-css.html#icons

編輯:看起來你可以使用V3.0.0 - 你有沒有嘗試使用glyphicons沒有其他類你有補充嗎?只是標準類:

<span class="glyphicon glyphicon-star"></span> 

如果負載,那麼它可能有一些做glyphicon-text-widthglyphicon-adjus(adjus拼寫錯誤,也許?)

+0

我努力說我使用2.3.2,但它是引人注目的V3,之後,它是直截了當的。謝謝你的提示 – Marthin