Theme whole search page

neochief - November 9, 2008 - 13:55
Project:Sphinx search
Version:6.x-1.x-dev
Component:Code
Category:task
Priority:normal
Assigned:Unassigned
Status:needs review
Description

Hello

I found the lack of flexibility in theming the search page. At this time, all the output lies in sphinxsearch_search_page() function, which not allows theming. And if you, for instance, want to show search form at the top and the bottom of search results, you are not able to do so.

I divided the output from it's logic and called function theme_sphinxsearch_search_page(). Now people are able to make changes to whole serch page, not only to it's children.

Hope you'll find this usefull to. Please, review the patch.

AttachmentSize
sphinxsearch.module.patch2.67 KB

#1

markus_petrux - November 9, 2008 - 14:20

That's a good idea. :)

I add a link to the TODO list. But, I would wait a little until the hook_sphinxsearch_api() and "search page profile" things are done because sphinxsearch_search_page() could have been changed a little since then.

#2

matason - March 20, 2009 - 11:09

Hi Markus,

Thanks for your work on the Sphinx Search module, I've tested this patch and feel it provides a huge benefit to users (saves us hacking/killing kittens), would be really good get this patch committed, do you see any reason why it shouldn't be?

Regards,

Chris

Ps. Think of the kittens ;)

#3

markus_petrux - March 20, 2009 - 11:43

OMG! I have this module a bit abandoned, because I'm trying to finish a few other things that took priority on the project I'm working on. But I hope to get back to this in the coming weeks.

Feel free to use the attached patch as-is. I'll have to release a version of the module with the features you can see now + this patch and maybe one or two more things. But, that will not be the final result that we need, so I'll have to create a new branch with all the thing we need to add for our project.

I'm glad it can be useful for some of you out there as it is. Don't worry, I'll keep a version up to date for those that rely on current implementation, plus these small changes.

 
 

Drupal is a registered trademark of Dries Buytaert.