Does anyone know why this would not work in IE7/8?
drop_area = $('div#drop_area');
It works perfectly in IE9, FF2/3, and Chrome. Internet Explorer 7/8 gives the following error:
SCRIPT438: Object doesn't support this property or method
Edit: This is the HTML that goes with my javascript:
http://pastebin.com/nwxx8RzW
The code you’ve shown on pastebin has numerous global variable issues. In other words, you are coding assuming that variables you are declaring are local in scope, whereas in reality they turn out to be global. Examples include
set,box_handle,elements,i,id,drop_area,element,row,image_id, etc. All of your functions are global in scope as well, when they can easily be encapsulated in an other function.Now I don’t know if there’s some subtle interactions going on, whether some code has hammering (global) data set by other code, but it certainly seems as if something is getting overwritten and hence methods and properties are disappearing. I would start by going through the code and adding
varto local variables. Next I’d be encapsulating most of this code in an anonymous autoexecuting function.