found error in duplication, the type of button used is the issue. Changed to submit and works