WordPress.org

Ready to get started?Download WordPress

Forums

Author Image
[resolved] Not for novices or the faint-hearted! (19 posts)

  1. inge12
    Member
    Posted 1 year ago #

    I installed Author Image hoping it would display the image the way Gravatars are displayed for those authors without a Gravatar image.

    It didn't work for me -- perhaps because there is a conflict with the use of gravatars?

    The reason I say this is not for novices is that it looks like a bit of coding is required to make it work correctly.

    And now that I disabled the plugin and the author for whom I wished to use this plugin has registered with Gravatar, I still only get a blank instead of the image, just as I did when Author Image was installed.

    I did all of the following:
    I disabled the plugin,
    I uninstalled the plugin
    Deleted all plugin files.
    Deleted directory apparently installed by plugin.
    Disabled "Show Avatars" and enabled it again.
    Changed settings on default avatars.

    Nothing works, and the author's gravatar still does not show up. Neither does a default gravatar show up for this author.

    I am not happy!

    Stay away from this plugin unless the author fixes the issue that does not restore original settings to blog when the plugin is disabled and deleted! (See responses to this message. If satisfactory, then my advice does not apply.)

    Oh, yeah ... I registered for the support site, but after I deleted the plugin, an attempt to login returned this message "User not found" And, yes, I have the email message that says I was successfully registered, and I used the correct email address.

    If you're good enough that you could write your own plugin, by all means try out this one!

    http://wordpress.org/extend/plugins/sem-author-image/

  2. maummad
    Member
    Posted 1 year ago #

    I have this same problem. How can I fix it?

  3. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    Greetings,

    First of all thanks for pointing out the issue with the forum registration. I had no clue it was doing that. I had just recently enabled the email confirmation to tackle the endless spamming as posting was a little bit too open. It is now working but was a bad issue for someone like yourself attempting to get support.

    I'm sorry you were having so many issues with the plugin. It is very easy to use as it simply creates a plugin to add to your sidebar or uses a one line php entry if your modifying a theme's post/page template directly.

    I think the issue simply lies in confusion about what the plugin is intended to do. It basically allows you to upload an image to a user's profile in WordPress. This is done under Users->Your Profile at the very end of the screen. The uploaded image is stored in an authors subdirectory under wp-content. There is no tie in with gravatars at all. It should not have caused any side effects.

  4. inge12
    Member
    Posted 1 year ago #

    Hi Mike,

    Thanks for answering.

    I wanted to use the plugin exactly as you described in your last paragraph.

    What makes me think that there's some kind of conflict with Gravatar images is that I had tried to use your plugin to include an image for one particular author. But I couldn't make it work. Then when I uninstalled the plugin and deleted the files, the Gravatar image still would not show up, but I got only a blank image instead of the Gravatar image.

    It's been a while, and I'll have to revisit the issue, because I would really like to be able to use the plugin.

    Note the end of my original comment: Can you assure users that if they uninstall and delete your plugin files, everything will default to native WordPress and Gravatar (if installed). That means no hooks left behind, etc. It would probably mean testing on several different setups on other computers.

  5. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    What theme are you using? I assume this is with the latest WordPress 3.5 version?

    Your uninstall comment is what is perplexing me as this plugin doesn't make any changes to the database schema nor update any other data. Once the plugin is deactivate it wouldn't be hooking into anything. There is a transient data entry. Perhaps there is a conflict with the theme or another plugin using the same name.

  6. Daragott
    Member
    Posted 1 year ago #

    I have the same problem too. I just installed the plugin, upload pictures of administrators and authors, but the pictures don't appear.

    WP-content is set 777 as you ask in the plugin page. I use Magazinum as theme for my magazine. I use Firefox as browser and the cache was cleared.

    WordPress version is 3.5.2

    You can see here the latest article published: http://x-centricmodels.com/mag/?p=5461

    Thank you for your help.

  7. inge12
    Member
    Posted 1 year ago #

    Hi Mike,

    H'mm .. .your response is interesting. Makes me wonder why I got the results I did when installing and uninstalling your plugin was all ...

    I use Weaver ii pro latest version. And Gravatar was active for the default images.

  8. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    @Daragott,

    Did you add <?php the_author_image();?> to the template for your theme?

  9. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    @inge12,

    I'll have to load up Weaver ii to see what happens. I know that theme has many options and is very configurable. Perhaps there is issue as to how the filter/hook works together.

    Mike

  10. Daragott
    Member
    Posted 1 year ago #

    @Mike Koepke

    Upss no, but where in the template I must add this?

  11. Daragott
    Member
    Posted 1 year ago #

    I ve added <?php the_author_image();?> in the template of my theme, but it does nt work. I'm not really good to do this. I suppose it was not at the good place, but I'm confused

  12. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    Can you ask a question regarding your understanding (not saying it is incorrect either) of the plugin's functionality?

    Are you looking for the author's image to be appearing in the comment replies for a page/post or the image to appear next to the page/post's title?

  13. Daragott
    Member
    Posted 1 year ago #

    Hello Mike Koepke. I want to have the image of the author of a post at the beginning of the article.

    As example, in this post, you have the name of the author, and I want the photo too: http://x-centricmodels.com/mag/?p=5461

  14. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    I'm not familiar with the theme you use. Typically you'd have an index.php or single.php file in the theme.

    In the file you'd see something like

    <?php the_title( '<h3>', '</h3>' ); ?>

    It is after this you would add
    `<?php the_author_image();?>'

  15. Daragott
    Member
    Posted 1 year ago #

    Thank you Mike for your help. In my theme, I have both files, index.php and single.php

    But none have the code you told me: <?php the_title( '<h3>', '</h3>' ); ?>

    Here is what we find in the 2 files:

    <strong>Index.php</strong>
    
    <?php get_header(); ?>
    <?php $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; // gets current page number ?>
    
     	<?php if (is_home() && $paged < 2 && option::get('featured_enable') == 'on' ) { get_template_part('wpzoom', 'slider'); } // Featured Slideshow ?>
    
     	<?php if (is_home() && $paged < 2 && option::get('carousel_enable') == 'on' ) { get_template_part('wpzoom', 'carousel'); } // Horizontal Carousel ?>
    
     	<div id="content">
    
     		<?php if ( $paged < 2 && option::get('featured_art_show') == 'on') { // Featured Article
    			get_template_part('featured', 'post');
    		} ?>
    
    		<?php if ( $paged < 2 && option::get('featured_categories') == 'on') {  // Home Categories
    			get_template_part('featured', 'categories');
    		}  ?>
    
    		<?php if ( $paged > 1 || option::get('recent_posts') == 'on') { ?>
    
    		<div class="archiveposts">
    
    			<h3><?php echo option::get('recent_title'); ?></h3>
    
    	 		<?php
    				global $query_string; // required
    
    				/* Exclude categories from Recent Posts */
    				if (option::get('recent_part_exclude') != 'off') {
    					if (count(option::get('recent_part_exclude'))){
    						$exclude_cats = implode(",-", (array) option::get('recent_part_exclude'));
    						$exclude_cats = '-' . $exclude_cats;
    						$args['cat'] = $exclude_cats;
    					}
    				}
    
    				/* Exclude featured posts from Recent Posts */
    				if (option::get('hide_featured') == 'on') {
    
    					$featured_posts = new WP_Query(
    						array(
    							'post__not_in' => get_option( 'sticky_posts' ),
    							'posts_per_page' => option::get('slideshow_posts'),
    							'meta_key' => 'wpzoom_is_featured',
    							'meta_value' => 1
    							) );
    
    					while ($featured_posts->have_posts()) {
    						$featured_posts->the_post();
    						global $post;
    						$postIDs[] = $post->ID;
    					}
    					$args['post__not_in'] = $postIDs;
    				}
    
    				$args['paged'] = $paged;
    				if (count($args) >= 1) {
    					query_posts($args);
    				}
    				?>
    
    			<?php get_template_part('loop'); ?>
    
     		</div> <!-- /.archiveposts -->
    
    		<?php } ?>
    
    	</div> <!-- /#content -->
    
    <?php get_sidebar(); ?>
    <?php get_footer(); ?>
    
    <strong>single.php</strong>
    
    <?php get_header(); ?>
    <?php $template = get_post_meta($post->ID, 'wpzoom_post_template', true); ?>
    
    <div id="content"<?php if ($template == 'full') { echo " class=\"full-width\""; } ?>>
    
    	<div id="post-<?php the_ID(); ?>" <?php post_class(''); ?>>
    
    		<?php while (have_posts()) : the_post(); ?>
    
    			<div class="meta">
     				<?php if (option::get('post_category') == 'on') { ?><?php the_category(', '); ?><?php } ?>
    				<?php if (option::get('post_date') == 'on') { ?><?php if (option::get('post_category') == 'on') { ?> — <?php } ?><?php printf('%s at %s', get_the_date(), get_the_time()); ?><?php } ?>
    				<span><?php edit_post_link( __('Edit this post', 'wpzoom'), ' ', ''); ?></span>
    			</div>
    
      			<h1 class="title"><a>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h1>
    
    			<?php if (option::get('post_author') == 'on') { ?><span class="author"><?php _e('by', 'wpzoom'); ?> <?php the_author_posts_link(); ?></span><?php } ?>
    
    			<div class="entry">
     				<?php the_content(); ?>
     				<div class="clear"></div>
       			</div>
    
      			<?php wp_link_pages( array( 'before' => '<div class="nextpage">' . __( 'Pages:', 'wpzoom' ) . '', 'after' => '</div>' ) ); ?>
    
    			<div class="after-meta">
    
    				<?php if (option::get('post_tags') == 'on') { ?><?php the_tags( '<div class="tags_list">'. __('Tags ', 'wpzoom'). '', '', '</div>'); ?><?php } ?>
    
    				<?php if (option::get('post_share') == 'on') { ?>
    					<div class="share_box">
    						<h4><?php _e('Share:', 'wpzoom') ?></h4>
    
    						<div class="share_btn"><a href="http://twitter.com/share">" class="twitter-share-button" data-count="horizontal">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script></div>
    						<div class="share_btn"><iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo urlencode(get_permalink($post->ID)); ?>&layout=button_count&show_faces=false&width=1000&action=like&font=arial&colorscheme=light&height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:80px; height:21px;" allowTransparency="true"></iframe></div>
     							<div class="clear"></div>
    					</div>
    				<?php } ?>
    
    			</div>
    
    			<?php if (option::get('post_authorbio') == 'on') { ?>
    			<div class="post_author">
    				<?php echo get_avatar( get_the_author_meta('ID'), 70 ); ?>
    				<span><?php _e('Author:', 'wpzoom'); ?> <?php the_author_posts_link(); ?></span>
    				<?php the_author_meta('description'); ?>
    			</div>
    			<?php } ?>
    
    			<div id="comments">
    				<?php if (option::get('post_comments') == 'on') {
    					comments_template();
    					} ?>
     			</div> <!--/ #comments -->
    
    		<?php endwhile; wp_reset_query(); ?>
    	</div> <!-- /.post -->
    </div><!-- /#content -->
    <?php if ($template != 'full') { get_sidebar(); } ?>
    
    <?php get_footer(); ?>


    [Please be sure to use the code buttons or backticks when posting code on the forums]

    I hope this will help you to understand my problem. Thank you.

  16. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    To have the author image show on the single page post (the page that only display 1 post but the entire post content)

    you'd edit the single.php file

    '
    <h1 class="title">" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></h1>

    <span class="alignleft"><?php the_author_image();?></span>

    <?php if (option::get('post_author') == 'on') { ?><span class="author"><?php _e('by', 'wpzoom'); ?> <?php the_author_posts_link(); ?></span><?php } ?>'

    This should put the image under the title and align it to the left.

  17. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    @inge12

    I tried this out with the Weaver ii theme. First, YIKES on that theme! Talk about endless tweaking and options to be set. I couldn't find any conflict with gravatars or the plugin.

    I was able to establish my gravatar for my login and have that show for posts (once I enabled the gravatars option under Posts Specifics). I enabled the Author Image plugin, edit my profile, upload and image and then have the image show in the sidebar. I also was able to drop the widget into the one of the Weaver widgets areas (like Blog Top widget Area) and have it show on a page.

    If you want to have the image show if no gravatar exists, you'd do something like in this forum thread. http://wordpress.org/support/topic/how-to-detect-if-theres-no-gravatar-and-pust-a-custom-message?replies=9

    <?php if(function_exists('get_avatar')) {
       if(validate_gravatar($comment->comment_author_email)){
            echo get_avatar($comment, '80');
       }
       else {
            echo get_avatar($comment, '80');
            echo '<div style="margin-left: 20px;">
             <a href="http://yourblog/minitutorial" title="How">(How?)</a> </div>';
            }
    }
    ?>

    Obviously it would be specific to how Weaver allows you to modify it's behavior, but in the else block when no gravatar is found you'd call '<?php the_author_image();?>' function. someone in the weaver forum could probably help you with the exaxt code needed.

    Mike

  18. Daragott
    Member
    Posted 1 year ago #

    Thanks Mike, but it does'nt work at all. In the past, I had the author image in the posts. May be it's due to a new version of the theme, but nothing works with it.

    And with all the plugins using JQuerry, nothing works. And the editior of the theme never gave me a sloution to resolve my problem.

    I think I gonna try to find another nice theme who will works better. Thanks

  19. Mike Koepke
    Member
    Plugin Author

    Posted 1 year ago #

    @inge12

    You've inspired me! What you originally posted about makes sense for this plugin. If I have uploaded an image for the author it should also use that as the gravatar for the author in posts and in comment submissions.

    So I've gone ahead and implemented the solution. The Author's Image becomes your gravatar as well on the site. In your case where the author didn't have a gravatar set, they can now upload a photo in their User Profile and it will be used by any theme that calls get_avatar(), like weaver ii.

    Mike

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic