Display post author, date, labels and comments with icons below post titles

When there are no comments made to your posts, there's a link that says 'Be the First to comment!' and when there is just one comment it says '1 comment so far'. If you want to make your blog more stylish by replacing these texts with some cute small icons along with the default Author Name, Post Date, Labels and Comments... then just follow the next steps:






Steps:
 
Step 1. From your Blogger Dashboard, click on the Template option, then press the Edit HTML button:


Step 2. Select the "Expand widgets templates" box



Step 3. Search for the below code (press the CTRL + F keys and paste the code in the search box):


<div class='post-header-line-1'>

If you can't find the code above, look for this one:

    <div class='post-header'>

Step 4. Paste the following code below/after the code above:

<font style='background:transparent url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEghCyodvyGDDbl5tCAeNVx-GwV7tlusF7mQkrb5pJL8t6c7jHxsNbjQcxqo37pe9mq-HiL2isttKrgTmodsA61AmSp51v3c5-3_AEYNP2Xb_gv7uSBK3ltosrQ1C25q33J1vZ10K81Dd0nJ/s1600/author.gif) no-repeat scroll top left;padding-left:25px;font-size:11px;'><data:post.author/></font> | <font style='background:transparent url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhAH72O8g8Z47SmbmmEZ_b5f4JKTH24tij9DOXYIkeJw4sJh4pfQU5k9RzAf7tLRP6GNz1YXvPtCWgNvMH2oAvl8fiZmnN6yYDSTvD-Kizw_M0R8_-FE5GLVrobmI3x2zKZir8FNpauPRHo/s1600/clock_icon.gif) no-repeat scroll top left;padding-left:25px;font-size:11px;'><data:post.timestamp/></font> | <font style='background:transparent url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjHuGPFQ3gOrKL5Z1J7wAGQrXg9KttQf0aCGG879FDiBgKoT4pYD_5l-pacOPBbRODoTESTWLlYeAUl9kuLuD7zeDw8-LA-RtwMmsPvNOkN9t6dtFoA_1VnNwGiDl78UkIV04dtGy6arX_p/s1600/tag+icon.gif) no-repeat scroll top left;padding-left:25px;font-size:11px;'><b:if cond='data:post.labels'>
<b:loop values='data:post.labels' var='label'>
<a expr:href='data:label.url + &quot;?max-results=8&quot;' rel='tag'><data:label.name/></a>
<b:if cond='data:label.isLast != &quot;true&quot;'>|</b:if>
</b:loop>
</b:if></font>
<span class='post-comment-link' style='Float:right;'>
        <b:if cond='data:blog.pageType != &quot;item&quot;'>
          <b:if cond='data:post.allowComments'>
            <a class='comment-link' expr:href='data:post.addCommentUrl' expr:onclick='data:post.addCommentOnclick' style='background:url(https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjhzvsibaQ-5XQUpEEZu4cp6h2g0-sURsNocZoqZXPwVmyYCNBgI8Nq7Xuryj58dE6QuPteru9OhnSq312R_HuHcaSodsc9JXFP4Rvzgqv-ZhHL0QNhWoGWIjM2z78u11mYQe-TRzHNFatP/s1600/comment-icon.png) no-repeat;Padding-left:20px;'><b:if cond='data:post.numComments == 0'>Be the first to comment!<b:else/> <b:if cond='data:post.numComments == 1'><data:post.numComments/> Comment so far<b:else/><data:post.numComments/> Comments so far</b:if> </b:if></a>
          </b:if>
        </b:if>
      </span>

How to customize:

If you want to change the icons, just replace the URL addresses above colored with:

  • Red - Author
  • Green - Date
  • Blue - Labels
  • Violet - Comment bubble

... with the URL address of your image.

Step 5. Save template... and you're done!

2 komentar:

  1. Very good written article. It will be beneficial to anybody who utilizes it, including yours truly :). Keep up the good work - can’t wait to read more posts.
    website design

    BalasHapus