public function bibitParfum() { $term = Input::get('term'); $data = Parfum::distinct()->select('nama', 'id')->where('nama', 'LIKE', '%' . $term . '%')->groupBy('id')->take(15)->get(); $result = []; foreach ($data as $aroma) { if (strpos(Str::lower($aroma), $term) !== false) { $result[] = ['value' => $aroma->nama]; } } return Response::json($result); }