how to make the autocomplete suggestions appear in a dropdown menu and not as a normal list as text below the search box
<p>I have created an autocomplete component where the datasoucre ia the localhost solr.Everything works fine,but i need the suggestions to come in the format of a drop down menu box,but in my case its showing up as a normal list and no drop down appears.</p>

<p>Heres my code,</p>

<pre><code>&lt;%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%&gt;
&lt;%@ taglib prefix="f"  uri="http://java.sun.com/jsf/core"%&gt;
&lt;%@ taglib prefix="h"  uri="http://java.sun.com/jsf/html"%&gt;
&lt;%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %&gt;
&lt;%@ taglib prefix="rich" uri="http://richfaces.org/rich" %&gt;
&lt;%@ taglib prefix="a4j" uri="http://richfaces.org/a4j"%&gt;
&lt;!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt;
&lt;html&gt;
&lt;head&gt;
&lt;meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"&gt;
&lt;title&gt;Autocomplete&lt;/title&gt;
&lt;script type="text/javascript" src="jquery-1.4.2.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="jquery.ui.core.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="jquery.ui.position.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="jquery.ui.widget.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="jquery.ui.autocomplete.js"&gt;&lt;/script&gt;
&lt;SCRIPT type="text/javascript"&gt;

$(function() {
    $("#autotextsearch").autocomplete({
        source: function( request, response ) {
            $.ajax({
            url: "http://localhost:8080/solr2/select?q=Query%3A"+request.term+"*&amp;wt=json",
            data: { 
                style: "full", 
                maxRows: 5
             }, 
             dataType: "json",
             type: "GET", 
             contentType: "application/json; charset=utf-8", 
             cache:false,
             asynch:false,
             success: function( data ) {
             data=parse();
             function parse(){
             var parsedQueries=[];
             for(var i=0;i&lt;data.response.docs.length;i++){
                parsedQueries[i]=data.response.docs[i].Query;
            }
            return parsedQueries;
            }

             response($.map(data, function( item ) { 
                    return { 
                        label: item,
                        value: item
                    }; 
            }));
            }
          }); 
         },
        minLength: 2
        });
    });
    &lt;/SCRIPT&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;f:view&gt;
&lt;label for="autotextsearch"&gt;Search Here :  &lt;/label&gt;
&lt;input id="autotextsearch"/&gt;
&lt;/f:view&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>
