PDA

View Full Version : div background !!!


nits4u
09-12-2009, 07:47 AM
is it necessary to specify height of div which has a bg image ??

mean i have a "div" tag which has some content n also a background image(repeat-y) set to it. Now when i set the height of div tag to auto, the background image disappear. But if i specify it so specific value, image shows.
And i want to set the height to auto so that it adjust with the content.

Is it possible !!!
Thank You.

Corrosive
09-12-2009, 07:49 AM
Just take the height out completely. It will adjust correctly then.

nits4u
09-12-2009, 09:57 AM
didn't get you...
mean no need to mention height ???

coloeagle
09-12-2009, 01:26 PM
didn't get you...
mean no need to mention height ???
Yup, that is what he means. :-D

Corrosive
09-13-2009, 08:16 AM
Yes, I very rarely specify heights in my designs as I want each page to grow with the content.