How to highlight the author comments in blogger blogs. This will help to
Commenters can find author comments easily with this hack. Blog Author
comments are highlighted differently to normal style. Many blogger are
using this hack in their blogs. No other plugins are needed. Using a
small Xml template hack we can change style of author comments.
Installing of this hack little bit difficult to other hacks.
Add this code very carefully
How to Highlight the Author Comments in Blogger?
First Step:-
Note: Backup your template before applying this hack
Second Step:- Adding CSS code- Login to your Blogger Dashboard
- Select Design Section
- Choose Edit HTML tab
- Check Expand Widgets (i.e., Tick Expand Widgets check box)
- Find
]]></b:skin>
Tag in Your template - Add Bellow code Before it
#Change Background and Border Colors as you need.comment-body-author { background: #CEF6E3; border: 2px solid #FA5858; padding: 5px; }
- Now Save your template
Add this code very carefully
- Find the following section of code in your template
- I am not sure the code exactly like bellow
But<data:comment.body/>
tag must present in code
So Find<data:comment.body/>
tag and then select entire code like bellow<dd class='comment-body'> <b:if cond='data:comment.isDeleted'> <span class='deleted-comment'><data:comment.body/></span> <b:else/> <p><data:comment.body/></p> </b:if> </dd>
- After finding code successfully then Add Bellow code Before it
<b:if cond='data:comment.author == data:post.author'> <dd class='comment-body-author'> <p><data:comment.body/></p> </dd> <b:else/>
- and Add bellow code After it
</b:if>
- After adding Above two codes then Save your template and check your Comments
<b:if cond='data:comment.author == data:post.author'>
<dd class='comment-body-author'>
<p><data:comment.body/></p>
</dd>
<b:else/>
<dd class='comment-body'>
<b:if cond='data:comment.isDeleted'>
<span class='deleted-comment'>
<data:comment.body/></span>
<b:else/>
<p><data:comment.body/></p>
</b:if>
</dd>
</b:if>
Enregistrer un commentaire