Manage the display of search results

This documentation is written for the 7.x-2.x version of Display Suite.

Display Suite can override the way that Drupal's (and Apache solr's) default search results are being displayed. This will be useful if you wanted to include images or file attachments in search results.

WHAT/WHERE search + Solr 3.6 + location(lat/lng) + radius based search

This doc will help you to

  • Modify schema.xml so that it supports geo location values
  • WHAT/WHERE search (radius based) - instead of a single keyword based search
  • Content-type based filtration
  • Implementation of hook_apachesolr_index_document_build, hook_apachesolr_query_alter

I am not going through the steps for installing / connecting solr with drupal. A lot of articles are already available online.

Case

Typically for job/property search sites, where you have two text fields: WHAT and WHERE. I am using the apachesolr search pages for this implementation.
Example search:
WHAT: drupal architect
WHERE: Mumbai, Maharashtra, India
(basically, the 'where' is an autofill textbox - which gets data from YQL - and its cached when search is being repeated)

Schema.xml

Installing Apache Solr on Windows 2008 with Jetty Running as a Service

Please note that this article was reproduced with permission from Bill Beckelman's website. The original article can be found here. This guide has been used succesfully with Drupal.


Initial Solr Setup


1. Install the latest Java JDK from http://www.oracle.com/technetwork/java/javase/downloads/index.html.
Make sure to select 64bit version if you need it.

Only local images are allowed. title="image" border="0" alt="image" src="/files/solr_windows_installation-1.png"
width="589" height="473">


 


2. Download Solr 1.4.1 from one of the mirrors at http://www.apache.org/dyn/closer.cgi/lucene/solr/
(at the time of writing, not all mirrors seem to be hosting 1.4.1, but most seem
to have at least 1.4.0)

Only local images are allowed. title="image" border="0" alt="image" src="/files/solr_windows_installation-2.png"
width="566" height="236">


3. Unzip the Solr download. You should have the files listed in the image
below. Open the example folder.

Only local images are allowed.

Manipulating Apache Solr search results using the QueryElevationComponent and elevate.xml

In order to use these directions, you must have access to the your Apache Solr installation including solrconfig.xml and elevate.xml.

By default, Apache Solr does not use the QueryElevationComponent (which enables the administrator to manipulate query results) in the default request handler. This page is a guide on how to use QueryElevationComponent to artificially promote nodes based on a search query.

Pages

Subscribe with RSS Subscribe to RSS - Apache Solr