resize image heights

unbornink

New Member
Hello,

How can I get images to resize according to the browser height and keep the aspect ratio? (horizontal scrolling site)
I can only every seem to get it to work with width. Do I need some form of Javascript? HTML5/CSS3?

Thanks in advance.
 
I had this a little while ago and I found this did the trick:

<style>

img.bg {

min-height: 576px;
min-width: 1024px;


width: 100%;
height: 100%;


position: fixed;
top: 0;
left: 0;
z-index:-1;
}


(max-width: 1024px){
img.bg {
left: 50%;
margin-left: -512px; }
}
</style>

<body>
<img src="images/bg.jpg" class="bg">
</body>
 
thanks, unfortunately that isn't going to work for me.
looking at it again, I think the issues is being about to scale multiple images, within divs & the divs themselves.

www.unbornink.com/test2/

this is what I have so far
 
Back
Top