NutzCN Logo
问答 nutz book de index 启动过后点击事件没反应 其他都可以
发布于 2052天前 作者 qq_183ceadf 1091 次浏览 复制 上一个帖子 下一个帖子
标签:
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;UTF-8">
<title></title>
<script type="text/javascript" src="http://lib.sinaapp.com/js/jquery/2.0.3/jquery-2.0.3.min.js"></script>
<script type="text/javascript">
    var me = '<%=session.getAttribute("me") %>';
    var base = '${base}';
    $(function() {
        $("#login_button").click(function() {
            $.ajax({
                url : base + "/user/login",
                type: "POST",
                data:$('#loginForm').serialize(),
                error: function(request) {
                    alert("Connection error");
                },
                dataType:"json",
                success: function(data) {
                    alert(data);
                    if (data == true) {
                        alert("登陆成功");
                        location.reload();
                    } else {
                        alert("登陆失败,请检查账号密码")
                    }
                }
            });
            return false;
        });
        if (me != "null") {
            $("#login_div").hide();
            $("#userInfo").html("您的Id是" + me);
            $("#user_info_div").show();
        } else {
            $("#login_div").show();
            $("#user_info_div").hide();
        }
    });
</script>
</head>
<body>
	<div id="login_div">
		<form action="#"  method="post" id="loginForm">
			用户名<input type="text" value="admin" name="username">
			密  码<input type="password" value="123456" name="password" >
			<button id="longin_button">提交</button>
		</form>
	</div>
	<div id="user_info_div">
		<p id="userInfo"></p>
		<a href="${base}/user/logout">登出</a>
	</div>
