March 7th, 2012, 11:02 PM
How do i limit page height?
I have a page with a 500px high image. I have another image that moves down it thats 1000px high. I only want the page to be 500px high, so that the 1000px image slides off and disappears leaving behind the 500px image. Ive tried setting style="max-height:500px;" in the body tag but that didnt do anything. Googling "limit page height" didnt help either. How is this done?
March 7th, 2012, 11:38 PM
I'm not quite sure of what you're trying to achieve, but I think that this might work.
Wrap the images in a <div> tag, and apply a CSS rule to that div for "overflow: hidden;". Just set the width and height on the div and anything that doesn't fit inside that will not be shown.
<div style="width: 500px; height: 500px; overflow; hidden;"><img /></div>
March 8th, 2012, 12:01 AM