Archived topic
Adding Job Title and Social Links in Author Archive Page
6 replies · Started by Vish on February 10, 2019
How can I add Job Title (Senior Editor/Contributor etc..) and links to Social Profile such as Twitter/Facebook (in the form of icons; I have font awesome) in the author archive page?
What I'm looking to achieve:
Author Name
Senior Editor | Twitter Facebook
Thank you :)
Note: I'm leaving a link to a author page.
Hi there,
Hooks Element should work for this:
https://docs.generatepress.com/article/hooks-element-overview/
https://docs.generatepress.com/article/hooks-visual-guide/
The content would be something like:
<?php if ( is_author( 'Vish' ) ) : ?>
<div class="author-description">Things about Vish</div>
<?php endif; ?>
Make sure Execute PHP is checked.
Select Author Archives in Display Rules.
Let me know :)
Actually, it's probably better to create multiple hooks, then use the filter instead:
https://docs.generatepress.com/article/generate_hook_element_display/
Let me know :)
Thanks Leo :) I used the first suggestion and it worked perfectly.
However, I don't understand what exactly is your second suggestion is. Is it mandatory that I follow that? If not, what are the drawbacks?
Both methods should work.
I actually prefer the first method so that you don't need to create multiple elements :)
Thanks for the clarification :)
No problem :)