Added Underscorejs as local lib. Modified mainjs integration later functions. Added global error handler for ajax calls.