From cc8de041156232390357cccd84da712f178b6d87 Mon Sep 17 00:00:00 2001 From: Joe Date: Fri, 22 Jul 2022 23:56:47 +0200 Subject: [PATCH] php 8. cannot generate recurring invoices after upgrade to 2.4.12. Fixed. --- reporting/includes/reporting.inc | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/reporting/includes/reporting.inc b/reporting/includes/reporting.inc index dd4b5a5c..4bcdad83 100644 --- a/reporting/includes/reporting.inc +++ b/reporting/includes/reporting.inc @@ -140,17 +140,16 @@ function print_link($link_text, $rep, $pars = array(), $dir = '', $icon=false, $class='printlink', $id='') { global $path_to_root, $SysPrefs; - $url = $dir == '' ? $path_to_root.'/reporting/prn_redirect.php?' : $dir; $id = default_focus($id); + $parm = array(); foreach($pars as $par => $val) { - if ($val != null) - $pars[$par] = "$par=".urlencode($val); + if ($val != "") + $parm[] = "$par=".urlencode($val); } - $pars[] = 'REP_ID='.urlencode($rep); - $url .= implode ('&', $pars); - + $parm[] = 'REP_ID='.urlencode($rep); + $url .= implode ('&', $parm); if ($class != '') $class = $SysPrefs->pdf_debug ? '' : " class='$class'"; if ($id != '') -- 2.30.2