Hi

On a dev project, the module overwrites the default search engine. In this case it is solr.

It provides the core search as standard.

CommentFileSizeAuthor
#5 solr_search2.patch356 bytesjdanthinne
#3 custom_solr.patch350 bytesjdanthinne

Comments

jdanthinne’s picture

Hi,
unfortunately, I don't have a server with solr installed to test that... so it's difficult to find where the problem is.
Can you tell me exactly:

  • what is wrong?
  • when does the override happen?
  • why do you use custom_search for in your case?
bennos’s picture

it is a global test server, just for testing new modules with typical modules, which I use.

solr is as search installed. Solr config provides an option to hijack the core search. solr depends on the core search module.

When I use a the drupal search block the redirect goes to /search/node and not to /search/apache_solr

jdanthinne’s picture

Status: Active » Needs review
StatusFileSize
new350 bytes

Can you try this patch?
I really don't know if it's going to work, but it tests if apachesolr_search is enabled and then redirects to /search/apache_solr instead of /search/node.

bennos’s picture

the redirect works.

posted the wrong URL.
Right is /search/apachesolr_search

To make it complete, you should add also a detection for Lucene API Search.

jdanthinne’s picture

StatusFileSize
new356 bytes

Here's the corrected patch.
Can you tell me which url is used by Lucene API Search?

jdanthinne’s picture

Status: Needs review » Fixed

Right, I've corrected the solr url, and managed to install Lucene API and made the changes to custom_search to work well with both.
Commited to DEV.

bennos’s picture

Lucene API uses
search/luceneapi_node
as URL.

An other question about Form_state. Hope you can help.

It is a redirect form a normal search box to a views constructed search.
I want to construct via form state redirect following URL.
jobsearch?key=key1

can you help?
thx

jdanthinne’s picture

Yes, I had already found for Lucene API.

For your other question, I don't really understand what you mean…
Can you be more precise please (a screenshot with annotations?) ?

bennos’s picture

hi

I have a view with an exposed search filter.
A search with the view, creates an URL like this www.domain.com/jobsearch?key=searchkey1234

For this specific use case, I want to change the redirect url to
www.domain.com/jobsearch?key=searchkey1234

the form state
$form_state['redirect'] = 'jobsuche?key='. $keys;

produces a lot of errors.

jdanthinne’s picture

I begin to understand...
Can you tell me which errors you get?

jdanthinne’s picture

Status: Fixed » Needs work
bennos’s picture

white page, ah wsod, nothing in the watchdog. haven't looked in the apache error log.

jdanthinne’s picture

Status: Needs work » Needs review

Hi,
I've added a setting "Force search path", where you can enter the path you want.
Download the latest DEV version (from 2010-Apr-06 +) and just try to enter the path "jobsearch?key=[key]" and tell me if it's working the way you want.

jdanthinne’s picture

NB: DEV version released sooner than expected. You can test with 2010-Apr-05.

bennos’s picture

thx. will try it out.

jdanthinne’s picture

Status: Needs review » Closed (fixed)