The explicit question: I've got a site where, in a Facebook-y sort of way, one user can "follow" another. It's also possible for, say, Alice to "block" Bob from following her or otherwise seeing her content. So: Given that I'm using apachesolr and apachesolr_user for the site's search, how do I modify/extend the search process so that a blocked Bob will not see any search results involving Alice (ideally, both Alice's user entry and any nodes owned by Alice)?

hook_apachesolr_query_alter() and additional "filters" within that handler would seem to be involved, but I haven't deciphered how I might use that towards this end. I could, I guess, do this as part of search-result.tpl.php, but dropping results from there will give me uneven and unpredictable numbers of items (maybe even zero) on a search result page, and I'd prefer to keep those things clean.

The meta-question: I've been all over Google this afternoon, and, while I've found lots of pages referring to add_filter(), I can't find any sort of concise description of exactly how to make use of add_filter(). Pointers in that area would be appreciated as well...

Comments

jim_at_miramontes created an issue.