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