cleaned some code and added a submit button to the test page.