This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
I just want to read a xml file located in the same path of my servlet... I�d like to use a relative path to find and open the file... I�ve tried like this: --- SimpleServlet.java --- SAXBuilder b = new SAXBuilder("org.apache.xerces.parsers.SAXParser"); Document configXml = b.build(SimpleServlet.class.getResourceAsStream("/config.xml")); --- it returned an error: --- org.jdom.JDOMException: Error on line 0: File "" not found. --- please help me!
Joined: Mar 15, 2002
ops, sorry... actually the xml file is located at app dir (the jsp and html file directory)... how can I found the xml file in that directory?