add user input validation. add mine-server support (not integrated in the html)