Genesis Author Box Shortcode

This shortcode enables you to add the Genesis author box within the content area of a post or page or anywhere else outside your wp editor.

Here’s a example where the shortcode is added to the WordPress editor showing the author box between 2 paragraphs of text inside a post.

author-box-shortcode

As you can see above, there’s some break tags and default CSS which you can over ride via your child themes style.css file to change the padding, background etc like this:

author-box

Here’s the code for members:

Related Code


Comments

8 responses to “Genesis Author Box Shortcode”

  1. Aimee Devlin Avatar
    Aimee Devlin

    Hey Brad!

    I’ve added this code to Gallery Pro, and it works great. I have one issue.

    I was unable to turn the author box off on single posts, and the theme author suggested I remove the following from the genesis_changes.php file:

    add_filter( ‘get_the_author_genesis_author_box_single’, ‘__return_true’ );

    This has removed the author box from the posts, but it has also rendered the shortcode useless. Are you able to assist with a tweak at all? Many thanks 🙂

    (I want the author box to appear before my end of post widgets, so that’s why I’d prefer to use the shortcode over the automatically added author box.)

    1. Brad Dalton Avatar
      Brad Dalton

      Use this code to remove the author box

      [code]remove_action( ‘genesis_after_entry’, ‘genesis_do_author_box_single’, 8 );[/code]

      1. Aimee Devlin Avatar
        Aimee Devlin

        Thank you 🙂 It worked nicely

  2. I did manage to enter an ID to the code, but the genesis function itself uses a global.
    When I overridden that global, all the boxes showed the same author (the first one)

    1. Brad Dalton Avatar
      Brad Dalton

      Hi

      Do you want a archive of author boxes?

      OR

      A list of authors like this http://wpsites.net/web-design/author-contributors-page-template/

      1. Yes, but only for some of the authors

        1. Brad Dalton Avatar
          Brad Dalton

          You can use the include parameter with a list of user i.d’s for get_user

          Example:=
          [code]
          ‘include’ => array(‘1′,’2′,’3’),
          [/code]

  3. Heya, quite cool
    This will only allow for an author box of the actual writer. is there a way to add multiple boxes for several writers?

Leave a Reply

Join 5000+ Followers

Get The Latest Free & Premium Tutorials Delivered The Second They’re Published.