Merge pull request #2481 from tudacs/fix_sota

Make SOTA-CSV-export safer by adding quotes
pull/2497/head
Peter Goodhall 2023-09-18 14:19:11 +01:00 zatwierdzone przez GitHub
commit 2dad61ac35
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 11 dodań i 1 usunięć

Wyświetl plik

@ -35,6 +35,16 @@ $bands = array(
);
foreach ($qsos as $qso) {
$timestamp = strtotime($qso['COL_TIME_ON']);
print "V2,".$qso['station_callsign'].",".$qso['COL_MY_SOTA_REF'].",".date('d/m/y', $timestamp).",".date('Hi', $timestamp).",".$bands[$qso['COL_BAND']].",".$qso['COL_MODE'].",".$qso['COL_CALL'].",".$qso['COL_SOTA_REF'].",".$qso['COL_COMMENT']."\n";
printf("V2,%s,%s,%s,%s,%s,%s,%s,%s,\"%s\"\n",
$qso['station_callsign'],
$qso['COL_MY_SOTA_REF'],
date('d/m/y', $timestamp),
date('Hi', $timestamp),
$bands[$qso['COL_BAND']],
$qso['COL_MODE'],
$qso['COL_CALL'],
$qso['COL_SOTA_REF'],
$qso['COL_COMMENT']
);
}
?>