How to hide post footer in blogger all posts or archive view?

In Blogger's configuration you can choose what to show in the footer of your posts, but there are only global footer options for all views of your posts - view of one post, view of all posts list or archive. To hide blogger's post footer in all posts view and in archive view, use this JavaScript custom code. It is fast and super lightweight:









<script>
<!--

show = false;

var str=document.URL;
var patt1=/\/\d{4}\//g;

if(str.match(patt1) != null) {
    show = true;
}

if(show == false){
    var elems = document.getElementsByTagName('div'), i;
    matchClass = 'post-footer';
    content = '';
    for (i in elems) {
        if((' ' + elems[i].className + ' ').indexOf(' ' + matchClass + ' ')
                > -1) {
            elems[i].innerHTML = content;
        }
    }
}
-->
</script>

How to add custom HTML/JavaScript you can read here:

http://webdeveloperblg.blogspot.com/2013/03/how-to-add-custom-htmljavascript-to.html

2 comments:

  1. Nice blog, here I had an opportunity to learn something new in my interested domain. I have an expectation about your future post so please keep updates.
    Regards,
    Best PHP Training in Chennai

    ReplyDelete
  2. Thanks for sharing this valuable information to our vision. You have posted a trust worthy blog keep sharing.
    Regards,
    PHP Training Chennai

    ReplyDelete

You can ask IT questions in comments!