From f643310fec64b886408722f3a6a5b4a93ac86b35 Mon Sep 17 00:00:00 2001 From: DB4SCW Date: Tue, 25 Nov 2025 06:30:48 +0000 Subject: [PATCH] support for contests with differet length of rcvd exch --- application/controllers/Cabrillo.php | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/application/controllers/Cabrillo.php b/application/controllers/Cabrillo.php index eebcfecf2..1f745372f 100644 --- a/application/controllers/Cabrillo.php +++ b/application/controllers/Cabrillo.php @@ -269,23 +269,25 @@ class Cabrillo extends CI_Controller { $stxstring = null; $srxstring = null; - //process all sent exchanges + //process all sent exchanges, handle those that are shorter than maximum gracefully for ($i=1; $i <= $sent_exchange_count; $i++) { - if($stxstring == null) - { - $stxstring = $qso["SENT_EXCH_" . $i]; - }else{ - $stxstring = $stxstring . ' ' . $qso["SENT_EXCH_" . $i]; + if(isset($qso["SENT_EXCH_" . $i])){ + if($stxstring == null){ + $stxstring = $qso["SENT_EXCH_" . $i]; + }else{ + $stxstring = $stxstring . ' ' . $qso["SENT_EXCH_" . $i]; + } } } - //process all sent exchanges + //process all sent exchanges, handle those that are shorter than maximum gracefully for ($i=1; $i <= $rcvd_exchange_count; $i++) { - if($srxstring == null) - { - $srxstring = $qso["RCVD_EXCH_" . $i]; - }else{ - $srxstring = $srxstring . ' ' . $qso["RCVD_EXCH_" . $i]; + if(isset($qso["RCVD_EXCH_" . $i])){ + if($srxstring == null){ + $srxstring = $qso["RCVD_EXCH_" . $i]; + }else{ + $srxstring = $srxstring . ' ' . $qso["RCVD_EXCH_" . $i]; + } } }