Welcome Guest, Not a member yet? Register   Sign In
Jquery CodeIgniter 2.X


I have a mistake in my dev that i don' t understand.
I have a form which is link to a controler projet/formulaire

In this form i have an input text with an ID="ref".

I want to use

source: "<?php site_url('projet/autocomplete') ?>

But when I type one cheracter in my input text nothing happen.
In public function projet/autocomplete i put a javascript alert and it doesn't appear.
I think that it don't go to the projet/autocomplete

Somebody have an idea.
Have a nice

Autocomplete is an ajax request so your contoller needs to echo results. Also you are using it wrongly as you need to define the serviceUrl: which returns the option data or provide the option data manually.

Have a look here:

Or the API docs

Hope that helps,


Theme © iAndrew 2016 - Forum software by © MyBB