Squaring input number with JS script in external file