What are the differences between Joomla Model Types?

First of all all the classes are available for code study under:

\libraries\legacy\model\

Classes

It's also important to understand that these classes should be used (generally speaking) in connection with the corresponding controllers: JControllerLegacy, JControllerForm and JControllerAdmin.

JModelLegacy - is the base class for the Joomla model (model as in MVC). It will basically work as a Factory class by initializing the database driver object and the table object.

You may want to extend this class if you just want to do some basic SQL queries (any work with JDatabase) and write other business logic.

Difference between components, modules, extensions and plugins in Joomla

Plugins

Plugins enable you to execute code in response to certain events, either Joomla core events or custom events that are triggered from your own code. This is a powerful way of extending the basic Joomla functionality.

Components

Components are the main functional units that display in your template, like the content management system, contact forms, Web Links and the like. They are usually displayed in the center of the main content area of a template (depending on the template).

Modules

A more lightweight and flexible extension used for page rendering is a module. Modules are used for small bits of the page that are generally less complex and able to be seen across different components. Sometimes modules are linked to a component such as the core latest news module.

© 2024, Joomla King

Contact Info

Search