</body>
</html>
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Server version:        Apache Tomcat/9.0.1
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Server built:          Sep 27 2017 17:31:52 UTC
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Server number:         9.0.1.0
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: OS Name:               Windows 10
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: OS Version:            10.0
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Architecture:          amd64
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Java Home:             C:\Program Files\Java\jre1.8.0_152
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: JVM Version:           1.8.0_152-b16
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: JVM Vendor:            Oracle Corporation
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: CATALINA_BASE:         D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: CATALINA_HOME:         D:\apache-tomcat-9.0.1
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Command line argument: -Dcatalina.base=D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Command line argument: -Dcatalina.home=D:\apache-tomcat-9.0.1
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Command line argument: -Dwtp.deploy=D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Command line argument: -Djava.endorsed.dirs=D:\apache-tomcat-9.0.1\endorsed
八月 15, 2018 1:51:27 下午 org.apache.catalina.startup.VersionLoggerListener log
信息: Command line argument: -Dfile.encoding=UTF-8
八月 15, 2018 1:51:27 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
信息: Loaded APR based Apache Tomcat Native library [1.2.14] using APR version [1.6.2].
八月 15, 2018 1:51:27 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
信息: APR capabilities: IPv6 [true], sendfile [true], accept filters [false], random [true].
八月 15, 2018 1:51:27 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
信息: APR/OpenSSL configuration: useAprConnector [false], useOpenSSL [true]
八月 15, 2018 1:51:27 下午 org.apache.catalina.core.AprLifecycleListener initializeSSL
信息: OpenSSL successfully initialized [OpenSSL 1.0.2l  25 May 2017]
八月 15, 2018 1:51:28 下午 org.apache.coyote.AbstractProtocol init
信息: Initializing ProtocolHandler ["http-nio-8080"]
八月 15, 2018 1:51:28 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
信息: Using a shared selector for servlet write/read
八月 15, 2018 1:51:28 下午 org.apache.coyote.AbstractProtocol init
信息: Initializing ProtocolHandler ["ajp-nio-8009"]
八月 15, 2018 1:51:28 下午 org.apache.tomcat.util.net.NioSelectorPool getSharedSelector
信息: Using a shared selector for servlet write/read
八月 15, 2018 1:51:28 下午 org.apache.catalina.startup.Catalina load
信息: Initialization processed in 1729 ms
八月 15, 2018 1:51:28 下午 org.apache.catalina.core.StandardService startInternal
信息: Starting service [Catalina]
八月 15, 2018 1:51:28 下午 org.apache.catalina.core.StandardEngine startInternal
信息: Starting Servlet Engine: Apache Tomcat/9.0.1
八月 15, 2018 1:51:30 下午 org.apache.jasper.servlet.TldScanner scanJars
信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
八月 15, 2018 1:51:30 下午 org.apache.catalina.startup.HostConfig deployDescriptor
信息: Deploying configuration descriptor [D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\conf\Catalina\localhost\nutzbook.xml]
八月 15, 2018 1:51:30 下午 org.apache.catalina.startup.SetContextPropertiesRule begin
警告: [SetContextPropertiesRule]{Context} Setting property 'source' to 'org.eclipse.jst.jee.server:nutzbook' did not find a matching property.
八月 15, 2018 1:51:33 下午 org.apache.jasper.servlet.TldScanner scanJars
信息: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
18-08-15 13:51:33.370 INFO [main] Select SystemLog as Nutz.Log implement
18-08-15 13:51:33.568 INFO [main] NutFilter[nutz] starting ...
18-08-15 13:51:33.606 DEBUG [main] Locations count=9 time use 24ms
18-08-15 13:51:33.612 DEBUG [main] Locations count=13 time use 5ms
18-08-15 13:51:33.626 DEBUG [main] Loading by class org.nutz.mvc.impl.NutLoading
18-08-15 13:51:33.629 INFO [main] Nutz Version : 1.r.67-SNAPSHOT 
18-08-15 13:51:33.630 INFO [main] Nutz.Mvc[nutz] is initializing ...
18-08-15 13:51:33.630 DEBUG [main] Web Container Information:
18-08-15 13:51:33.631 DEBUG [main]  - Default Charset : UTF-8
18-08-15 13:51:33.631 DEBUG [main]  - Current . path  : C:\Users\dyh\Desktop\.
18-08-15 13:51:33.631 DEBUG [main]  - Java Version    : 1.8.0_152
18-08-15 13:51:33.631 DEBUG [main]  - File separator  : \
18-08-15 13:51:33.632 DEBUG [main]  - Timezone        : Asia/Shanghai
18-08-15 13:51:33.632 DEBUG [main]  - OS              : Windows 10 amd64
18-08-15 13:51:33.633 DEBUG [main]  - ServerInfo      : Apache Tomcat/9.0.1
18-08-15 13:51:33.633 DEBUG [main]  - Servlet API     : 4.0
18-08-15 13:51:33.634 DEBUG [main]  - ContextPath     : /nutzbook
18-08-15 13:51:33.634 DEBUG [main]  - context.tempdir : D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\nutzbook
18-08-15 13:51:33.635 DEBUG [main]  - MainModule      : net.wendal.nutzbook.MainModule
18-08-15 13:51:33.638 DEBUG [main] >> app.root = D:/ec/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/nutzbook
18-08-15 13:51:33.703 DEBUG [main] Using 101 castor for Castors
18-08-15 13:51:33.704 DEBUG [main] @IocBy(type=org.nutz.mvc.ioc.provider.ComboIocProvider, args=["*js", "ioc/", "*anno", "net.wendal.nutzbook", "*tx", "*async"],init=[])
18-08-15 13:51:33.741 DEBUG [main] Found 1 resource by src( ioc/ ) , regex( ^(.+[.])(js|json)$ )
18-08-15 13:51:33.741 DEBUG [main] loading [dao.js]
18-08-15 13:51:33.745 DEBUG [main] Loaded 2 bean define from path=[ioc/] --> [dataSource, dao]
18-08-15 13:51:33.752 INFO [main]  > scan 'net.wendal.nutzbook'
18-08-15 13:51:33.758 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
18-08-15 13:51:33.769 INFO [main]    > add 'userModule                              ' - net.wendal.nutzbook.UserModule.UserModule
18-08-15 13:51:33.797 DEBUG [main] Load AopConfigure for anno=org.nutz.aop.interceptor.async.Async by type=org.nutz.aop.interceptor.async.AsyncAopIocLoader
18-08-15 13:51:33.802 INFO [main] ... NutIoc init complete
18-08-15 13:51:33.807 INFO [main] Build URL mapping by org.nutz.mvc.impl.UrlMappingImpl ...
18-08-15 13:51:33.809 DEBUG [main] @Views(DefaultViewMaker.class)
18-08-15 13:51:33.813 DEBUG [main] @ChainBy(org.nutz.mvc.impl.NutActionChainMaker)
18-08-15 13:51:33.821 DEBUG [main] module class location 'file:/D:/ec/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/nutzbook/WEB-INF/classes/'
18-08-15 13:51:33.821 DEBUG [main]  > scan 'net.wendal.nutzbook'
18-08-15 13:51:33.826 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
18-08-15 13:51:33.830 DEBUG [main]    >> add 'net.wendal.nutzbook.UserModule.UserModule'
18-08-15 13:51:33.830 DEBUG [main] Use org.nutz.mvc.impl.NutEntryDeterminer as EntryMethodDeterminer
18-08-15 13:51:33.845 INFO [main] Optional processor class not found, disabled : org.nutz.integration.shiro.NutShiroProcessor
18-08-15 13:51:33.858 INFO [main] Optional processor class not found, disabled : org.nutz.plugins.validation.ValidationProcessor
18-08-15 13:51:33.877 DEBUG [main]    '/user/count'               >> (UserModule.java:27).count            : int        | @Ok(json ) @Fail(http:500) | by 0 Filters | (I:UTF-8/O:UTF-8)
18-08-15 13:51:33.882 DEBUG [main]    '/user/login'               >> (UserModule.java:32).login            : Object     | @Ok(json ) @Fail(http:500) | by 0 Filters | (I:UTF-8/O:UTF-8)
18-08-15 13:51:33.885 DEBUG [main]    '/user/logout'              >> (UserModule.java:43).logout           : void       | @Ok(>>:/ ) @Fail(http:500) | by 0 Filters | (I:UTF-8/O:UTF-8)
18-08-15 13:51:33.886 INFO [main] Found 3 module methods
18-08-15 13:51:33.886 DEBUG [main] @Localization not define
18-08-15 13:51:33.887 INFO [main] Setup application...
18-08-15 13:51:33.890 DEBUG [main] Get 'dao'<interface org.nutz.dao.Dao>
18-08-15 13:51:33.890 DEBUG [main] Get '$aop_async'<interface org.nutz.ioc.aop.config.AopConfigration>
18-08-15 13:51:33.891 DEBUG [main] 	 >> Load definition name=$aop_async
18-08-15 13:51:33.893 DEBUG [main] Found IocObject($aop_async) in AsyncAopIocLoader@651092951
18-08-15 13:51:33.893 DEBUG [main] 	 >> Make...'$aop_async'<interface org.nutz.ioc.aop.config.AopConfigration>
18-08-15 13:51:33.912 DEBUG [main] Save object '$aop_async' to [app] 
18-08-15 13:51:33.920 DEBUG [main] Load AopConfigure for anno=org.nutz.ioc.aop.Aop by type=org.nutz.ioc.aop.config.impl.AnnotationAopConfigration
18-08-15 13:51:33.920 DEBUG [main] 	 >> Load definition name=dao
18-08-15 13:51:33.920 DEBUG [main] Found IocObject(dao) in JsonLoader(paths=[ioc/])
18-08-15 13:51:33.920 DEBUG [main] 	 >> Make...'dao'<interface org.nutz.dao.Dao>
18-08-15 13:51:33.920 DEBUG [main] Save object 'dao' to [app] 
18-08-15 13:51:33.921 DEBUG [main] Get 'dataSource'<>
18-08-15 13:51:33.921 DEBUG [main] 	 >> Load definition name=dataSource
18-08-15 13:51:33.922 DEBUG [main] Found IocObject(dataSource) in JsonLoader(paths=[ioc/])
18-08-15 13:51:33.922 DEBUG [main] 	 >> Make...'dataSource'<>
18-08-15 13:51:33.922 DEBUG [main] Save object 'dataSource' to [app] 
18-08-15 13:51:33.942 DEBUG [main] Load class com.alibaba.druid.pool.DruidDataSource without AOP
八月 15, 2018 1:51:34 下午 com.alibaba.druid.pool.DruidDataSource info
信息: {dataSource-1} inited
18-08-15 13:51:34.321 DEBUG [main] Load class org.nutz.dao.impl.NutDao without AOP
18-08-15 13:51:34.323 DEBUG [main] Get 'dataSource'<>
18-08-15 13:51:34.519 DEBUG [main] Jdbcs init complete
18-08-15 13:51:34.519 INFO [main] Get Connection from DataSource for JdbcExpert, if you lock at here, check your database server and configure
18-08-15 13:51:34.715 DEBUG [main] select expert : org.nutz.dao.impl.jdbc.mysql.MysqlJdbcExpert
18-08-15 13:51:34.722 DEBUG [main] JDBC Driver --> mysql-connector-java-5.1.14 ( Revision: ${bzr.revision-id} )
18-08-15 13:51:34.723 DEBUG [main] JDBC Name   --> MySQL-AB JDBC Driver
18-08-15 13:51:34.723 DEBUG [main] JDBC URL    --> jdbc:mysql://127.0.0.1:3306/nutzbook
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_client=utf8mb4
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_connection=utf8mb4
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_database=utf8
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_filesystem=binary
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_results=
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_server=utf8
18-08-15 13:51:34.727 DEBUG [main] Mysql : character_set_system=utf8
18-08-15 13:51:34.728 DEBUG [main] Mysql : character_sets_dir=C:\Program Files (x86)\MySQL\MySQL Server 5.5\share\charsets\
18-08-15 13:51:34.729 DEBUG [main] Mysql : binlog_format=STATEMENT
18-08-15 13:51:34.730 DEBUG [main] Mysql : database=nutzbook
18-08-15 13:51:34.730 DEBUG [main] Mysql : user=root@localhost
18-08-15 13:51:34.742 DEBUG [main] Database info --> MYSQL:[MySQL - 5.5.25a]
18-08-15 13:51:34.748 DEBUG [main] Found 4 resource by src( net/wendal/nutzbook/ ) , regex( ^.+[.]class$ )
18-08-15 13:51:34.791 DEBUG [main] SELECT COUNT(*) FROM t_user 
18-08-15 13:51:34.793 INFO [main] Nutz.Mvc[nutz] is up in 1158ms
八月 15, 2018 1:51:34 下午 org.apache.catalina.startup.HostConfig deployDescriptor
信息: Deployment of configuration descriptor [D:\ec\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\conf\Catalina\localhost\nutzbook.xml] has finished in [3,947] ms
八月 15, 2018 1:51:34 下午 org.apache.coyote.AbstractProtocol start
信息: Starting ProtocolHandler ["http-nio-8080"]
八月 15, 2018 1:51:34 下午 org.apache.coyote.AbstractProtocol start
信息: Starting ProtocolHandler ["ajp-nio-8009"]
八月 15, 2018 1:51:34 下午 org.apache.catalina.startup.Catalina start
信息: Server startup in 6417 ms

1 回复

已经解决 谢谢了

添加回复
请先登陆
回到顶部