How to filter post listing (in WP dashboard posts listing) using a custom field (search functionality)?

I coded a plugin just for that and never got around to publish it : Usage: In the dropdown you have a list of all custom fields, so just select the field you want to filter by and click filter. if you want to filter to a specific value of a custom field then select … Read more

Custom query with orderby meta_value of custom field

You can define the meta key for orderby parameter using the old method (I tested on WP 3.1.1)… query_posts( array( ‘post_type’ => ‘services’, ‘order’ => ‘ASC’, ‘meta_key’ => ‘some_key’, ‘orderby’ => ‘meta_value’, //or ‘meta_value_num’ ‘meta_query’ => array( array(‘key’ => ‘order_in_archive’, ‘value’ => ‘some_value’ ) ) ) );

Add filter menu to admin list of posts (of custom type) to filter posts by custom field values

Simple to do, first create the dropdown with just the meta values you want and then catch the submit of the filter, just change POST_TYPE to the name of your post type and META_KEY to the name of your meta key: <?php /* Plugin Name: Admin Filter BY Custom Fields Plugin URI: http://en.bainternet.info Description: answer … Read more