Ads

Latest News

Sunday, 22 March 2015

Social Content Locker for Blogger

Social Content Locker for Blogger

social-content-locker-for-blogger
Do you have a feeling that they completely ignore whether your website has traffic or not. Well, in that case you have to drive your readers to like or share your page in order to discover your content. This is likely the best means to increase your social traffic, especially for those design sites that shares free resources.
Locking the entire page by some pop up probably the worst idea because this fails to showcase the importance of your content. That's why this locker is designed to lock a specific part of your page instead of the entire page. It can lock any part of your webpage and can be implemented infinite times on a single page. You can even change the appearance of this locker to your custom style.  

Before you proceed to make any customization in your blogger template, it is recommended to backup your blog in case something goes wrong.

 Let's start.
Step 1:
Go to 'Template' and click 'Edit HTML'.
social-content-locker-for-blogger



Step 2:
Make sure whether jQuery library is already included in your blog. If not, search for (Ctrl+f) <head> and write down the following line just below <head>.


<script src='http://code.jquery.com/jquery-1.10.2.min.js' type='text/javascript'/>
Step 3:
Now search for (Ctrl+f) </head> and paste the following code before </head>.










Customization

Buttons
    There are seven buttons available for content locking. These are,
social-content-locker-for-blogger
     
     You can apply any number of buttons for your site. You can even change the order of these buttons in the order:[] option (index 8 of the code). Separate each button by a comma (,).
    Remember, for every button you inserted, you have to provide an URL link of your social media page. However for buttons of similar type like "facebook-like" and "facebook-share", you may provide only one link. For instance, my facebook page is https://www.facebook.com/infopoint11 which I can use for both "facebook-like" and "facebook-share" buttons.



Text

This section consists of two sub-sections. These are "header" and "message"; "message" appears under the "header". You can modify the content of these two sub-sections of your own or you can leave these fields empty. Detailed description of "header" and "message" is depicted below (index 15 and 16 of the code).

header
social-content-locker-for-blogger-1



message
message-social-content-locker-for-blogger

Theme
This specifies the visual aspect of your locker. There are five predefined locker themes available. You can select any of the following styles (index 20 of the code).

secrets
theme-secrets-----social-content-locker-for-blogger

dandyish
theme-dandyish-----social-content-locker-for-blogger

 flat
theme-flat-----social-content-locker-for-blogger

glass
theme-glass--------social-content-locker-for-blogger
 starter
theme-starter-----social-content-locker-for-blogger

Additional Customization

Timer 

A countdown timer will be displayed if you choose any integer value. For instance, if you want to close your social locker after 300secs, you can insert timer: 300 in your code. A 0 value of timer indicates infinite time (index 19 of the code). 
 
set-timer----social-content-locker-for-blogger

Close

Change your code from close: false to close: true in order to display a close icon at the corner of your locker (index 19 of the code). 
close----social-content-locker-for-blogger






Now whenever you are interested to display social content locker in your blog post, wrap your code within this snippet of code.


<article id="default-usage">
 <div class="to-lock" style="display:none;">
  -- Hidden Content Starts --
 </div>
</article>


Update

Facebook Share Button
A lot of people have been asking me that they are having problem whenever they are trying to implement Facebook share button. Well, first I have to clarify that Facebook share button does not work the way as Facebook like button. For integrating Facebook like button in your website pages you don’t need an App ID, a unique identifier for your website, but for integrating Facebook share button App ID is must required.  

Get a Facebook App ID for your website. Follow the steps carefully and comeback when you're done.

Once you have your App ID, you can insert it in your code. In order to do this, change the facebook option as follows.  

facebook: {
  appId:1234567890, //write your actual App ID
  url:"https://www.facebook.com/infopoint11", //replace with your Facebook url
},
 
 But wait. What if your Facebook like button and share button url are not the same.

Different URL for Facebook

Well, fortunately this also possible with social content locker. You have to declare url twice. For example, write the facebook option as follows.

facebook: {
  like:{
    url:"https://www.facebook.com/infopoint11" //replace with your Facebook url
  },
  share:{
    appId:1234567890, //write your App ID,
    url:"http://infopoint11.blogspot.com", //replace with your blog name
  },
},

You got it, right? But wait again. What if your like button url remains same all the time but your share button url is dynamic and it is same as your blog current url.

Dynamic URL for Facebook



For this purpose you have to declare a variable where you can pass your current blog url and write that variable in facebook share section. Sounds dumb, right? Well if you are familiar with web designing you would probably understand what I'm talking about. But the purpose of this blog is to provide code for everyone. So the entire code is written below (for this last customization only).


<script type='text/javascript'>
  //<![CDATA[
jQuery(document).ready(function ($) {
  $('#default-usage .to-lock').sociallocker({
    var current_url = $(location).attr('href');
    buttons: {order:["facebook-like","facebook-share","google-plus"]},
    facebook: {
      like:{url:"https://www.facebook.com/infopoint11"},
      share:{appId:1234567890, url:current_url},
    },
    google: {url:"https://plus.google.com/+infopoint11Blogspot"},
    text: {
      header: "Like us To Unlock This Content",
      message: "This content is locked. Like us on Twitter, Facebook or Google plus to unlock it."
    },
    locker: {close: false, timer: 0,},
    theme: "secrets"
  });



Hope your problems will be solved by now.
Credit
This awesome widget is created by Onepress-media for Wordpress blog.

I tried my best to keep things as uncomplicated as possible. Any type of question related to this will be appreciated.
Happy Blogging.
  • Blogger Comments
  • Facebook Comments

5 comments:

  1. Thank u infopoint11 for this amazing,helpful trick, i will definitly try it on my blog

    ReplyDelete
  2. This comment has been removed by the author.

    ReplyDelete
  3. Savvy post . Incidentally , if your business is wanting a a form , my boss saw a sample form here http://pdf.ac/5Arwo6.

    ReplyDelete
  4. for the best coupons and deals you can go on paybackdollar.Paybackdollar have more then 5000 store of the world
    and paybackdollar have the best quality and quantity. if your inerested go on givining link
    coupon code

    ReplyDelete

  5. anthropologie free shipping


    Thanks for sharing this amazing article, it is very informative post good work keep it up.

    ReplyDelete

Item Reviewed: Social Content Locker for Blogger Description: Social content locker for blogger. Lock your content and unlock it by social media likes or share. Grow your social media audience by this blogger trick. Rating: 5 Reviewed By: Felicity Smoke
Scroll to Top