码迷,mamicode.com
首页 > 其他好文 > 详细

EasyUI登陆框(练习)

时间:2014-10-13 23:26:57      阅读:269      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   color   io   os   ar   java   for   

bubuko.com,布布扣
<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登陆框(练习)

标签:style   blog   http   color   io   os   ar   java   for   

原文地址:http://www.cnblogs.com/vakeynb/p/4023119.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!