最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

簡(jiǎn)單的郵箱登陸的提示效果類似于yahoo郵箱

 更新時(shí)間:2014年02月26日 15:38:46   作者:  
類似于yahoo郵箱登陸的提示效果,當(dāng)鼠標(biāo)聚焦到郵箱地址文本框時(shí),文本框文字被清空

當(dāng)鼠標(biāo)聚焦到郵箱地址文本框時(shí),文本框內(nèi)的“請(qǐng)輸入郵箱地址”文字被清空。

效果圖:

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

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="類似于yahoo郵箱登陸的提示效果.aspx.cs" Inherits="類似于yahoo郵箱登陸的提示效果" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
    <script type ="text/javascript" src ="Scripts/jquery-1.7.1.js"></script>
    <script type ="text/javascript" >
        $(function () {
            //對(duì)地址框進(jìn)行操作
            $("#address").focus(function () {        //地址框獲得鼠標(biāo)焦點(diǎn)
                var txt_value = $(this).val();       //得到當(dāng)前文本框的值
                if (txt_value == "請(qǐng)輸入郵箱地址") {
                    $(this).val("");                 //如果符合條件,則清空文本框內(nèi)容
                }
            });
            $("#address").blur(function () {         //地址框失去鼠標(biāo)焦點(diǎn)
                var txt_value = $(this).val();       //得到當(dāng)前文本框的值
                if (txt_value == "") {
                    $(this).val("請(qǐng)輸入郵箱地址");      //如果符合條件,則設(shè)置內(nèi)容
                }
            })
            //對(duì)密碼框進(jìn)行操作
            $("#password").focus(function () {
                var txt_value = $(this).val();
                if (txt_value == "請(qǐng)輸入郵箱密碼") {
                    $(this).val("");
                }
            });
            $("#password").blur(function () {
                var txt_value = $(this).val();
                if (txt_value == "") {
                    $(this).val("請(qǐng)輸入郵箱密碼");
                }
            })
        });
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div>
    <input type ="text" id ="address" value ="請(qǐng)輸入郵箱地址" /><br /><br />
        <input type ="text" id ="password" value ="請(qǐng)輸入郵箱密碼" /><br /><br />
        <input type ="button" value ="登錄" />
    </div>
    </form>
</body>
</html>

相關(guān)文章

最新評(píng)論

洱源县| 绥德县| 石景山区| 婺源县| 佛冈县| 阜新市| 随州市| 年辖:市辖区| 台江县| 甘泉县| 丰原市| 虎林市| 浮梁县| 揭西县| 利辛县| 新建县| 崇文区| 洛扎县| 汝州市| 东辽县| 东丽区| 清新县| 宁武县| 东城区| 高唐县| 康保县| 白银市| 郴州市| 焉耆| 万全县| 应城市| 饶河县| 内丘县| 临朐县| 旬阳县| 临邑县| 丁青县| 洪洞县| 永春县| 台东市| 桐乡市|