complete login and search part