Use radix 10 for parseInt, Put event handler in function expression.