Related posts by the same author

There are many plugins that offer lists of related entries but practically none offers the possibility of showing only entries of the same author of the current one something very useful in sites with external collaborations.

So if you have a site where you admit external collaborations, it will be very appreciated that, at the end of each new article, there is a list of other articles by the same author .

Getting it only takes two steps , and the first is create function for which you will have to add to your utilities plugin the following code:

// Related entries function by author

function get_related_author_posts () {

global $ authordata $ post ;

$ authors_posts = get_posts ( array ( 'author' = > $ authordata -> ID 'post__not_in' = > array ( $ post -> ID ) 'posts_per_page' = > 5 ) ) ;

] $ output = '

    ' ;

    foreach [1945902] 5] ( $ authors_posts as $ authors_post ) { [19659002] $ output . = '

  • <a href = "' . get_permalink ( $ authors_post -> ID ) . '">' . apply_filters ( 'the_title' $ authors_post -> post_title $ authors_post -> ID ) . '
  • ' ;

    } [19659000] $ output . = '

' ;

return $ output ;

}

Once you save the changes, you only have to add the following to the individual input file ( single.php ) in the exact place where you want to appear 5 related entries of the same author :

If you want to change the styles or the number of entries ( posts_per_page '=> 5 ) simply adapt the function to your liking.

Set up Google+ authorship on WordPress.com

 wordpress-google-authorship

Not always the best option is to install your own WordPress, in fact there are times when it does not matter or just you can not or you do not want. What is always of interest, and increasingly is setting up the authorship of your posts with Google+ Google's social network.

If you have a WordPress installed on your server, it's easy to add authorship of Google Plus but how to do it in WordPress.com if you can not install plugins or insert code in the themes?

Well, tranqui, which is really very simple and the steps a little …

… What is "Google Authorship" in WordPress.com? …

The basics you have to understand about the Google+ authoring process, or Google Plus, how you prefer to call it, consists of two fundamental steps:

  1. Link from your Google+ profile to the author page of your WordPress
  2. Link from your WordPress site to your Google+ user page

So let's go to it …

… 1. Link from your Google+ profile to the author page of your WordPress …

This part does not require, even in a WordPress installed on your server, to modify or add any code. You just have to identify your author page in the WordPress where you have published content .

If you have WordPress hosted on your server you can add a link to your author page but in WordPress.com, how can you not touch code, or are you looking for a theme that already has this utility or, to make sure, you can use the Authors widget.

For this you go to "Appearance -> Widgets" and you add the widget called " Authors "
 widget authors

What the widget will show in the sidebar of your theme, with the gravatar if you have it:
 widget authors in blog

Clicking on your name will take you to your author page, if you have the subject:
 author page wordpress.com

There are topics that they do not have an author's page, which would complicate things, if that were the case – for example – the subject or default WordPress (Twenty Twelve) and you will see it. In any case the really important thing is that you copy the URL of your author page which will be something like this:

http://MIWEB.wordpress.com/author/NOMBREUSUARIO/

Already have ?, Well, go to Google+ …

Go to your Google+ user page, type https://plus.google.com/112849525913645686409/about and click on the blue button labeled " Edit profile " next to your name.
 google + edit profile blue button

Go down the page to a block named " Contribute to " and click on any part of it to activate the edition. Then click on the link called " Add custom link " and enter the name you want and, importantly, paste your author URL into the WordPress.com site that you copied above.
 add url author wordpress on google +

Save and we have finished the most tedious and long part, now we have the easiest part left.

… 2. Link from your WordPress site to your Google+ user page

We return to our site on WordPress.com and go through the section of "Appearance -> Widgets" this time we add a text widget, that great friend who serves almost everything.

 widget text url author google plus in wordpress

Put the name you want, the important thing is to create a link to your Google+ profile , which would be done as follows:

I think it should not be necessary to repeat it, but go, it never hurts, remember to change the numbering of the example, which is my profile, and the name (of course) for yours.

Very important, the name should be exactly the one you have in Google Plus with the "+" in front and stuck to it, come on, follow the example

The widget, already on the site, will show the link, which will link to your Google+ profile, which is what Google needs at the end of the day. What magic does is, in addition to the first step, is the reference to ? Rel = author how can you imagine.

Save the text widget changes and you have closed the circle that Google asks for authorship . Now you just have to wait a bit, because sometimes it will take you to generate the thumbnail, and check in the web checking the " rich snippets " from Google if everything went well.
 author page google plus

Oh, and in case I forgot to say it, this is a basic for Google positioning these days.

Did you find it difficult?

NOTICE : this publication is from two years ago or more. If it's a code or a plugin it might not work in the latest versions of WordPress, and if it's a news story it might be obsolete. Then do not say we have not warned you.

Loading …

That may also help you:

Limit categories by author • WordPress Help

If you use WordPress as CMS or simply if there are several authors on your website and you want to control in which categories you can publish each type of user would surely like to limit it.

] There are several ways to get it, as far as I could find, using various plugins, so take note …

