Skip to content
This repository has been archived by the owner on Feb 4, 2021. It is now read-only.

Commit

Permalink
#319: Fixing buttons on settings page
Browse files Browse the repository at this point in the history
  • Loading branch information
robinpoort committed Jun 8, 2017
1 parent 075d59c commit 09f9a58
Showing 1 changed file with 14 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,24 @@
// Load tooltips behavior
JHtml::_('behavior.formvalidation');
JHtml::_('bootstrap.tooltip');
?>
<script type="text/javascript">

// Load JS message titles
JText::script('ERROR');
JText::script('WARNING');
JText::script('NOTICE');
JText::script('MESSAGE');

JFactory::getDocument()->addScriptDeclaration('
Joomla.submitbutton = function(task)
{
if (task == 'application.cancel' || document.formvalidator.isValid(document.id('application-form')))
if (task === "config.cancel.application" || document.formvalidator.isValid(document.getElementById("application-form")))
{
Joomla.submitform(task, document.getElementById('application-form'));
jQuery("#permissions-sliders select").attr("disabled", "disabled");
Joomla.submitform(task, document.getElementById("application-form"));
}
}
</script>
};
');
?>

<?php JFactory::getDocument()->setBuffer($this->loadTemplate('navigation'), 'modules', 'sidebar'); ?>

Expand Down

0 comments on commit 09f9a58

Please sign in to comment.