Form validation now working