We (my boss) would like to pull the payloadID and timestamp from incoming cXML orders for injection into our MySQL database. The code to inject the information is already complete and working, and I am able to pull information from tags and attributes within the XML, however I don't seem to be able to pull any information from within the <cXML> tag itself.
Here's an example of the cXML tag:
<cXML payloadID="systemgeneratedpayloadid" timestamp="timestamp" version="1.2.021" xml:lang="en-US">
The XML is set up as follows:
foreach($this->simpleXML as $url)
And here are some examples of how the information that works is pulled in the same function:
$item = $url->OrderRequest->OrderRequestHeader['orderID']; #Attribute from tag
$NetworkID = $url->From->Credential->Identity; #XML data
I have tried to pull the payloadID and timestamp like so without results:
$item = $url->cXML['payloadID'];
Anyone have any suggestions? Your help would be greatly appreciated.