phonegap을 사용하여 앱을 개발 중입니다. 이미 320x480 해상도 화면과 호환되는 내 앱을 만들었습니다. 이제 미디어 쿼리를 사용하여 480x800 화면과 호환되도록했습니다. 잘phonegap에서 미디어 쿼리를 사용하는 방법
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- style1 -->
<link rel="stylesheet" media="only screen and (min-width: 200px) and (max-width: 320px) and (orientation: portrait)" href="style.css">
<!-- style2 -->
<link rel="stylesheet" media="only screen and (min-width: 321px) and (max-width: 480px) and (orientation: portrait)" href="style2.css">
<!-- style3 -->
<link rel="stylesheet" media="only screen and (min-width: 481px) and (max-width: 1024px) and (orientation: portrait)" href="medium-style.css">
을 다음과 같이 더 높은 해상도로 이제 문제는 내가 480 × 800 해상도의 화면에서 응용 프로그램을 다음 대신이 style1.I 또한 하나의 스타일 시트를 사용하여 뷰포트를 제거하려고 사용 style2를 사용하여 실행할 때. 미디어 쿼리와 관련된 전화 설명서도 찾을 수 없습니다. 도와주세요.
작동하지 않습니다. 가장 높은 너비의 미디어 쿼리 만 감지합니다. –
죄송합니다. 그것은'min-width' 일 것이고, 나는 대답을 편집했다. – NEOLPAR
아직도 작동하지 않습니다. 웹 브라우저에서는 제대로 작동하지만 avd에서는 작동하지 않습니다. 이것이 avd에 문제가 될 수 있습니까? –