サポート » 使い方全般 » wp_list_authors() に the author meta を加えて表示させたい

  • author一覧表示に、user_url,descriptionなどを表示させたいのですが可能でしょうか

    宜しくお願いします

1件の返信を表示中 - 1 - 1件目 (全1件中)
  • トピック投稿者 shiro99

    (@shiro99)

    http://665-667.com/2010/01/26/014216
    を参考に

    $users = get_users_of_blog();
    foreach ( $users as $user ){
    	//デフォルトの管理者adminは表示しない。
    	if(!($user->ID == 1 && get_the_author_meta('user_level',$user->ID) == 10)) {
    		//User Photo を設定している場合
    		if(userphoto_exists($user)){
    			$iconalt = get_the_author_meta('user_url', 'nickname', $user->user_id);
    			//投稿者別アーカイブのパス
    			$link = get_author_posts_url($user->user_id);
    			$userlist=get_users_of_blog();
    			//ユーザ表示名とサイトURLを表示
    			foreach ( $userlist as $user) {
    			//the_author_meta( 'user_nicename', $user->ID);
    			the_author_meta( 'user_url', $user->ID);
    			//width,height 50pxで表示
    			$img = '<img src="'.userphoto_path($user->ID).'" width="50" height="50" alt="'.$iconalt.'" />';
    			echo '<a href="'.$link.'">'.$img.'</a><br />';
    			}
    		}
    	}
    }

    と書きましたが、adminの空画像が表示されるのと、urlをlinkさせたいです

    宜しくお願いします。

1件の返信を表示中 - 1 - 1件目 (全1件中)
  • トピック「wp_list_authors() に the author meta を加えて表示させたい」には新たに返信することはできません。