Moved confirmDelete js function to global scope.