Form stuck on "Please wait" when it is submitted