Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm working on a them theme that is search-heavy, and my users are putting huge priority on an improved search function.

I think I will have to use a special direct query to search these things:

  1. Terms
  2. Title
  3. Content

And allow flexibility such as:

  1. Word fragments (search bread, finds wonderbread)
  2. Phrases (search Orange Man, returns post with man in title, orange in terms)

Without asking anyone to re-invent the wheel, I was wondering if any such direct query example existed that I can modify to the needs of my custom post type (and possibly taxonomy).

I have no doubt many have wondered the same thing in various projects.

share|improve this question
    
You start off talking about a theme, and then ask about a custom post type, which you haven't described. Regardless, this question is, at core, an SQL one. –  vancoder Apr 16 '13 at 21:32
    
You could always go the route of an out-of-the-box solution, with a plugin I've had great results with this one: wordpress.org/extend/plugins/relevanssi –  NW Tech Apr 22 '13 at 19:30
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.