Browse Source

Updated so that validate() will pull the name from the root element if it exists. ISLANDORA-134

pull/105/head
mroy 14 years ago
parent
commit
3a7f5415ea
  1. 4
      XMLDatastream.inc

4
XMLDatastream.inc

@ -187,6 +187,10 @@ printerWindow.document.write(text);
elseif ($rootEl->attributes->getNamedItem('schemaLocation') !== NULL) { elseif ($rootEl->attributes->getNamedItem('schemaLocation') !== NULL) {
//figure out where the schema is located and validate. //figure out where the schema is located and validate.
list(, $schemaLocation) = preg_split('/\s+/', $rootEl->attributes->getNamedItem('schemaLocation')->nodeValue); list(, $schemaLocation) = preg_split('/\s+/', $rootEl->attributes->getNamedItem('schemaLocation')->nodeValue);
$name = $rootEl->getAttribute('name');
if ($name !== FALSE) {
$this->name = $name;
}
} }
$schemaLocation = NULL; $schemaLocation = NULL;
return TRUE; return TRUE;

Loading…
Cancel
Save