Hi all

I am trying to do a simple string match using jsp or servlet. The problem
arises when my servlet or jsp is unable to locate the XML file that is parsed
and then the string match is done. I get an error message as follows :

Error: 500
Location: /examples/servlet/students1
Internal Servlet Error:
java.io.FileNotFoundException: http://24.181.167.18:8080/students.xml (The
system cannot find the path specified)        at
java.io.FileInputStream.open(Native Method)

I have a method in the servlet class that tries to get a parse an XML file.
The code for the parsing is as follows:

String uri = "http://24.181.167.18:8080/students.xml";
Parser ps = new Parser(uri);
InputStream is = new FileInputStream(uri);
Document document = ps.readStream(is);
is.close();

I assume that here the error occurs. I have the entire code online (in a
different folder too) if you want to help me. You can look at it at
http://24.181.167.18/kalyan/students1.java and the xml file students.xml is in
the same directory.

I would really appreciate it if some one could help me fix the bug!

Thanks,
Kalyan



____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to