You are here

public function LdapServerAdmin::drupalFormSubmit in Lightweight Directory Access Protocol (LDAP) 7.2

Same name and namespace in other branches
  1. 8.2 ldap_servers/LdapServerAdmin.class.php \LdapServerAdmin::drupalFormSubmit()
  2. 7 ldap_servers/LdapServerAdmin.class.php \LdapServerAdmin::drupalFormSubmit()

File

ldap_servers/LdapServerAdmin.class.php, line 465

Class

LdapServerAdmin

Code

public function drupalFormSubmit($op, $values) {
  $this
    ->populateFromDrupalForm($op, $values);
  if ($values['clear_bindpw']) {
    $this->bindpw_clear = TRUE;
  }
  if ($op == 'delete') {
    $this
      ->delete($this);
  }
  else {
    try {
      $save_result = $this
        ->save($op);
    } catch (Exception $e) {
      $this
        ->setError('Save Error', t('Failed to save object.  Your form data was not saved.'));
    }
  }
}