Fixed notice undefined variable in advanced search.