<?php
$xmlString=<<<XML
<?xml version="1.0" encoding="ISO-8859-1"?>
<Processrere>
<ProcessDispositionDocumentResponses>
<ProcessDispositionDocumentResponse>
<ns0:Rsere> SCANNER.TIF302.42.236</ns0:Rsere>
<ns0:Doser>1545421</ns0:Doser>
<ns0:Caseser>130803</ns0:Caseser>
</ns0:ProcessDispositionDocumentResponse>
</ns0:ProcessDispositionDocumentResponses></ns0:Processrere>
XML;
$modifiedData = str_replace("ns0:", "", $xmlString);
$xml = simplexml_load_string($xmlString1);
$xml = simplexml_load_string($modifiedData);
//echo $xml->getName() . "<br />";
foreach($xml->children()->children()->children() as $child)
{
if ($child->getName() ==="CaseNumber"){
$caseNumber=$child;
}
}
echo $caseNumber;
$xmlString=<<<XML
<?xml version="1.0" encoding="ISO-8859-1"?>
<Processrere>
<ProcessDispositionDocumentResponses>
<ProcessDispositionDocumentResponse>
<ns0:Rsere> SCANNER.TIF302.42.236</ns0:Rsere>
<ns0:Doser>1545421</ns0:Doser>
<ns0:Caseser>130803</ns0:Caseser>
</ns0:ProcessDispositionDocumentResponse>
</ns0:ProcessDispositionDocumentResponses></ns0:Processrere>
XML;
$modifiedData = str_replace("ns0:", "", $xmlString);
$xml = simplexml_load_string($xmlString1);
$xml = simplexml_load_string($modifiedData);
//echo $xml->getName() . "<br />";
foreach($xml->children()->children()->children() as $child)
{
if ($child->getName() ==="CaseNumber"){
$caseNumber=$child;
}
}
echo $caseNumber;
No comments:
Post a Comment