I'm currently trying to create a layout that will be compatible for multiple screen sizes. Below are the screen sizes that I design:
Screen Size:
- 640x480
- 800x600
- 1024x768
- 1280x1024 (and more)
I am having problems creating css3 media queries, so my layout changes when the window width reaches one of these widths. Below is an example of the media queries that I am currently using, but it does not work for me, so I am wondering if anyone can help me fix it.
<link rel="stylesheet" type="text/css" media="screen and (max-width: 700px)" href="css/devices/screen/layout-modify1.css"> <link rel="stylesheet" type="text/css" media="screen and (min-width: 701px) and (max-width: 900px)" href="css/devices/screen/layout-modify2.css"> <link rel="stylesheet" type="text/css" media="screen and (max-width: 901px)" href="css/devices/screen/layout-modify3.css">
I tried moving on to a new set of media queries, but they still don't work for me. Can someone please help explain what I'm doing wrong. Some of you have already tried to explain, but I do not understand. New media queries are displayed below:
<link rel="stylesheet" type="text/css" media="screen and (max-width: 640px)" href="css/devices/screen/layout-modify1.css"> <link rel="stylesheet" type="text/css" media="screen and (max-width: 800px)" href="css/devices/screen/layout-modify2.css"> <link rel="stylesheet" type="text/css" media="screen and (max-width: 1024px)" href="css/devices/screen/layout-modify3.css"> <link rel="stylesheet" type="text/css" media="screen and (max-width: 1280px)" href="css/devices/screen/layout-modify4.css">
html css html5 css3 media-queries
JaPerk14 Dec 12 '12 at 20:08 2012-12-12 20:08
source share