adding form and validation javascript