PHP
Chilkat2 PHP
Load XML from Local FilePath
Demonstrates how to load XML from a local XML file.Chilkat PHP Downloads
<?php
use Chilkat2\Xml;
$xml = new Xml();
// Pass either an absolute file path, or a file path relative from the current working directory of the caller.
try {
$xml->LoadXmlFile('qa_data/hamlet.xml');
} catch (\Chilkat2\Exception $e) {
echo $e->getMessage(), "\n";
exit;
}
echo "Success.\n";