Fix for non-working admin plugin and code injection 

I've fixed some issues with the plugin. There was a typo in the reference to the TextArea class and I think the wrong event was used for injecting the script code to the page. The plugin is now working ok for me.