OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   saving xml file into local disk using jsp

[ Lists Home | Date Index | Thread Index ]
  • To: xml-dev <xml-dev@lists.xml.org>
  • Subject: saving xml file into local disk using jsp
  • From: Seetha Rama Krishna <ram_kurra@yahoo.co.in>
  • Date: Mon, 5 Jun 2006 16:41:07 +0100 (BST)
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.co.in; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=R7F1TlWryeYIjvsnOSlsFyBGdusaelClYNMHxhQcXoHYJMgeK4YRlPWnA78yBysEMe5ZzaALZrTvHw8dEK6FUBksc+LjNEmB6/Ea+2C+n3Xt4l0vJPSvVSq4kK/twUkQIfOBFKxFZKJlHAWsa1cQtSbLx5lUs+0lvR5ccQtfT50= ;

Hi Techies,
           I am creating the xml file from jsp and  generation of xml is working fine for me.
       Now the  query is    How can I point out the location of local machine??
   Here is my code

String locationAndBackupFileName =request.getParameter("locationAndNameOfBackupFile");
System.out.println("Location"+locationAndBackupFileName);
StringWriter stringOut = new StringWriter();
XMLSerializer serial = new XMLSerializer(stringOut, new OutputFormat("xml", "UTF-8", true));
response.setContentType("application/xml");
response.setHeader("Content-Disposition","attachement; filename="+locationAndBackupFileName);
serial.setOutputCharStream(new FileWriter(locationAndBackupFileName));

serial.serialize(document.getDocumentElement());
when I xcute my code I am getting download dialog box, with save option.
    But after downloading no data is available.
   Can u guys help me to fix this problem




regards,
ramu

Send instant messages to your online friends http://in.messenger.yahoo.com

Stay connected with your friends even when away from PC. Link: http://in.mobile.yahoo.com/new/messenger/





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS