2013-11-24 42 views
0

我不能讓我的CSS文件正確讀取我的HTML頁面。它的東西很簡單,與路徑有關。無法鏈接css文件與正確的網址

這是我目前在html文件

<link rel="stylesheet" href="/css/foundation.css" type="text/css" media="screen" /> 

這是域

http://crea8tion.com/PU2/index.html

有人可以幫助我正確的文件路徑?

當我把它的工作原理index.html文件的同一位置的CSS文件,但這並不是理想的解決方案

回答

1

在的<link rel="stylesheet" href="/public_html/Product Upload form/css/foundation.css" type="text/css" media="screen" /> 代替這樣做:

<link rel="stylesheet" href="/Product Upload form/css/foundation.css" type="text/css" media="screen" /> 
+0

謝謝,但仍然沒有解決問題。 – Dano007

+0

@ Dano007這些是你的內容文件http://gyazo.com/7981143ce941b88bbcaa13a4801f64c4.png最後一個是我指出你需要改變的一個,只是刪除/ public_html部分,你不能在你的頭上發現頁? – Laziale

1

你必須從你的路徑中刪除public_html/

您有:

/public_html/Product Upload form/css/foundation.css 

更改爲:

/Product Upload form/css/foundation.css 

更新:

你也有JS錯誤:

Failed to load resource: the server responded with a status of 404 (Not Found) http://crea8tion.com/PU2/js/plupload.full.min.js 
Uncaught SyntaxError: Unexpected token < jquery.plupload.queue.js:1 
Uncaught TypeError: Object [object Object] has no method 'pluploadQueue' index.html:131 
+0

我不認爲在我的路徑上面顯示有哪些? – Dano007

+0

查看頁面源代碼(或調試器窗口),你確實有它。我看到你改變了它,現在正在加載。 – Niels

0

在這裏你去:

<link rel="stylesheet" href="/PU2/css/foundation.css" type="text/css" media="screen" /> 

/指根。您的css文件位於css文件夾中,該文件夾位於通常爲public_html的根目錄下的PU2文件夾。

您可以在這裏broswer訪問您的樣式表:http://crea8tion.com/PU2/css/foundation.css