Your doctype doesn't include a public ID (that's not the same thing as the root element). Try <dtd systemid="http://cobertura.sourceforge.net/xml/coverage-04.dtd" location=...
Andy. On 6 Feb 2012 08:17, "Soni, Ashish IN BLR SISL" <ashish.s...@siemens.com> wrote: > ** ** ** ** ** ** ** > > I tried with below file but still it is checking for network connection.** > ** > > ** ** > > <project basedir="." name="hazard" default="TransformFile">**** > > <property name="in.xml" value="coverage.xml"/>**** > > <property name="out.file" value="hazardSource.html"/>**** > > <property name="xslt.file" value="Convert.xslt"/>**** > > <property name="sources" value="V:/ic010375_nt_vb36b/sdm/src/j_mods" > />**** > > ** ** > > <target name="TransformFile">**** > > <!-- Transform one file into an HTML file -->**** > > <xslt in="${in.xml}" out="${out.file}"**** > > style="${xslt.file}">**** > > *<xmlcatalog>*** > > * **<dtd** **publicid=**"coverage"** **location=** > "${basedir}/coverage-04.dtd"**/>*** > > * **</xmlcatalog>*** > > </xslt>**** > > </target>**** > > </project>**** > > ** ** > > DTD entry in coverage.xml is**** > > *<!DOCTYPE coverage SYSTEM " > http://cobertura.sourceforge.net/xml/coverage-04.dtd">* > > * * > > *Note: *I created empty file in basedir with name *coverage-04.dtd***** > > ** ** > > ----------------------------------------------------------------**** > > With best regards,**** > > Ashish Soni**** > > **** > > Siemens Information Systems Ltd. **** > > Corporate Technology**** > > Corporate Development Center India**** > > Healthcare 1**** > > PACS**** > > **** > > No 84, Keonics Electronics City,**** > > Hosur Road, Bangalore 560100**** > > Tel.: +91 80 2511 3353**** > > mailto.: ashish.s...@siemens.com**** > > www.siemens.co.in**** > ------------------------------ > > *From:* Andy Stevens [mailto:insomniacpeng...@googlemail.com] > *Sent:* Monday, February 06, 2012 1:29 PM > *To:* Ant Users List > *Cc:* Soni, Ashish IN BLR SISL > *Subject:* Re: Disable DTD validation**** > > ** ** > > You need to supply a catalog entry to map the system uri to a local copy. > Can't remember the details offhand, but I'm pretty sure the task's > configuration allows for this. Or it might be a separate xml catalog task. > Check the docs.**** > > Andy**** > > On 6 Feb 2012 05:41, "Soni, Ashish IN BLR SISL" <ashish.s...@siemens.com> > wrote:**** > > Hello all! > > I have a XML document with <DOCTYPE> section: <!DOCTYPE coverage SYSTEM " > http://cobertura.sourceforge.net/xml/coverage-04.dtd"> (XML coverage > report of cobertura) > > When I try process this document with <xslt> task, it fails with > ConnectException. How can I prevent XSLT processor from validating of XML > document? Or may be from loading external DTDs. > > I check old post they are taking about xmlcatalog, but in above dtd we > don't have publicid. > > Any help is appreciated! > > ---------------------------------------------------------------- > With best regards, > Ashish Soni > > Siemens Information Systems Ltd. > Corporate Technology > Corporate ****Development Center** **India**** > Healthcare 1 > PACS > > No 84, ****Keonics** **Electronics** **City****, > ****Hosur Road**, **Bangalore**** 560100 > Tel.: +91 80 2511 3353 <%2B91%2080%202511%203353> > mailto.: ashish.s...@siemens.com<mailto:ashish.s...@siemens.com> > www.siemens.co.in<http://www.siemens.co.in>**** >