On the blog center, click to share articles to social media using a plugin called Sharebar, and in this article I will provide a tutorial on how to add google + in the sharebar plugin, why only Google+, because this plugin by default includes adding other social buttons such as facebook and twitter. I do not recommend this plugin for you, because the developer hasn’t updated it for 2 years.
What is Sharebar?
Sharebar is a plugin that is used to share articles or share on social media. If you open one of the articles on the blog center, click, of course, you will see the social share button to the left of the article, and when you scroll down and up the plugin will follow and float. This plugin is also adapted for mobile, if accessed via a smartphone, the button will automatically be under the article title.
I have seen a lot of plugins for social sharing, some are premium and also free, for sharebar of course it’s free and more than enough for you to use. But if you are not interested in this plugin, you can also use other plugins which I think are very good and recommended. Floating Social Bar.
Install and activate Sharebar as you would any other plugin. You can download the sharebar directly from WordPress.org here.
This plugin offers a number of social share buttons by default. For each social share button there are two button options: one ‘Big button’ button to display a button on the left or right of your page container, and a ‘Small button’ button that will be displayed under your title when accessed on a smartphone or smartphone size. tablet.
There are a number of other configuration options available in the ‘Settings’ tab that you can use to customize colors and presentation.
Added Google +1 Button for Sharebar
Google provides four button options through its webmaster pages. namely the Small, medium, standard and tall buttons. For the sharebar we use Tall for Big buttons and Medium for Small buttons.
Big Button Sharebar
Small Button Sharebar
You can get the code directly from google directly by visiting the address here
To install on your site, copy the following code and put it in the header.php of the wordpress theme that you use in:
<script src="https://apis.google.com/js/platform.js" async defer></script>
Then copy the following code and put it in the sharebar plugin:
Big Button Code:
<div class="g-plusone" data-size="tall"></div>
Code Small Button:
<div class="g-plusone" data-size="medium"></div>
Enter the code above so that it looks like the image below in your sharebar plugin.
Here is a tutorial for adding google plus to the sharebar plugin, hopefully it’s useful for all of you. 🙂