Salve,
ho questo script:
$('#str_cerca_auto').autocomplete(
'/handler/get_articoli_suggeritore.ashx',
{
delay: 5,
minChars: 1,
matchSubset: false,
matchContains: false,
cacheLength: 10,
autoFill: false
}
);
$('#str_cerca_auto').result(function (event, data, formatted) {
if (data) {
if (data[1] != "0") {
aggiungi_costo(data[1]);
}
}
})
qualcuno mi sa dire perchè la funzione "aggiungi_costo(n)" viene eseguita 2 volte al click sul risultato??
il plugin in questione è questo: http://bassistance.de/jquery-plugins/jquery-plugin-autocomplete/