Today spell looking at Google Webmaster Tools, I came across some 404 pages on . Being curious, I proceeded to run across which pages does Google written report equally "Not Found" too I came across a foreign URL, i which I bring never seen associated amongst a Blogger blog. The URL which Google reported equally non beingness establish was equally follows:-
- https://moulinxrouge.blogspot.com/ related-content.g?q=
Update: Blogger has disallowed the related-content.g?q= page through robots.txt. It volition no longer live anything worth worrying about.
When I checked on to run across which pages linked to this page, I was surprised to run across that almost all of the pages on this spider web log had links pointing to this page. As I did non retrieve placing such a link, I checked the root code of my blog. Strangely, I discovered a novel fight of JavaScript added to it. The script which was added is equally follows:-
Anyone having basic cognition of Java would empathize that this code is for generating contextually related posts for blogger. So, this indicates that afterward launching the mobile supported themes, the Blogger evolution squad is hold out off to add together some other novel too ofttimes demanded characteristic inwards Blogger, too gladly it is i that volition tending bloggers to trim back bounce charge per unit of measurement too display to a greater extent than appropriate related posts.<script type="text/javascript"> role setAttributeOnload(object, attribute, val) { if(window.addEventListener) { window.addEventListener("load", function(){ object[attribute] = val; }, false); } else { window.attachEvent('onload', function(){ object[attribute] = val; }); } } role showRelatedContent() { var el = document.getElementById('related-frame'); if (el.style.visibility = 'visible') { return; } el.style.visibility = 'visible'; el.src = 'related-content.g?q=' /* insert URL hither */; showRelatedContent.prevOnClick = document.onclick; // Hide related-content dropdown when clicking anywhere exactly on it. document.onclick = function() { var el = document.getElementById('related-frame'); if (el.style.visbility != 'hidden') { el.style.visibility = 'hidden'; } document.onclick = showRelatedContent.prevOnClick; }; } </script>
Investigating further, I bring come upwards to know that each spider web log hosted on Blogger has received this novel fight of code implying that this characteristic would live made populace whatever fourth dimension soon.
Meanwhile, yous tin utilisation the related posts widget I bring employed here.
Steps:-
1. Just, re-create too glue this CSS inwards your pattern earlier </head>.
2. Copy too glue the code below nether <data:post.body/>.
<b:if cond="data:blog.pageType == "item"">
<style type="text/css">
#related-posts{float:center;text-transform:none;height:100%;min-height:100%;padding-top:5px;padding-left:5px}
#related-posts .widget{padding-left:6px;margin-bottom:10px}
#related-posts ul{list-style-type:none;margin:0 0 0px 0;padding:0px;text-decoration:bold;font-size:12px;text-color:#000}
#related-posts ul li{background:transparent url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiuw8qZzPEO0TncJSGIEil9aKsbCevxfIg8JIpmtlP2IoOgNZ8JbGmbsyOZrkEU7DDZ50hMC8mvszRoJ-SUgg_r69YlBEKOj8WBmPGDaRwVpvq5Ko_uu1cF_OFtRxsYokrfXf5CMpMnfYM/s200/greentickbullet.png)
no-repeat;display:block;list-style-type:none;margin-bottom:13px;padding-left:30px;padding-top:0px}
#related-posts .widget h2, #related-posts h2{font-size: 12px;font-weight: bold;margin-bottom:0.75em;margin-top: 0em;padding-top: 0em;}
</style>
<script type="text/javascript">
var relatedpoststitle="You powerfulness too like:";
</script>
<script src="http://blogergadgets.googlecode.com/files/related-posts-for-blogger.js" type="text/javascript">
</b:if>
<b:if cond='data:blog.pageType == "item"'>
<div id='related-posts'>
<b:loop values='data:post.labels' var='label'>
<b:if cond='data:label.isLast != "true"'>
</b:if>
<b:if cond='data:blog.pageType == "item"'>
<script expr:src='"/feeds/posts/default/-/" + data:label.name + "?alt=json-in-script&callback=related_results_labels&max-results=6"' type='text/javascript'/></b:if></b:loop>
<script type='text/javascript'>
var maxresults=5;
removeRelatedDuplicates(); printRelatedLabels("<data:post.url/>");
</script>
</div>
</b:if>
3. Save the template too apply the changes.
No comments:
Post a Comment