Posted By

nathanbweb on 05/11/11


Tagged

php wordpress admin


Versions (?)

WordPress Add Link to Admin Menu with mt_add_pages


 / Published in: PHP
 

URL: http://bit.ly/wpsup-addadminlk

  1. // Add link to Admin Menu
  2. // via bit.ly/wpsup-addadminlk
  3. function mt_add_pages() {
  4. add_menu_page('admin-menu', 'menu-name', 5, __FILE__, 'mt_toplevel_page');
  5. }
  6. function mt_toplevel_page() {
  7. echo '
  8. <div class="wrap">
  9. <h2>New admin menu</h2>
  10. <li><a href="http://www.icore.net.tc"><h3>Author Homepage</h3></a></li>
  11. </div>';
  12. }
  13. add_action('admin_menu', 'mt_add_pages');

Report this snippet  

You need to login to post a comment.