diff --git site/sites/all/modules/opensearch/opensearch.module site/sites/all/modules/opensearch/opensearch.module index 4ae0a36..b0659cd 100644 --- site/sites/all/modules/opensearch/opensearch.module +++ site/sites/all/modules/opensearch/opensearch.module @@ -223,16 +225,18 @@ function opensearch_feed($type, $keys, $results) { $items .= format_rss_item($result['title'], $result['link'], $result['snippet'], array('relevance:score' => (float)$result['score'])); } + $get = drupal_query_string_encode($_GET, array('q')); $args = array( 'opensearch:totalResults' => $GLOBALS['pager_total_items'][0], 'opensearch:startIndex' => $GLOBALS['pager_page_array'][0] * 10 + 1, 'opensearch:itemsPerPage' => 10, array('key' => 'opensearch:link', 'attributes' => array('href' => url('opensearch/'. $type, array('absolute' => TRUE)), 'type' => 'application/opensearchdescription+xml')), + array('key' => 'atom:link', 'attributes' => array('href' => url('opensearch/'. arg(1) .'/'. urlencode(search_get_keys()), array('query' => trim($get) ? $get : NULL, 'absolute' => TRUE)), 'rel' => 'self', 'type' => 'application/rss+xml')), array('key' => 'opensearch:Query', 'attributes' => array('role' => 'request', 'searchTerms' => $keys)), ); $output = "\n"; - $output .= " TRUE)) ."\" ". implode(' ', $namespaces) .">\n"; + $output .= " TRUE)) ."\" ". implode(' ', $namespaces) .">\n"; $output .= format_rss_channel( $keys .' - '. variable_get('site_name', 'drupal') .' '. check_plain(module_invoke($type, 'search', 'name')) .' '. t('search'), $base_url,