I have two plugins, one uses the function wp_insert_post(), the other has a code like this:
add_action('future_to_publish', 'myFunc', 10, 1);
add_action('new_to_publish', 'myFunc', 10, 1);
add_action('draft_to_publish', 'myFunc', 10, 1);
function myFunc( $postID ) {
}
When the first plugin runs wp_insert_post(), $postID is always empty. If I use the hook "publish_post" and press update then $postID does have a value, so what I am doing wrong?