手动下载dtd文件并配置到myeclipse中

在myEclipse里面配置struts2.xml的是后老是出现<?xml version="1.0" encoding="UTF-8" ?>报错,而且写标签的时候没有提示,后来发现时myeclipse里面没有引入http://struts.apache.org/dtds/struts-2.0.dtd,在网上找了好久终于找到引入dtd的方法:

在eclipse中 struts2配制文件中不支持提示,这时需要手工添加dtd的支持

Preferences -> MyEclipse Blue Edition -> Files and Editors -> XML -> XML Catalog -> Add

1)Location中找到struts2.0.dtd的地址
2)Key Type中选中URI
3)Key : 在struts.xml中找到dtd的地址:http://struts.apache.org/dtds/struts-2.0.dtd

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章