View Full Version : PHP and XML

03-04-2003, 12:19 AM
Recently, I have been really getting into the whole XML and I love it all. Now I'm running into some problems that I know should be possible, but don't know what to do.

I have three files: test.xml, test.xsd and test.php

test.xml contains all the XML, duh, hehe.
test.xsd contains the schema for test.xml.
test.php will be the PHP script that will parse the test.xml file.

Is it possible to have PHP validate against the schema while it is parsing. I was told that the Expat library that PHP uses to parse the XML doesn't support schemas. I know it will work with DTDs but I prefer to work with schemas. I don't know what to do to get it work. Does anyone have any ideas on how this can be done? Thanks.