Custom Field Date Problem

I agree with Denis, I don’t like using custom fields for this kind of stuff, but I’m not aware of any other way yet… What you what can be done by altering the SQL query for the loop, something like this: add_filter(‘posts_join’, ‘my_post_filter_join’); function my_post_filter_join($join) { global $wpdb; if(is_home() || is_category() || is_search()) $join .= … Read more

Only admin should be able to add a particular custom field

The way I would approach this is: Create a custom field with an underscore in front of it – Example: _rating this way it doesn’t show up in the normal custom field interface Create a meta box that manages this custom field Wrap your add_meta_box function with if(current_user_can(‘administrator’)) This will only create the meta box … Read more