$arr = new Array(); while($p<$size){ $arr[$p]["number"] = $data[$p]; $arr[$p]["data"] = $kkk[1]; $arr[$p]["status"] = "A"; $p++; }