YEARLY-ALIASES-001
JFactory / JText / JHtml everywhere
“It still works with J* aliases” is not Joomla 6 native
Years of “it still works” is why Joomla 6 upgrades white-screen. Aliases are a crutch, not the destination.
JFactory / JText / JHtml everywhere → Namespaced classes, BC plugin off
What you will see
- Class "JFactory" not found
Symptoms people search
it still works on joomla 5 · aliases are fine · we will rename later
Replace this code
Swap JFactory / JText / JHtml everywhere for Namespaced classes, BC plugin off.
Joomla 3
Remove or stop calling this
// “We’ll rename later. Joomla 4 still has aliases.”Joomla 4 / 6
Use this instead
Disable Behaviour – Backward Compatibility on Joomla 5 staging. Every Class "J…" not found is remaining debt. Native Joomla 6 has no J* globals.How to fix it
- 1Treat every J* as a ticket.
- 2Use this reference A–Z, then scan the ZIP.
- 3Do not ship a “Joomla 6” extension that still needs the J5 compat plugin.
Also known as
class alias · J prefix · temporary aliases · native joomla 6
Related issues
- Joomla 3 → 4Joomla API
JRequest::getVar() and the whole JRequest API
JRequest::getVar() → $app->getInput()->get('id')
- Joomla 3 → 4Joomla API
JError / JException
JError::raiseError() → throw new RuntimeException() / try-catch
- Joomla 3 → 4Joomla API
isAdmin() / isSite()
$app->isAdmin() → $app->isClient('administrator') / isClient('site')
- Joomla 3 → 4Joomla API
Factory::getUri()
JFactory::getUri() → Uri::getInstance()
- Joomla 3 → 4Joomla API
Factory::getXml() / JXMLElement
JFactory::getXML() → SimpleXMLElement
- Joomla 3 → 4Joomla API
Factory::getEditor()
JFactory::getEditor() → Editor::getInstance()