Add “external” link to admin menu in the backend

you can create a function that redirects to the front-end
like this:

function redirect_home_987(){
  wp_redirect( home_url() ); 
  exit;
}

and call that function in WordPress default add_menu_page function like this:

add_menu_page( 'redirecting', 'View Site', 'read', 'my-top-level-handle', 'redirect_home_987');

Hope this helps

Leave a Comment