add debugger and form validation