Update javascript to work in Search Form