Archived topic
Getting author pic to appear in full width page header
21 replies · Started by gedosan on October 23, 2017
Hey guys,
So I got my author pics alongside the author names on standard blog posts (using your snippet shared in another thread) and it looks awesome. I'd like the author bio pic to appear on full width page headers too where I add the shortcode {{post_author}}.
Possible?
Included link to the post in question in website URL box.
Thanks
Hi there,
This post might help: https://generatepress.com/forums/topic/filter-generate_post_author_output-not-apply-to-page-header-add-on/#post-363312
Let me know :)
hey Tom, so I got that working:
Can you hit me up with some CSS to center the avatar with name to the right (on one line) - don't need the date.
My domain.com and followed by this:
/?p=10538&preview=1&_ppp=610254a238
Thanks
Give this a shot:
.foto-autor,
.autor-post {
display: inline-block;
}
.foto-autor img.avatar.photo {
float: none;
top: auto;
width: 50px;
bottom: -15px;
margin-left: 10px;
}
Looks cool, cheers - how do i remove the date?
Try removing this line in the code: <time datetime="<?php the_time('Y-m-d'); ?>"><?php the_time('d F Y'); ?></time>
thanks
Glad we could help!
Ah, scroll down - my avatar appears at the top too.
Sorry what's the problem?
Just saw the question in another topic, we will stick with this one.
Try this:
header.entry-header {
display: none;
}
But that removes it from all pages right. I need it to remain visible on normal posts.
What do you mean by all pages right? So you only want to remove them on single posts?
So pages with page headers I want them removed (because the author pic appears in the page header) and for all other posts I want it to remain.
G
Where else was the avatar showing up? I'm not seeing anything now?