How to automatically refresh form upon submission