表格单元改变大小 [英] Table cells change size

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

问题描述

我是Dreamweaver的新手(使用MX 2004)。我有一个2行3列表。

我已将每列设置为200像素。第二行我已将
合并到一个单元格中。当我在合并的

单元格中输入文本(或其他任何内容)时,上面的3列会更改像素宽度。像素宽度仍然是
表示为200.但像素宽度在列上方以绿色显示,例如
200(172)。似乎括号内的数字是单元格所显示的大小,而不是指定的200,但我似乎无法改变这个,无论我多么努力尝试。我的浏览器是IE6,所以

应该不是问题。


我不明白为什么3个顶级单元格显示完美,即使是

下面合并的单元格为空,但是当输入文本时它们会改变它们的价值

更改!


任何人都可以帮助我吗?

I''m new to Dreamweaver (using MX 2004). I have a 2 row 3 column table.
I have set each column to 200 pixels. The second row I have merged
into one cell. When I enter text (or anything else) into the merged
cell the 3 columns above change pixel width. The pixel width still
says 200. But the pixel width shown in green above the columns it says
200(172)for example. It seems that the bracketed number is the size
the cell displays at rather than the specified 200, but I can''t seem
to change this no matter how hard I try. My browser is IE6 so that
shouldn''t be the problem.

I don''t understand why the 3 top cells display perfectly, even with
the merged cell below empty, but then when text is entered they
change!

Can anyone help me??

推荐答案

文章< 7c ************************* @ posting.google.com> ,
sa ********** @ xtra.co.nz 用...启发我们
In article <7c*************************@posting.google.com> ,
sa**********@xtra.co.nz enlightened us with...
我是Dreamweaver的新手(使用MX 2004)。我有一个2行3列表。
我已将每列设置为200像素。我已将第二行合并为一个单元格。当我在合并的
单元格中输入文本(或其他任何内容)时,上面的3列会改变像素宽度。
I''m new to Dreamweaver (using MX 2004). I have a 2 row 3 column table.
I have set each column to 200 pixels. The second row I have merged
into one cell. When I enter text (or anything else) into the merged
cell the 3 columns above change pixel width.




他们应该这样做。这是表的行为。


如果你不想在文本越过边框时进行扩展,请使用带有

的div作为溢出的CSS 。


-

-

~kaeli~

自杀是最真诚的形式自我批评。
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace



They''re supposed to. That''s table behaviour.

If you don''t want expansion when text goes over the borders, use a div with
proper CSS for overflow.

--
--
~kaeli~
Suicide is the most sincere form of self-criticism.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace


谢谢你,但前三个单元格中的文字并没有溢出。它是
是底部合并单元格,它使前三个单元格改变大小。

底部单元格确实有包装文本,但它不会改变表格的宽度,而只是前三个单元格中的每一个。


我原本认为顶部单元格与底部单元格中的
无关,只要TABLE宽度保持不变。


那么我怎样才能让前三个单元格完全相同 - 这就是它的方式

让我的网站看起来很笨!


欣赏任何建议。谢谢。
Thanks for that, but the text in the top 3 cells isn''t overflowing. It
is the bottom merged cell that makes the top 3 cells change size. The
bottom cell does have wrapping text but it doesn''t change the width of
the TABLE, just each of the top 3 CELLS.

I would have thought that the top cells'' with is independant of what
is in the bottom cell providing the TABLE width remains the same.

So how would I get the top 3 cells to be exactly equal - the way it is
is making my website look dumb!

Appreciate any suggestion. Thanks.


文章< 7c ************************** @发布.google.com>,
sa ********** @ xtra .co.nz 启发我们...
In article <7c**************************@posting.google.com >,
sa**********@xtra.co.nz enlightened us with...
谢谢你,但前三个单元格中的文字并没有溢出。它是底部合并的单元格,使前三个单元格改变大小。
底部单元确实有包装文本,但它不会改变表格的宽度,只是前三个单元格中的每一个。
Thanks for that, but the text in the top 3 cells isn''t overflowing. It
is the bottom merged cell that makes the top 3 cells change size. The
bottom cell does have wrapping text but it doesn''t change the width of
the TABLE, just each of the top 3 CELLS.




实际上,我发现事实并非像你一样。单元格扩展的方式似乎非常依赖于用户代理实现和

doctype声明(没有doctype或doctype中缺少url抛出

浏览器进入怪癖模式)。也就是说,它在MSIE中可能看起来很好用怪癖

模式,但在Firefox标准中看起来很糟糕(等等)。


要解决这种类型问题,当我不希望细胞改变大小时,它们下面的细胞扩大了,我不会把它们放在同一张桌子上。我把它们放在另一张桌子里面的每张桌子上。


----------------< - 主表容器指定宽度

|这里的内容| < ---在自己的桌子上,100%宽度

----------------

|这里的内容| < ---在自己的桌子上,100%宽度

----------------


桌子真的从来没有打算布局。对于某些事情,我仍然发现它们比使用CSS更容易上班

。我正在慢慢地学习如何从表格中获取

用于布局,但我不时会遇到问题(大多数情况下是b / b
具有流畅,相对定位的列和文本大小调整推送图层

不合适的地方以及整个扩展内容的东西。


您可能需要考虑使用CSS检查无表格布局。我不知道它是否适用于你正在做的事情。但它值得学习。

之一我的网站是用纯CSS完成的。另一个我无法弄清楚如何得到它

没有表工作(当用户调整文本太大时,第三个

列将包装到底部,但使用绝对定位通常不是我的风格......)。尝试尝试一下。我计划最终将

能够放下我所有东西的布局。


我在这个网站上找到的信息非常有帮助我。

这个页面特别解决了我遇到的PITA问题。
http://www.quirksmode.org/index.html...centering.html


HTH < br $> b $ b -

-

~kaeli~

杀死一个男人,你就是杀人犯。杀死数百万你和你b $ b是一个征服者。杀死所有人,你就是上帝。
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace



Actually, I''ve found that to not be the case, as you have. The way the cells
expand seems to be very much dependent on the user agent implementation and
the doctype declaration (no doctype or a lack of a url in doctype throws
browsers into quirks mode). That is, it may look fine in MSIE with quirks
mode, but look awful in Firefox standard (and so on).

To solve this type of problem, when I don''t want cells to change size when
cells beneath them expand, I don''t put them in the same table. I put them
each in their own table inside another table.

---------------- <-- main table container specifies width
| content here | <--- in its own table with 100% width
----------------
| content here | <--- in its own table with 100% width
----------------

Tables really were never meant for layout. I still find them easier to work
with than CSS though for some things. I am slowly learning how to get away
from tables for layout, but I DO run into issues from time to time (mostly
with fluid, relatively positioned columns and text resizing pushing layers
out of place and with the whole expanding content thing).

You may want to consider checking out table-less layout with CSS. I don''t
know if it would work for what you''re doing. But it''s worth learning. One of
my sites is done with pure CSS. The other I couldn''t figure out how to get it
to work right without tables (when the user resized the text too big, the 3rd
column would wrap to the bottom, but using absolute positioning isn''t usually
my style...). Try experimenting with it though. I plan on eventually being
able to drop the tables for layout for all my stuff.

I have found the info at this site to be very helpful to me.
This page in particular solved a PITA problem I was having.
http://www.quirksmode.org/index.html...centering.html

HTH
--
--
~kaeli~
Kill one man and you are a murderer. Kill millions and you
are a conqueror. Kill everyone and you are God.
http://www.ipwebdesign.net/wildAtHeart
http://www.ipwebdesign.net/kaelisSpace


这篇关于表格单元改变大小的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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