Hi
i have this line of code that i want to test when a user choose ...
$c=count($pulse);
array_push($ser, $pulse);
foreach($ser as $serv){
$serv1[] = $serv;
}
if($c>=4){
include('full.php');
$netw = empty($_POST['netw'])?null:$_POST['netw'];
$client = empty($_POST['client'])?null:$_POST['client'];
getRecords($date,$date2,$report,$client,$netw,$auto);
}
in this line all the check boxes supposed to be ticked and it works fine
and now i want to add to this command if a user tick only 2 1 any propabilities...
the script will be called
function getRecords($startDate,$endDate,$report,$customer,$serial,$auto){
$sql="SELECT * FROM count_transactions WHERE DATE(tran_date) BETWEEN '$startDate' AND '$endDate' and account_no=$auto and unit_name='Litres' ";
if ($customer != null) $sql .= " AND customer_no=$customer ";
if ($serial != null) $sql .= " AND unit_serial=$serial ";
if ($ser<4) $sql .= " AND pulse_channel=$serv[] ";
$sql .= " GROUP BY unit_serial";
any help please