java - 在jsp上打印org.w3c.dom.Document

标签 java jsp spring-mvc

我从 Spring Controller ModelAndView 发送对象 org.w3c.dom.Document。所以我需要在我的jsp上打印它而不需要scriplet。有没有办法用jSTL来做到这一点? 比 X))

最佳答案

JSTL 有 XML tags 。您可以尝试<x:out>

但最好使用 Controller (或 Servlet)并将文档打印到 response.getOutputStream() ,使用我在this answer中提供的方法

关于java - 在jsp上打印org.w3c.dom.Document,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3764140/

相关文章:

java - 集合 : Printing the top five occurrences by reading from a file

java - 我想在 Java 中使用 String.replaceAll(regex, regex) 而不是 (regex, String)

java - Servlet 返回 "HTTP Status 404 The requested resource (/servlet) is not available"

jsp - 如何使用 EL 在 JSP 中获取 request/session/servletcontext 属性?

java - Spring MVC,Tile在运行war文件jetty Runner时不渲染jsp页面

java - 在应用程序上下文中添加 applicationContext-dao.xml 和 applicationContext-service.xml 背后的原因是什么

java - 检查 Android 中 Typeface 对象的系列

java - 当类的名称为 Integer、String 等时会发生什么

java - Liferay 错误 [RuntimePageImpl-16] 不是有效的包含

java - 在 Spring-mvc 拦截器中,如何访问处理程序 Controller 方法?