ok
Direktori : /home/keydecors/www/admin/pages/ |
Current File : /home/keydecors/www/admin/pages/getcate.php |
<?php include("../model/dboperation.php"); $term=$_GET["term"]; $query="SELECT * FROM prod_name where p_name like '%".$term."%' order by pro_id"; $result = $mysqli->query($query); $json=array(); while($student = $result->fetch_assoc()) { $json[]=array( 'value'=> $student["p_name"], 'label'=>$student["p_name"]." - " ); } echo json_encode($json); ?>