悬停显示问题 [英] hover display problem

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

问题描述



我在理解显示和悬停时遇到了问题。


我正试图将鼠标悬停在一个问题上并显示答案。


..问号{

颜色:#fff;

背景:紫色;

宽度:300px;

font-weight:bold;

padding-left:5px;

}

..回答{

颜色:#000;

背景:#fff;

宽度:500px;

填充: 0px 20px 0px 20px;

display:none;

}


< div class =" question"> This是一个问题< / div>

< div class =" answer">这就是答案。这就是答案。这是

答案。这就是答案。这就是答案。这就是答案。这个

就是答案。这就是答案。这就是答案。这是

答案。这就是答案。这就是答案。这就是答案。这个

就是答案。这就是答案。这就是答案。 < / div>


..hover:question {display .answer}


完全丢失。


I''m having problems understanding display and hover.

I''m trying to hover over a question and have the answer display.

..question {
color: #fff;
background: purple;
width: 300px;
font-weight: bold;
padding-left: 5px;
}
..answer {
color: #000;
background: #fff;
width: 500px;
padding: 0px 20px 0px 20px;
display: none;
}

<div class="question">This is a question</div>
<div class="answer">This is the answer. This is the answer. This is the
answer. This is the answer. This is the answer. This is the answer. This
is the answer. This is the answer. This is the answer. This is the
answer. This is the answer. This is the answer. This is the answer. This
is the answer. This is the answer. This is the answer. </div>

..hover:question {display .answer}

Totally lost.

推荐答案

zzpat< zz ******* @ gmail.comwrote:
zzpat <zz*******@gmail.comwrote:

> .hover:问题{display .answer}
>.hover:question {display .answer}

http: //www.w3.org/TR/CSS1#basic-concepts


''显示''

价值:内联|块| list-item |磨合|内联块|

表|内联表| table-row-group | table-header-group |
table-footer-group |表格行table-column-group | table-column |

table-cell |表格标题|没有|继承
http://www.w3 .org / TR / CSS21 / visuren.html#display-prop

-

Spartanicus

http://www.w3.org/TR/CSS1#basic-concepts

''display''
Value: inline | block | list-item | run-in | inline-block |
table | inline-table | table-row-group | table-header-group |
table-footer-group | table-row | table-column-group | table-column |
table-cell | table-caption | none | inherit
http://www.w3.org/TR/CSS21/visuren.html#display-prop

--
Spartanicus

< br>

周五,2007年2月9日21:58:38 +0100,Spartanicus< in ***** @ invalid.invalid>

写道:
On Fri, 09 Feb 2007 21:58:38 +0100, Spartanicus <in*****@invalid.invalid>
wrote:

zzpat< zz ******* @ gmail.comwrote:
zzpat <zz*******@gmail.comwrote:

> .hover:question {display .answer}
>.hover:question {display .answer}


http ://www.w3.org/TR/CSS1#basic-concepts


''显示''

价值:内联|块| list-item |磨合|内联块|

表|内联表| table-row-group | table-header-group |
table-footer-group |表格行table-column-group | table-column |

table-cell |表格标题|没有|继承
http://www.w3 .org / TR / CSS21 / visuren.html#display-prop



确实。


..问题:悬停。回答{display:block;}

-

Rik Wasmus


Indeed.

..question:hover .answer{display:block;}

--
Rik Wasmus


Scripsit zzpat:
Scripsit zzpat:

我正试图将鼠标悬停在一个问题上并显示答案。
I''m trying to hover over a question and have the answer display.



这是一种错误的方法,至少在创作WWW时是这样的(这是我们在这里讨论的b $ b)。在向用户披露必要的b / b $ b信息时,你会依赖CSS,从而忽略了常见的CSS警告。

That''s a wrong approach, at least in authoring for the WWW (which is what we
discuss here). You would rely on CSS in matters of disclosing essential
information to the user, thereby ignoring the usual CSS caveats.


.hover:question {display .answer}


完全输了。
.hover:question {display .answer}

Totally lost.



是的,你是;

悬停元素后,你不能改变另一个元素的属性。


-

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

Yes, you are; you can''t change the properties of another element upon
hovering an element.

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


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

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