Replace Gravatar with img URL for avatars

Unless I have misunderstood your question to accomplish a custom gravatar to use in your theme add the code below to your functions.php or into a custom plugin. From there customize the title and the image you want to use. See screenshot below for the finished outcome. add_filter( ‘avatar_defaults’, ‘dev_designs_gravatar’ ); /** * Display a … Read more

Remove /author/ from the author profile url

Essentially, you can’t do that because you’ve overlapped the “page” and “author” sections in the namespace. See, with your setup, then given a URL like http://example.com/whatever, WordPress has no way to distinguish whether “whatever” is an author or a Page. To do this, you’d need to add a lot more code to add extra querying … Read more

How To Remove The Author(s) From Certain Posts

A quick fix would be to use WP’s body class and in your stylesheet target the element containing the autor name to hide it for the page(s) you want. For example : .page-id-227 #my_authors{ display: none } Update : Another solution would be to use conditional tags in your templates, to print the author names … Read more

Get the comment author ID by the comment ID

you should use it: <?php get_comment( $id, $output ); ?> Return comment_ID (integer) The comment ID comment_post_ID (integer) The post ID of the associated post comment_author (string) The comment author’s name comment_author_email (string) The comment author’s email comment_author_url (string) The comment author’s webpage comment_author_IP (string) The comment author’s IP comment_date (string) The datetime of the … Read more

Get only the author profile picture image url inside a loop

Putting the following inside loop should fulfill your needs: <?php $get_author_id = get_the_author_meta(‘ID’); $get_author_gravatar = get_avatar_url($get_author_id, array(‘size’ => 450)); if(has_post_thumbnail()){ the_post_thumbnail(); } else { echo ‘<img src=”‘.$get_author_gravatar.'” alt=”‘.get_the_title().'” />’; } ?>

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)