1. 程式人生 > >在Eclipse中匯入dtd和xsd檔案,使XML自動提示

在Eclipse中匯入dtd和xsd檔案,使XML自動提示

DTD 型別約束檔案 
    1. Window->Preferences->XML->XML Catalog->User Specified Entries視窗中,選擇Add 按紐 

    2.在Add XML Catalog Entry 對話方塊中選擇或輸入以下內容: 
        Location: F:\soft\programmingSoft\Framework\Ibatis\sql-map-config-2.dtd 
        Key Type: URI 
        KEY: http://ibatis.apache.org/dtd/sql-map-config-2.dtd 


XSD 型別約束檔案 

    1. Window->Preferences->XML->XML Catalog->User Specified Entries視窗中,選擇Add 按紐 

    2.在Add XML Catalog Entry 對話方塊中選擇或輸入以下內容: 
        Location: F:\soft\programmingSoft\Framework\Spring\spring-framework-2.5.6.SEC01-with-dependencies\spring-framework-2.5.6.SEC01\dist\resources\spring-beans-2.5.xsd 

        Key Type: Schema Location 
        KEY: http://www.springframework.org/schema/beans/spring-beans-2.5.xsd