Statistics for blogger without any third party plugin 2016
Hey guys, Today I’ll share the Statistics Widget for blogger [Modification of Default Blogger Stats Widget] like screenshot.
Features
- Total number of posts
- Total number of Comments
- Total number of page-views
Step by step guide
You won’t required any technical knowledge to implement this trick. just follow the steps below:
- First open blogger.
- Select Layout and click on Add a Gadget.
- Now select Blog’s stats and add it.
- Now select Template and click on backup/restore and backup the Template, and close that pop-up.
- Now click on edit HTML, and click on Jump to widget button and select Stats1 widget.
[post_ads]
- Replace the stats1 code with below code.
<b:widget id='Stats1' locked='false' title='' type='Stats'> <b:includable id='main'> <b:if cond='data:title'><h2><data:title/></h2></b:if> <div class='widget-content'> <ul> <li> <h4 id='Stats1_totalPosts'>&hellip;</h4> <span>Posts</span> </li> <li id='totalComments'> <h4 id='Stats1_totalComments'>&hellip;</h4> <span>Comments</span> </li> <li id='totalCount'> <h4 expr:id='data:widget.instanceId + "_totalCount"'>&hellip;</h4> <span>Pageviews</span> </li> </ul> <script type='text/javascript'> //<![CDATA[ function totalPosts(json){document.getElementById('Stats1_totalPosts').innerHTML=json.feed.openSearch$totalResults.$t};function totalComments(json){document.getElementById('Stats1_totalComments').innerHTML=json.feed.openSearch$totalResults.$t};document.write('<script type=\"text/javascript\" src=\"/feeds/posts/default?alt=json-in-script&max-results=0&callback=totalPosts\"><\/script><script type=\"text/javascript\" src=\"/feeds/comments/default?alt=json-in-script&max-results=0&callback=totalComments\"><\/script>'); //]]> </script> </div> </b:includable> </b:widget>
- Now Press Ctrl + F and search for ]]></b:skin> tag.
]]></b:skin>
- Now paste the below code before the
]]></b:skin>
tag.#Stats1 ul{margin:0px 0;border:0;padding:0} #Stats1 li{display:inline;width:28%;margin:0;border:0;background-color:#fff;background:#0090D5;color:#fff;float:left;padding:5px 7px;text-decoration:none;text-shadow:none;margin:0 1px 1px 0;font-size:12px;list-style-type:none} #Stats1 h4{margin:0;font-size:18px;line-height:1.2em;color:#fff;text-shadow:none} #Stats1 span{font-size:12px;color:#fff;text-shadow:none} #totalComments{background-position:0 -68px} #totalCount{background-position:0 -136px}
You can change the background. For color code click here
- Save the template.
- Now check the blog Statistics.
Thanks guys, I hope you enjoyed the post, please do comment and share the post.
COMMENTS