Merge pull request #18397 from swastikpareek/issue-1987-fix-isFrontPage-function
[civicrm-core.git] / CRM / UF / Form / Field.php
index 4bfcb214af81150eddebdc9b685c6a948d8218f7..997962cd40b1f77cd35c80b4f1167b66310712b0 100644 (file)
@@ -467,8 +467,11 @@ class CRM_UF_Form_Field extends CRM_Core_Form {
     // if view mode pls freeze it with the done button.
     if ($this->_action & CRM_Core_Action::VIEW) {
       $this->freeze();
-      $this->addElement('button', 'done', ts('Done'),
-        ['onclick' => "location.href='civicrm/admin/uf/group/field?reset=1&action=browse&gid=" . $this->_gid . "'"]
+      $this->addElement('xbutton', 'done', ts('Done'),
+        [
+          'type' => 'button',
+          'onclick' => "location.href='civicrm/admin/uf/group/field?reset=1&action=browse&gid=" . $this->_gid . "'",
+        ]
       );
     }