[resolved] Admin_menu function not working (4 posts)

  1. tinwatchman
    Posted 7 years ago #

    So I'm trying to develop a custom plugin for a site that I'm working on, and I'm having an unexpectedly difficult time with it. Right now, I can't seem to get a top-level menu to show up using the admin_menu function. I've been going around and around, and I can't seem to figure out why. Does anyone have any clue what I'm doing wrong?

    Here's my code so far, with some details changed:

    (also some database stuff above, but that seems to be in working order)
    function myprefix_add_new() { ?>
    	<div class="wrap">
              <h2>My Title Goes Here</h2>
    <?php }
    function myprefix_admin_menu_add() {
    	$mymainpage = add_menu_page("My Page Title","My Page Title",1,__FILE__,'myprefix_add_new');

    Does anyone see what I could be doing wrong? Or have done wrong?

  2. tinwatchman
    Posted 7 years ago #

    bump. Could really use some help here...

  3. tinwatchman
    Posted 6 years ago #


  4. tinwatchman
    Posted 6 years ago #

    Sigh. admin_menu. Not admin-menu, admin_menu. It's an underscore. Sorry for bothering you, everyone.

Topic Closed

This topic has been closed to new replies.

About this Topic