function get_LinkDATA($conDB, $MainID){ $data= array(); $sql="select tb_servicelink.slide_id, tb_servicelink.slide_titleTH, tb_servicelink.slide_titleEN FROM tb_servicelink Where tb_servicelink.slide_textTH='$MainID' ORDER BY tb_servicelink.slide_point ASC"; $qry=mysqli_query($conDB, $sql); $numR=mysqli_num_rows($qry); $data[0][0]=$numR; $i=1; while($fet=mysqli_fetch_array($qry, MYSQLI_BOTH)){ $data[$i][1]=$fet["slide_id"]; $data[$i][2]=$fet["slide_titleTH"]; $data[$i][3]=$fet["slide_titleEN"]; $i=$i+1; } return $data; } ?>