prevent IE from going into compatibility mode
listen for JS errors
add debug statements