public static function update_ModeS_flarm() { global $tmp_dir, $globalDebug; if ($globalDebug) { echo "Modes Flarmnet: Download..."; } update_db::download('http://flarmnet.org/files/data.fln', $tmp_dir . 'data.fln'); if (file_exists($tmp_dir . 'data.fln')) { if ($globalDebug) { echo "Add to DB..."; } $error = update_db::retrieve_modes_flarmnet($tmp_dir . 'data.fln'); } else { $error = "File " . $tmp_dir . 'data.fln' . " doesn't exist. Download failed."; } if ($error != '') { echo $error; exit; } elseif ($globalDebug) { echo "Done\n"; } }