diff --git a/update_amda/makeHAPIMetadata.php b/update_amda/makeHAPIMetadata.php index 36c7dae..4299506 100644 --- a/update_amda/makeHAPIMetadata.php +++ b/update_amda/makeHAPIMetadata.php @@ -12,7 +12,7 @@ $doc = new DOMDocument(); $xpath = new DOMXpath($doc); -$dataset_nodes = $xpath->query("/dataRoot/dataCenter/mission/instrument/dataset | /dataRoot/dataCenter/mission/observatory/instrument/dataset"); +$dataset_nodes = $xpath->query("/dataRoot/dataCenter/mission/instrument/dataset | /dataRoot/dataCenter/mission/observatory/instrument/dataset | /dataRoot/dataCenter/mission/instrument/datasetGroup/dataset"); $datasets = array(); foreach ($dataset_nodes as $dataset_node) { $datasetId = $dataset_node->getAttribute("xml:id"); @@ -175,7 +175,7 @@ foreach ($dataset_nodes as $dataset_node) { if (!empty($ranges)) { $bin_info = (Object)array(); $bin_info->{"name"} = $nameBin; - $bin_info->{"units"} = $unitsBin; + $bin_info->{"units"} = html_entity_decode($unitsBin); $bin_info->{"ranges"} = $ranges; if ($bin_index == 0) { array_unshift($bins, $bin_info); @@ -196,7 +196,7 @@ foreach ($dataset_nodes as $dataset_node) { $units = $parameter_node->getAttribute("units"); if (empty($units)) $units = NULL; - $parameter->{"units"} = $units; + $parameter->{"units"} = html_entity_decode($units); //fill $parameter->{"fill"} = "-1e31"; -- libgit2 0.21.2