JMENU-ABSTRACT-001

class MyMenu extends JMenu

JMenu is abstract — you must implement load()

JMenu became AbstractMenu. Subclasses that do not implement load() are abstract and fatal.

class MyMenu extends JMenuExtend AbstractMenu and implement load()

Dies at Joomla 3 → 4J3: Works nativelyJ4: Changed behaviourJ6: Removed — fatalBC plugin: partialPatch possible — review itJoomla API

What you will see

  • Class LmsMenu contains 1 abstract method
  • Cannot instantiate abstract class

Symptoms people search

menu class abstract · JMenu load()

Replace this code

Swap class MyMenu extends JMenu for Extend AbstractMenu and implement load().

Joomla 3

Remove or stop calling this

class LmsMenu extends JMenu {
    // Joomla 3 allowed incomplete subclasses
}

Joomla 4 / 6

Use this instead

class LmsMenu extends \Joomla\CMS\Menu\AbstractMenu {
    public function load() { /* return items */ return true; }
}

How to fix it

  1. 1Implement load().
  2. 2Use the namespaced AbstractMenu.

Also known as

AbstractMenu · JMenu load · doExecute

Related issues

Get in touch

Have a project in mind? Let's talk about it.

Tell us what you're building. Whether it's a new site, an online store, a mobile app, or something that needs AI under the hood, we'll get back to you within a business day.

Free consultation
No commitment, no pressure
Reply within 24 hours
Usually much faster

Prefer a direct conversation?

Request a project quote

Tell us about your project

Fill out the quick form and we'll reach out.