PR-6.1-dev Pending

User tests: Successful: Unsuccessful:

avatar Denitz
Denitz
30 Dec 2025

Summary of Changes

We have nice #__extensions.custom_data MEDIUMTEXT column to store custom extension data, but it's not available in Joomla get extension methods.

Example: currently, if a template stores any own data in #__extensions.custom_data, it can be only retrieved via separate SQL query.

It would be nice to be able to have access to custom_data via native $app->getTemplate(true)

I.e. YooTheme will be able to use this workaround to reduce extra SQL query per page load.

Same for components, menus and modules.

Testing Instructions

Install patch.

Actual result BEFORE applying this Pull Request

You can't get custom_data via $app->getTemplate(true) and other extension get methods:

var_dump(\Joomla\CMS\Component\ComponentHelper::getComponent('com_content'));
var_dump(\Joomla\CMS\Plugin\PluginHelper::getPlugin('authentication', 'joomla'));
var_dump(\Joomla\CMS\Helper\ModuleHelper::getModule('mod_menu'));
var_dump(\Joomla\CMS\Factory::getApplication()->getTemplate(true));

Expected result AFTER applying this Pull Request

You can get custom_data in all methods above.

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar Denitz Denitz - open - 30 Dec 2025
avatar Denitz Denitz - change - 30 Dec 2025
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 30 Dec 2025
Category Administration com_templates
avatar HLeithner
HLeithner - comment - 30 Dec 2025

I did a quick look and it isn't loaded anywhere in the core, for example the ComponentHelper also doesn't load it. So I'm not so sure if it should be added at all. it's a field only for 3rd party extensions (based on the relevant github pr and issue) which also means it's in your space to use it as you need it.

If we load it we should be consistent and make it available in all get functions.

avatar Denitz Denitz - change - 7 Jan 2026
Labels Added: PR-6.1-dev
avatar joomla-cms-bot joomla-cms-bot - change - 7 Jan 2026
Category Administration com_templates Administration com_templates Libraries
avatar Denitz Denitz - change - 7 Jan 2026
Title
[6.1] Provide #__extensions.custom_data with $app->getTemplate(true)
[6.1] Provide #__extensions.custom_data for components, menus, modules and template styles
avatar Denitz Denitz - edited - 7 Jan 2026
avatar Denitz Denitz - change - 7 Jan 2026
The description was changed
avatar Denitz Denitz - edited - 7 Jan 2026
avatar Denitz
Denitz - comment - 7 Jan 2026

@HLeithner I've updated the description and code to have custom_data for components, menus and modules consistently.

avatar HLeithner
HLeithner - comment - 7 Jan 2026

thanks, now we need some testers.

avatar laoneo
laoneo - comment - 7 Jan 2026

@wilsonge can you have a look here?

avatar wilsonge
wilsonge - comment - 7 Jan 2026

I mean I'm ok with this i guess. Given we decided in #19348 that it was used by various extensions it makes sense to make it easily available in existing queries for them to use. Do we need a helper method in the InstallScript's to help extension dev's set it?

avatar HLeithner
HLeithner - comment - 8 Jan 2026

at least not in this pr, I think.

Add a Comment

Login with GitHub to post a comment