Cannot pass variable to page definition
You called: add_submenu_page( ‘tools.php’, ‘STL Update’, ‘STL Update’, ‘manage_options’, ‘update_live’, [‘stl_page’, ‘stagingSite’ => $stagingSite]); Note that the 6th parameter you passed was [‘stl_page’, ‘stagingSite’ => $stagingSite] which is not a callable type, and a callable is expected. callable can be: ‘function_name’ [ $object, ‘method_name’ ] [ ‘class’, ‘static_method_name’ ] function() { /* I’m a lambda/closure/anonymous … Read more