After an autocompleter has been initialised, and the page is unloaded, JS error is thrown in IE 8.
This is the line in question:
$(global).addEvent('unload', function(){
if (this.node) this.node.set('autocomplete', 'on'); // if autocomplete is off when you reload the page the input value gets erased
}.bind(this));
throwing 'object does not support this property or method' - it is as if the DOM element has lost its mootools bindings and behaves as a plain IE DOM element.
I have found that the script works fine if setting autocomplete to on is wrapped with $, so:
if (this.node) $(this.node).set('autocomplete', 'on');
After an autocompleter has been initialised, and the page is unloaded, JS error is thrown in IE 8.
This is the line in question:
$(global).addEvent('unload', function(){ if (this.node) this.node.set('autocomplete', 'on'); // if autocomplete is off when you reload the page the input value gets erased }.bind(this));
throwing 'object does not support this property or method' - it is as if the DOM element has lost its mootools bindings and behaves as a plain IE DOM element.
I have found that the script works fine if setting autocomplete to on is wrapped with $, so:
if (this.node) $(this.node).set('autocomplete', 'on');