fix names array and load new page on submit