getting info from the form to make the search