Finally i can activate the Search Everything plugin once again (i temporarily disabled it after upgrading to Wordpress 2.1 because of producing duplicate results. Especially if the results can be found on multiple pages). And fortunately there’s someone already found a solution for this problem (many thanks to Tiago Pocinho by creating a fix for this problem)
To fix this problem, you can simply add below lines to the search everything plugin :
add_filter(‘posts_request’, ‘SE2_distinct’);
function SE2_distinct($query){
global $wp_query;
if (!empty($wp_query->query_vars['s'])) {
if (strstr($where, ‘DISTINCT’)) {}
else {
$query = str_replace(‘SELECT’, ‘SELECT DISTINCT’, $query);
}
}
return $query;
}
Yep .. that’s all .. but just in case you want to see a detailed description of this problem, you can see it at Search Everything page at Google Code
Actually i should be thanking you Dan because of your wonderful search everything plugin and by visiting this small blog :)
Dan dancameron.org Feb 23, 2007 at 2:52 AM
Oh, and THANK YOU.
Dan dancameron.org Feb 23, 2007 at 2:52 AM
I applied this fix and released 3.0 yesterday.
dancameron.org/wordpress