add_submenu_page() issue
-
I am trying to add a Menu in WordPress Admin Panel. I am using below code.
This code is working.
add_submenu_page('weather_info', 'Weather Information', 'Weathers', 'manage_options', 'weathers', [$this, 'weathers']);
But below code is not working. I am facing error
Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'edit.php?post_type=weather' not found or invalid function name
.add_submenu_page('weather_info', 'Weather Information', 'Weathers', 'manage_options', 'weathers', 'edit.php?post_type=weather');
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘add_submenu_page() issue’ is closed to new replies.