encode data for form input first