Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Floated Image with max-height set scales outside parent Re: Floated Image with max-height set scales outside parent

#83588
furrball1383
Member

just changing the percentage in this case should fix it for you, leaving it as a percentage should make it so that the image can get bigger or smaller than its actual size but still stay within its container as it has a percentage less than 100.

@ChristopherBurton what they’re trying to do is have a in icon and text within a div, the objective being to keep the icon constrained within the div and sized so that it is squished between the text and the outer div. Ok now I don’t know if you’ll be able to understand what I just said…


@donnapep
it may be best is you make a quick mock up of the div and what you’re expecting it to look like at 2 different sizes and put it up so hat we can use this to guage how you expect the icon to interact with the rest of the divs.