iranianpep / ajax-live-search

AJAX Live Search is a PHP search form that similar to Google Autocomplete feature displays the result as you type.
MIT License
247 stars 80 forks source link

Codeigniter - How to implement the ajax live search script #56

Closed mauro269 closed 7 years ago

mauro269 commented 7 years ago

Good morning, first of all a big thank to Ehsan for sharing this great job. 👍

I would like to install the script in my codeigniter structure. What I want to do is to put the ajax-live-search-master folder in the following path:

localhost/mydomain.com/application/third_party/

All the codes to recall the Live Search function (to be clear, the code written in the main "index.php" file) has been put in my "header.php" file that is in the following path:

localhost/mydomain.com/application/views/templates/

I don't know if you already know how codeigniter works, but the base URL (that is "localhost/mydomain.com") is recalled in the following way:

<?php echo base_url() ?>

Considering all of this, which files should I modify to implement the live search script in my CodeIgniter website? Thanks for your kind support.

PS: I've already filled all the MySQL database information in the Config.php file and it works like a charm (I've used the script as downloaded without implementing it on my script).

iranianpep commented 7 years ago

Hi,

I've answered the similar question here: https://github.com/iranianpep/ajax-live-search/issues/53

If still needs help let me know.

Cheers, Ehsan

mauro269 commented 7 years ago

Hi Ehsan, thanks for your kind reply. I had taken a look to the answer you gave in that thread. I tried to implement the modifies as you suggested but it didn't work. Maybe I'm doing something wrong...so I kindly ask you if can give a more precise lists of files to modify and what rows to modify to obtain the final result. I think this could be an integration to the script documentation you've already made. Thanks for your support.

mauro269 commented 7 years ago

Hello Ehsan, I didn't receive any reply from you. Is it all ok?

iranianpep commented 7 years ago

Hi,

Please accept my apologies. I'm pretty busy and cannot keep up with the questions here.

I don't have the chance to work with Codeigniter, but have you checked the error logs? Also while you develop make sure that the error reporting is enabled. Also check Google Chrome (or your favorite browser) condole for any javascript error. Other than that, check the Network tab in the Google Chrome console and check the response you get from the server for the ajax request.

Let me know how you go.

Cheers, Ehsan