how to call any data from .xml to servlet??????????

User jdom for that.

import org.jdom.*;
import java.io.*;
class parseXml {
public static void main(String args[]) {
Saxbuilder build = new SaxBuilder();

Document doc =build.build(new File("youxml")) ;

String value = (Element)XPath.selectSingleNode(doc,"yournodepath").getValue();

}

}

please i am not understood.Please tell me with tomcat server........

You can parse the xml inside your service method of servlet.I have only given you a templet to parse a xml using java.

thank u madam........

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.