. Updated Daily. Editions SDA India   SDA Indonesia
JAX Asia 2008 - Conference for Enterprise Java, SOA, Spring, Web Services, Ajax, Agile and more
BUSINESS ENTERPRISE SOLUTIONS ARCHITECTURE INFORMATION SECURITY WIRELESS & MOBILITY DATA & STORAGE DEVELOPMENT HARDWARE













News

Wednesday, 25 April 2007

Article: Learn to Validate XML Files within PHP4 Applications

 

 

Raphael Stolt while importing XML data against a DTD (Document Type Definition), discovered a solution to solve his problem of validating without using PHP4. PHP 4 wasn't supporting the Document Object Model (DOM) XML functions, so he didn’t favour it.

Instead he used Xmllint, a command line XML tool. This tool parses XML files and can be used to verify that the files are well formed and are working according to an associated DTD/XML Schema.

He demonstrates a method body, which shows an example call of the Xmllint tool for validating a given XML file against a DTD. The location of the DTD file is wrapped inside a DOCTYPE definition of the import file and will be automatically resolved by Xmllint.

He concludes by saying that Xmllint is helpful when writing custom DTDs or XML Schema, as you get an immediate reply regarding the correctness of the definition rules and their 'impact' on the associated XML files.

 

Read the Post

 
 
print save email comment

print

save

email

comment

 
 

Search SDA Asia

Free eNewsletter

SDA Asia Magazine Free Download
 
 
 
Copyright @ 2008 SDA Asia Magazine - All Right Reserved Privacy Policy | Terms of Use