faultstring.PHP_EOL; exit($msg); } $basesDom = new DomDocument("1.0"); $basesDom->load(DDSERVICE."/BASE/INFO/Bases.xml"); // Remote from DDBASE/INFO foreach ($basesDom->getElementsByTagName("dataCenter") as $center) { $id = $center->getAttribute("xml:id"); if (is_dir(DATAPATH."/RemoteData/$id")) { foreach (glob(DATAPATH."/RemoteData/$id/*") as $file) { if (basename($file) == "base.xml") continue; $ds = basename($file,".nc"); if ($client->isRemoteViAdded($id, strtolower($ds))) continue; // VI exists; do nothing // vi was deleted in DDBASE; delete everything unlink($file); $paramId = strtolower($id)."_".strtolower($ds); foreach (glob(DATAPATH."/RemoteData/PARAMS/$paramId*.xml") as $xml) unlink($xml); foreach (glob(DATAPATH."/LocalData/ParamDef/$paramId*.xml") as $xml) unlink($xml); } } } } ?>