Name: Fix "0 comments" bug in blogger

Added by: Michael

Properties:

Let's see some images below




Yeah, a lot of blogger templates contain this "bug", here, here, here and much more :). And of course, it's also include "1 comments" bug lol. How to fix this ? Follow these steps :

1. Searching for these lines of code

<b:if cond='data:post.numComments == 1'>
1 <data:commentLabel/>:
<b:else/>
<data:post.numComments/> <data:commentLabelPlural/>:
</b:if>


2. Change them to

<b:if cond='data:post.numComments == 0'>
No comment
<b:else/>
<b:if cond='data:post.numComments == 1'>
1 comment
<b:else/>
<data:post.numComments/> comments
</b:if>
</b:if>


3. Save your template and DONE.

We can change "No comment", "1 comment" to "0 Comment", "One Comment" or anything else if you like :)

And of course we can do this as below madly way (not recommended lol)

<b:if cond='data:post.numComments == 0'>
No comment
<b:else/>
<b:if cond='data:post.numComments == 1'>
One comment
<b:else/>
<b:if cond='data:post.numComments == 2'>
Two comments
<b:else/>
<b:if cond='data:post.numComments == 3'>
Three comments
// four, five, six, seven, eight, ... How much can you count? lol
<b:else/>
<data:post.numComments/> comments
</b:if>
</b:if>
</b:if>
</b:if>

If you have any question, feel free to ask me. Thank you :)