作成者 SELECT BOX 表示
氏名は、姓、名の順に表示します。
関数 hk_func_author_select は、“共通関数”に記載します。
コード
// -------------------------------- // 作成者 SELECT BOX 表示 // -------------------------------- function hk_functions_author_select() { if ( isset( $_REQUEST['author'] ) ) $author = $_REQUEST['author']; else $author = ''; hk_func_author_select( $author ); return; } add_action( 'restrict_manage_posts', 'hk_functions_author_select' );
作成者氏名表示
氏名は、姓、名の順に表示します。
コード
// -------------------------------- // 作成者氏名表示 // -------------------------------- function hk_functions_the_author( $display_name ) { global $authordata; global $pagenow; if (( $pagenow == 'edit.php' ) || ( $pagenow == 'upload.php' )) { if ( $authordata ) return $authordata->last_name.' '.$authordata->first_name; else return $display_name; } return $display_name; } add_filter( 'the_author', 'hk_functions_the_author' );
このプログラムをお使いになる場合は、お使いになる方の自己責任でお願いします。