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

Jquery實(shí)現(xiàn)的一種常用高亮效果示例代碼

 更新時(shí)間:2014年01月28日 08:54:58   作者:  
本篇文章只要是對(duì)Jquery實(shí)現(xiàn)的一種常用高亮效果示例代碼進(jìn)行了介紹,需要的朋友可以過(guò)來(lái)參考下,希望對(duì)大家有所幫助

如下所示:

復(fù)制代碼 代碼如下:

<html>
<head>
    <title>jquery</title>
    <style>
        body
        {
            font-size: 12px;
        }
        li
        {
            list-style: none;
            height: 34px;
            padding-top: 5px;
        }
    </style>

    <script type="text/javascript" src="jquery-1.2.6.pack.js"></script>

    <script type="text/javascript">
$(document).ready(function(){   
    var oInputs = $("ul.demo input");

    oInputs.each(function(i){
        oInputs.eq(i).focus(function(){
            oInputs.eq(i).parent().css("background-color","ccf");
        }).blur(function(){
            oInputs.parent().css("background-color","");
        })
     });

   
    oInputs.focus(function(){
        $(this).css("background-color","ff9").blur(function(){
            $(this).css("background-color","");
        });
    })
})
    </script>

</head>
<body>
    <ul class="demo">
        <li>
            <h5>
                注冊(cè)選項(xiàng)</h5>
        </li>
        <li>用戶名:<input type="text" value="" id="name" style="width: 200px" /></li>
        <li>密 碼:<input type="password" value="" id="pass" style="width: 200px" /></li>
        <li>愛(ài) 好:<input type="checkbox" value="" />籃球&nbsp;<input type="checkbox" value="" />足球&nbsp;<input
            type="checkbox" value="" />音樂(lè)</li>
    </ul>
    </script>
</body>
</html>

相關(guān)文章

最新評(píng)論