/** * Changes standard behavior. * * @param object A param tag node. * @param string The control name. * * @return array Any array of the label, the form element and the tooltip. * @since 1.0 */ public function renderButton(&$node) { $html = parent::renderButton($node); $formName = $this->_formName; return preg_replace(array("/Joomla\\.submitbutton\\(([^)]*)\\)/", "/adminForm/"), array("Joomla.submitform(\$1, document.{$formName})", $formName), $html); }