I have divs setup basically as follows:
Now in my CSS I have application set with a border. I want this around the complete application. This is also specified as position:relative with top:5px; Now when I position my header with position:relative and the divs inside of that with position:absolute they go where I expect. But as soon as I try to position the modules it overflows the border of the application. How can I get the application box to grow so it always includes the interior boxes? I tried relative, absolute, different displays and even float and clear, but I guess I just don't understand. At this point good ole tables seem a lot simpler.
Code:
<div id="TicketManager" class="application">
<div class="header">
<div class="logo"></div>
<div class="spacer"></div>
<h2 class="letterhead">Ticketing System</h2>
<div class="specialLogo"></div>
<div id="Navigation" class="navigation">
<ul class="items">
<li class="item lnkCreateTicket">Create Ticket</li>
<li class="item lnkViewTickets">View Tickets</li>
</ul>
</div>
<div class="content">
</div>
</div>
<div class="modules">
<div id="TicketsViewer" class="module">
<div class="navigation">
<ul class="items">
<li class="item lnkOpenTickets">Pending Tickets</li>
<li class="item lnkClosedTickets">Completed Tickets</li>
</ul>
</div>
<div class="content gridView">
<div class="header">
<span class="label">Id</span>
<span class="label sortable">Truck</span>
<span class="label sortable">Trailer</span>
<span class="label">Options</span>
</div>
<div class="dataRow">
<span class="data id">12</span>
<span class="data truck">SomeTruck1</span>
<span class="data trailer">SomeTrailer1</span>
<span class="data options">
<span class="option">Update</span>
<span class="option">Close</span>
</span>
</div>
<div class="dataRow">
<span class="data id">15</span>
<span class="data truck">SomeTruck3</span>
<span class="data trailer">SomeTrailer3</span>
<span class="data options">
<span class="option">Update</span>
<span class="option">Close</span>
</span>
</div>
<div class="dataRow">
<span class="data id">77</span>
<span class="data truck">SomeTruck6</span>
<span class="data trailer">SomeTrailer6</span>
<span class="data options">
<span class="option">Update</span>
<span class="option">Close</span>
</span>
</div>
</div>
</div>
Now in my CSS I have application set with a border. I want this around the complete application. This is also specified as position:relative with top:5px; Now when I position my header with position:relative and the divs inside of that with position:absolute they go where I expect. But as soon as I try to position the modules it overflows the border of the application. How can I get the application box to grow so it always includes the interior boxes? I tried relative, absolute, different displays and even float and clear, but I guess I just don't understand. At this point good ole tables seem a lot simpler.
Code:
.application {
border:2px; border-color:#C1D72F; border-style:solid; padding:1px; text-align:left; margin:5px;
position:relative; width:975px; top:5px; font-size:.9em; background-color: white; display:block;
}
/* Header */
#TicketManager>.header { position:relative; margin:5px; background-image:url('../images/interface/fillerGreen.gif'); background-repeat:repeat; width:965px; height:81px; }
#TicketManager .header>.logo { position:absolute; left:0px; width:273px; height:81px; background-image:url('../images/interface/logoEJIW.gif'); }
#TicketManager .header>.spacer { position:absolute; left:279px; height:81px; z-index:1; }
#TicketManager .header>.letterhead { position:absolute; top:20px; left:340px; z-index:1;}
#TicketManager .header>.specialLogo { position:absolute; right:5px; width:90px; height:76px; background-image:url('../images/interface/logo125Years.gif'); }
/* Modules */
#TicketManager .modules {
top:90px;
}