search posts

Canine: WordPress Custom Searches

The WordPress search by default looks through the title and content of all available posts and pages for given query words. But sometimes you might want to only search a certain category or search custom fields or some other criteria. On the Canine Lifeline site, we have a dog section where we want to be able to list dogs based on a number of parameters, such as age, gender, adoption status, et cetera. We are currently storing dogs as posts in a particular category, and using Magic Fields to add custom fields for various aspects of each dog.

WordPress sends search queries as GET requests from its search form. The “s” variable contains the search query, but others are allowed. In fact, if you’re familiar with the “query_posts” function, many of the parameters for that are available, and the rest can be enabled, because the search is basically just a regular WordPress query with parameters appended from the GET variables.

Continue reading post "Canine: WordPress Custom Searches"

WordPress.com: Webmaster Tools and Site Explorer

I’ve been using Google’s Webmaster Tools and more recently Yahoo’s Site Explorer for my other sites.  They allow me to see crawl errors, keywords and some query ranking info, crawl statistics, and some other search engine related info as well as set some settings for how these engines handle my sites.

Because of the way these sites validate ownership of submitted sites (an uploaded file or a meta tag), I didn’t think I’d be able to use them with WordPress.com.  However, with a little searching, I found this page, which says how to do it.  In fact, had I payed more attention when exploring the admin section of my account, I might have noticed that the capability is built into the “Tools” page.

You just submit the URL like for other sites, then choose to validate with the meta tag.  Copy the meta tag and paste it into a specified field in that “Tools” page.  “Save Changes” and then press the validate button on Google or Yahoo.

This worked instantly on Google.  For some reason, Yahoo is just saying “Failed”.  Since it says it may take 24 hours to validate, I guess I’ll have to wait.  You’d figure a message other than failed would be used to say that it hasn’t been validated yet, but I’ve looked at the source of the page and verified the meta tag was there.

[Update 1/24/10] Finally Yahoo has validated by retrying. I had done this a few times spaced out after the initial setup, but it had just failed. I’m not sure why it finally worked. [update]