How to disable XML´s DTD validation in Weblogic10?

Hello folks, we are trying to upgrade our server to Weblogic10, but it´s XML parser is validating XML´s DTD and ´cause we are behind a firewall we receive a error like:
Tried all: ´6´ address, but could not connect over HTTP to server: 'www.w3.org', port: '80'
Does anyone here known how to disable DTD validation in WL10?
Regards,
lottalava

Well you can create non validating parser programatically .
http://edocs.bea.com/wls/docs100/xml/programming.html#wp1069856
i.e.
SAXParserFactory spf = SAXParserFactory.newInstance();
spf.setValidating(false);
Hope this helps.

Similar Messages

  • How to disable xml validation

    I'm trying to write an SVG parser using Xerces. The problem is that when the SVG file contains the doctype tag <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">my program throws the following exception:
    java.net.UnknownHostException: www.w3.org
            at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
            at java.net.Socket.connect(Socket.java:507)
            at java.net.Socket.connect(Socket.java:457)
    etc.If I remove <!DOCTYPE> tag, it works fine. According to what I read here, it's necessary to disable XML validation. The Xerces API documentation says that there is a method setValidation() in org.apache.xerces.framework.XMLParser but I can't locate it. Moreover, I don't see any org.apache.xerces.framework package in Xerces supplied with NetBeans 5.0 nor in Xerces 2.8.0 downloaded from apache.org (the XMLParser class available to me is located in org.apache.xerces.parsers).
    My question is simple:
    How to disable XML validation if the setValidation() method is not avaliable
    OR
    how to make the setValidation method available to my program?
    I'm really confused :(
    Here is the code:
    package svgviewer;
    import java.io.File;
    import org.w3c.dom.*;
    import org.w3c.dom.traversal.*;
    import org.apache.xerces.parsers.*;
    public class SVGFileParser {
        public void parse(String filename) throws Exception {
            File file = new File(filename);
            DOMParser parser = new DOMParser();
            parser.parse(file.toURL().toString()); //exception is thrown if doctype tag is present in the svg file

    You're solving the wrong problem here. Turning off validation won't help, because DTDs don't only do validation. Even non-validating parsers have to read the DTD in case it contains entity definitions, for example.
    If you want to stop the parser from looking for the DTD then you write a EntityResolver and apply it to the parser. The EntityResolver should be just like the one in the example in the API docs except it should return new InputSource(new StringReader("")).

  • XML SAX dtd Validation Problem

    Hi,
              I’m having problems getting an xml document to validate within Weblogic 8.1. I am trying to parse a document that references both a dtd and xsd. Both the schema and dtd reference need to be substituted so they use local paths. I specify the schema the parser should use and have created an entityResolver to change the dtd reference.
              When this runs as a standalone app from eclipse the file parses and validates without a problem. When deployed to the app server the process seems to be unable read the contents of the dtd. Its not that it cannot find the file (no FileNotFoundException is thrown but this can be created if I delete the dtd) rather it seems to find no declared elements.
              Initial thought was that the code didn’t have access to read the dtd from its location on disk, to check I moved the dtd to within the deployed war and reference as a resource. The problem still persists.
              Code Snippet:
              boolean isValid = false;
              try {
              // Create and configure factory
              SAXParserFactory factory = SAXParserFactoryImpl.newInstance();
              factory.setValidating(true);
              factory.setNamespaceAware(true);
              // To be notified of validation errors in the XML document,
              // add a custom error handler to the document builder
              PIMSFeedFileValidationHandler handler
              = new PIMSFeedFileValidationHandler();
              // Create and Configure Parser
              SAXParser parser = factory.newSAXParser();
              parser.setProperty(JAXP_SCHEMA_LANGUAGE, W3C_XML_SCHEMA);
              parser.setProperty(NAMESPACE_PROPERTY_KEY, getSchemaFilePath());
              // Set reader with entityResolver for dtd
              XMLReader xmlReader = parser.getXMLReader();
              xmlReader.setEntityResolver(new SAXEntityResolver(this.dtdPath));
              // convert file to URL, as it is a remote file
              URL url = super.getFile().toURL();
              // Open an input stream and parse
              InputStream is = url.openStream();
              xmlReader.setErrorHandler(handler);
              xmlReader.parse(new InputSource(is));
              is.close();
              // get the result of parsing the document by checking the
              // errorhandler's isValid property
              isValid = handler.isValid();
              if (!isValid) {
              LOGGER.warn(handler.getMessage());
              LOGGER.debug("XML file is valid XML? " + isValid);
              } catch (ParserConfigurationException e) {
              LOGGER.error("Error parsing file", e);
              } catch (SAXException e) {
              LOGGER.error("Error parsing file", e);
              } catch (IOException e) {
              throw new FeedException(e);
              return isValid;
              See stack trace below for a little more info.
              2005-01-28 10:24:09,217 [DEBUG] [file] - Attempting validation of file 'cw501205.wa1.xml' with schema at 'C:/pims-feeds/hansard/schema/hansard-v1-9.xsd'
              2005-01-28 10:24:09,217 [DEBUG] [file] - Entity Resolver is using DTD path file:C:/Vignette/runtime_services/8.1/install/common/nodemanager/
              VgnVCMServer/stage/pims-hansard/pims-hansard.war/WEB-INF/classes/com/morse/pims/cms/feed/sax/ISO-Entities.dtd
              2005-01-28 10:24:09,227 [DEBUG] [file] - Creating InputSource at: file:C:/Vignette/runtime_services/8.1/install/common/nodemanager/VgnVCMServer/stage/pims-hansard/pims-hansard.war/WEB-INF/classes/com/morse/pims/cms/feed/sax/ISO-Entities.dtd
              2005-01-28 10:24:09,718 [WARN ] [file] - org.xml.sax.SAXParseException: Element type "Hansard" must be declared.
              org.xml.sax.SAXParseException: Element type "Session" must be declared.
              org.xml.sax.SAXParseException: Element type "DailyRecord" must be declared.
              org.xml.sax.SAXParseException: Element type "Volume" must be declared.
              org.xml.sax.SAXParseException: Element type "Written" must be declared.
              org.xml.sax.SAXParseException: Element type "WrittenHeading" must be declared.
              org.xml.sax.SAXParseException: Element type "Introduction" must be declared.
              … continues for all the elements in the doc
              2005-01-28 10:24:10,519 [DEBUG] [file] - XML file is valid XML? false
              2005-01-28 10:24:10,519 [WARN ] [file] - Daily Part file 'cw501205.wa1.xml' was not valid XML and was not processed.
              Has anybody seen this behavior before with weblogic and if so how have you resolved the issue.
              Thanks in Advance
              Adam

    It looks like you clicked on "Post" before you got around to explaining your problem. I don't see any error messages or any description of what was supposed to happen and what happened instead.
    Now, I don't know anything about XML Schema, but just guessing at how that unique name feature might be designed, and just guessing that your unique name is actually in the <userId> element, I would suggest that this:
    <xsd:unique name="un_name"> 
      <xsd:selector xpath="USER"/> 
      <xsd:field xpath="."/> 
    </xsd:unique> is at fault because it doesn't mention the <userId> element anywhere.

  • JDev 9.0.3_2: web.xml fails DTD validation

    Hi all,
    I just started using JDev 9.0.3_2 and found that it is trying to validate my web.xml when I build my Project.
    It is complaining about the <distributable> Tag inside my web.xml file. It should NOT be complaining about this, but it is obviously using either an outdated DTD or the wrong one.
    How can I either point JDev at the correct DTD or get it to stop attemting to validate web.xml?
    Thanks!
    Kevin Dougan

    I think I have figured out a workaround: It appears that JDeveloper is extremely picking about web.xml and validates it in a strict sense. You MUST put your elements in EXACTLY the same order as specified in the DTD, or it throws an error.
    However, that doesn't answer my original question: Is there a way to specify the DTD for web.xml (or other elements for that matter, Schema's aside for the moment) or at least turn off this form of validation? If not in the current release, is this coming in 9.0.4 or 9.0.5?
    Thanks again,
    Kevin

  • How to filter xml using dtd and create a new xml document

    Good morning my name is Antonio and I'm an italian programmer.
    I need an help about the follow question.
    I want to filter the contents of a XML document using a DTD to allow
    only the valid elements and attributes as specified in the DTD to be
    passed through to the output, any data that does not conform to the DTD
    should be filtered out.
    To resolve this problem there's XML Translator Generator (XTransGen): http://www.alphaworks.ibm.com/tech/xmltranslatorgenerator
    but at moment it's not avaiable.
    Can you help me?
    Many thanks.
    ciao
    Antonio

    ...

  • Oracle Service Bus business service - How to disable XML content check.

    Hi All,
    Dear Experts I have the necessity to disable the check on the XML content when message is forwarded to external system by on Oracle Service Bus Business Service to avoid that the XML content as string that I inserted in message is wrapped with the CDATA[[.
    Thanks a lot,
    Mike

    There is no explicit option to disable the check on the XML content.
    But the you can use Messaging Service of type Text request which will consider the data as string and so there will be no check.
    If you want to use WSDL/AnyXML/AnySOAP proxies, the XML check is always carried when the $body varaible is not checked/modified when content streaming is enabled while creating the proxy. I'm quite sure HTTP transport supports content streaming and the stream from the input is directly given to BS with out realizing the XML. Only short coming is it should be a pure pass through and no data enrichment and any action in pipeline that requires realizing the XML from the stream.
    Let me know if this helps.
    Thanks
    Manoj

  • HOW TO KNOW VALID XML WITH DTD ? WITHOUT PARSING  ?

    i am creating the xml file
    i need to validate the xml with DTD to confirm is it valid or not ?
    with out parsing...
    could you tell me how ?
    Durga

    without parsing u cant do it..

  • How to parse XML against XSD,DTD, etc.. locally (no internet connection) ?

    i've searched on how to parse xml against xsd,dtd,etc.. without the needs of internet connection..
    but unfortunately, only the xsd file can be set locally and still there needs the internet connection for the other features, properties.
    XML: GML file input from gui
    XSD: input from gui
    javax.xml
    package demo;
    import java.io.File;
    import java.io.IOException;
    import java.net.MalformedURLException;
    import java.net.URL;
    import javax.xml.XMLConstants;
    import javax.xml.transform.Source;
    import javax.xml.transform.stream.StreamSource;
    import javax.xml.validation.Schema;
    import javax.xml.validation.SchemaFactory;
    import javax.xml.validation.Validator;
    import org.xml.sax.SAXException;
    public class Sample1WithJavaxXML {
         public static void main(String[] args) {
              URL schemaFile = null;
              try {
                   //schemaFile = new URL("http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd");
                   File file0 = new File("AppSchema-C01-v1_0.xsd");
                   schemaFile = new URL(file0.toURI().toString());
              } catch (MalformedURLException e1) {
                   // TODO Auto-generated catch block
                   e1.printStackTrace();
              //Source xmlFile = new StreamSource(new File("web.xml"));
              Source xmlFile = new StreamSource(new File("C01.xml"));
              SchemaFactory schemaFactory = SchemaFactory
                  .newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
              //File file1 = new File("XMLSchema.dtd");
              //SchemaFactory schemaFactory = SchemaFactory
                   //.newInstance("javax.xml.validation.SchemaFactory:XMLSchema.dtd");
              Schema schema = null;
              try {
                   schema = schemaFactory.newSchema(schemaFile);
              } catch (SAXException e1) {
                   // TODO Auto-generated catch block
                   e1.printStackTrace();
              Validator validator = schema.newValidator();
              try {
                validator.validate(xmlFile);
                System.out.println(xmlFile.getSystemId() + " is valid");
              } catch (SAXException e) {
                System.out.println(xmlFile.getSystemId() + " is NOT valid");
                System.out.println("Reason: " + e.getLocalizedMessage());
              } catch (IOException e) {
                   // TODO Auto-generated catch block
                   e.printStackTrace();
    }Xerces
    package demo;
    import java.io.File;
    import java.util.Date;
    import org.apache.xerces.parsers.DOMParser;
    public class SchemaTest {
         private String xmlFile = "";
         private String xsdFile = "";
         public SchemaTest(String xmlFile, String xsdFile) {
              this.xmlFile = xmlFile;
              this.xsdFile = xsdFile;
         public static void main (String args[]) {
              File file0 = new File("AppSchema-C01-v1_0.xsd");
              String xsd = file0.toURI().toString();
              SchemaTest testXml = new SchemaTest("C01.xml",xsd);
              testXml.process();
         public void process() {
              File docFile = new File(xmlFile);
              DOMParser parser = new DOMParser();
              try {
                   parser.setFeature("http://xml.org/sax/features/validation", true);
                   parser.setFeature("http://apache.org/xml/features/validation/schema", true);
                   parser.setProperty("http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation",
                             xsdFile);
                   ErrorChecker errors = new ErrorChecker();
                   parser.setErrorHandler(errors);
                   System.out.println(new Date().toString() + " START");
                   parser.parse(docFile.toString());
              } catch (Exception e) {
                   System.out.print("Problem parsing the file.");
                   System.out.println("Error: " + e);
                   System.out.println(new Date().toString() + " ERROR");
                   return;
              System.out.println(new Date().toString() + " END");
    }

    Thanks a lot Sir DrClap..
    I tried to use and implement the org.w3c.dom.ls.LSResourceResolver Interface which is based on the SAX2 EntityResolver.
    please give comments the way I implement it. Here's the code:
    LSResourceResolver Implementation
    import org.w3c.dom.ls.LSInput;
    import org.w3c.dom.ls.LSResourceResolver;
    import abc.xml.XsdConstant.Path.DTD;
    import abc.xml.XsdConstant.Path.XSD;
    public class LSResourceResolverImpl implements LSResourceResolver {
         public LSResourceResolverImpl() {
          * {@inheritDoc}
         @Override
         public LSInput resolveResource(String type, String namespaceURI, String publicId, String systemId, String baseURI) {
              ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
              LSInput input = new LSInputImpl(publicId, systemId, baseURI);
              if ("http://www.w3.org/2001/xml.xsd".equals(systemId)) {
                   input.setByteStream(classLoader.getResourceAsStream(XSD.XML));
              } else if (XsdConstant.PUBLIC_ID_XMLSCHEMA.equals(publicId)) {
                   input.setByteStream(classLoader.getResourceAsStream(DTD.XML_SCHEMA));
              } else if (XsdConstant.PUBLIC_ID_DATATYPES.equals(publicId)) {
                   input.setByteStream(classLoader.getResourceAsStream(DTD.DATATYPES));
              return input;
    }I also implement org.w3c.dom.ls.LSInput
    import java.io.InputStream;
    import java.io.Reader;
    import org.w3c.dom.ls.LSInput;
    public class LSInputImpl implements LSInput {
         private String publicId;
         private String systemId;
         private String baseURI;
         private InputStream byteStream;
         private String stringData;
         public LSInputImpl(String publicId, String systemId, String baseURI) {
              super();
              this.publicId = publicId;
              this.systemId = systemId;
              this.baseURI = baseURI;
         //getters & setters
    }Then, here's the usage/application:
    I create XMLChecker class (SchemaFactory implementation is Xerces)
    import java.io.File;
    import java.io.IOException;
    import java.util.ArrayList;
    import java.util.List;
    import javax.xml.XMLConstants;
    import javax.xml.stream.FactoryConfigurationError;
    import javax.xml.transform.Source;
    import javax.xml.transform.stream.StreamSource;
    import javax.xml.validation.Schema;
    import javax.xml.validation.SchemaFactory;
    import javax.xml.validation.Validator;
    import org.xml.sax.ErrorHandler;
    import org.xml.sax.SAXException;
    import org.xml.sax.SAXParseException;
    import abc.xml.XsdConstant.Path.XSD;
    public class XMLChecker {
         private ErrorMessage errorMessage = new ErrorMessage();
         public boolean validate(String filePath){
              final ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
              List<Source> schemas = new ArrayList<Source>();
              schemas.add(new StreamSource(classLoader.getResourceAsStream(XSD.XML_SCHEMA)));
              schemas.add(new StreamSource(classLoader.getResourceAsStream(XSD.XLINKS)));
              schemas.add(new StreamSource(classLoader.getResourceAsStream("abc/xml/AppSchema.xsd")));
              SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI);
              schemaFactory.setResourceResolver(new LSResourceResolverImpl());
              try {
                   Schema schema = schemaFactory.newSchema(schemas.toArray(new Source[schemas.size()]));
                   Validator validator = schema.newValidator();
                   validator.setErrorHandler(new ErrorHandler() {
                        @Override
                        public void error(SAXParseException e) throws SAXException {
                             errorMessage.setErrorMessage(e.getMessage());
                             errorMessage.setLineNumber(e.getLineNumber());
                             errorMessage.setColumnNumber(e.getLineNumber());
                             throw e;
                        @Override
                        public void fatalError(SAXParseException e) throws SAXException {
                             errorMessage.setErrorMessage(e.getMessage());
                             errorMessage.setLineNumber(e.getLineNumber());
                             errorMessage.setColumnNumber(e.getLineNumber());
                             throw e;
                        @Override
                        public void warning(SAXParseException e) throws SAXException {
                             errorMessage.setErrorMessage(e.getMessage());
                             errorMessage.setLineNumber(e.getLineNumber());
                             errorMessage.setColumnNumber(e.getLineNumber());
                             throw e;
                   StreamSource source = new StreamSource(new File(filePath));
                   validator.validate(source);
              } catch (SAXParseException e) {
                   return false;
              } catch (SAXException e) {
                   errorMessage.setErrorMessage(e.getMessage());
                   return false;
              } catch (FactoryConfigurationError e) {
                   errorMessage.setErrorMessage(e.getMessage());
                   return false;
              } catch (IOException e) {
                   errorMessage.setErrorMessage(e.getMessage());
                   return false;
              return true;
         public ErrorMessage getErrorMessage() {
              return errorMessage;
    }Edited by: erossy on Aug 31, 2010 1:56 AM

  • DOM Parser Configuration...how to switch off DTD validation?

    Hi all,
    I am developing some implementation code in Java using JBuilder2005, in which DOM3 parser is also being utilised. Now the question is how to switch off DTD validation (seems its default mode is 'on') so that no validation will be carried out at all even DTD declaration statement is presented in an input XML document?
    Many thanks in advance
    Frank

    First of all, thank you so much for responding, DrClap. =)
    setValidating(false) of the DocumentBuilderFactory instance, factory, does not work as expected; it still stubbornly try to seek the external DTD file and fires 'IOException' error in case of no such a DTD.
    To follow up the EntityResolver approach, I searched online for almost the whole afternoon but still could not figure out how to do it exactly. In particular, I found http://www.jdom.org/docs/faq.html#a0350, which tells a way doing it, but I got 'StringBufferInputStream is deprecated' error. Then I changed to
    new InputStream(new ByteArrayInputStream("".getBytes()))adapted from http://forum.java.sun.com/thread.jspa?threadID=572919&messageID=2842185. But another error occurs: 'java.io.InputStream is abstract; cannot be instantiated'. Furthermore, I have looked at many docs(tutorials, APIs...) on parser configuration, usage of EntityResolver/setEntityResolver()...but they turned out not helpful. Could you please give out more details on how to do this using EntityResolver?? Many many thanks...

  • Regarding validating XML against DTD

    hello,
    In my project I am receiving xml via HTTP post request
    and this XML needs to be validated against a DTD in a remote server.
    e.g. assume the xml to be
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE PUSH SYSTEM "http:\\whatever:xx\whatever\sms.dtd">
    <PUSH ICP="Partenaire" ADM="UtilisateurChezPartenaire" VERSION="1.0">
    </PUSH>
    the java code uses Xerces parser
          DOMParser parser = new DOMParser();
          parser.setFeature("http://xml.org/sax/features/validation", true);
          parser.setProperty(
                             "http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation",
                             "http:\\whatever:xx\whatever\sms.dtd"");
          parser.parse("c://localcopy/sms.xml");this Works fine.
    But in some case I receive xml file without any !DOCTYPE declaration
    (but is still needs to be validated against the same DTD as its mentioned in the business rules)
    in such case how can the XML be validated against the DTD.
    am I extected to add the
    <!DOCTYPE PUSH SYSTEM "http:\\whatever:xx\whatever\sms.dtd">
    to every XML via some XSLT script or is there a direct way of
    validating a xml that has no DOCTYPE reference to a DTD
    (the assumption is the DTD location is known beforehand)

    ok, i managed to solve the problem my self, using Transformer makes the job easier.
    here is the code for anyone who might run into the same problem.#
         public void whatEver(){
              try{
                   DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance();
                   DocumentBuilder dBuilder = dbFactory.newDocumentBuilder();
                   Document xmlDocument = dBuilder.parse(new FileInputStream("c://a.xml"));
                   DOMSource source = new DOMSource(xmlDocument);
                   //StringWriter writer = new StringWriter();
                   StreamResult result = new StreamResult("c://a.xml");
                   TransformerFactory tf = TransformerFactory.newInstance();
                   Transformer transformer = tf.newTransformer();
                   transformer.setOutputProperty(OutputKeys.DOCTYPE_SYSTEM, "./transformations/Push_Gateway.dtd");
                   //TransformerFactory transformerFactory = TransformerFactory.newInstance();
                   //Transformer newtransformer = transformerFactory.newTransformer();
                   transformer.transform(source, result);
              catch(Exception e){
                   e.printStackTrace();
         }the above code reads the a.xml file and adds/removes the DOCTYPE as specified in the transformer.setOutputProperty method and the same xml file is updated, this way different DTD could be referenced by the same xml and validated. this saves the process of adding/removing DOCTYPE via xslt.

  • Disabling dtd validation

    I know it sounds odd.. but I need my appserver to run offline. basically I am creating a stand alone server and application installation that one of our marketing guys can take on the road on a laptop and demo to people where there is no internet.
    you know.. localhost style ;-)
    One problem.. when there is no internet, DTD validation for sun and oracle wesite DTDs all fail. Removing all dtd references or making them local would take as long as it would take me to write a script to do it... I am hoping there is just a setting in the application server that I can set to disable dtd validation. The whole app is done being developed.. I don't need my xml validated anymore! I need to be able to run without the intarwebnets!
    please help!

    Haven't worked with this but possibly this method of "deactivation" is not valid in 11gR2? Have you cross checked that with Oracle support?

  • Validating an xml with DTD external DTD

    Hi
    how can i validate my XML File with an external DTD ?
    thanks for your replies
    serge

    Hi,
    when you use the XML Library, the interface <b>if_ixml_parser</b> has a static method <b>set_validation( )</b> to activate and deactivate a DTD validation.
    There are the follow constants in the if_ixml_parser for the DTD validation-mode:
    <b>if_ixml_parser=>co_no_validation</b>
    Do not validate the XML-Document against the document type definition (DTD)
    <b>if_ixml_parser=>co_validate</b>
    Validate the XML-Document against the document type definition (DTD)
    <b>if_ixml_parser=>co_validate_if_dtd</b>
    Validate the XML-Document against the document type definition (DTD) if a DTD is specified. Otherwise parse the Document in non validating mode.
    see also the SAP online-help:
    <a href="http://help.sap.com/saphelp_webas610/helpdata/de/bb/5766b2dca511d4990b00508b6b8b11/content.htm">Interface if_ixml_parser</a>
    Regards
    Stefan

  • How to use the validation.xml in struts validation?

    Can any one please help me, how to use the validation.xml in struts validation? possible please give me simple example.
    Edited by: SathishkumarAyyavoo on Jan 31, 2009 12:03 PM

    These 2 are the good articles for the beginners to do validation things in Struts. you can follow any one of them.
    1. [http://viralpatel.net/blogs/2009/01/struts-validation-framework-tutorial-example-validator-struts-validation-form-validation.html]
    2. [http://www.vaannila.com/struts/struts-example/struts-custom-validation-example-1.html]
    All the best.

  • Ejb-jar.xml DTD validation error?

    I am attempting to deploy a JAR on App Server 8 PE. The application does not contain any EJBs but I understand that the ejb-jar.xml descriptor is still needed. I am running the app server on Windows XP.
    My issue is as follows:
    I understand that the root element for the ejb-jar.xml file (<ejb-jar>) is required. Since I have no EJBs, I should be able to leave this root element blank (as I have in previoius successful deployments to earlier versions of Sun App Server). When I attempt to deploy, I receive the following DTD Validation error via the admin console:
    The content of element type "ejb-jar" is incomplete, it must match "(description?,display-name?,small-icon?,large-icon?,enterprise-beans,relationships?,assembly-descriptor?,ejb-client-jar?)".
    Am I missing something?
    My ejb-jar.xml file looks like:
    <!DOCTYPE ejb-jar PUBLIC
         "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
         "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    </ejb-jar>
    Many thanks in advance to any assistance...

    I am attempting to deploy a JAR on App Server 8 PE.
    The application does not contain any EJBs but I
    I understand that the ejb-jar.xml descriptor is still
    needed. I am running the app server on Windows XP.
    My issue is as follows:
    I understand that the root element for the
    ejb-jar.xml file (<ejb-jar>) is required. Since I
    have no EJBs, I should be able to leave this root
    element blank (as I have in previoius successful
    deployments to earlier versions of Sun App Server).
    When I attempt to deploy, I receive the following
    g DTD Validation error via the admin console:
    The content of element type "ejb-jar" is incomplete,
    it must match
    "(description?,display-name?,small-icon?,large-icon?,e
    nterprise-beans,relationships?,assembly-descriptor?,ej
    b-client-jar?)".
    Am I missing something?
    My ejb-jar.xml file looks like:
    <!DOCTYPE ejb-jar PUBLIC
    "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans
    s 2.0//EN"
         "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
    <ejb-jar>
    </ejb-jar>
    Many thanks in advance to any assistance...I hav tried this and it is working
    <?xml version="1.0" encoding="UTF-8" ?>
    <ejb-jar
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
    http://java.sun.com/xml/ns/j2ee/ejb-jar_2_1.xsd"
    version="2.1">

  • Validating xml with dtd

    Hi,
             I have found a piece of code through google, to validate an xml file with an external dtd file. which is
               function validateDocument()
                    xmlDocumentObject = new ActiveXObject("microsoft.XMLDOM")
                    xmlDocumentObject.onreadystatechange = changeHandler
                    xmlDocumentObject.load('C:\\My.xml')
                function changeHandler()
               and for that we need to a import i.e  #import "C:\WINDOWS\system32\msxml4.dll"
              here when i try to import "msxml4.dll" in Acrobat javascript (js) file, it is giving error, application exits.
               How can i import dll in Acrobat javascript to get some functionality, or if not
              What someother way to achieve this(To validate xml with dtd file).
             This is totally making me crazy, please someone help me on this issue.
    thanks in advance.

    thanks Leonard,
             But my problem is i have an xml(i created that using acrobat javascript)and a dtd file, i want validate xml file with that dtd, using acrobat or some other way.  How can i validate xml with dtd, please help me.

Maybe you are looking for

  • 2-way file upload/download b/w client/server

    I need help for a good design strategy for 2-way file upload/download betweeen client and server. I have to upload a set of files to the server (which is a servlet) and again the servlet downloads another set of files to the client (which is an apple

  • Can I load JPG, PDF documents into the Document section of iCloud

    I am concerned about the Document section of Icloud. I used Idisk for storing documents to readily have accessible. It appears that I can only store Iwork, Inumbers, Keynote files that are made from Apple's applications. That doesnt seem really custo

  • WinXP Ok vs Win2000 Bad character mode report

    Hello, We have a character mode report designed and running in a Windows XP machine. To make it work was necessary to create a custom PRT file that contains the condensed and non condensed codes used by the report. After some tries it is running ok.

  • WL NT service Troubles.

    WL runing as NT service version 6.1 The problem is that while its runing as NT service , the behavior is uncertian and the request to weblogic time out (thru ISAPI)and if I hit directly on port 7001 I get error 500.I see some javac consoles popping u

  • How is goods receipt and invoice sent from backend system to SRM system?

    Hi friends How is goods receipt and invoice sent from backend system to SRM system? Thanks regards Krishna