ここの初心者。
私はレスポンシブ デザインを学ぼうとしていますが、Chrome で期待どおりに動作しているときに、ie9 で最大幅の問題に遭遇しました。ブラウザウィンドウを調整するときに、スケーリングしようとしている画像の最大幅を調整するだけではありません。html コードと css を表示させてください。
HTML コード:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>This is a test</title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
<link rel="stylesheet" type="text/css" href="css/resetmin.css" />
<link rel="stylesheet" type="text/css" href="css/test3.css" />
</head>
<body>
<div style="background-color:black; height:35px;"></div>
<div id="container">
<div class="content">
<div class="header">
<h1>This is my header</h1>
</div>
<div class="pic">
<img src="image001.jpg" alt="Just a picture 815px width and 500px height"></img>
</div>
<div class="imageControl">
</div>
<div class="clear"></div>
</div>
<div class="content">
<div class="header">
<h1>This is my header</h1>
</div>
<div class="pic">
<img src="image002.jpg" alt="Just a picture 500px width and 815px height"></img>
</div>
<div class="imageControl">
</div>
<div class="clear"></div>
</div>
<div class="sideBar"></div>
<div class="padding"></div>
</div>
<div style="background-color: #555; width: 960px; height: 485px; margin: 0 auto; clear: both;"></div>
</body>
</html>
CSS コード: test3.css
body {
color: #333;
font: 100%/1.5 Cambria, Georgia, serif;
background: #ece6d6 url(_assets/bg-light.png) repeat;
/* margin: 0 auto; */
}
img {
display: block;
max-width: 100%;
}
#container {
width: 960px;
margin: 0 auto;
background-color: #aaa;
}
.header {
height: 40px;
border-top: 1px solid #000;
}
.content {
background-color: grey;
float: left;
margin: 15px 15px 0px 15px;
}
.pic {
width: auto;
padding: 15px;
background-color: #777;
float: left;
/* position: relative;
top: 15px;
left: 15px; */
}
.imageControl {
width: 85px;
height: 350px;
background-color: #ccc;
float: right;
/* position: relative;
top: 15px;
left: 15px; */
}
.clear {
clear: both;
}
.padding {
padding-bottom: 15px;
clear: both;
}
.sideBar {
width: 300px;
height: 250px;
margin: 15px 15px 0px 0px;
float: right;
background-color: #333;
}
h1 {
font: bold 1.6em Cambria, Georgia, serif;
}
@media screen and (max-width: 980px) {
#container {
width: 95%;
}
.sidebar {
width: 30%;
}
.sidebar .widget {
padding: 8% 7%;
margin-bottom: 10px;
}
}
ぜひご覧いただき、ご検討ください。それはまだ進行中の作業なので、ブラウザーを調整するときに乱雑なレスポンシブ デザインを気にしないでください (IE9 では縮小されないため、今の私の問題は画像です)。
ありがとう。それでも不明な点がある場合は、お問い合わせください。回答を試みます。