aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Problem with table row overlapping with table header Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Problem with table row overlapping with table header" Watch "Problem with table row overlapping with table header" New topic
Author

Problem with table row overlapping with table header

jason pitt
Greenhorn

Joined: Nov 10, 2005
Posts: 18
Hi,

I am having problem with the first table row being overlapped with table header.

Below is the code that I am using

<DIV id="1" style=" WIDTH: 50%; HEIGHT:250px; overflow: auto" >
<table style="float:left" align="center" width="40%" cellpadding="3">
<thead >
<tr>
<th> ... </th>
</tr>
</thead>
<tbody>
<tr>
<td> ... </td>
</tr>
</tbody>
</table>
</div>

Could someone please suggest a solution?

Thanks,
Jason
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61434
    
  67

If the table is the only thing in the div, why are you floating it left? Does the problem go away if you remove the float?


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
jason pitt
Greenhorn

Joined: Nov 10, 2005
Posts: 18
I am using "float" in the table because, earlier I had problem getting spaces with the table. Even I remove "float" I am having overlapping problem.

Thanks,
Jason
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61434
    
  67

Well float is the wrong way to go about getting spacing.

Please post the full HTML.
jason pitt
Greenhorn

Joined: Nov 10, 2005
Posts: 18
Hi,

I think the problem is with CSS. Can anyone please let me know how to code a table with fixed table header and scrollable table rows. And Table header should be in the same table as the table rows. I don't want table header and table rows coded in separate tables.

Thanks,
Jason
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
this
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem with table row overlapping with table header