The hook_menu implements only the 'page callback', 'access callback' and 'access arguments'.
It would be nice if we could pass the page arguments too. =)

I've managed to get it working with:

<?php
$items[$class_name::getPath()] = array_merge(
          array(
        'page callback' => $class_name . '::pageCallback',
        'access callback' => 'cool_default_page_access_callback',
        'access arguments' => array($class_name),
          ), $class_name::getDefinition()
      );
      if (method_exists($class_name, 'getPageArguments')) {
          $items[$class_name::getPath()]['page arguments'] = $class_name::getPageArguments();
      }
?>

=)

Comments

nimbfire created an issue. See original summary.

  • pedrorocha committed 17d88b8 on 7.x-2.x
    Issues #2714575, #2828809, #2579269 by pedrorocha, joe-b, jidrone, manu...
pedrorocha’s picture

Status: Active » Fixed

Fixed on 2.0 release

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.