• Skip to primary navigation
  • Skip to main content
OsomCode

OsomCode

Awesome code tutorials for WordPress and Genesis

  • Subscribe
  • My account
    • Edit profile
    • Favorites
    • Update credit card
  • Login

Hide Genesis author box to logged in users

Discover with this tutorial how to stop displaying the Genesis author box to users who have logged in to WordPress using code.

Showing the author box at the end of posts can be an interesting strategy if you want sporadic visitors to “remember your face”.

On the other hand, if you have loyal subscribers, you’d rather not bore them with your face every time they finish reading a tutorial, don’t you think?

Are you interested in hiding the author box to logged in users? Here’s how:

Snippet to hide the author box to users identified with their account

Add the following line at the end of the functions.php file:

To see this and another 839 code snippets of this website, login or subscribe here.

In this code you use the filter get_the_author_genesis_author_box_single in combination with the WordPress conditional tags is_singular and is_user_logged_in() to prevent the author box from displaying if the user is logged in.

Conclusions

Now you know how to hide the author box from users who have already logged in to their account.

Any questions? Let me know in the comments.

And if you want to give me any suggestion for future tutorials, leave it in the contact form. Advantages of being a subscriber. 😉

Author box Genesis Framework PHP

To leave read and make questions about this code, you can login or register.

  • About OsomCode
  • FAQ
  • Contact

Legal Notice · Privacy Policy · Cookie Policy · Terms and conditions
Copyright © 2023

Lost your password?