結果 : how to do input validation in javascript