HELP Me : Throwing XML page through Servlet
Om Band
om at lgsi.co.in
Tue Mar 30 10:34:07 BST 1999
Hi,
Kan U Help Mi Please ?
I am developing a search engine which will have a XML
search form linked with a Servlet. The Servlet should take input
from the textfield of the XML form, scan the database for matches &
generate an XML page with the results found.(Dynamically) !
Ideally it should not make a file of that XML but should throw
it directly to the client m/c. In this case I am not able to link it
with the already created XSL stylesheet which will already be
on the server (Static).
Even with making a separate XML file I am not able to display
the XML page through Servlet, though directly it could be displayed
with the same address typed in Address field of the browser !!
The code I am using for Servlet is............
(This makes a separate file)
doPost(HttpServletRequest, HttpServletResponse response)
{-------
--------
String file = "c:\\xml\\file.xml";
fw = new FileWriter(file);
pw = new PrintWriter(fw);
pw.println("<?xml version=.....--------"); // Making
an
pw.println("-------------------------"); // XML
file.
---------------------------------------------
response.sendRedirect(file);
}
This code gives an error : xsl not found.
(Which is there in the same dir)
Alse How can I do this without making a separate .xml file ?
THANKS !!
-Om
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ic.ac.uk/pipermail/xml-dev/attachments/19990330/63a9fbe6/attachment.htm
More information about the Xml-dev
mailing list