Re: [PHP-XML-DEV] DTD being ignored?

[email protected] (Joshua Ruppert)
Newsgroups php.xml.dev
Message-ID <[email protected]>
Is there any talk of supporting other parsers that would validate?

Josh

Christian Stocker wrote:

>HI
>
>It's not a validiating parsers (I assume you speak of ext/xml and expat),
>so it really doesn't care about DTDs
>
>Furthermore, this list is about the developement of xml-support in php,
>not about using xml in php. [email protected] is the more aproriate
>list for such questions
>
>chregu
>
>On Sat, 7 Jun 2003, Joshua Ruppert wrote:
>
>  
>
>>I set up a dtd but the xml parser seems to be ignored. I have fields
>>that are set to be required and others that are set to be straight
>>character data (CDATA). If I remove the required field the the parse
>>should fail, but doesn't. Also, the parser is trying to parse the cdata
>>fields. I know this because if I create the xml with <![CDATA[my
>>data]]>, instead of relying on the dtd, the fields go through just fine.
>>
>>My DTD looks like this:
>><!DOCTYPE webSync [
>>
>><!ELEMENT webSync (transaction+)>
>><!ATTLIST webSync syncID CDATA #REQUIRED>
>><!ATTLIST webSync nbTrans CDATA>
>>
>><!ELEMENT transaction (syncItem, tname, compID?, actionCD, data?, pk?)>
>><!ELEMENT syncItem (#CDATA)>
>><!ELEMENT tnam     (#CDATA)>
>><!ELEMENT compID   (#CDATA)>
>><!ELEMENT actionCD (#CDATA)>
>><!ELEMENT data     (#CDATA)>
>><!ELEMENT pk       (#CDATA)>
>>
>>]>
>>
>>The opening of my xml looks like this:
>><?xml version="1.0" encoding="iso-8859-1"?>
>><!DOCTYPE webSync PUBLIC "-//Bene-Care Inc//Website syncronization//EN"
>>"http://192.168.100.5/dtd/webSync.dtd">
>>
>>Am I doing something wrong here?
>>
>>Josh
>>
>>
>>
>>    
>>
>
>  
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.