Hello and welcome dear Bloggers !
Thanks for being on our site InfoByAK where we share important articles on how to blog on blogger and wordpress. Today's tutorial is about Blogger platform where we can create a free blog using a free subdomain blogspot.com
Whether we purchase a custom domain name or Top Level Domain name (TLD) for our blog but most of the bloggers face an issue of blogger URL that consist the month and year of post publishing which is not a positive point for the blog future. I learnt this thing just 5 days ago that how can I remove date from my blogger post URL. Whenever I used to share my blog posts on Social Media it was so irritated for me because it increases the length of the post URL which I never liked. I visited so many blogs on Technical Solutions and analysed one thing on their blogs that one which blog is created on WordPress their post link is so clear. I thought of it and wished to do the same on my site. So I searched on YouTube for a video that could help me to do this but no use. I thought that it's not possible for me because I am running my blog on blogger. One day I asked one of my friends who is in blogging since last 5 years he sent me a code to put into my blogger HTML coding and I did the same. I was so happy to see my blog posts links without date and .html
It helped me to shorten my blog post links and make them like a wordpress posts. Let me show you the demo of this amazing trick. Before I applied the code into my blogger template the URL one of blog posts was :-
https://www.infobyak.ga/2018/10/create-web2apk-free-of-cost.html
After I put the code into blogger template it became so cool :-
https://www.infobyak.ga/create-web2apk-free-of-cost
Let's suppose you have a well reputed blog on Blogger or WordPress where you composed number of posts and some of them have ranked on Google's first page but after 2-3 years when someone looks your blog post link they don't open it thinking that it was an old post. So if they don't see any date including in a post link they don't mind that the post is older or new. Another thing is that long blog post link is not considered good therefore a lot of bloggers use URL shortner to attract and make click the link.
Remove date and .html from blog post link
Here I am gonna give you an HTML code which you have to embed in your blogger template. Copy this code and paste under <head> tag
<script type="text/javascript">
//<![CDATA[
// BloggerJS v0.3.1
// Copyright (c) 2017-2018 Kenny Cruz
// Licensed under the MIT License
var urlTotal,nextPageToken,postsDatePrefix=!1,accessOnly=!1,useApiV3=!1,apiKey="",blogId="",postsOrPages=["pages","posts"],jsonIndex=1,secondRequest=!0,feedPriority=0,amp="&"[0];function urlVal(){var e=window.location.pathname,t=e.length;return".html"===e.substring(t-5)?0:t>1?1:2}function urlMod(){var e=window.location.pathname;"p"===e.substring(1,2)?(e=(e=e.substring(e.indexOf("/",1)+1)).substr(0,e.indexOf(".html")),history.replaceState(null,null,"../"+e)):(e=(e=postsDatePrefix?e.substring(1):e.substring(e.indexOf("/",7)+1)).substr(0,e.indexOf(".html")),history.replaceState(null,null,"../../"+e))}function urlSearch(e,t){var n=e+".html";t.forEach(function(e){-1!==e.search(n)&&(window.location=e)})}function urlManager(){var e=urlVal();0===e?accessOnly||urlMod():1===e?getJSON(postsOrPages[feedPriority],1):2===e&&(accessOnly||history.replaceState(null,null,"/"))}function getJSON(e,t){var n=document.createElement("script");if(useApiV3){var o="https://www.googleapis.com/blogger/v3/blogs/"+blogId+"/"+e+"?key="+apiKey+"#maxResults=500#fields=nextPageToken%2Citems(url)#callback=bloggerJSON";nextPageToken&&(o+="#pageToken="+nextPageToken),nextPageToken=void 0}else o=window.location.protocol+"//"+window.location.hostname+"/feeds/"+e+"/default?start-index="+t+"#max-results=150#orderby=published#alt=json-in-script#callback=bloggerJSON";o=o.replace(/#/g,amp),n.type="text/javascript",n.src=o,document.getElementsByTagName("head")[0].appendChild(n)}function bloggerJSON(e){var t=[];if(useApiV3||void 0===urlTotal&&(urlTotal=parseInt(e.feed.openSearch$totalResults.$t)),useApiV3){try{e.items.forEach(function(e,n){t.push(e.url)})}catch(e){}nextPageToken=e.nextPageToken}else try{e.feed.entry.forEach(function(n,o){var r=e.feed.entry[o];r.link.forEach(function(e,n){"alternate"===r.link[n].rel&&t.push(r.link[n].href)})})}catch(e){}urlSearch(window.location.pathname,t),urlTotal>150?(jsonIndex+=150,urlTotal-=150,getJSON(postsOrPages[feedPriority],jsonIndex)):nextPageToken?getJSON(postsOrPages[feedPriority]):secondRequest&&(nextPageToken=void 0,urlTotal=void 0,jsonIndex=1,secondRequest=!1,0===feedPriority?(feedPriority=1,getJSON("posts",1)):1===feedPriority&&(feedPriority=0,getJSON("pages",1)))}function bloggerJS(e){e&&(feedPriority=e),urlManager()}bloggerJS();
//]]>
</script>
Just follow these steps to remove date from blog post URL :-
● Go to Blogger Dashboard
● Click on Template/Theme
● Click on Edit HTML
● Click anywhere among the coding and press Ctrl + F and search <head> (if working on PC)
Or
Look for <head> tag (if working on Phone)
● Paste the code under <head> tag
● Click on Save
Now you can check whether the date and .html removed or not from all blog post links.
I am sure this post helped you to make your blog post URL as professional as WordPress website.
Thanks for being on our site InfoByAK where we share important articles on how to blog on blogger and wordpress. Today's tutorial is about Blogger platform where we can create a free blog using a free subdomain blogspot.com
Whether we purchase a custom domain name or Top Level Domain name (TLD) for our blog but most of the bloggers face an issue of blogger URL that consist the month and year of post publishing which is not a positive point for the blog future. I learnt this thing just 5 days ago that how can I remove date from my blogger post URL. Whenever I used to share my blog posts on Social Media it was so irritated for me because it increases the length of the post URL which I never liked. I visited so many blogs on Technical Solutions and analysed one thing on their blogs that one which blog is created on WordPress their post link is so clear. I thought of it and wished to do the same on my site. So I searched on YouTube for a video that could help me to do this but no use. I thought that it's not possible for me because I am running my blog on blogger. One day I asked one of my friends who is in blogging since last 5 years he sent me a code to put into my blogger HTML coding and I did the same. I was so happy to see my blog posts links without date and .html
It helped me to shorten my blog post links and make them like a wordpress posts. Let me show you the demo of this amazing trick. Before I applied the code into my blogger template the URL one of blog posts was :-
https://www.infobyak.ga/2018/10/create-web2apk-free-of-cost.html
After I put the code into blogger template it became so cool :-
https://www.infobyak.ga/create-web2apk-free-of-cost
Why to remove date from blog post URL
Let's suppose you have a well reputed blog on Blogger or WordPress where you composed number of posts and some of them have ranked on Google's first page but after 2-3 years when someone looks your blog post link they don't open it thinking that it was an old post. So if they don't see any date including in a post link they don't mind that the post is older or new. Another thing is that long blog post link is not considered good therefore a lot of bloggers use URL shortner to attract and make click the link.
Remove date and .html from blog post link
Here I am gonna give you an HTML code which you have to embed in your blogger template. Copy this code and paste under <head> tag
<script type="text/javascript">
//<![CDATA[
// BloggerJS v0.3.1
// Copyright (c) 2017-2018 Kenny Cruz
// Licensed under the MIT License
var urlTotal,nextPageToken,postsDatePrefix=!1,accessOnly=!1,useApiV3=!1,apiKey="",blogId="",postsOrPages=["pages","posts"],jsonIndex=1,secondRequest=!0,feedPriority=0,amp="&"[0];function urlVal(){var e=window.location.pathname,t=e.length;return".html"===e.substring(t-5)?0:t>1?1:2}function urlMod(){var e=window.location.pathname;"p"===e.substring(1,2)?(e=(e=e.substring(e.indexOf("/",1)+1)).substr(0,e.indexOf(".html")),history.replaceState(null,null,"../"+e)):(e=(e=postsDatePrefix?e.substring(1):e.substring(e.indexOf("/",7)+1)).substr(0,e.indexOf(".html")),history.replaceState(null,null,"../../"+e))}function urlSearch(e,t){var n=e+".html";t.forEach(function(e){-1!==e.search(n)&&(window.location=e)})}function urlManager(){var e=urlVal();0===e?accessOnly||urlMod():1===e?getJSON(postsOrPages[feedPriority],1):2===e&&(accessOnly||history.replaceState(null,null,"/"))}function getJSON(e,t){var n=document.createElement("script");if(useApiV3){var o="https://www.googleapis.com/blogger/v3/blogs/"+blogId+"/"+e+"?key="+apiKey+"#maxResults=500#fields=nextPageToken%2Citems(url)#callback=bloggerJSON";nextPageToken&&(o+="#pageToken="+nextPageToken),nextPageToken=void 0}else o=window.location.protocol+"//"+window.location.hostname+"/feeds/"+e+"/default?start-index="+t+"#max-results=150#orderby=published#alt=json-in-script#callback=bloggerJSON";o=o.replace(/#/g,amp),n.type="text/javascript",n.src=o,document.getElementsByTagName("head")[0].appendChild(n)}function bloggerJSON(e){var t=[];if(useApiV3||void 0===urlTotal&&(urlTotal=parseInt(e.feed.openSearch$totalResults.$t)),useApiV3){try{e.items.forEach(function(e,n){t.push(e.url)})}catch(e){}nextPageToken=e.nextPageToken}else try{e.feed.entry.forEach(function(n,o){var r=e.feed.entry[o];r.link.forEach(function(e,n){"alternate"===r.link[n].rel&&t.push(r.link[n].href)})})}catch(e){}urlSearch(window.location.pathname,t),urlTotal>150?(jsonIndex+=150,urlTotal-=150,getJSON(postsOrPages[feedPriority],jsonIndex)):nextPageToken?getJSON(postsOrPages[feedPriority]):secondRequest&&(nextPageToken=void 0,urlTotal=void 0,jsonIndex=1,secondRequest=!1,0===feedPriority?(feedPriority=1,getJSON("posts",1)):1===feedPriority&&(feedPriority=0,getJSON("pages",1)))}function bloggerJS(e){e&&(feedPriority=e),urlManager()}bloggerJS();
//]]>
</script>
Just follow these steps to remove date from blog post URL :-
● Go to Blogger Dashboard
● Click on Template/Theme
● Click on Edit HTML
● Click anywhere among the coding and press Ctrl + F and search <head> (if working on PC)
Or
Look for <head> tag (if working on Phone)
● Paste the code under <head> tag
● Click on Save
Now you can check whether the date and .html removed or not from all blog post links.
I am sure this post helped you to make your blog post URL as professional as WordPress website.
0 Comments
Thanks for your comments 👍