PDA

View Full Version : Resolved why my code doesn't work only in Chrome and Safari?



tpravioti
02-02-2010, 12:21 PM
hi everybody!!
i made a gallery that works fine in Firefox, IE and Opera but it breaks in Chrome and Safari??

isn't this correct in my code?? :


$('sel').change=update_tag();
for (var ii=0; ii<images.length; ii++) {
$('thumb_'+images[ii].idnode).setStyle('border:medium solid transparent');
}


Does anybody have any ideas of what might happening??

Nile
02-02-2010, 01:10 PM
You'd either have to do:


$('sel').change(function(){
update_tag()
});

Or:


$('sel').bind('change', function(){
update_tag();
});

tpravioti
02-02-2010, 02:43 PM
thanks..finally it was so easy!!