? .cvsignore ? SolrPhpClient ? Zend ? auth-servlet.patch ? entity-fixes-528086-17.patch ? entity-fixes-528086-20.patch ? entity-type-348668-38.patch ? less-breakage-528086-21.patch ? mlt-restrict-372767-38.patch ? mlt-restrict-372767-40.patch ? mysql-opt-592522-16.patch ? noresults-661952-1.patch ? text-analyzer.xml Index: apachesolr_search.module =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/apachesolr/apachesolr_search.module,v retrieving revision 1.1.2.6.2.122 diff -u -p -r1.1.2.6.2.122 apachesolr_search.module --- apachesolr_search.module 17 Dec 2009 15:27:52 -0000 1.1.2.6.2.122 +++ apachesolr_search.module 17 Dec 2009 16:24:43 -0000 @@ -241,7 +241,9 @@ function apachesolr_search_execute($keys unset($params['fq']); } - $response = $solr->search($query->get_query_basic(), $params['start'], $params['rows'], $params); + // We must run htmlspecialchars() here since converted entities are in the index. + // and thus bare entities &, > or < won't match. + $response = $solr->search(htmlspecialchars($query->get_query_basic(), ENT_NOQUOTES, 'UTF-8'), $params['start'], $params['rows'], $params); // The response is cached so that it is accessible to the blocks and anything // else that needs it beyond the initial search. apachesolr_static_response_cache($response); @@ -430,7 +432,9 @@ function apachesolr_process_response($re $results[] = array( 'link' => url($doc->path), 'type' => apachesolr_search_get_type($doc->type), - 'title' => $doc->title, + // template_preprocess_search_result() runs check_plain() on the title + // again. Decode to correct the display. + 'title' => htmlspecialchars_decode($doc->title, ENT_QUOTES), 'user' => theme('username', $doc), 'date' => $doc->created, 'node' => $doc,