Fix download buttons on search pages.

This is in addition to a previous commit to fix the download buttons on
tree pages.