WordPress.org

Support

Support » Plugins and Hacks » Need post ID for new post

Need post ID for new post

  • Hi,

    I am finishing an advanced wordpress and tinymce plugin and have the following problem.

    once the plugin button is clicked on, the popup menu needs the post id in order to save information to the wordpress database, specifically to wp_postmeta.

    The temp ID is useless because wordpress doesn’t move the fields to the correct ID later, and it doesn’t allow to read them oneself with get_post_meta() either.

    A possible solution would be to automatically autosave every new post so that a draft is immediately created and a final ID is given by wordpress.

    Could someone tell me how to do it? or help me any other way?

  • The topic ‘Need post ID for new post’ is closed to new replies.