Autocomplete. Why wont you work?

Autocomplete. Why wont you work?

I have this script

  1. $( document). ready( function() {

    $( "#Search"). autocomplete( 'loadxml.asp',
    { minChars: 2
    , matchSubset: false
    , matchContains: true
    , width: 290
    , max: 10
    , scrollHeight: 600
    , dataType: 'json'
    , parse: newParser
    , cacheLength: 10
    , selectFirst: false
    , formatItem: function( row) { return row[ 'value'] }
    }). result( function( event, data) {
    window. location. href = data. url;
    });

    function newParser( raw) {
    var array = new Array();

    var prodCount = 0;

    for ( var i = 0; i < raw. length; i++) {
    if ( raw[ i] != null) {
    var text
    if ( raw[ i]. type == "product") {
    text = "<a href='" + raw[ i]. landing + "'><div class='searchitem product";
    if ( prodCount == 0) {
    text = text + " first";
    prodCount = 1;
    }
    text = text + "'><div class='imagearea'><img src='" + raw[ i]. image + "' alt='' /></div>"
    } else {
    text = "<div class='searchitem'>"
    }
    text = text + "<div class='detailarea'>" + raw[ i]. text + "</div></div>";

    array[ array. length] = { 'data': { text: raw[ i]. text, value: text, url: raw[ i]. landing, image: raw[ i]. image },
    'result': '', 'value': raw[ i]. text
    }
    };
    }
    return array;
    }
    });
Can you see anything in here that would make it not work at all my source is returning values by the way. And I have jquery-1.9.0.min.js loaded. Please help. It used to work on IE only and now NOTHING!

If you need any other info please feel free to ask.

Kind regards,
Glenn - glenn223