2013-11-27 53 views
1

我使用Unsemantic Grid來構建站點。當我在我的筆記本電腦上瀏覽網站時,它起作用,但當我在iPad上瀏覽網站時無法正常工作 - 網格元素的行爲與標準塊元素相似,並且位於不同的線路上。'非語義網格'在桌面上運行,而不是在iPad上運行

我已經從一個完全空白的網站開始,看看我能否找到問題,但我顯然做錯了 - 它仍然無法在iPad上使用。

下面是測試頁面的源代碼,因爲它現在站立(用於代碼道歉析出):

<html> 
<head> 

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> 
<meta charset="UTF-8"> 
<meta http-equiv="x-ua-compatible" content="ie=edge" /> 
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1" /> 

<!-- proper HTML title --> 
<title>title</title> 

<!--[if lt IE 9]> 
<script src="js/unsemantic/html5.js"></script> 
<![endif]--> 
<link rel="stylesheet" href="style.css" /> 
<!--[if (gt IE 8) | (IEMobile)]><!--> 
<link rel="stylesheet" href="styles/unsemantic/unsemantic-grid-responsive-tablet-no-ie7.css" /> 
<!--<![endif]--> 
<!--[if (lt IE 9) & (!IEMobile)]> 
<link rel="stylesheet" href="styles/unsemantic/ie.css" /> 
<![endif]--> 

</head> 

<body> 

    <div class="grid-container"> 

    <div class="grid-100 mobile-grid-100"> 
      <h1 class="grid-100">Here's a heading</h1> 
      <hr /> 
     </div> 
     <div class="grid-25 mobile-grid-25">25% wide</div> 
     <div class="grid-50 mobile-grid-50">50% wide</div> 
     <div class="grid-25 mobile-grid-25">25% wide</div> 

    </div> 

</body> 

</html> 

style.css中不包含任何可以停止工作這一點 - 我已經刪除對它的引用從頁面,但它沒有區別。

沒有使用css重置。

在我的筆記本電腦,頁面呈現的是這樣的:

Page viewed on laptop

在我的iPad上,頁面呈現的是這樣的:

Page viewed on iPad

Unsemantic demo和演示提供的源代碼在桌面和iPad上都可以正常工作 - 這就是它的設計目的。

我知道這是我失蹤的東西,但我有某種心理障礙,無法找到什麼標記或CSS我忘記指定可能導致此。

我不確定這個問題還包括什麼,但如果有人能幫助,我會非常感激。

謝謝

回答

2

現在已解決。看來問題出在Unsemantic.com樣式表中的某個地方,針對mobile, tablet and desktop

更確切地說,我確定它確實是工作,但沒有在我使用的配置中出於某種原因。

這個問題的目的是讓我的網站啓動並運行,並且使用Unsemantic網格提供的響應式樣式表已經解決了這個問題。出於這個原因,我將這個問題標記爲已解決。

所有我需要做的就是上傳到標準樣式表並改變這一點:

<link rel="stylesheet" href="css/unsemantic/unsemantic-grid-responsive-tablet-no-ie7.css" type="text/css" /> 

要這樣:

感謝

相關問題