Add rel = "author" and rel = "me" in WordPress • WordPress Help

In case you did not know, Google has long since included a form of customize search results assign authorships to publications, tags HTML rel = "author" and rel = "me" .

Using these tags in your publications will show some ' snippets 'from Google more attractive than, in addition to improve your branding in the network will attract more attention in the list of results than if they did not, and consequently you will have more clicks towards your publications

By the way, by taking the URL your authorship, is also a preventive way to avoid (although some do not care) content theft.

Sufficient reasons ?, then we will add these tags to WordPress …

It's a few steps, but it's worth it:

1. Create a profile on Google+

Even if you do not like the new social network Google Plus, only SEO is worth it, so go to http://plus.google.com and create a profile. Then you go to your profile page and click on "Edit profile". On the right you will see a box called "Other profiles", click and add the name and URL of your author page on the blog.

This step, like the following one – which is related – is not Clear that it is essential (not even Google makes it clear), it is not over, so do it and period, not too late.

2. Add the URL of your Google+ profile to your author page in WordPress

It seems that Google, although it is not clear if it is mandatory, wants links to your Google+ profile. So let's do it, we have 3 ways:

  1. With plugin : Install the plugin Easy rel author plugin which adds one more field to the user profile page, in which to include the URL of Google+ and then it will be displayed on the author's page
  2. With ñapa : If you do not want to install the plugin you can do something as simple as, in the user's Web field, put the one of your Google profile plus instead of your blog or similar.
  3. With function : I already explained how fields are added or removed from the user profile , but here you have it simplified and adapted. Just add this code to the file functions.php or to your function plugin. You get the same as with the previous plugin:

3. Link to your Google+ profile by adding rel = "me"

Whenever you link to your Google+ profile, add tag rel = "me" . For example:

It does not matter if it is from an icon added in your sidebar or in an entry, always add the tag rel = "me"

Another possibility is a blogroll link or a personalized menu, in both cases you should add the link relationship XFN, and indicate in the field to the effect "me".

Finally, another great place to add the rel = "me" in a link to your Google profile is in your file humans.txt which Google recognizes as valid for these purposes.

4. Link to your WordPres author page by adding rel = "author"

Similarly, whenever there is a link to your author page in your active topic, add the tag rel = "author" . For it you must modify (and if you use it you add it) to the link to the profile of the author of the entry – normally in 'single.php' or 'index.php' – the tag in this way:

5. Link to your Google+ profile on the author or other page

On the author page, usually author.php you have to add a code to show the link to your Google + profile, this :

You can also add a box with your profile, and link to your profile on Google+, using the plugin rel = author which adds it automatically.

6. Check that it works

You just have to check that everything went well, and if you do not want to wait for Google to update the snippets of your publications, you can test if you've done well in the verification tool "Rich snippets" from Google . Simply type the URL of an entry on your site, or your author page, and you should see the image of your Google+ profile next to the snippet.

By the way, if you are missing something, this tool will tell you the errors and what you have to do to fix it.


If all the above seems too messy you can try the plugin Googleplus author connect which promises to get these beautiful snippets just by installing and activating it.

References:

NOTICE : this publication is from two years ago or more. If it's a code or a plugin it might not work in the latest versions of WordPress, and if it's a news story it might be obsolete. Then do not say we have not warned you.

Loading …

That may also help you: