xml报错(dtd):The markup declarations contained or pointed to by the document type declaration must be well-formed


文件后缀为.xml里如下一行报错“The markup declarations contained or pointed to by the document type declaration must be well-formed.”

<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">

外部“http://mybatis.org/dtd/mybatis-3-mapper.dtd”在浏览器里是能打开下载的,但是本地服务启动项目,需要将其下载下来,再导入到eclipse里。eclipse如何导入dtd步骤如下:

1、Eclipse中打开window-->Preferences-->XML-->XML catalog --> add
2、location 选择 file system,然后选择你的本地dtd文件。
3、key type 选择 Public ID。
4、key 填入上述行中用绿色标注的值。  [“eclipse如何导入dtd”的更为详细解答:https://www.cnblogs.com/wangmingshun/p/5675952.html]


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM