Update theme.php

Added search page optimization