Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Mar 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Very Quick Pointer Needed - Ajax.Autocompleter

    Hey guys,
    I have lots of experience with PHP/MySQL, but I know next to nothing about javascript, ajax, etc.

    I have everything I need for the scriptaculous Ajax.Autocompleter set up.
    The database spits out search results perfectly and everything else.

    I just don't know how to make the Ajax.Autocompleter object work.

    Right now I just have
    Code:
    <script type="text/javascript">
    new Ajax.Autocompleter("autocomplete", "autocomplete_choices", "ajaxsearch.php", {});
    </script>
    in the head section (along with the scriptaculous/prototype).

    and then
    Code:
    <input type="text" id="autocomplete" name="autocomplete_parameter"/>
    <div id="autocomplete_choices" class="autocomplete"></div>
    in the body.


    Does it need to be in a function or something?


    (Don't laugh at me too much :P)

  • #2
    New to the CF scene
    Join Date
    Mar 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Never mind- got it.
    Script was supposed to be in the body, and I was missing some of the scriptaculous scripts.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •