I do not have enough information
I need to get echo fields
How should I do it?
function dvrvarsagoster($bulunan_toplam_cikis, $bulunan_marka, $kamera_sayisi, $bulunan_dvr_idler) {
$bulunandvr_idler = join(',',$bulunan_dvr_idler);
$dvridlervesayilari = array_count_values($bulunan_dvr_idler);
$rowspan = count($dvridlervesayilari);
echo "
<table class=\"table table-bordered table-hover\">
<thead>
<tr class=\"bg-primary\">
<th class=\"col-md-0\">Seç</th>
<th class=\"col-md-2\">DVR Markası</th>
<th class=\"col-md-2\">Ses Girişi</th>
<th class=\"col-md-3\">Kmr Girişi</th>
<th class=\"col-md-3\">DVR Adı & Tanımı</th>
<th class=\"col-md-2\">Fiyatı</th>
<th class=\"col-md-0\">Adet</th>
</tr>
</thead>
<tbody>";
echo "
<tr>
<td rowspan=\"".$rowspan."\" style=\"vertical-align: middle;\"><input type=\"radio\" class=\"dvr_getir\" value=\"".$bulunandvr_idler."\" name=\"secilen_dvr\" /></td>";
global $PDO;
$arr = array_map('trim', explode(',',$bulunandvr_idler));
$in = str_repeat('?,', count($arr) - 1) . '?';
$sql = "
SELECT
dvrlar.id,
dvrlar.dvr_markasi,
dvrlar.dvr_audioin,
dvrlar.dvr_camerain,
dvrlar.dvr_adi,
dvrlar.birim_fiyati,
dvrlar.dvr_para_birimi,
dvrlar.stok,
markalar.urun_markasi,
dvrtipi.dvr_audio_in,
parabirimi.para_birimi,
dvrtipi.dvr_camera_in
FROM dvrlar
INNER JOIN parabirimi ON dvrlar.dvr_para_birimi = parabirimi.id
INNER JOIN markalar ON dvrlar.dvr_markasi = markalar.id
INNER JOIN dvrtipi ON dvrlar.dvr_audioin = dvrtipi.id
WHERE dvrlar.id IN ($in)";
$dvr_ara = $PDO->prepare($sql);
$params = array_merge($arr);
$dvr_ara->execute($params);
$dvr_sayisi = $dvr_ara->rowCount();
$i=0;
$urun_adet = 0;
while ($row = $dvr_ara->fetch()){
global $cf;
global $secilen_para_birimi;
$urun = array("b_fiyati"=>$row['birim_fiyati'], "para_birimi"=>$row['para_birimi']);
$fiyati = convert($cf,$urun,$secilen_para_birimi);
$fiyati_d = para($fiyati);
if($i == 0){
echo "
<td><a style=\"cursor:pointer;\" title=\"Ürün Açıklaması\" onClick=\"aciklama('dvrlar', '" . $row['id'] . "')\"><span class=\"glyphicon glyphicon-info-sign\"></span></a> ".$row['urun_markasi']."</td>
<td>".$row['dvr_audio_in']."</td>
<td>".$row['dvr_camera_in']."</td>
<td>".$row['dvr_adi']."</td>
<td>".$fiyati_d." ".$secilen_para_birimi."</td>
<td>".$dvridlervesayilari[$row['id']]."</td>
</tr>";
}else{
echo "
\n<tr>
<td><a style=\"cursor:pointer;\" title=\"Ürün Açıklaması\" onClick=\"aciklama('dvrlar', '" . $row['id'] . "')\"><span class=\"glyphicon glyphicon-info-sign\"></span></a> ".$row['urun_markasi']."</td>
<td>".$row['dvr_audio_in']."</td>
<td>".$row['dvr_camera_in']."</td>
<td>".$row['dvr_adi']."</td>
<td>".$fiyati_d." ".$secilen_para_birimi."</td>
<td>".$dvridlervesayilari[$row['id']]."</td>
</tr>";
}
$urun_adet += $dvridlervesayilari[$row['id']];
$i++;
}
echo "
\n<tr class=\"alert alert-info\">
<td colspan=\"7\">".$kamera_sayisi." kamera için <b>".strtoupper($bulunan_marka)."</b> markadan ".$urun_adet." adet ".$bulunan_toplam_cikis." kamera girişli DVR elde edilmiştir</td>
</tr>";
echo "\n</tbody>\n</table>";
}