MENU_CALLBACK still inserting menu item

View: New views
3 Messages — Rating Filter:   Alert me  

MENU_CALLBACK still inserting menu item

by Paul Kim-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hello,

I have a hook_menu implementation that I want to refer to a function
callback to a specific URL with 'type" => MENU_CALLBACK, but it is still
putting it in the main nav menu bar. What am I doing wrong?

      $items[] = array(
        'path'  => 'user/'. arg(1) .'/profile',
        'title' => 'Profile',
        'callback' => 'node_page_edit',
        'callback arguments' => array($node),
        'type' => MENU_CALLBACK,
        'access' => $access,
      );

Thanks in advance!
--
[ Drupal support list | http://lists.drupal.org/ ]

Re: MENU_CALLBACK still inserting menu item

by Paul Kim-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Nevermind, I found another array element that was setting this to
MENU_NORMAL_ITEM.

Paul Kim wrote:

> Hello,
>
> I have a hook_menu implementation that I want to refer to a function
> callback to a specific URL with 'type" => MENU_CALLBACK, but it is still
> putting it in the main nav menu bar. What am I doing wrong?
>
>       $items[] = array(
>         'path'  => 'user/'. arg(1) .'/profile',
>         'title' => 'Profile',
>         'callback' => 'node_page_edit',
>         'callback arguments' => array($node),
>         'type' => MENU_CALLBACK,
>         'access' => $access,
>       );
>
> Thanks in advance!
>  

--
[ Drupal support list | http://lists.drupal.org/ ]

Re: MENU_CALLBACK still inserting menu item

by matt connolly :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

What version of Drupal are you using?

hook_menu is quite different in D5 and D6.

-Matt

On 17/07/2008, at 8:53 PM, Paul Kim wrote:

> Hello,
>
> I have a hook_menu implementation that I want to refer to a function
> callback to a specific URL with 'type" => MENU_CALLBACK, but it is  
> still
> putting it in the main nav menu bar. What am I doing wrong?
>
>      $items[] = array(
>        'path'  => 'user/'. arg(1) .'/profile',
>        'title' => 'Profile',
>        'callback' => 'node_page_edit',
>        'callback arguments' => array($node),
>        'type' => MENU_CALLBACK,
>        'access' => $access,
>      );
>
> Thanks in advance!
> --
> [ Drupal support list | http://lists.drupal.org/ ]

--
[ Drupal support list | http://lists.drupal.org/ ]