add signup page
implement user mode validation and refactor server code