Added download attributes to download links.
This commit is contained in:
parent
ce43a0a07d
commit
c858c586cd
Notes:
subgit
2018-03-07 17:59:01 +01:00
r688 www/trunk
@ -131,7 +131,7 @@ function ajaxLoadEvents(stime, etime, id, target) {
|
|||||||
var mseedurl = sprintf('%s?net=GE,GR,RN&cha=EH?,HH?&start=%04d-%02d-%02dT%02d:%02d:%02d&end=%04d-%02d-%02dT%02d:%02d:%02d', config['ajax']['mseedURL'], Number(sTime.getUTCFullYear()), Number(sTime.getUTCMonth())+1, Number(sTime.getUTCDate()), Number(sTime.getUTCHours()), Number(sTime.getUTCMinutes()), Number(sTime.getUTCSeconds()), Number(eTime.getUTCFullYear()), Number(eTime.getUTCMonth())+1, Number(eTime.getUTCDate()), Number(eTime.getUTCHours()), Number(eTime.getUTCMinutes()), Number(eTime.getUTCSeconds()));
|
var mseedurl = sprintf('%s?net=GE,GR,RN&cha=EH?,HH?&start=%04d-%02d-%02dT%02d:%02d:%02d&end=%04d-%02d-%02dT%02d:%02d:%02d', config['ajax']['mseedURL'], Number(sTime.getUTCFullYear()), Number(sTime.getUTCMonth())+1, Number(sTime.getUTCDate()), Number(sTime.getUTCHours()), Number(sTime.getUTCMinutes()), Number(sTime.getUTCSeconds()), Number(eTime.getUTCFullYear()), Number(eTime.getUTCMonth())+1, Number(eTime.getUTCDate()), Number(eTime.getUTCHours()), Number(eTime.getUTCMinutes()), Number(eTime.getUTCSeconds()));
|
||||||
row += '<tr class="tablesorter-childRow event-download">'
|
row += '<tr class="tablesorter-childRow event-download">'
|
||||||
+ '<td colspan="4" eventid="'+id+'">'
|
+ '<td colspan="4" eventid="'+id+'">'
|
||||||
+ sprintf('Download <a class="xml-link" target="_blank" href="%s">QuakeML</a> or <a class="mseed-link" target="_blank" href="%s">miniSEED</a>', xmlurl, mseedurl)
|
+ sprintf('Download <a class="xml-link" target="_blank" download="%s.xml" href="%s">QuakeML</a> or <a class="mseed-link" target="_blank" download="%s.mseed" href="%s">miniSEED</a>', id, xmlurl, id, mseedurl)
|
||||||
+ '</td></tr>';
|
+ '</td></tr>';
|
||||||
// add row to table
|
// add row to table
|
||||||
if ( stime <= oTime && etime >= oTime ) {
|
if ( stime <= oTime && etime >= oTime ) {
|
||||||
|
@ -81,8 +81,8 @@ function loadStations(stime, etime) {
|
|||||||
sc3mlRespURL = URL + '&level=response&format=sc3ml';
|
sc3mlRespURL = URL + '&level=response&format=sc3ml';
|
||||||
dlsvFile = sprintf('%s_%s.dlsv', network.toUpperCase(), station.toUpperCase());
|
dlsvFile = sprintf('%s_%s.dlsv', network.toUpperCase(), station.toUpperCase());
|
||||||
row += '<tr class="tablesorter-childRow station-download"><td colspan="4">'
|
row += '<tr class="tablesorter-childRow station-download"><td colspan="4">'
|
||||||
+ sprintf('Download details: <a href="%s" target="_blank">FDSNxml</a> or <a href="%s" target="_blank">SC3ml</a></br> ', fdsnxmlURL, sc3mlURL)
|
+ sprintf('Download details: <a download="%s.xml" href="%s" target="_blank">FDSNxml</a> or <a download="%s.sc3" href="%s" target="_blank">SC3ml</a></br> ', stationID, fdsnxmlURL, stationID, sc3mlURL)
|
||||||
+ sprintf('Response files: <a href="%s" target="_blank">FDSNxml</a>, <a href="%s" target="_blank">SC3ml</a> ', fdsnxmlRespURL, sc3mlRespURL)
|
+ sprintf('Response files: <a download="%s_response.xml" href="%s" target="_blank">FDSNxml</a>, <a download="%s_response.sc3" href="%s" target="_blank">SC3ml</a> ', stationID, fdsnxmlRespURL, stationID, sc3mlRespURL)
|
||||||
+ sprintf('or <a href="%s" download="%s" type="application/octet-stream">datalessSEED</a>', config['ajax']['dlsvURL'] + '/' + dlsvFile, dlsvFile.toLowerCase())
|
+ sprintf('or <a href="%s" download="%s" type="application/octet-stream">datalessSEED</a>', config['ajax']['dlsvURL'] + '/' + dlsvFile, dlsvFile.toLowerCase())
|
||||||
+ '</td></tr>';
|
+ '</td></tr>';
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user