Hi All,

I am just wondering if any of you have any neat ideas about validating a newly constructed DOM before writing it to a file.

Basically I wish to :

   -create the DOM tree complete with data in the elements
   -validate this using an XSD specific to the document
   -write the XML to a file/buffer

The first and last items I have working fine, but the validation of the document before writing is proving sligthly elusive for the moment.

There is validation of the data before it is entered into the DOM, but I would like to validate it against the XSD as an added measure, and without having the expense of re-parsing the serialised DOM if possible.

I don't see anything obvious, in the DOMDocument class at least.

Many thanks in advance for any pointers etc,

Kind Regards

Dara


Reply via email to