Log in
You shouldn't have to be an expert to be safe on a computer.

Home

Guides

Seminars

Tips and Tricks

About Jsearch2

Saturday, May 21st, 2011 (10 comments)

Why Jsearch

The original inspiration for Jsearch was a page where I wanted to upload many pictures and then be able to find them by combining categories to get just the right picture. Imagine my disappointment to find out that you couldn't combine anything in WordPress!

Since I couldn't find any plugins that solved the problem, I wrote up a little hack that used the query_posts function of WordPress which has the power to combine multiple terms, categories and tags for advanced searches, but isn't utilized by standard WordPress functions.

At first I created only a bunch of checkboxes next to the category listings to allow multiple category search, but I realized that if there were a user-friendly front-end to the query_posts function, I could do a lot more.

The next two iterations of the search worked on this principle and tried to make a simple to use and pretty interface that allowed the selection of search criteria and fed it into query_posts. The first was an ugly mess and the second was prettier (since I learned to use Jquery) and more robust, but still clunky in many ways.

My first attempt at making it all work. Consider it a beta.
My first attempt at making it all work. Consider it a beta.
Version 1 is nice looking, but big!
Version 1 is nice looking, but big!

Version 2

Version 2 was a major upgrade for several reasons. First, I simplified and minimized the interface. Version 1 is what I used to learn Jquery, but in version 2 I actually used it effectively:

A lot, LOT tighter!
A lot, LOT tighter!

V2 also gets rid of the need to "generate a url". Because I tried to get fancy and use AJAX instant updating, the search was complicated to bookmark and wouldn't navigate well (when paging, you couldn't hit the back button and have it go to a previous page). I abandoned that idea and went to straight page reload for each search.

A major improvement to v2 is based on the query. Until now, I had used the WordPress search functions in order to maintain compatibility and to avoid having to do the work of creating queries myself!

This time, I stopped whining and dug deep to remember how to do advanced queries and found it to be much simpler than I remembered. I won't promise that the new query is faster than what WordPress offers, but it now searches both page/post comments and custom taxonomies!

You're welcome :)

Focus on Usability

In every iteration, I've used the feedback and experience I've received and finally decided on this design:

Jsearch v2.5 - The best I could come up with to date.
Jsearch v2.5 - The best I could come up with to date.

Besides streamlining the search dynamics between keywords and categories and tags, this is easier and faster to use in nearly every way.

More than anything, I tried to make it as simple to use and understand as possible.

A final word

So in v2.5 I finally feel comfortable releasing this as a real plugin on the WordPress page and will probably do so eventually. For people who've been using it through the iterations and seen what I've done, they know I don't necessarily fix or update too often, though I try as hard as I can.

If you do find something that needs to be fixed or updated or would like to request additional functionality, just let me know in the comments. I can't promise speed, but as others have learned, good things come to those who wait (click Jsearch Setup below to download and install Jsearch).

Seminars and Guides

Sick of Identity theft?

CLICK HERE

Want to be safe online?

CLICK HERE
Work With Jeremy

Inquire about

Seminars

Conferences

Consultation

Private Tutoring

Classes

Support the Geek

If you hate ads as much as I do, please consider supporting us by donating or browsing our recommended products


Recommended Products and Services
Quick Tips:
IDENTITY THEFT
PRIVACY
INTERNET SAFETY
PASSWORDS