Don't show gravatar on every post
-
I would like my gravatar only to show on my sticky post en on my replies on comments. So I don’t want it to show on every ‘normal’ post. Is this possible. And if so, could you explain it to me in a (not so) technical way?
I hope someone can help me.
Thanks a lot!
Go to Graphene Options –> Display –> Posts Display Options and uncheck Show post author’s gravatar. Showing gravatar only in sticky post would be tricky. You may need to hack the theme core.
Admin
Actually, you can do this just by using CSS. First, enable the Show post author’s gravatar. Then, add the following code into the Custom CSS option:
.post .post-avatar-wrap {
display: none;
}
.sticky .post-avatar-wrap {
display: block;
}Hi Syahir,
Thank you for responding so quickly! And thank you so much for this wonderful theme!
I have done what you suggested, enabled the post gravatar and copied your code into the custom CSS option, but nothing seemed to happen.
Just to make sure, I also copied your code into the style.css (I don’t know if there is any difference but thought it couldn’t do any harm….. please correct me if I am wrong here 🙂
Anyway, still nothing changed. Maybe it is useful to mention that I have activated a child theme.
I hope you can help me further with this issue.
Thanks.
.sticky!?!?! Oh! I didn’t know that! Thanks for the heads up Syahir!@Corine If you are going to add the above code in child theme’s style sheet, try adding
!importantafter “none” and “block”.post .post-avatar-wrap {
display: none !important;
}
.sticky .post-avatar-wrap {
display: block !important;
}Mod
Anyway, still nothing changed.
Try emptying your browser cache and your server cache (if you are using a caching plugin).
.sticky!?!?! Oh! I didn’t know that! Thanks for the heads up Syahir!That’s not the only one:
http://blog.kjodle.net/2012/02/24/styling-wordpress-posts-pages-archives-and-home-pages-by-class/
I knew all of them, except .sticky! 🙂
Bookmarked Ken. Thanks for that!
Oh, and I LOVE your image of the IE “E” with the red X… next to our beloved “Fire Fox”.
Goodmorning gentlemen,
First of all thank you all so much for your help.
Unfortunately, it’s still not working. This is what I have done:
I have copied en pasted your code in the style.css of the child theme:
.post .post-avatar-wrap {
display: none !important;
}
.sticky .post-avatar-wrap {
display: block !important;
}Saved it and nothing changed. I then emptied my browser cache….. still nothing changed.
Since I am a total beginner when it comes down to all of this I am sure I am probably making some silly mistake.
I hope you can help me.
Thanks (again).
If the above code doesn’t work in child theme style sheet, try adding it in Graphene Options –> Display –> Custom CSS.
Please put your code between backticks in this forum. I’ve corrected your previous post.
Viewing 10 posts - 1 through 10 (of 13 total)
- 1
- 2
- You must be logged in to reply to this topic.
