how to use jquery autocomplete in codeigniter - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: how to use jquery autocomplete in codeigniter (/showthread.php?tid=33256) Pages:
1
2
|
how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] Hi help me how to use jquery autocomplete in codeigniter i tried but the code didnt populate. this is my view home.php Code: [removed][removed] this is my controller searcheasy.php Code: function view() this is my model dbsearch.php Code: var $namearr=array(); i cant get the country list out in text box.suggest me to solve this. thankyou sona how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]mddd[/eluser] Just some observations.. Code: $this->load->model('dbsearch'); Code: $this->load->view('home',$data); I would suggest checking what you actually get back from the Ajax call. It will probably have php errors and useless html in it.. Not something the autocomplete script knows what to do with. how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] thanks mddd i changed the model here Code: $this->load->model('dbsearch'); i m new to codeigniter so can you help me how could i pass the data to home page through ajax . my code didnt populate the list of terms returned by dbsearch thanks how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]mddd[/eluser] You don't need to do anything to "pass the data". The page searcheasy/view is already being loaded by Ajax! All you need to do is output the data in a format that the jQuery autocomplete function expects. That's it. Like I said: check what data is being output jQuery and you should see soon enough. how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] thank you mddd i remove the view loaded Code: $this->load->view('home',$data); while i m enter letter in textbox it automatically disappear and it didnt populate the search list. is anything wrong in my jquery. or my model.help me thanks how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]mddd[/eluser] You need to output in a format that jQuery understands. Right now you are just echoing every key on a new line. Check the jQuery manual and find out in what format you have to output the data. how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] thanks can u give me example for how to display the jquery data? how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]mddd[/eluser] Browser extensions like Firebug for Firefox or Web inspector for Safari / Chrome will let you see all the loaded files and their contents. how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] my textbox will trigger but content only doesnt populate for my controller which is posted previously how could i get the data how to use jquery autocomplete in codeigniter - El Forum - 08-20-2010 [eluser]goldensona[/eluser] how to pass the data to autocomplete jquery function from controller. can give some example please help me thanks |