Programmatically generates search page