[wp-hackers] integrating custom search function to additionaldatabase table

Stefan Hartweg stefan at hartweg.net
Wed May 3 23:42:42 GMT 2006

Thanks Andy.

The query is one issue, the bigger problem I have at the moment is how to
execute my own query first and then use these results to CALL the actual
Wordpress search, since I'm not using the Wordpress search form.
In non programming terms: how do I get Wordpress to "execute the stuff it
would normally execute when someone pushes the Search button" i.e. find the
posts, display the results in the template doing the loop, etc...


-----Original Message-----
From: wp-hackers-bounces at lists.automattic.com
[mailto:wp-hackers-bounces at lists.automattic.com] On Behalf Of Andy Skelton
Sent: Thursday, 4 May 2006 9:38 AM
To: wp-hackers at lists.automattic.com
Subject: Re: [wp-hackers] integrating custom search function to
additionaldatabase table

On 5/3/06, Stefan Hartweg <stefan at hartweg.net> wrote:
> My problem is, I don't know how I can make my search function talk
> so that the results (i.e. the posts that match certain values from my own
> table) get displayed on a page, using the loop?
> I don't think I can use any use filters such as posts_where, as this uses
> Wordpress' own query and not my own, or can I?

Two more filters to consider:
posts_join (along with posts_where, you can accomplish your search in one
posts_request (total control over the query, if you're daring)

wp-hackers mailing list
wp-hackers at lists.automattic.com

More information about the wp-hackers mailing list