Handle many search focus elements on the page

The code assumed only one search focus would apear on the page. We have
two on the new homepage so it needs to work with both of them.