JHTML-BOOTSTRAP-FRAMEWORK-001
JHtml::_('bootstrap.framework')
JHtml::_('bootstrap.framework')
Joomla 3 bootstrap.framework loaded Bootstrap 2 (and often jQuery). On Joomla 4+ it does the wrong thing or nothing useful. Cassiopeia/Atum already load Bootstrap 5 through WebAssetManager.
JHtml::_('bootstrap.framework') → WebAssetManager bootstrap.css + bootstrap.es5
Symptoms people search
bootstrap.framework · double bootstrap · dropdowns broken
Replace this code
Swap JHtml::_('bootstrap.framework') for WebAssetManager bootstrap.css + bootstrap.es5.
Joomla 3
Remove or stop calling this
JHtml::_('bootstrap.framework');
JHtml::_('bootstrap.loadCss');Joomla 4 / 6
Use this instead
$wa = $this->getDocument()->getWebAssetManager();
$wa->useStyle('bootstrap.css');
$wa->useScript('bootstrap.es5');How to fix it
- 1Delete bootstrap.framework from templates and extensions.
- 2If you still need Bootstrap JS, depend on bootstrap.es5 in joomla.asset.json.
- 3Rewrite markup to Bootstrap 5 (this reference: row-fluid, span*, data-bs-*).
Also known as
bootstrap.framework · bootstrap.loadCss · JHtml bootstrap
Related issues
- Joomla 3 → 4JavaScript
behavior.framework (MooTools)
JHtml::_('behavior.framework') → Do not load MooTools — use vanilla JS or WebAssetManager
- Joomla 3 → 4JavaScript
JHtmlBootstrap::modal()
JHtmlBootstrap::modal() → HTMLHelper::_('bootstrap.renderModal')
- Joomla 3 → 4JavaScript
Chosen.js (formbehavior.chosen)
JHtml::_('formbehavior.chosen') → Core styled <select>, Choices.js, or Tom Select
- Joomla 3 → 4Joomla API
JHtmlBatch
JHtmlBatch → Layouts joomla.html.batch.*
- Joomla 4 → 5JavaScript
addScript() / addStyleSheet() vs WebAssetManager
$doc->addScript() → WebAssetManager + joomla.asset.json
- Joomla 5 → 6JavaScript
Assuming jQuery is always on the page
JHtml::_('jquery.framework') → Declare jQuery in joomla.asset.json only if you still need it