Solved

Table height

Posted on 2004-09-03
2
353 Views
Last Modified: 2010-04-09
How do I make the height of a table span the whole document? I have a menubar aligned to the left, with a height of "100%", but it only fills up the 1st page, and if there's content that spans more than 1 page and I scroll down, from the 2nd page on that content begins directly below my left menu as opposed to to the right of it. How can I fix that?

Here is the table:

<table width="200" height="100%" border="0" align="left">
<tr><td><a href="displayAddUserForm.do">Add User</a></td></tr>
...
<tr><td height="100%">&nbsp;</td></tr>

Btw this menu is in a separate file, if that helps.

Thanks in advance.
0
Comment
Question by:Flavaflav
2 Comments
 
LVL 19

Accepted Solution

by:
dakyd earned 50 total points
ID: 11975029
Since you're already using tables, will something like this work?  Depending on the rest of your page, however, it may be simpler/better to move away from a table layout.  Regardless, hope that helps.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD PUBLIC HMTL 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

<html>
<head>
<style type="text/css">
table {
  border-collapse: collapse;
}

table td {
  border: 2px solid #000000;
}

table table td {
  border: 0;
}

#Menu {
 vertical-align: top;
}
</style>
</head>

<body>
<table>
  <tr>
    <td id="Menu">
      <table>
        <tr><td><a href="displayAddUserForm.do">Add User</a></td></tr>
      </table>
    </td>
    <td>
      Content
      <p>As this grows, so will the menu on the left</p>
      <p>You can test this by adding more content here</p>
      <br />
      More Content
      <p>What's more, this content will stay to the right of the menu</p>
      <p>Go ahead and try it</p>
    </td>
  </tr>
</table>
</body>
</html>
0
 
LVL 2

Expert Comment

by:cheyennejk
ID: 11975407
Trimming your margins may help:

<body leftmargin="0" rightmargin="0" topmargin="0" bottommargin="0">
0

Featured Post

ScreenConnect 6.0 Free Trial

Check out the updates in one game-changing release, ScreenConnect 6.0, based on partner feedback. New features include a redesigned UI that improves session organization and overall user experience. See the enhancements for yourself!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article discusses four methods for overlaying images in a container on a web page
Is your Office 365 signature not working the way you want it to? Are signature updates taking up too much of your time? Let's run through the most common problems that an IT administrator can encounter when dealing with Office 365 email signatures.
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question