Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-33720

Deprecate support for local plugin navigation callback without the local_ prefix.

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.3
    • 2.4
    • Navigation
    • MOODLE_23_STABLE
    • MOODLE_24_STABLE
    • wip-MDL-33720-m24
    • Easy
    • Hide
      1. Install a local plugin (I recommend Marina's moodlecheck)
      2. Create a lib.php file within the local plugin if there isn't already one.
      3. Do one of the following:
        • If local_pluginname_extends_navigation exists rename it to pluginname_extends_navigation
        • Create a function in lib.php called pluginname_extends_navigation with no args that does nothing.
      4. Browse to your site (any page with navigation block)
      5. Check you get a debug notice.
      Show
      Install a local plugin (I recommend Marina's moodlecheck) Create a lib.php file within the local plugin if there isn't already one. Do one of the following: If local_pluginname_extends_navigation exists rename it to pluginname_extends_navigation Create a function in lib.php called pluginname_extends_navigation with no args that does nothing. Browse to your site (any page with navigation block) Check you get a debug notice.

    Description

      Presently we have the following two navigation callbacks:

      function local_nicehack_extends_navigation(global_navigation $nav);
      function local_nicehack_extends_settings_navigation(settings_navigation $nav, context $context);

      We also support mapping the following to the first callback above:

      function nicehack_extends_navigation(global_navigation $nav);

      After the release of 2.3 I think it is in our best interests to add a debugging call to the old alternative so that in 2.4 people get advised to upgrade and in 2.5 we can remove it.

      Attachments

        Issue Links

          Activity

            People

              samhemelryk Sam Hemelryk
              samhemelryk Sam Hemelryk
              Andrew Davis Andrew Davis
              Dan Poltawski Dan Poltawski
              Frédéric Massart Frédéric Massart
              Adrian Greeve, Jake Dallimore, Mathew May, Mihail Geshoski, Peter Dias, Sujith Haridasan
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                3/Dec/12