Change page title in admin area

add_filter(‘admin_title’, ‘my_admin_title’, 10, 2); function my_admin_title($admin_title, $title) { return get_bloginfo(‘name’).’ • ‘.$title; } You could also do a str_replace on $admin_title to remove “— WordPress” and change “‹”. Look at the top of the wp-admin/admin-header.php file to see what is going on by default.

How to change the case of all post titles to “Title Case”

Updating the posts $all_posts = get_posts( ‘posts_per_page’ => -1, ‘post_type’ => ‘post’ ); foreach ( $all_posts as $single ) { wp_update_post( array( ‘ID’ => $single->ID, ‘post_title’ => to_title_case( $single->post_title ) // see function below )); } Converting a string to “Title Case” And, while not pertinent to WP, for the sake of completeness: function to_title_case( … Read more

query_post by title?

functions.php <?php add_filter( ‘posts_where’, ‘title_like_posts_where’, 10, 2 ); function title_like_posts_where( $where, $wp_query ) { global $wpdb; if ( $post_title_like = $wp_query->get( ‘post_title_like’ ) ) { $where .= ‘ AND ‘ . $wpdb->posts . ‘.post_title LIKE \’%’ . esc_sql( $wpdb->esc_like( $post_title_like ) ) . ‘%\”; } return $where; } ?> Then: $args = array( ‘post_title_like’ => … Read more

Change “Enter Title Here” help text on a custom post type

There is no way to customize that string explicitly. But it is passed through translation function and so is easy to filter. Try something like this (don’t forget to change to your post type): add_filter(‘gettext’,’custom_enter_title’); function custom_enter_title( $input ) { global $post_type; if( is_admin() && ‘Enter title here’ == $input && ‘your_post_type’ == $post_type ) … Read more

How Do I Set the Page Title Dynamically?

There is no documentation on it but you could always apply a filter to the_title like this: add_filter(‘the_title’,’some_callback’); function some_callback($data){ global $post; // where $data would be string(#) “current title” // Example: // (you would want to change $post->ID to however you are getting the book order #, // but you can see how it … Read more