minor js changes
added framework for error reporting in create-alert