Welcome Guest, Not a member yet? Register   Sign In
Ajax and CI : I am lost
#1

[eluser]TDSPower[/eluser]
Hello,

I am working on my CI project.

I meet an error with the Autocompletion with the CI Ajax Library.

I create a controller which will show the form :

Code:
class Accueil extends All_accueil {
...
        function test(){
            $this->load->view('javascript_test');
        }
        
        function auto(){
              echo("<ul id=\"categorie_auto_complete\"><li>TEst</li><li>123</li></ul>");
        }
...
}

Here is the view (form), the input type text categorie is normally autocompleted (with the LI created with auto())...
Code:
&lt;form action="test.hpp" name="a"&gt;

<div id=\"categorie_auto_complete\" style="height:30px; width:100px; background-color:grey;"></div>
        &lt;input type="text" id="categorie" name="categorie" size="20"&gt;
        &lt;input type="submit" value="Tester"&gt;
&lt;?
echo $this->ajax->auto_complete_field('categorie',array('url' => '/accueil/auto'));
?&gt;

Nothing appears when i write some text on the input text...

When I look on firebug :
Quote:Erreur : $(element) has no properties
Fichier source : http://localhost/magnet/system/javascript/prototype.js
Ligne : 987

Don't understand where is the problem with such an implicit error !

Thanks a lot,

François


Messages In This Thread
Ajax and CI : I am lost - by El Forum - 01-22-2008, 02:40 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 02:59 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 02:59 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:04 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:15 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:23 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:29 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:54 PM
Ajax and CI : I am lost - by El Forum - 01-22-2008, 03:55 PM
Ajax and CI : I am lost - by El Forum - 01-04-2010, 02:17 AM



Theme © iAndrew 2016 - Forum software by © MyBB