/** * Function to build the form * * @return void * @access public */ public function buildQuickForm() { CRM_Utils_System::setTitle(ts('Settings - Cleanup Caches and Update Paths')); list($this->_oldBaseURL, $this->_oldBaseDir, $this->_oldSiteName) = CRM_Core_BAO_ConfigSetting::getConfigSettings(); $this->assign('oldBaseURL', $this->_oldBaseURL); $this->assign('oldBaseDir', $this->_oldBaseDir); $this->assign('oldSiteName', $this->_oldSiteName); $this->addElement('submit', $this->getButtonName('next', 'cleanup'), 'Cleanup Caches', array('class' => 'form-submit', 'id' => 'cleanup-cache')); $this->add('text', 'newBaseURL', ts('New Base URL'), NULL, TRUE); $this->add('text', 'newBaseDir', ts('New Base Directory'), NULL, TRUE); if ($this->_oldSiteName) { $this->add('text', 'newSiteName', ts('New Site Name'), NULL, TRUE); } $this->addFormRule(array('CRM_Admin_Form_Setting_UpdateConfigBackend', 'formRule')); parent::buildQuickForm(); }