Add a custom menu item that supports wildcards
This code can be used after the new post was saved. Otherwise there is no post object at the time. Please pay attention that the code was not tested. <?php // get post ID from the URL query $post_id = $_GET[‘post’]; // get post object $new_item_to_add = get_post($post_id, OBJECT); // get menu to add the … Read more