You are here

protected function LdapAuthenticationConfAdmin::linesToArray in Lightweight Directory Access Protocol (LDAP) 7

Same name and namespace in other branches
  1. 8.2 ldap_authentication/LdapAuthenticationConfAdmin.class.php \LdapAuthenticationConfAdmin::linesToArray()
  2. 7.2 ldap_authentication/LdapAuthenticationConfAdmin.class.php \LdapAuthenticationConfAdmin::linesToArray()
1 call to LdapAuthenticationConfAdmin::linesToArray()
LdapAuthenticationConfAdmin::populateFromDrupalForm in ldap_authentication/LdapAuthenticationConfAdmin.class.php

File

ldap_authentication/LdapAuthenticationConfAdmin.class.php, line 599

Class

LdapAuthenticationConfAdmin

Code

protected function linesToArray($lines) {
  $lines = trim($lines);
  if ($lines) {
    $array = preg_split('/[\\n\\r]+/', $lines);
    foreach ($array as $i => $value) {
      $array[$i] = trim($value);
    }
  }
  else {
    $array = array();
  }
  return $array;
}