브라우저 높이에 따라 이미지 크기를 조정하려고합니다.Firefox에서 이미지 크기 조정 문제가 발생했습니다.
Chrome 및 Safari에서 작동하는 것으로 보이지만 Firefox에서 확인하면 이미지가 원래 크기로 유지됩니다.
여기까지 내가 지금까지 가지고있는 코드가 있습니다.
HTML :
<div class="full-width">
<div class="image-wrapper">
<div class="images">
<img src="http://farm8.staticflickr.com/7165/6840151639_b31263de71_b_d.jpg" />
<img src="http://farm8.staticflickr.com/7165/6840151639_b31263de71_b_d.jpg" />
</div>
</div>
</div>
CSS :
.full-width {
height: 100%;
width: 100%;
position: absolute;
}
.image-wrapper {
position: absolute;
right: 0;
width: 50%;
height: 55%;
margin-right: 15px;
}
.images {
position: absolute;
right: 0;
}
.image-wrapper img {
display: block;
height: auto;
max-height: 50%;
width: auto\9; /* ie8 */
}
현재 작동하는 예를 볼 수 있습니다 http://jsfiddle.net/Pywak/
나는 이미 'position : relative;'가있는 다른 outter div'# wrap'을 가지고 있습니다. – mousesports