"_"); $dataSet = strtr($_GET['id'], $replace); $referXML = baseDir."/DDsys.xml"; $DDsys = new DOMDocument("1.0"); $DDsys->load($referXML); $xp = new domxpath($DDsys); $VI_NAME = $xp->query("//NAME[.='".$dataSet."']"); if ($VI_NAME->item(0)->nodeValue != NULL) { $VI = $VI_NAME->item(0)->parentNode; $location = $VI->getElementsByTagName("LOCATION")->item(0)->nodeValue; $info = basename($VI->getElementsByTagName("INFO")->item(0)->nodeValue, '.nc').'.xml'; if (!file_exists($location.$info)) exit('NO INFO XML'); $infoDom = new DOMDocument("1.0"); $infoDom->loadXML(file_get_contents($location.$info)); // for NFS $Start = $infoDom->getElementsByTagName("GlobalStart")->item(0)->nodeValue; $Stop = $infoDom->getElementsByTagName("GlobalStop")->item(0)->nodeValue; exit($Start.",".$Stop); } else { exit('NO SUCH DATASET'); } ?>