WordPress.org

Support

Support » Plugins and Hacks » Adding co-authors Bio, Avatar & Link but the link to be on the profile of author

Adding co-authors Bio, Avatar & Link but the link to be on the profile of author

Viewing 5 replies - 1 through 5 (of 5 total)
  • <?php foreach( get_coauthors() as $coauthor ) : ?>
    <div id="authorinfo" class="columns alpha omega marT30 marB20">
        <a href="<?php echo $coauthor->user_url; ?>"><?php echo get_avatar( $coauthor->user_email, '80' ); ?></a>
        <h5 class="marB10"><?php _e('By', 'contempo'); ?>: <a href="<?php echo $coauthor->user_url; ?>"><?php echo $coauthor->display_name; ?></a></h5>
        <p><?php echo $coauthor->description; ?></p>
            <div class="clear"></div>
    </div>
    <?php endforeach; ?>

    Ok so this is the code what i need is to get this function that i got from template tags

    function coauthors_posts_links( $between = null, $betweenLast = null, $before = null, $after = null, $echo = true ){
    return coauthors__echo(‘coauthors_posts_links_single’, ‘callback’, array(
    ‘between’ => $between,
    ‘betweenLast’ => $betweenLast,
    ‘before’ => $before,
    ‘after’ => $after
    ), null, $echo );
    }

    Can anyone help?

    <?php foreach( get_coauthors() as $coauthor ) : ?>
    <div id="authorinfo" class="columns alpha omega marT30 marB20">
        <?php echo get_avatar( $coauthor->user_email, '80' ); ?>
        <h5 class="marB10"><?php _e('By', 'contempo'); ?>: <?php coauthors_posts_links(); ?></h5>
        <p><?php echo $coauthor->description; ?></p>
            <div class="clear"></div>
    </div>
    <?php endforeach; ?>

    So far i came up with this but the avatar i cannot get it correctly linked

    please anyone some help?

    and also there is the avatar and under it the names!

    it should be avatar,name of autor,bio of author and on next line second author and third and so on and also avatar image and name linked
    to coauthors_posts_links page

    <?php foreach( get_coauthors() as $coauthor ) : ?>
    <div id="authorinfo" class="columns alpha omega marT30 marB20">
        <?php echo get_avatar( $coauthor->user_email, '80' ); ?>
        <h5 class="marB10"><?php _e('By', 'contempo'); ?>: <?php echo(coauthors_posts_links_single($coauthor)); ?></h5>
        <p><?php echo $coauthor->description; ?></p>
            <div class="clear"></div>
    </div>
    <?php endforeach; ?>

    Still problematic ! ouf anyone out there?

    <?php foreach( get_coauthors() as $coauthor ) : ?>
    <div id="authorinfo" class="columns alpha omega marT30 marB20">
        <?php echo get_avatar( $coauthor->user_email, '80' ); ?>
        <h5 class="marB10"><?php _e('By', 'contempo'); ?>: <?php printf('<a href="%s" title="%s" rel="author">%s</a>',
        get_author_posts_url( $coauthor->ID, $coauthor->user_nicename ),
        sprintf( __( 'Posts by %s', 'co-authors-plus' ), $coauthor->display_name ),
        $coauthor->display_name
        ); ?></h5>
        <p><?php echo(substr($coauthor->description, 0, 140) . sprintf(' <a href="%s" title="Read more" class="bio-readmore">%s</a>',
        get_author_posts_url( $coauthor->ID, $coauthor->user_nicename ),
        "Read more"
        )); ?></p>
            <div class="clear"></div>
    </div>
    <?php endforeach; ?>

    I managed but i could not link the avatar also… can someone please help here and if any better ways of doing this i am open to suggestions!

    CAN ANYONE HELP HOW TO MAKE THIS BETTER???????????

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Adding co-authors Bio, Avatar & Link but the link to be on the profile of author’ is closed to new replies.