Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Give privileged users of the site a little window into what's making it work with the page callback function (and perhaps the arguments?) for each page.
Comments
Comment #1
mlncn CreditAttribution: mlncn commentedImplemented. For page callbacks where the menu item explicitly states the file, we include where the function lives.
Asked on IRC:
13:45 benjamin-agaric: Xray module gives glimpses into the inner workings of Drupal, such as giving the page callback function that produced the page. "This page is brought to you by the function node_page_view()." If the menu item defined a file, it can also say what file this function is in: "This page is brought to you by the function user_admin(), which lives in the file modules/user/user.admin.inc."
13:45 benjamin-agaric: Is there any reasonably sane way to get the function's file (or module, which would account for the same thing)?
13:46 benjamin-agaric: (when it is not defined in menu_router)
merlinofchaos said, "Only with grep."
That saves me a lot of fruitless looking.
Knowing if the file is in core or not so API documentation can be linked to is the same issue.
Comment #2
mlncn CreditAttribution: mlncn commented@TODO #968232: Integrate with API module to provide function links if API module is installed locally.