• Resolved Tom

    (@tomasz_b)


    How exactly should I use the template function get_comment_author_twitter_url($comment_id) to make the avatar link to the Twitter profile?

    My comments.php contains:

    <h2>Comments</h2>
    	<ol id="comments">
    		<?php foreach ($comments as $comment) : ?>
    
    		<li id="comment-<?php comment_ID(); ?>" class="<?php echo $altcomment; ?>">
    
    			<div class="gravatar">
    				<?php if (function_exists('get_avatar')) {
    					echo get_avatar(get_comment_author_email(),'40');
    				} ?>
    			</div>
    
    			<div class="the_comment">
    				<p><?php comment_author_link(); ?><br />
    				<span class="small-text"><?php comment_date('F d, Y'); ?></span></p>
    				<?php comment_text(); ?>
    			</div>
    
    		</li>
    
    		<?php
    			if ($altcomment == 'alt') {
    				$altcomment = '';
    			} else {
    				$altcomment = 'alt';
    			}
    		?>
    
    		<?php endforeach; ?>
    	</ol>

    http://wordpress.org/extend/plugins/twitter-avatar-reloaded/

Viewing 1 replies (of 1 total)
  • Plugin Author Sudar Muthu

    (@sudar)

    Inside the for loop you can call the function using the following code.

    get_comment_author_twitter_url(comment_ID())

Viewing 1 replies (of 1 total)
  • The topic ‘Make avatar link to Twitter profile’ is closed to new replies.