Read the XML file with jdom

xiaoxiao2021-04-02  211

Two files student.xml, jdomxmlparse.jsp

1. When putting Student.xml in the CLASSES below Web-INF

Document read_doc = builder.build (this.getclass (). GetResourceAsStream ("/ student.xml")))

2. When putting Student.xml below Web-INF

Document read_doc = builder.build (this.getclass (). GetResourceAsStream ("/../ student.xml");

转载请注明原文地址:https://www.9cbs.com/read-131378.html

New Post(0)