欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

js制作的鼠標懸浮時產(chǎn)生的下拉框效果

 更新時間:2012年10月27日 23:28:54   作者:  
js制作的鼠標懸浮時產(chǎn)生的下拉框效果,需要的朋友可以參考下
先給大家補補課,講個簡單的例子:
復(fù)制代碼 代碼如下:

<html><head>
<meta type-equiv="Content-Type" content="text/html">
<meta charset="utf-8″>
<script type="text/javascript">
jq=jQuery.noConflict();
jq=(document).ready(function(){
jq("a").mouseover(function(){
jq("a").css("color","#c00″);
});
jq("a').mouseout(function(){
jq("a").css("color","#000000″);
});
</script>
</head><body>
<a href="www.dbjr.com.cn">鼠標放在上面看看會發(fā)生什么</a>
</body></html>

jq=jQuery.noConflict();
這是定義一個js的jquery庫名;
jq(document).ready(function(){
/*這是一個關(guān)于document對象的函數(shù)里面是函數(shù)內(nèi)容*/
});
jq("a").mouseover()function(){
/*這是定義事件mouseover的內(nèi)容*/
}。
在看一個實際例子;點擊時隱藏文本:
復(fù)制代碼 代碼如下:

<html><head>
<script type="text/javascript">
$(document).ready(function() {
$(".abc .hide").click(function() {
$("this").parents("abc").hide("slow"); }); });
</script>
<stype type="text/css">
div.abc {
background: #e5eec;
padding: 7px;
margin: 0px;
border: solid 1px #c00; }
</stype>
</head><body>
<div class="abc">
<p><button class="abc" type="button">hide<button><br/>
這段文字將被隱藏<br/>
這段文字也將被隱藏
</p></div>
<div class="abc"><p>
<button class="abc" type="button">hide me</button><br/>
這段文字在點擊hideme時隱藏<br/>
這段文字同樣也會隱藏。
</p></dvi>
</body></html>

功課差不多了,我們言歸正傳回到主題下拉框才是王道。
復(fù)制代碼 代碼如下:

<html><head>
<!–author linuxa
blogs: www.dbjr.com.cn–>
<meta http-equiv="content-type" content="text/html">
<meta charset="utf-8″>
<title>下拉框的制作</title>
</head><body>
</body></html>

相關(guān)文章

最新評論