Support » Fixing WordPress » Basic: How to Add Checkbox to New Post Interface?

  • 3dom


    Good day! In plugin I have to add checkbox onto new post interface which is always checked (it’s value doesn’t have to be saved in database) – how to do that?

    Tried mumb-jumbo like

    function rt_post() {
    add_action(‘dbx_page_sidebar’, ‘rt_admin_sidebar’);
    function rt_admin_sidebar() {
    echo ‘Hello! Some content for admin here: <checkbox name=”check-me” value=”1″ checked />’;
    add_action( ‘admin_init’, “rt_post” );

    but it didn’t work. Any ideas?

Viewing 3 replies - 1 through 3 (of 3 total)
  • See function information on add_meta_box.



    Thanks alot! Too bad we cannot add rep here =) Solved – almost: section placed down below on post page.

    Anyone happen to know how to place checkbox into “Publish” widget/box?

    Try adding an action onto .. post_submitbox_misc_actions or post_submitbox_start

    That’s the only 2 hooks i can see available inside that box, if they’re not suited i don’t think there’s any more i can suggest..

    Hope that helps..

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Basic: How to Add Checkbox to New Post Interface?’ is closed to new replies.