I am using the Jquery Elastic. It works fine with Firefox but fails in chrome. I have only one textarea I am using it on.
HTML:
<textarea id = "tarea">Lorem Ipsum</textarea>
Binding the textarea with the plugin function:
$(document).load(function() { $('#tarea').elastic() ; }) ;
I opened the plugin file and found through alert
statements where the execution stops in chrome:
--- code above this initializing arrays, works fine in both FF and chrome
return this.each( function() {
-- Chrome does not execute anything in the callback
// Elastic only works on textareas
if ( this.type !== 'textarea' ) {
return false;
}
.
.
.
}
--- return ends here , chrome does not execute anything here either.
I have checked the JS for error with firebug and found nothing. I have a similar plugin for chrome as well and even that does not report any javascript errors.
Update :
I changed the call to the plug from being a 'load'
event to a 'ready'
event. And it works now. I can't understand why though.