2

I'm a noobie to Drupal - recently "converted" from WordPress.

I want to create custom search forms that use checkboxes to allow visitors to search in a specific content type. Sorry for the shady example, but the search form on the front page of the Pirate Bay is exactly what I'm looking for. It would also be great to be able to set the default option based on context - if the user is on a page of a particular content type, that content type should be set as the default in the search checkboxes.

I've installed Drupal 7, Apache Solr search, and the Facet API. I'd give a link, but it's installed locally on mamp for development.

I want the custom search form because the site I'm building has a lot of different - and interrelated - kinds of information separated into different "areas" of the site defined by content type. One area is for social service resources, another is for social service organization profiles, another for trainings and workshops, etc. Each of these use Views to display related information in other content types (i.e. "Related Trainings" listed in the sidebar of a resource page). In essence, the site maps out the entire social service system in our community and serves as an information center for clients and case workers.

When someone visits our site looking for emergency shelter, for example, the information they are looking for is in the "Resource" content type and I don't want them getting a deluge of info from trainings, org profiles, forums, etc. Another example would be a case worker wanting training on how to apply for Social Security disability benefits for a client - I want them to be able to choose to restrict search results to the "Training" content type. Faceted search seems to be able to allow users to drill down and refine results, but I want them to be able to filter before getting results.

Anyone know how I might do this?

1 Answer 1

0

Take a look at this module, it may be what you need: http://drupal.org/project/custom_search. It extends drupal built-in search module. You can add filters for content types, taxonomies etc in drop-down triggered when searching.

2
  • Thanks! This is exactly what I was looking for - going to add a whole lot of power to my site.
    – Phil Owen
    Oct 1, 2012 at 19:24
  • NP, im using it on my site, it works very well.
    – NenadP
    Oct 2, 2012 at 7:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.