2
A
回答
5
- 下降
pageDebugger.jsp
在你的web应用 - 访问包括来自另一个JSP一样,
layout.jsp
显示每一页上这个细节在表后 - 此页面列出
- 请求参数
- 页面作用域属性和值
- 请求作用域属性和值
- 会话范围的属性和值
- 应用范围属性和值的范围定义
- 选项来搜索资源的类路径上
- 依赖于Spring
- 请求头
- 所有的Spring bean框架是可选删除它,如果你不使用
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<html>
<head>
<style type="text/css">
td {
word-wrap: break-word;
}
</style>
</head>
<body>
<table width="100%" border="1" cellpadding="0" cellspacing="0"
style="table-layout: fixed;">
<colgroup>
<col width="500">
</colgroup>
<tr>
<th colspan="2">
<h3>attributes in $paramValues</h3>
</th>
</tr>
<c:forEach var="entry" items="${paramValues}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><c:forEach var="item" items="${entry.value}"
varStatus="status">
<pre><c:out value="${item}" /></pre>
<c:if test="${not status.last}">
<br />
</c:if>
</c:forEach></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>attributes in $requestScope</h3>
</th>
</tr>
<c:forEach var="entry" items="${requestScope}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><pre><c:out value="${entry.value}" /></pre></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>attributes in $sessionScope</h3>
</th>
</tr>
<c:forEach var="entry" items="${sessionScope}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><pre><c:out value="${entry.value}" /></pre></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>attributes in $pageScope</h3>
</th>
</tr>
<c:forEach var="entry" items="${pageScope}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><pre><c:out value="${entry.value}" /></pre></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>attributes in $headerValues</h3>
</th>
</tr>
<c:forEach var="entry" items="${headerValues}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><c:forEach var="item" items="${entry.value}"
varStatus="status">
<pre><c:out value="${item}" /></pre>
<c:if test="${not status.last}">
<br />
</c:if>
</c:forEach></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>attributes in $applicationScope</h3>
</th>
</tr>
<c:forEach var="entry" items="${applicationScope}">
<tr>
<td><c:out value="${entry.key}" /></td>
<td><pre><c:out value="${entry.value}" /></pre></td>
</tr>
</c:forEach>
<tr>
<th colspan="2">
<h3>System Properties</h3>
</th>
</tr>
<tr>
<th>Key</th>
<th>Value</th>
</tr>
<%@page import="java.util.Map"%>
<%@page import="java.util.Set"%>
<%@page import="java.util.Properties"%>
<%@page import="java.util.Arrays"%>
<%
Properties p = System.getProperties();
Set<Map.Entry<Object, Object>> set = p.entrySet();
for (Map.Entry<Object, Object> e : set) {
%>
<tr>
<td><%=e.getKey()%></td>
<td><%="".equals(e.getValue()) ? " " : e.getValue()%></td>
<%
}
%>
</tr>
<tr>
<th colspan="2">
<h3>Spring Beans</h3>
</th>
</tr>
<%@page import="org.springframework.web.context.WebApplicationContext"%>
<%@page
import="org.springframework.web.context.support.WebApplicationContextUtils"%>
<%@page import="org.springframework.core.io.Resource"%>
<%
try {
WebApplicationContext springContext = WebApplicationContextUtils
.getWebApplicationContext(config.getServletContext());
if (springContext != null) {
String[] beanNames = springContext.getBeanDefinitionNames();
Arrays.sort(beanNames);
for (String beanName : beanNames) {
String className = springContext.getType(beanName)
.getName();
%>
<tr>
<td><%=beanName%></td>
<td><%=className%></td>
</tr>
<%
}
%>
<tr>
<th colspan="2">
<h3>Spring Resources</h3>
</th>
</tr>
<tr>
<th colspan="2">
<form><input name="resources" size="50"/></form>
</th>
</tr>
<%
String resourceNames = request.getParameter("resources");
if (resourceNames != null) {
Resource[] resources = springContext
.getResources(resourceNames);
for (Resource r : resources) {
%>
<tr>
<td><%=r.getFilename()%></td>
<td><%=r.getURI()%></td>
</tr>
<%
}
}
}
} catch (Exception e) {
e.printStackTrace();
}
%>
</table>
</body>
</html>
此外,如果你有选项来修改web.xml文件,看看这些是也可用于监测/型材活动HTTP会话属性
0
有很大的帮助。在工作中,我已经使用JDeveloper来从IDE运行在调试模式下的应用程序。您可以将断点插入到.jsp中并查看所有调试信息。虽然,我不是jdeveloper的忠实粉丝,但它是IDE的一个很好的功能。页面直接或
相关问题
- 1. 创建JSP信息页面
- 2. 在jsp页面中显示错误信息需要帮助
- 3. 如何将信息从一个jsp页面传递到其他jsp页面
- 4. 在WebLogic中调试JSP页面
- 5. 如何使用Tomcat调试JSP页面?
- 6. 调试信息
- 7. 调试,信息
- 8. 调试信息
- 9. 从调用助手方法的页面上的助手类调用方法
- 10. -sass-调试信息
- 11. GCC调试信息
- 12. DLL调试信息
- 13. ASP.NET浏览器调试(支持信息)页面
- 14. 如何在C#页面中编写调试信息
- 15. “!map:ActiveSupport :: HashWithIndifferentAccess”没有出现在页面调试信息中
- 16. Eclipse,C++和“调试助手”?
- 17. 托管调试助手“DisconnectedContext”
- 18. Ajax从JSP页面调用servlet页面
- 19. 用JewelCLI手动输出帮助信息?
- 20. 从anathor jsp页面调用jsp方法
- 21. 从Servlet调用JSP页面
- 22. 从jsp页面调用GWT
- 23. JSP:使用从一个页面到另一个页面的信息
- 24. Spring新手,在jsp页面中调用spring bean方法(2.5,xml),测试
- 25. 从JSP页面调用另一个JSP页面
- 26. 如何将信息从servlet传递到JSP页面
- 27. 将信息从servlet发送到jsp页面
- 28. JSP页面缓存来自旧会话的信息
- 29. 帮助把RDF在Web页面(JSP)
- 30. 使用page.info页面信息
最后! thx,使我的一天 – TecHunter