There isn't a XML example, but it should be possible to adapt this json
example:

http://dev.jquery.com/view/trunk/plugins/autocomplete/demo/json.html

Basically replace the dataType and change the parsing code. You can still
use jQuery to convert the xml response to JavaScript objects. See for
example http://www.xml.com/pub/a/2007/10/10/jquery-and-xml.html

Jörn

On Tue, Dec 2, 2008 at 3:47 PM, Casey Wise <[EMAIL PROTECTED]> wrote:

>
> You guys, I really dig working with jQuery, very powerful stuff.  I've
> been trying to implement the autocomplete plugin but I don't know how
> to ask this question, or google what I need to know.
>
> We have 6000 staff (records) here on campus and we want to be able to
> search them by their first & last name.  I have to use an XML web
> service that's controlled by another group.  Getting the output
> changed would be near impossible, so it's gotta come out this way.  I
> curl that XML into a PHP.  I pass that php a "GET" argument of name,
> in this instance "casey" and below is what it comes back with.
>
> Can this be done with XML like this using the autocomplete plugin
>
> <searchResults status="OK">
>        <totalEntries>4</totalEntries>
>        <entry employeeID="cmwise">
>                <email>[EMAIL PROTECTED]</email>
>                <firstName>Casey</firstName>
>                <fullName>Casey M Wise</fullName>
>                <zip>3501</zip>
>                <department name="Application Systems Svs">
>                        <title>Sr Web Developer</title>
>                </department>
>                <building>COMP 115</building>
>                <lastName>Wise</lastName>
>                <phone>330/972-6523</phone>
>                <displayName>Mr Casey M Wise</displayName>
>        </entry>
>        <entry employeeID="cem22">
>                <email>[EMAIL PROTECTED]</email>
>                <firstName>Casey</firstName>
>                <fullName>Casey E Merriman</fullName>
>                <zip>3001</zip>
>                <department name="Speech, Lang/Path & Audiology">
>                        <title>Graduate Assistant</title>
>                </department>
>                <building></building>
>                <lastName>Merriman</lastName>
>                <phone></phone>
>                <displayName>  Casey E Merriman</displayName>
>        </entry>
>        <entry employeeID="cfm2">
>                <email></email>
>                <firstName>Casey</firstName>
>                <fullName>Casey F Miller</fullName>
>                <zip>4731</zip>
>                <department name="Human Resources">
>                        <title>Employment Services Assistant</title>
>                </department>
>                <building>ASB 135</building>
>                <lastName>Miller</lastName>
>                <phone>330/972-5988</phone>
>                <displayName>Ms Casey F Miller</displayName>
>        </entry>
>        <entry employeeID="cbakula">
>                <email>[EMAIL PROTECTED]</email>
>                <firstName>Casey</firstName>
>                <fullName>Casey J Bakula</fullName>
>                <zip>3904</zip>
>                <department name="Electrical & Computer Engr">
>                        <title>Graduate Assistant</title>
>                </department>
>                <building></building>
>                <lastName>Bakula</lastName>
>                <phone></phone>
>                <displayName>Casey J Bakula</displayName>
>        </entry>
> </searchResults>
>

Reply via email to