[web] PHP and divs.....an unhappy relationship

Started by
1 comment, last by jon723 15 years, 9 months ago
Hello everyone, I've recently been using php to load some content into a div section of pages I'm creating. The way I'm doing things, I have an outer div which has a background image I'm using to tile a border image I'm using. This div has an inner div which has the php content loaded into it. For some reason, the php that is loaded isn't stretching the height of the outer div which has an 'auto' height. The inner div has a default height of 300px. This is the url of the page in question, does anyone have a solution to this problem: http://homeadvantagenj.com/NewSite/contactus.php Sincerely, Jon
www.lefthandinteractive.net
Advertisement
This has nothing to do with PHP (which merely generates some HTML), and everything to do with the interaction between your CSS and the HTML.

In practice, what happens is that your inner DIV has a fixed height, and therefore the text within it, which is too large, will overflow and appear below it without changing the actual size of the DIV. Since the size of the inner DIV never changes the size of the outer DIV never changes either.

Simply drop the height of the inner DIV and everything will behave correctly.
Ah, that worked, thanks!!
www.lefthandinteractive.net

This topic is closed to new replies.

Advertisement