如何从3列固定宽度CSS样式表中删除列? [英] How can I remove a column from a 3-Column Fixed Width CSS stylesheet?

查看:83
本文介绍了如何从3列固定宽度CSS样式表中删除列?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,


这可能听起来很愚蠢,但我有一个非常好的主页模板

不幸的是它是一个3列固定宽度CSS格式。现在我没有给b
$ b有正确列的任何内容,并希望中间栏

只是为了占用那个空间。

这是可能的吗?


感谢您的帮助,我们非常感谢!

Sarita

Hello,

this might sound stupid, but I got a really nice homepage template
which unfortunately is a 3-Column Fixed Width CSS format. Now I don''t
have any content for the right column and would like the middle column
just to use up that space instead.

Any way this is possible?

Thanks for your help, it is highly appreciated!
Sarita

推荐答案

Sarita于2007年6月在comp.infosystems上写道。 www.authoring.stylesheets:
Sarita wrote on 06 mrt 2007 in comp.infosystems.www.authoring.stylesheets:

这可能听起来很愚蠢,
this might sound stupid,



你们关心?请不要。

Do you care? Please don''t.


但是我有一个非常好的主页模板

不幸的是它是一个3列固定宽度CSS格式。现在我没有给b
$ b有正确列的任何内容,并希望中间栏

只是为了占用那个空间。

这有可能吗?
but I got a really nice homepage template
which unfortunately is a 3-Column Fixed Width CSS format. Now I don''t
have any content for the right column and would like the middle column
just to use up that space instead.

Any way this is possible?



是的,只需为你的主页写一个2列。


你需要什么?为什么?主页模板?


-

Evertjan。

荷兰。

(请更改在我的电子邮件地址中的点'x''点数

Yes, just write a 2 column one for your homepage.

What is and why do you need a "homepage template"?

--
Evertjan.
The Netherlands.
(Please change the x''es to dots in my emailaddress)


Sarita写道:
Sarita wrote:

>

但是我有一个非常好的主页模板

不幸的是它是一个3列固定宽度CSS格式。现在我没有给b
$ b有正确列的任何内容,并希望中间栏

只是为了用尽那个空间。
>
but I got a really nice homepage template
which unfortunately is a 3-Column Fixed Width CSS format. Now I don''t
have any content for the right column and would like the middle column
just to use up that space instead.



为什么你不去找一个不错的2列模板呢? ;)

Why don''t you go and find yourself a nice 2-column template instead? ;)


这有可能吗?
Any way this is possible?



当然,但由于你没有提供网址,所以不可能给b $ b提供任何细节。 />

-

Berg

Of course, but since you haven''t provided a URL it isn''t possible to
give any specifics.

--
Berg


Scripsit Sarita:
Scripsit Sarita:

这可能听起来很愚蠢,但我有一个非常好的主页模板

,不幸的是它是一个3列固定宽度CSS格式。
this might sound stupid, but I got a really nice homepage template
which unfortunately is a 3-Column Fixed Width CSS format.



使用你无法管理的模板并不是真正的愚蠢迹象

但不明智。最好使用简单的布局,你可以处理,而不是与其他人的设计一起工作,当你希望修改它时会遇到麻烦。

Using a template that you cannot manage is not really a sign of stupidity
but ill-advised. It''s better to use simple layout that you can handle than
to work with someone else''s design and run into trouble when you wish to
modify it.


现在我没有

有正确列的任何内容,并希望中间栏

只是用尽那个空间。
Now I don''t
have any content for the right column and would like the middle column
just to use up that space instead.



好​​吧,只需删除右栏。确保检查整个表格的宽度

设置(如果设置)是否与列宽

设置一致(如果已设置)。


作为一个kludge,你可以使用CSS来压制第三列(但结果

是不可预测的,如果这使得列宽的总和不同于

总宽度的设定):


td:first-child + td + td {display:none; }


无法在IE 6或更早版本上工作,或在Quirks模式下在IE 7上工作。好吧,你可以把
添加类属性,比如class =" third"到第三列的单元格

并使用类选择器:


td.third {display:none;几乎任何支持CSS的浏览器都可以使用
。但是为什么还要麻烦,什么时候你可以直接删除栏目?


-

Jukka K. Korpela(Yucca ;)
http://www.cs.tut.fi/ ~jkorpela /

Well, just remove the right column. Make sure to check that the width
setting for the entire table, if set, is consistent with the column width
settings, if set.

As a kludge, you can use CSS to suppress the third column (but the results
are unpredictable if this makes the sum of column widths different from the
setting of the total width):

td:first-child + td + td { display: none; }

Doesn''t work on IE 6 or earlier, or on IE 7 in Quirks mode. Well, you could
add class attributes, say class="third", to the cells of the third column
and use a class selector:

td.third { display: none; }

which works on almost any CSS-enabled browser. But why bother, when you can
simply remove the column?

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/


这篇关于如何从3列固定宽度CSS样式表中删除列?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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