请尝试此代码。粘贴到函数中。php
add_action(\'admin_menu\', \'custom_page\');
function custom_page() {
add_submenu_page( \'woocommerce\', \'Name of page\', \'Name of item\', \'manage_options\', \'custom-slug\', \'custom_page_content\' );
}
function custom_page_content() {
echo \'Page content\';
}
