Search HST archive for given RA, Dec and radius. Output requested columns
as comma-separated values.
#!/archive/data1/bin/php -f <?php # # standalone PHP program # (edit top line to point to local PHP executable) # # Submits GET request to search HST archive for given RA, Dec, and radius, # limit results to 10 records, # returns data set name, RA, Dec, and Target name # as a comma-separated list # prints out column headings and data #
# download results from MAST as an array called $data # (ignore errors)
$data = @file($request);
# print column headings (skip data types in next row)
print "$data[0]\n\n";
# now print search results
$cnt = count($data); for ($i=2; $i<$cnt; $i++) print "$data[$i]\n";
?>
Search FUSE archive for multiple coordinates. Output comma-separated values
with coordinates in decimal degrees.
#!/archive/data1/bin/php -f <?php # # standalone PHP program # (edit top line to point to local PHP executable) # # Submits GET request to search FUSE archive # request multiple RA & Dec values # (results for each input position will be separated by a blank line) # limit each set of results to 10 records, # return columns for data set name, Target name, RA, & Dec # output as a comma-separated list with coordinates in decimal degrees #
# download results from MAST as an array called $data # (ignore errors)
$data = @file($request);
# print column headings (skip data types in next row)
print "$data[0]\n";
# now print search results
$cnt = count($data); for ($i=2; $i<$cnt; $i++) print "$data[$i]"; ?>
Search HST ACS data (both spectra and images) for
NGC 1068 observations. Return only science data (i.e., no
calibration files). Output comma-separated values with
coordinates in decimal degrees.
#!/usr/local/php5/bin/php -f <?php # # standalone PHP program # (edit top line to point to local PHP executable) # # request ACS science observations (images and spectra) of NGC 1068 # (within 3 arcminutes), return all default columns # output as a comma-separated list with coordinates in decimal degrees #
# download results from MAST as an array called $data # (ignore errors)
$data = @file($request);
# print column headings (skip data types in next row)
print "$data[0]\n";
# now print search results
$cnt = count($data); for ($i=2; $i<$cnt; $i++) print "$data[$i]";
?>
Search for HST program id 9788
Return only science data.
Output comma-separated values with
coordinates in decimal degrees.
#!/usr/local/php5/bin/php -f <?php # # standalone PHP program # (edit top line to point to local PHP executable) # # request ACS science observations (images and spectra) of NGC 1068 # (within 3 arcminutes), return all default columns # output as a comma-separated list with coordinates in decimal degrees #