请问jsp未运行的源码和运行起来的源码为什么不一样?

flyskytoday 2015-09-21 03:35:30
java的东东,不会,请教各位~~
为什么两个代码不一样,窍门在哪???

未运行的源码如下:
<%@ page language="java" pageEncoding="GBK"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://acegisecurity.org/authz" prefix="authz"%>
<html>
<head>
<title>系统登录</title>
<script type="text/javascript">
jQuery(document).ready(function(){
if (window != top) top.location.href = location.href;
var a = getQueryStringRegExp("a");
if(a==2){
$("input[name='j_password']").focus();
$("#warn").html("您输入的用户密码不匹配,请重新输入!");
}else{
$("input[name='j_username']").focus();
}
if(!a) $("#warn").hide();
});
function getQueryStringRegExp(name){
var reg = new RegExp("(^|\\?|&)" + name + "=([^&]*)(\\s|&|$)", "i");
if (reg.test(location.href))
return unescape(RegExp.$2.replace(/\+/g, " "));
return "";
};
</script>
<style type="text/css">
<!--
body { background: #006FB6;}
-->
</style>
</head>

<body>
<authz:authorize ifAnyGranted="AUTH_SYSTEM_ANONYMOUS">

<form id="loginform" action="./j_acegi_security_check" method="post">
<div class="login">
<div id="warn"></div>
<div><font color="white">用户名:</font><input type="text" name="j_username" value="admin" autocomplete="off"/></div>
<div><font color="white">密 码:</font><input type="password" name="j_password" value="111111"/></div>
<div style="margin: 15px 50px;"><input type="submit" class="submitbutton" value="登录"/>        </div>
</div>
</form>

</authz:authorize>
</body>
</html>

运行起来的源码如下:
 



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh-cn" lang="zh-cn" xmlns:qz="http://www.emaptech.com/">
<head>


<meta http-equiv="Content-Type" content="text/html; charset=gb2312"/>
<meta name="author" content="上海南康科技"/>
<meta name="Copyright" content="上海南康科技 "/>
<meta name="Description" content="上海南康科技"/>
<meta name="robots" content="all"/>
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>
<link rel="Shortcut Icon" href="/userplatform/images/icon.ico" type="image/x-icon"/>
<link href="/userplatform/css/style.css" rel="stylesheet" type="text/css"/>
<link href="/userplatform/css/icons.css" rel="stylesheet" type="text/css"/>
<link href="/userplatform/css/extremecomponents.css" rel="stylesheet" type="text/css"/>
<script src="/userplatform/js/jquery.1.3.min.js" type="text/javascript"></script>
<script src="/userplatform/js/common.js" type="text/javascript"></script>
<script src="/userplatform/js/form/jquery.form.js" type="text/javascript"></script>
<script src="/userplatform/js/validate/jquery.validate.js" type="text/javascript"></script>
<script src="/userplatform/js/validate/validateform.js" type="text/javascript"></script>
<script src="/userplatform/js/AjaxAnyWhere/AjaxAnyWhere.js" type="text/javascript"></script>
<script src="/userplatform/js/funkyUI/jquery.funkyUI.js" type="text/javascript"></script>
<title>用户登录平台 - 系统登录 - 福州测绘成果管理系统</title>


<script type="text/javascript">
jQuery(document).ready(function(){
if (window != top) top.location.href = location.href;
var a = getQueryStringRegExp("a");
if(a==2){
$("input[name='j_password']").focus();
$("#warn").html("您输入的用户密码不匹配,请重新输入!");
}else{
$("input[name='j_username']").focus();
}
if(!a) $("#warn").hide();
});
function getQueryStringRegExp(name){
var reg = new RegExp("(^|\\?|&)" + name + "=([^&]*)(\\s|&|$)", "i");
if (reg.test(location.href))
return unescape(RegExp.$2.replace(/\+/g, " "));
return "";
};
</script>
<style type="text/css">
<!--
body { background: #006FB6;}
-->
</style>

</head>

<body>
<div class="page">
<!-- page top -->
</div>



<form id="loginform" action="./j_acegi_security_check" method="post">
<div class="login">
<div id="warn"></div>
<div><font color="white">用户名:</font><input type="text" name="j_username" value="admin" autocomplete="off"/></div>
<div><font color="white">密 码:</font><input type="password" name="j_password" value="111111"/></div>
<div style="margin: 15px 50px;"><input type="submit" class="submitbutton" value="登录"/>        </div>
</div>
</form>





<div class="page">
<div class="pagebottom">
<div class="copy">CopyRight © 2010-2015 福州测绘成果管理系统版权所有.  All Rights Reserved. 技术支持: <a href="http://www.nankang.com.cn" target="_blank">上海南康科技</a><sup>®</sup> </div>
</div>
</div>
</body>
</html>
...全文
77 点赞 收藏 2
写回复
2 条回复
切换为时间正序
当前发帖距今超过3年,不再开放新的回复
发表回复
中华雪碧 2015-09-21
头尾不一样,你打开的jsp只是一部分,头尾在其他的jsp中。
回复
兔子托尼啊 2015-09-21
解析前,解析后不一样很正常。。
回复
相关推荐
发帖
Web 开发
创建于2007-09-28

8.0w+

社区成员

Java Web 开发
申请成为版主
帖子事件
创建了帖子
2015-09-21 03:35
社区公告
暂无公告