Ignore:
Timestamp:
Mar 2, 2010, 3:54:22 PM (14 years ago)
Author:
nikrou
Message:

Feature 1451 : localization with gettext
Use php-gettext (developpement version rev43, because of php5.3) as fallback
Use native language (english) instead of key for translation
Keep directory en_UK for english customization
Need some refactoring for plurals

Todo : managing plugins in the same way

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/functions_user.inc.php

    r5014 r5021  
    4848  if ( !preg_match( $regex, $mail_address ) )
    4949  {
    50     return l10n('reg_err_mail_address');
     50    return l10n('mail address must be like xxx@yyy.eee (example : jack@altern.org)');
    5151  }
    5252
     
    6262    if ($count != 0)
    6363    {
    64       return l10n('reg_err_mail_address_dbl');
     64      return l10n('a user use already this mail address');
    6565    }
    6666  }
     
    8787    if ($count > 0)
    8888    {
    89       return l10n('reg_err_login5');
     89      return l10n('this login is already used');
    9090    }
    9191  }
     
    9999  if ($login == '')
    100100  {
    101     array_push($errors, l10n('reg_err_login1'));
     101    array_push($errors, l10n('Please, enter a login'));
    102102  }
    103103  if (preg_match('/^.* $/', $login))
    104104  {
    105     array_push($errors, l10n('reg_err_login2'));
     105    array_push($errors, l10n('login mustn\'t end with a space character'));
    106106  }
    107107  if (preg_match('/^ .*$/', $login))
    108108  {
    109     array_push($errors, l10n('reg_err_login3'));
     109    array_push($errors, l10n('login mustn\'t start with a space character'));
    110110  }
    111111  if (get_userid($login))
    112112  {
    113     array_push($errors, l10n('reg_err_login5'));
     113    array_push($errors, l10n('this login is already used'));
    114114  }
    115115  $mail_error = validate_mail_address(null, $mail_address);
Note: See TracChangeset for help on using the changeset viewer.