Tag Archives: plugins

Introducing menu_page_url()

We’ve just added a new api into WordPress 3.0 to make plugin writing that bit easier – #13829

It is now really easy to get the url for a plugin page that you have registered to make it easy to link between different plugin pages. You use the new function like this:

add_options_page('Best Evar Menu', 'Best Evar Menu', 'manage_options', 'best_evar_menu', 'best_evar_options_page');

menu_page_url( 'best_evar_menu' );

The function will by default echo the url out but if you want you can get it returned for processing by setting the second argument to false.