Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

About a year ago I remember seeing a plugin or some code which allowed you to add an author dropdown menu to the post "publishing" metabox instead of it being on its own.

I can't seem to find this code anymore and was wondering if anyone knows how to easily do this?

In an ideal situation I would like to essentially add an additional row under the "Visibility:" row within the Publish metabox stating "Author:" along with the current authors name and an edit link after the name. Upon clicking on the edit link a drop down would show up with the same information as is available in author metabox.

In any case, I would greatly appreciate to know how this can be done.

share|improve this question

2 Answers 2

up vote 3 down vote accepted

I somewhat suck with admin stuff so test this carefully. I had some issues with users not coming up in dropdown, but it fails with default meta box as well - probably because of my messed up test stack.

add_action( 'admin_menu', 'remove_author_box' );
add_action( 'post_submitbox_misc_actions', 'author_in_publish' );

function remove_author_box() {

    remove_meta_box( 'authordiv', 'post', 'normal' );
}

function author_in_publish() {

    global $post_ID;

    $post = get_post( $post_ID );
    echo '<div class="misc-pub-section">Author: ';
    post_author_meta_box( $post );
    echo '</div>';
}
share|improve this answer
    
Dude, this totally works! Wonderful! The only thing is that I am hoping you can modify this so that one or both of the following can take place. (a) it should be located under the "visibility" sections (b) it should show the current author with an edit link next to it which upon clicking it should show the drop down menu with an OK link just like when you click on the edit link for "status". Can you pull that off? –  NetConstructor.com Sep 20 '10 at 11:42
    
There is no hook right after Visibility, this is closest I could place it. And unfortunately changing mechanics is definitely too hard for my skills. It would require writing control from scratch (instead of moving it) and messing with JavaScript. –  Rarst Sep 20 '10 at 12:38
    
thank you... in anyone else knows how to do this please let me know –  NetConstructor.com Sep 20 '10 at 14:06

or use the plugin Adminimize for customize this via options

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.