protected function loadDocumentProperties($sPart)
{
$xmlReader = new XMLReader();
if ($xmlReader->getDomFromString($sPart)) {
$arrayProperties = array('/cp:coreProperties/dc:creator' => 'setCreator', '/cp:coreProperties/cp:lastModifiedBy' => 'setLastModifiedBy', '/cp:coreProperties/dc:title' => 'setTitle', '/cp:coreProperties/dc:description' => 'setDescription', '/cp:coreProperties/dc:subject' => 'setSubject', '/cp:coreProperties/cp:keywords' => 'setKeywords', '/cp:coreProperties/cp:category' => 'setCategory', '/cp:coreProperties/dcterms:created' => 'setCreated', '/cp:coreProperties/dcterms:modified' => 'setModified');
$oProperties = $this->oPhpPresentation->getDocumentProperties();
foreach ($arrayProperties as $path => $property) {
if (is_object($oElement = $xmlReader->getElement($path))) {
if ($oElement->hasAttribute('xsi:type') && $oElement->getAttribute('xsi:type') == 'dcterms:W3CDTF') {
$oDateTime = new \DateTime();
$oDateTime->createFromFormat(\DateTime::W3C, $oElement->nodeValue);
$oProperties->{$property}($oDateTime->getTimestamp());
} else {
$oProperties->{$property}($oElement->nodeValue);
}
}
}
}
}