首页 > 代码库 > EasyUI登陆框(练习)

EasyUI登陆框(练习)

<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 src="jquery-easyui-1.4/jquery.min.js"></script>    <script src="jquery-easyui-1.4/jquery.easyui.min.js"></script>    <link href="jquery-easyui-1.4/themes/icon.css" rel="stylesheet" />    <link href="jquery-easyui-1.4/themes/default/easyui.css" rel="stylesheet" />    <script src="jquery-easyui-1.4/locale/easyui-lang-zh_CN.js"></script>    <script type="text/javascript">        var loginDiv;        $(function () {            loginDiv = $("#loginDiv").dialog({                closable: false,                modal: true,                title: "欢迎您来到登录界面",                buttons: [                    {                        text: "注册",                        handler: function () { }                    }, {                        text: "登录",                        handler: function () {                            console.info("你丫的敢点我!");                            //提交数据:http://www.jb51.net/article/21051.htm                            console.info($("#loginFrom").serialize());                            $.ajax({                                url: sy.bh() + /userController.do?login,                                data: $("#loginFrom").serialize(),                                cache: false,                                datatype: json,                                success: function (r) {                                    if (r & r.success) {                                        $("#loginDiv").dialog("close");                                        $.messager.show({                                            title: 提示,                                            msg: r.msg                                        });                                    } else {                                        $.messager.alert(标题, r.msg);                                    }                                }                            });                        }                    }                ]            });        });    </script></head><body>    <form id="loginFrom" method="post" runat="server">        <div>            <div id="loginDiv" style="width: 250px; height: 150px;">                <table style=" padding:10px">                    <tr><th  style="text-align:right">用户名</th><td><input name="name"" /></td></tr>                    <tr><th  style="text-align:right">&nbsp;</th><td><input type="password" name="psw"/></td></tr>                </table>            </div>        </div>    </form></body></html>
View Code

未完成。。。

EasyUI登陆框(练习)