Answer the question
In order to leave comments, you need to log in
How to display a new item "News" in the wordpress admin panel and show all the posts of a specific category "News" in it?
How to display a new item "News" in the wordpress admin panel and show all the posts of a specific category "News" in it, that is, with the ability to edit adding, as it were, a copy of the Posts item, only everything is in a heap ... how to add an item, I found an example).
So I add item ()
add_action( 'admin_menu', 'register_my_page' );
function register_my_page(){
add_menu_page( 'news Title', 'news', 'edit_others_posts', 'my_page_slug', 'my_page_function', plugins_url( 'myplugin/images/icon.png' ), 6 );
}
function my_page_function(){
echo "Admin Page Test - this is a snippet on the item page";
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question