2017-10-19 73 views
-3

爲什麼我的網站在手機不支持

<!DOCTYPE html> 
 
<html> 
 
<head> 
 
\t <title>Responsive Images Test Page</title> 
 
</head> 
 
<body> 
 

 
\t <h1>Responsive Images Test Page</h1> 
 
\t <p>In supported browsers, the following image will load either small or large version depending on screen resolution, making a single 1kb request before requesting the appropriate size.</p> 
 

 
\t <img src="sample-content/running-sml.jpg?full=sample-content/running-lrg.jpg" /> 
 

 
\t <p id="cred"><strong>Photo credit (CC):</strong> Cia de Foto <a href="http://www.flickr.com/photos/ciadefoto/3192757134/in/[email protected]/">Flickr Creative Commons</a></p> 
 
\t 
 
</body> 
 
</html>

我想開發一個自適應網站。但我的網站不支持手機。 <meta name="viewport" content="width=device-width, initial-scale=1.0"> 我用上述標籤作爲響應網站。但這不起作用。 請幫我

+0

哪款手機?所有? – Kanak

+0

如果您不向我們顯示任何代碼,我們無法爲您提供幫助。 – Amorandron

+0

最好的將是分享一個鏈接到網站。 –

回答

0

響應式設計是你必須用CSS手動完成的事情。你不能簡單地添加一個meta標籤,你的頁面響應;) 爲了您上面的代碼示例,你可以做內聯這樣的:

<img style="max-width:100%" src="sample-content/running-sml.jpg?full=sample-content/running-lrg.jpg" /> 

當然你應該爲你的網站的樣式表文件。