Changed javascript for submit button