Skip to content

Commit

Permalink
Fix bootstrap js loading in Joomla 3.1.4
Browse files Browse the repository at this point in the history
In Joomla 314, they have updated and fixed the bootstrap version.

This fix checks for J3.1.4 and reverts to the Joomla version if we are
there.
  • Loading branch information
Sophist-UK committed Sep 3, 2013
1 parent 54410d8 commit 4b38e9d
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions source/plg_system_t3/includes/core/template.php
Expand Up @@ -699,7 +699,9 @@ function addHead()


// As joomla 3.0 bootstrap is buggy, we will not use it
$this->addScript(T3_URL . '/bootstrap/js/bootstrap.js');
if (version_compare(JVERSION, '3.1.4', 'lt')) {
$this->addScript(T3_URL . '/bootstrap/js/bootstrap.js');
}

// add css/js for off-canvas
if ($offcanvas && $responsive) {
Expand Down Expand Up @@ -744,7 +746,7 @@ function updateHead()
$doc = JFactory::getDocument();
$scripts = array();

if (version_compare(JVERSION, '3.0', 'ge')) {
if (version_compare(JVERSION, '3.0', 'ge') && version_compare(JVERSION, '3.1.4', 'lt')) {
$t3bootstrap = false;
$jabootstrap = false;

Expand Down

0 comments on commit 4b38e9d

Please sign in to comment.