Inside a table

Joined
Jul 27, 2011
Messages
2
Reaction score
0
HI, i have only just started html and was wondering why this is not working.
all i want is my div to be inside the table.

Thanks

<html>

<head>
<link rel="stylesheet" href="layout.css" type="text/css"/>
</head>

<body>

<table class="page">
<tr><td>
<div class="header">
<b><br>div box</b>
</div>

<div class="Tmenu">
<b>div box</b>
</div>

<div class="Smenu">
<b>div box</b>
</div>

<div class="footer">
<b>div box</b>
</div>

<div class="textblock">
<b>div box</b>
</div>

</td></tr></table>


</body>
</html>

CSS

div.header
{
position:absolute;
top:20px;
left:20px;
width:900px;
height:100px;
background-color:#eee;
text-align:center;

}

div.Tmenu
{
position:absolute;
top:125px;
left:20px;
width:900px;
height:30px;
background-color:#eee;
text-align:center;
}

div.Smenu
{
position:absolute;
top:160px;
left:20px;
width:200px;
height:500px;
background-color:#eee;
text-align:center;
}

div.footer
{
position:absolute;
top:800px;
left:20px;
width:900px;
height:60px;
background-color:#eee;
text-align:center;
}

div.textblock
{
position:absolute;
top:160px;
left:225px;
width:695px;
height:630px;
background-color:black;
text-align:center;
}

table.page
{
border:1px solid black;
width:900px;
height:1000px;
margin-left:auto;
margin-right:auto;
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top