Firefox中的表格和布局问题 [英] Problems with tables and layout in Firefox

查看:87
本文介绍了Firefox中的表格和布局问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我在使用某些表格代码时遇到了一些麻烦。它在Internet上运行良好,但是在Firefox 1.0.7中布局无法正常工作


这是一个firefox错误,还是我遗漏了HTML中的内容?它很漂亮

简单代码! (另外根据w3c验证器有效)


布局问题在第三行。我无法将嵌入式表格

(顶部和底部单元格)作为单元格的完整高度(除非

我取出第二行)。第三行中的HTML与第一行中的

HTML相同。


我已附上以下代码。

干杯,


Ben


<!DOCTYPE html PUBLIC" - // W3C // DTD HTML 4.01 Transitional // EN">

< html>

< head>

< title>测试页< / title>

< / head>

< body>

< form action ="">

< table border =" 1">

<! - 这一行很好 - >

< tr>

< td style =" height:100%">

< table border =" 1" style =" height:100%; width:100%;">

< tr>

< td style =" vertical-align:top; "> top< / td>

< / tr>

< tr>

< td style =" vertical - 对齐"> bottom< / td>

< / tr>

< / table>

< / td>

< td>< textarea rows =" 5" cols =" 10">< / textarea>< / td>

< / tr>


<! - 如果这个行被删除,然后下一行工作正常! - >

< tr>

< td> hmmm< / td>

< td>这是怎么回事on ???< / td>

< / tr>

<! - 这一行与第一行相同,但嵌入式表格不是100%高度 - >

< tr>

< td style =" height:100%">

<! - 这是在Firefox中不会表现的表! - >

< table border =" 1" style =" height:100%; width:100%">

< tr>

< td style =" vertical-align:top;"> top< / td>

< / tr>

< tr>

< td style =" vertical-align:bottom;">底部< / td>

< / tr>

< / table>

< / td>

< td>< textarea rows =" 5" cols =" 10">< / textarea>< / td>

< / tr>


< / table>

< / form>

< / body>< / html>

解决方案

>我在使用一些表格代码时遇到了一些麻烦。它在Internet

Explorer中工作正常,但是在Firefox 1.0.7中布局无法正常工作




更新:我已升级到Firefox 1.5,它仍然无法正常工作。


其他人可以确认他们的系统上的显示不正确

Firefox(或任何其他这个问题的浏览器)?


干杯,


Ben




2006年1月7日星期六,Ben Holness写道:

我遇到了一些表格代码的问题。它在Internet上运行良好,但在Firefox 1.0.7中布局无法正常工作



更新:我已经升级到Firefox 1.5但它仍然没有工作。




将测试文档的URL发布到合适的服务器上。


原因经常被解释足够。


>将测试文档的URL发布到合适的服务器上。


对不起,应该已经实现了!


我把它放在 http://usenet.hostiz.com/


反馈意见!


干杯,


Ben


Hi all,

I am having some trouble with some table code. It works fine in Internet
Explorer, but the layout doesn''t work correctly in Firefox 1.0.7

Is this a firefox bug, or am I missing something in the HTML? It is pretty
simple code! (Plus it is valid according to the w3c validator)

The layout problem is in the third row. I cannot get the embedded table
(with the top and bottom cells) to be the full height of the cell (unless
I take out the second row). The HTML in the third row is identical to the
HTML in the first row.

I have attached the code below.

Cheers,

Ben

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Test Page</title>
</head>
<body>
<form action="">
<table border="1">
<!-- This row is fine -->
<tr>
<td style="height: 100%">
<table border="1" style="height: 100%; width: 100%;">
<tr>
<td style="vertical-align: top; ">top</td>
</tr>
<tr>
<td style="vertical-align: bottom; ">bottom</td>
</tr>
</table>
</td>
<td><textarea rows="5" cols="10"></textarea></td>
</tr>

<!-- If this row is removed, then the next row works fine!!! -->
<tr>
<td>hmmm</td>
<td>what''s going on???</td>
</tr>

<!-- This row is identical to the first, but the embedded table is not 100% height -->
<tr>
<td style="height: 100%">
<!-- This is the table that won''t behave in Firefox!! -->
<table border="1" style="height: 100%; width: 100%">
<tr>
<td style="vertical-align: top;">top</td>
</tr>
<tr>
<td style="vertical-align: bottom;">bottom</td>
</tr>
</table>
</td>
<td><textarea rows="5" cols="10"></textarea></td>
</tr>

</table>
</form>
</body></html>

解决方案

> I am having some trouble with some table code. It works fine in Internet

Explorer, but the layout doesn''t work correctly in Firefox 1.0.7



Update: I have upgraded to Firefox 1.5 and it still doesn''t work.

Can anyone else confirm that the display is incorrect on their system on
Firefox (or any other browser for that matter)?

Cheers,

Ben



On Sat, 7 Jan 2006, Ben Holness wrote:

I am having some trouble with some table code. It works fine in Internet
Explorer, but the layout doesn''t work correctly in Firefox 1.0.7



Update: I have upgraded to Firefox 1.5 and it still doesn''t work.



Post the URL of your test document on a suitable server.

The reasons have been explained often enough.


> Post the URL of your test document on a suitable server.

Sorry, should have realised!

I have put it up at http://usenet.hostiz.com/

Feedback appreciated!

Cheers,

Ben


这篇关于Firefox中的表格和布局问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