表格式问题 [英] table style question

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

问题描述




我知道如果我希望我的所有桌面条目都高25,我可以把

这个放在我的样式文件中:


table tr td {height:25}

但是,如果我希望上述内容仅适用于特定的表格怎么办?怎么

我可以命名上面的风格并且只选择性地在某些

表中使用它吗?


我该放什么要调用它的表格吗?


我会想象它是这样的:


.myTableStyle {

table tr td {height:25}

}


然后


< table class = myTableStyle>


但我怀疑它就这么简单......


/ Eric



I know that if I want all my table entries to be of height 25, I can put
this in my style file:

table tr td {height:25}
But what if I want the above to only apply to a particular table ? How
can I name the above style and use it selectively in only certain
tables?

And what do I put in the table to invoke it ?

I would imagine it''s something like this :

.myTableStyle {
table tr td {height:25}
}

and then

<table class=myTableStyle>

but I doubt it''s that simple...

/Eric

推荐答案

Eric Osman写道:
Eric Osman wrote:
我想它会是这样的:

.myTableStyle {
table tr td {height:25}
}
然后

< table class = myTableStyle>

但是我怀疑它就这么简单...
I would imagine it''s something like this :

.myTableStyle {
table tr td {height:25}
}

and then

<table class=myTableStyle>

but I doubt it''s that simple...




几乎就是这么简单。怎么样


table.MyTableStyle,td.MyTableStyle

{

身高:25px;

}


< table class = MyTableStyle>


AFAIK你不必定义一个tr的风格。你必须指定

25 * * *

-


Groet,

Barbara

http:// home.wanadoo.nl/b.de.zoete/index.html


文章< 3F *********** ***@rcn.com> ;, Eric Osman写道:
In article <3F**************@rcn.com>, Eric Osman wrote:
我知道如果我希望我的所有桌面条目都高25,我可以把它放进去我的风格档案:

table tr td {height:25}
25cm? 25in? 25horses?你需要CSS中的单位。执行是零,它不需要
需要单位。

但是如果我希望上面只适用于特定的表怎么办?
我会想象它是这样的:

.myTableStyle {
table tr td {height:25}
}
但我怀疑它就是那么简单...
I know that if I want all my table entries to be of height 25, I can put
this in my style file:

table tr td {height:25} 25cm? 25in? 25horses? You need unit in CSS. Exeption is zero, it don''t
need unit.
But what if I want the above to only apply to a particular table? I would imagine it''s something like this :

.myTableStyle {
table tr td {height:25}
}

but I doubt it''s that simple...




不,它更简单:

..myTableStyle table tr td {height:2em;}




..myTableStyle td {height:2em;}


差不多。


-

Lauri Raittila< http://www.iki.fi/lr> < http://www.iki.fi/zwak/fonts>

Saapi l?hett ?? meili?,jos aihe ei liity ryhm ?? n,tai on yksityinen

tjsp。,mutta?l? L·海特? samaa viesti? meilitse ja ryhm ?? n。



No, it is much simpler:
..myTableStyle table tr td {height:2em;}

And

..myTableStyle td {height:2em;}

is about same.

--
Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
Saapi l?hett?? meili?, jos aihe ei liity ryhm??n, tai on yksityinen
tjsp., mutta ?l? l?het? samaa viesti? meilitse ja ryhm??n.


文章< bf ************ @ ID-52872.news。 uninaber.de>,Barbara de Zoete

写道:
In article <bf************@ID-52872.news.uni-berlin.de>, Barbara de Zoete
wrote:
table.MyTableStyle,td.MyTableStyle
{
高度:25px;
}

< table class = MyTableStyle>
table.MyTableStyle, td.MyTableStyle
{
height:25px;
}

<table class=MyTableStyle>




那不行。它使表格高度为25px,并且所有td都为类别

MyTableStyle。没有td'的内部表格有MyTableStyle类


你们两个都学到这个:
http://www.w3.org/TR/CSS2/selector.html

-

Lauri Raittila< http://www.iki.fi/lr> < http://www.iki.fi/zwak/fonts>

Saapi l?hett ?? meili?,jos aihe ei liity ryhm ?? n,tai on yksityinen

tjsp。,mutta?l? L·海特? samaa viesti? meilitse ja ryhm ?? n。



That don''t work. It makes the table 25px height, and all td''s with class
MyTableStyle. Not td''s inside table that has class MyTableStyle

Both of you, learn this:
http://www.w3.org/TR/CSS2/selector.html
--
Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
Saapi l?hett?? meili?, jos aihe ei liity ryhm??n, tai on yksityinen
tjsp., mutta ?l? l?het? samaa viesti? meilitse ja ryhm??n.


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

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