diff --git a/html/jrn_csv.php b/html/jrn_csv.php index 247282eee..b6f56f8f9 100644 --- a/html/jrn_csv.php +++ b/html/jrn_csv.php @@ -38,7 +38,7 @@ if ( $User->CheckAction($cn,IMP) == 0 || } - $p_cent=( isset ( $_POST['central']) )?'on':'off'; + $p_cent=( isset ( $_POST['central']) )?$_POST['central']:'off'; $Jrn=new jrn($cn,$_POST['jrn_id']); @@ -47,7 +47,8 @@ $Jrn->GetRow( $_POST['from_periode'], $_POST['to_periode'], $p_cent); - + if ( count($Jrn->row) == 0) + exit; foreach ( $Jrn->row as $op ) { // should clean description : remove tag and '; char $desc=$op['description'];