The site I'm currently working on uses the Domain Access module, and I needed Zeitgeist to return search data relevant to the user's current domain - e.g. searches made in www.a.com shouldn't show up in the Top 5 block for www.b.com, etc.

So, I modified Zeitgeist as such: if Domain Access is enabled, then the Zeitgeist admin page allows you to optionally "Filter by Domain." If that's turned on, then Zeitgeist keeps track of the domain for each search and returns domain-specific data in the blocks.

A separate issue: when Zeitgeist creates links for the search terms, it hard-codes 'search/node' as the search page path. I added an Advanced Settings option in the Zeitgeist admin page that allows the user to set a different search path. In my case, I needed the search terms linked to 'search/apachesolr_search'. (it still uses 'search/node' by default)

I'm attaching two patch files (one for .module and one for .install) that incorporate those two changes. I made the patch against the latest dev release ($Id: zeitgeist.module,v 1.9.6.6 2010/01/20 21:53:25 fgm Exp $).

I hope it's useful. This is my first time submitting anything to Drupal.

Comments

surgeonbor’s picture

StatusFileSize
new9.71 KB
new1.27 KB

Yikes, here are the attachments.

bleen’s picture

subscribe

bleen’s picture

Status: Active » Needs review
StatusFileSize
new11.24 KB

this is a reroll of the patches in #1 ... works with the most recent version of dev

fgm’s picture

Thanks for these patches. I am not ignoring you, but as I have exactly zero deployment of DomainAccess, it makes it difficult to review them meaningfully.

bleen’s picture

StatusFileSize
new11.71 KB

understood ... just keepin up with dev

bleen’s picture

StatusFileSize
new12.31 KB

still keepin up with dev ....