2015-07-20 51 views
0

在我的網站上,我試圖用他們的標識,名稱和關於它們的簡短描述來概述客戶。圖像未顯示在引導程序縮略圖中

我使用bootstrap縮略圖和chrome。

這是我的代碼:

<div class="row"> 
    <div class="col-sm-6 col-md-4"> 
     <div class="thumbnail"> 
      <img src="/img/logos/first.jpg" alt="first"> 
      <div class="caption"> 
       <h3>First</h3> 
       <p>Some text</p> 
      </div> 
     </div> 
    </div> 
    <div class="col-sm-6 col-md-4"> 
     <div class="thumbnail"> 
      <img src="/img/logos/second.png" alt="second"> 
      <div class="caption"> 
       <h3>Second</h3> 
       <p>Some text</p> 
      </div> 
     </div> 
    </div> 
    <div class="col-sm-6 col-md-4"> 
     <div class="thumbnail"> 
      <img src="/img/logos/third.png" alt="third"> 
      <div class="caption"> 
       <h3>Third</h3> 
       <p>Some text</p> 
      </div> 
     </div> 
    </div> 
</div> 

我的問題是,我看不到任何圖像。我所得到的是替代文字。圖像的路徑是正確的。

有人可以向我解釋爲什麼我的圖像不顯示?

編輯:

這是我的項目結構:

folders

SOLUTION

我已經找到了個錯誤!

  • 正確的路徑是「img/logos/first.jpg」。
  • 我還使用「sudo chmod 755 FILENAME」(Linux)修改了文件夾徽標和所有圖像。
+3

任何404錯誤控制檯? (路徑*是否正確?) – isherwood

+1

顯然你的標記是好的。 http://jsfiddle.net/t5y3onx4/ – isherwood

+1

你可以截圖你的文件夾結構。它可能是圖像所在的文件夾不正確的問題。嘗試驗證圖像和文件夾是否正確。 –

回答

1

路徑/img/Kundenlogos/third.png是相對於你的根目錄。例如,您可能有類似/Webseite/img/Kundenlogos/third.png的內容。也包括這一點。

如果你的結構是這樣的:

folder 
    html 
     file.html 
     index.html 
    img 
     Kundenbilder 
      first.jpg 
      second.jpg 

你也可以使用../img/Kundenlogos/third.png