dtd

how to get doctype tag with url using xsl:output

Hi, i have added the below xsl:output tag in xslt <xsl:output method="html" indent="yes" encoding="utf-8" doctype-public="-//W3C//DTD HTML 4.0 Transitional//EN" ></xsl:output> as a result i get the below doctype tag in the html output- <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> how can i mention the url in the do...

XmlResolver Class' GetEntity function

I wrote a custom resolver class. It works OK for resolving SYSTEM DTDs, but not for resolving PUBLIC DTDs. When the class has to resolve PUBLIC DTDs instead of the URI of the resource, the function receives the public identifier through the absoluteUri parameter of the GetEntity function. Is there a solution to this. In examples: if I...

JAXB Unable To Handle Attribute with Colon (:) in name?

I am attempting to use JAXB to unmarshall an XML files whose schema is defined by a DTD (ugh!). The external provider of the DTD has specified one of the element attributes as xml:lang: <!ATTLIST langSet id ID #IMPLIED xml:lang CDATA #REQUIRED > This comes into the xjc-generated class (standard generation; no *.xjb magic) as: @XmlAt...

Path to XML DTD for DBUnit in multi-module Java/Maven project?

I have a multi-module maven project. Within the persist module I have a number of XML files data files that reference a DTD: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE myapp-data SYSTEM "myapp-data.dtd" > <dataset> .....omitted for brevity.... </dataset> The DTD is stored in the same directory with the XML files and even...

DTD required elements ordering

I want to have list of required elements in any order defined in dtd, but have no idea how I could do this. For example, I have following definition: <!ELEMENT parent (child1, child2, child3)> This dtd declaration will successfully validate following piece of xml: <parent> <child1></child1> <child2></child2> <child3></child...

Java How to prevent that an external library downloads a DTD file

I've created a program in java that starts as JNLP (Java WebStart). This program can connect to a webdav service at the server, the JNLP was started from. The first webdav request results in a security warning that some code tries to open a connection to w3.org. I'm using a external webdav client library which creates a document interna...

How can I add an (otherwise) invalid HTML element into TinyMCE.

My HTML contains elements like this, because it uses inlines from django-basic-apps. <inline type="myapp.mymodel" id="4" /> I'm trying to use tinymce to insert one of these into the DOM. On the frontend of the site, these are processed into good code. In tinyMCE I've added the config: extend_valid_elements: 'inline[id|ids|type|filte...

Reading and writing to an XML - DTD error

I have a program where it reads and writes XML using XMLReader and XMLWriter XmlWriter writer = XmlWriter.Create(fullpath, settings); //content... writer.Flush(); writer.Close(); and my reader code XmlReader reader = XmlReader.Create(fullpath); while (reader.Read()) { switch(reader.NodeType) {...

How to validate XML file against DTD/XMLSchema using lxml.etree.iterparse()

lxml easily validates XML files against any DTD or XMLSchema if only you're using etree.XML(). I need to do the same trick with etree.iterparse(), so that whole XML file won't be put into memory. There are two problems here: 1. DTD is ignored by iterparse (be it internal or external) 2. XML is validated against XMLSchema, but errors ...

DTDs show up in project target path in Eclipse but not when using via Maven command line.

I wasn't sure what the best title is so if anyone has a better suggestion, fire away. I'm not sure what information I should be providing, so I'll tell you what is happening. I have some unit tests that pass fine in Eclipse. In these tests, there's some XML that's being validated against a custom built DTD (a slightly modified Apelon D...

Production-ready DTD or XSD for describing restaurant menus?

My current problem could best be solved by an industry standard DTD or XSD describing restaurant menus. I don't think such an industry standard exists. I'm hoping at least one organization has already published such a DTD/XSD, even if it's only for their own proprietary use. My goals are to store a wide range of arbitrary restaurant me...

Is it possible to define a wildcard attribute in DTD?

Hi I am wondering if there is any chance to create a wildcard attribute list in xhtml. E.g. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [ <!ATTLIST a tooltip CDATA #IMPLIED> <!ATTLIST a tooltip-align (top|bottom|right|left) #IMPLIED> ]> ...

Load XML by SSIS - DTD is prohibited in this XML document error

Hi All, Hope you all are doing well. Previously I asked a question how to import a XML file to SQL Server thanks to all you responses. As my source file come with heavy amount of data, I am trying to load by SSIS. Below are the steps I followed: Imported XML by BulkLoad to a XML type column Created XSD Schema out of that XML file in...

Creating XML using C# and an external DTD

Hi there, This is my first steps with XML and I must send a XML by HttpRequest (Which is not a problem to me now). By I've a question about DTDs. According to the HttpRequest destination APIs, I must validate my XML using an External DTD whos located there (this is for Canada Post shipping : http://cybervente.postescanada.ca/DevelopersR...

How to get a DTD's public and system IDs with NSXMLParser

I'm trying to retrieve the public and system IDs for a DTD in an XML document via NSXMLParser. While NSXMLParser in principal offers publicID and systemID selectors they don't seem to work for me. The doctype tag looks like this: <!DOCTYPE Article PUBLIC "-//SoftQuad Software//DTD Journalist v2.0 20000501//EN" "file:///C:/Program%20File...

Firefox addon doesn't work when using % in menu label and tooltip.

I am working on a firefox addon, and when I use % for a menu label and tooltip the addon doesn't work (doesn't show up on firefox). I am using the % in a .dtd file like this: <!ENTITY addonName.menuX "%09 (Tab)"> And in the .xul file like this: <menuitem class="menuitem-iconic" image="chrome://addonName/skin/image.png" tooltiptext="...

DTD syntax for SQL UNIQUE constraint

Hi, I am moving from accessing data from database to xml for my application specific need. I am currently writing DTD for the xml by referring to my sql table schema. I have defined a constraint on 4 columns to be unique(These 4 columns defines a directory structure 3 step deep so together they have to be unique eg. dir1/dir2/dir3/dirA ...

Where can I find a copy of the wddx.dtd?

I have a project that involves parsing wddx webservice responses. The DOM DocumentBuilder is throwing an exception that the XML is malformed as it does not reference a dtd. I inserted a DOCTYPE statement and now it is throwing an exception malformed - cannot find the protocol. I am quite certain it is my reference to the DTD and I now...

I do not want to parse some tags in XML

Currently this would be a sample XML that I am working on: <smsq> <sms> <id>96</id> <to>03333560511</to> <msg> danial says: hahaha <space> nothing. </msg> </sms> </smsq> Now please notice, that the tag can contain other tags (which should not be parsed) and I had to make a dtd for that. The dtd was something like this: ...

Official XHTML 1.1 DTDs vs. official XHTML 1.1 XML Schemas

I have the option of validating XHTML 1.1 documents against the official XHTML 1.1 DTDs (I use the plural because the "main" DTD actually includes several others) or against the official XHTML 1.1 XML Schemas. Now I know that the XML Schema language is more expressive and powerful and can therefore check for more things. What I'm wonder...