在struts-config.xml中声明Doc类型下
<!DOCTYPE struts-config PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 1.3//EN"
"http://struts.apache.org/dtds/struts-config_1_3.dtd">
在 xml 中的 url“http://struts.apache.org/dtds/struts-config_1_3.dtd”处,得到以下消息:“该文件无法验证为主机”struts.apache .org”目前无法访问。”
由于此原因,我无法部署该应用程序。
知道如何解决上述问题。
最佳答案
您问题中的链接对我来说效果很好,但下面的链接是我当前正在使用的,尝试一下看看?
http://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd
编辑:本地引用 dtd。我认为这应该可以解决问题。
- 复制struts-config_1_3.dtd,然后放入/WEB-INF/dtd文件夹
将struts-config.xml中的doctype修改为此
<!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.3//EN" "../dtd/struts-config_1_3.dtd">
关于java - 由于主机 "struts.apache.org"当前无法访问,因此无法验证该文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9661866/