Closed (works as designed)
Project:
Domain
Version:
7.x-3.8
Component:
User interface
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
14 Apr 2013 at 09:21 UTC
Updated:
23 May 2013 at 04:59 UTC
I like to have a feature like this:
User should be able to search across sites on demand.There should be a drop down in the search page which shows all domains
ie,if user is on a.site.com by default he should see the search results from domain a.But if he choose another domain ie,b.site.com he can see the search results of b.If he choose all he should see all the results from all domains.
Is this possible.If yes where should I make the changes.Please help.
Comments
Comment #1
agentrickardIt's not really possible without causing a cascade of problems. Since node access rules are per page-request, if you override those rules for search, then if you have domain-specific menu items, those will also change.
So it's not really possible in Drupal, without causing potentially unwanted behavior.
Comment #2
agentrickardYou can. however, do this with Views and Search API module, I believe. Views gives you the ability to disable SQL rewrites, which means you can apply your own filter using Domain Views.
Comment #3
ktrev commentedI was thinking of altering the search form.Add a new filter and filter the nodes before displaying based on the domain.
What you suggest seems to be more easy. Thanks for the reply.
Comment #4
ktrev commentedI used another method for this.I wrote a custom module that alters the search form.Provided a drop down in the form with the domains and altered the search query as follows.