height property of HTML table

S

Sebastiano

I have written a simple page with a 1x1 HTML table. I have set the two
property height and width of the table to 100%. I have named this page
test.htm and I try to see it using my IIS 5.0 (in Windows 2000 pro) and IE
6.1. My machine have installed .NET Framework 1.1 too. I see my page right,
the table covers all the space of the browser. If I change the page name in
test.aspx and I try to reload it, the height property is ignored and the
table is height as default, not all the page. Why? Is it a bug of .NET
Framework? If I examine the source code from IE the code is right, with the
right value for height property...

Many thanks

Sebastiano
 
M

Michael Ramey

Can you post your html source for this page, this I have to see. Just tried
this myself and it seemed to work fine to me, I don't see why it possibly
wouldn't.
 
S

Sebastiano

The code is very simple, just this:

<%@ Page Language="C#" ContentType="text/html" ResponseEncoding="iso-8859-1"
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<table width="100%" height="100%" border="1">
<tr>
<td>Test text</td>
</tr>
</table>
</body>
</html>

bye

Sebastiano
 
M

Michael Ramey

It's in your <!DOCTYPE ..> tag, take it out and it'll work fine. It's
probably something the W3C wants to phase out to get you to start using
stylesheets, I'd suggest researching the appropriate css to get it to work
the same.

HTH,
--Michael
 
S

Shahar

hi
I have the same configuration and the following code is work just fine
under my.aspx file (and my.htm):

<HTML>
<body>
<form id="frmMain" method="post" runat="server">
<table width="100%" height="100%" bgcolor=#ffff66>
<tr>
<td>aaa</td>
</tr>
</table>
</form>
</body>
</HTML>
 

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

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,019
Latest member
RoxannaSta

Latest Threads

Top