Changeset 11992


Ignore:
Timestamp:
Aug 24, 2011, 10:03:53 PM (13 years ago)
Author:
plg
Message:

feature 2027 implemented: the "lost password" feature was rewritten.

The algorithm is highly inspired from WordPress :

1) in a single field, you give a username or an email
2) Piwigo sends an email with the activation key
3) the user clicks on the link in the email (with the activation key) and is able to set a new password

The "lost password" feature is no longer limited to "classic" users:
administrators and webmasters can use it too (no need to tell webmasters
that they can only change their password in the database)

Location:
trunk
Files:
1 added
54 edited

Legend:

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

    r11826 r11992  
    785785  FROM '.USERS_TABLE.'
    786786  WHERE '.$conf['user_fields']['username'].' = \''.$username.'\'
     787;';
     788  $result = pwg_query($query);
     789
     790  if (pwg_db_num_rows($result) == 0)
     791  {
     792    return false;
     793  }
     794  else
     795  {
     796    list($user_id) = pwg_db_fetch_row($result);
     797    return $user_id;
     798  }
     799}
     800
     801function get_userid_by_email($email)
     802{
     803  global $conf;
     804
     805  $email = pwg_db_real_escape_string($email);
     806 
     807  $query = '
     808SELECT
     809    '.$conf['user_fields']['id'].'
     810  FROM '.USERS_TABLE.'
     811  WHERE UPPER('.$conf['user_fields']['email'].') = UPPER(\''.$email.'\')
    787812;';
    788813  $result = pwg_query($query);
     
    14731498}
    14741499
     1500/**
     1501 * search an available activation_key
     1502 *
     1503 * @return string
     1504 */
     1505function get_user_activation_key()
     1506{
     1507  while (true)
     1508  {
     1509    $key = generate_key(20);
     1510    $query = '
     1511SELECT COUNT(*)
     1512  FROM '.USER_INFOS_TABLE.'
     1513  WHERE activation_key = \''.$key.'\'
     1514;';
     1515    list($count) = pwg_db_fetch_row(pwg_query($query));
     1516    if (0 == $count)
     1517    {
     1518      return $key;
     1519    }
     1520  }
     1521}
     1522
    14751523?>
  • trunk/install/piwigo_structure-mysql.sql

    r11893 r11992  
    418418  `enabled_high` enum('true','false') NOT NULL default 'true',
    419419  `level` tinyint unsigned NOT NULL default '0',
     420  `activation_key` char(20) default NULL,
    420421  UNIQUE KEY `user_infos_ui1` (`user_id`)
    421422) ENGINE=MyISAM;
  • trunk/install/piwigo_structure-pdo-sqlite.sql

    r11893 r11992  
    481481  "enabled_high" BOOLEAN default true,
    482482  "level" INTEGER default 0 NOT NULL,
     483  "activation_key" CHAR(20) default NULL,
    483484  PRIMARY KEY ("user_id"),
    484485  CONSTRAINT "user_infos_ui1" UNIQUE ("user_id")
  • trunk/install/piwigo_structure-pgsql.sql

    r11893 r11992  
    582582  "enabled_high" BOOLEAN default true,
    583583  "level" INTEGER default 0 NOT NULL,
     584  "activation_key" CHAR(20) default NULL,
    584585  PRIMARY KEY ("user_id"),
    585586  CONSTRAINT "user_infos_ui1" UNIQUE ("user_id")
  • trunk/install/piwigo_structure-sqlite.sql

    r11893 r11992  
    481481  "enabled_high" BOOLEAN default true,
    482482  "level" INTEGER default 0 NOT NULL,
     483  "activation_key" CHAR(20) default NULL,
    483484  PRIMARY KEY ("user_id"),
    484485  CONSTRAINT "user_infos_ui1" UNIQUE ("user_id")
  • trunk/language/af_ZA/common.lang.php

    r11953 r11992  
    8989$lang['New on %s'] = "Nuut op %s";
    9090$lang['New password confirmation does not correspond'] = "U wagwoord bevestiging stem nie ooreen nie";
    91 $lang['New password sent by email'] = "Nuwe wagwoord per epos gestuur";
    92 $lang['No email address'] = "Geen epos adres nie";
    93 $lang['No classic user matches this email address'] = "Geen gebruiker met die epos adres nie";
    9491$lang['Notification'] = "Kennisgewing";
    9592$lang['Number of items'] = "Getal items";
     
    111108$lang['Search'] = "Soek";
    112109$lang['display available tags'] = "Vertoon beskikbare sleutelwoorde";
    113 $lang['Send new password'] = "Stuur nuwe wagwoord";
    114110$lang['Since'] = "Sedert";
    115111$lang['Sort by'] = "Sorteer volgens";
     
    305301$lang['Album: %s'] = "Album: %s";
    306302$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Swak status vir gebruiker \"gas\", verstek status sal gebruik word. Kontak die webwerf adminisrateur.";
    307 $lang['Administrator, webmaster and special user cannot use this method'] = "Administrateur, webwerf administrateur en spesiale gebruikers kan nie die metode gebruik nie";
    308303$lang['this email address is already in use'] = "die epos is reeds in gebruik";
    309304$lang['Album results for'] = "Album resultate vir";
  • trunk/language/ar_SA/common.lang.php

    r10398 r11992  
    9393$lang['New on %s'] = 'جديد لـ  %s';
    9494$lang['New password confirmation does not correspond'] = 'كلمة المرور ليست متطابقة';
    95 $lang['New password sent by email'] = 'كلمة المرور ارسلت لبريدك الالكتورني';
    96 $lang['No email address'] = 'لا بريد الكتروني';
    97 $lang['No classic user matches this email address'] = 'لا يوجد مستخدم مطابق لهذا البريد الالكتروني';
    9895$lang['Notification'] = 'تحديثات جديدة';
    9996$lang['Number of items'] = 'عدد البنود';
     
    116113$lang['Search'] = 'بحث';
    117114$lang['display available tags'] = 'أنظر في الكلمات الدلائلية';
    118 $lang['Send new password'] = 'ارسال كلمة مرور جديدة';
    119115$lang['Since'] = 'منذ';
    120116$lang['Sort by'] = 'ترتيب حسب ..';
     
    316312$lang['Album: %s'] = 'الألبوم: %s';
    317313$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'وضغ سيئ للضيف "ضيف", استخدم الحالة الافرتاضية. يرجى ابلاغ المسؤول عن الموقع.';
    318 $lang['Administrator, webmaster and special user cannot use this method'] = 'خاصية للادارة فقط لايمكنك استخدامها';
    319314$lang['this email address is already in use'] = 'هذا البريد مسجل لدينامن قبل';
    320315$lang['Album results for'] = 'نتيجة البحث في الالبومات عن:';
  • trunk/language/bg_BG/common.lang.php

    r11810 r11992  
    133133$lang['Album: %s'] = 'Албум: %s';
    134134$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Грешен статус за потребител "guest", ще бъде използвана настройка по подразбиране. Моля уведомете уебмастерът.';
    135 $lang['Administrator, webmaster and special user cannot use this method'] = 'Администратор, уебмастър и специални потребители не могат да използват този метод';
    136135$lang['this email address is already in use'] = 'този емайл адрес вече се използва.';
    137136$lang['Album results for'] = 'Албумни резултати за';
     
    172171$lang['New on %s'] = 'Нови на %s';
    173172$lang['New password confirmation does not correspond'] = 'Потвърждението за нова парола не съвпада';
    174 $lang['New password sent by email'] = 'Нова парола бе изпратена на мейла';
    175 $lang['No email address'] = 'Няма мейл адрес';
    176 $lang['No classic user matches this email address'] = 'Няма потребител със следният мейл адрес.';
    177173$lang['Notification'] = 'RSS';
    178174$lang['Number of items'] = 'Брой обекти';
     
    195191$lang['Search'] = 'Търси';
    196192$lang['display available tags'] = 'покажи налични тагове';
    197 $lang['Send new password'] = 'Изпрати нова парола';
    198193$lang['Since'] = 'От';
    199194$lang['Sort by'] = 'Сортирано по';
  • trunk/language/ca_ES/common.lang.php

    r10351 r11992  
    9191$lang['New on %s'] = 'Nou a %s';
    9292$lang['New password confirmation does not correspond'] = 'La confirmació de la nova contrasenya no correspon';
    93 $lang['New password sent by email'] = 'La nova contrasenya s\'ha enviat per correu electrònic';
    94 $lang['No email address'] = 'No hi ha l\'adreça de correu electrònic';
    95 $lang['No classic user matches this email address'] = 'No concorda cap usuari clàssic amb aquesta adreça de correu';
    9693$lang['Notification'] = 'Notificació';
    9794$lang['Number of items'] = 'Nombre d\'elements';
     
    114111$lang['Search'] = 'Cerca';
    115112$lang['display available tags'] = 'Veure etiquetes disponibles';
    116 $lang['Send new password'] = 'Envia nova contrasenya';
    117113$lang['Since'] = 'Des de';
    118114$lang['Sort by'] = 'Ordena per';
     
    312308$lang['Album: %s'] = 'Categoria: %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Estat erroni de l\'usuari "invitat", s\'està utilitzant l\'estat predeterminat. Si us plau informeu-ho a l\'administrador de la web.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'L\'administrador, l\'administrador de la web i els usuaris especials no poden utilitzar aquest mètode';
    315310$lang['this email address is already in use'] = 'un usuari ja utilitza aquesta adreça de correu';
    316311$lang['Album results for'] = 'Resultats de la categoria per';
  • trunk/language/cs_CZ/common.lang.php

    r11915 r11992  
    9595$lang['New on %s'] = 'Nový na %s';
    9696$lang['New password confirmation does not correspond'] = 'Zadaná hesla se neshodují.';
    97 $lang['New password sent by email'] = 'Nové heslo bylo zasláno e-mailem';
    98 $lang['No email address'] = 'Bez e-mailové adresy';
    99 $lang['No classic user matches this email address'] = 'Nebyl nalezen žádný uživatel se zadanou e-mailovou adresou';
    10097$lang['Notification'] = 'RSS vlákno';
    10198$lang['Number of items'] = 'Počet položek';
     
    117114$lang['Search'] = 'Vyhledat';
    118115$lang['display available tags'] = 'Ukázat dostupná klíčová slova';
    119 $lang['Send new password'] = 'Poslat nové heslo';
    120116$lang['Since'] = 'Od';
    121117$lang['Sort by'] = 'Řadit podle';
     
    314310$lang['Album: %s'] = 'Album: %s';
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Špatný stav pro uživatele "host", bude použit výchozí stav. Prosím informujte administrátora.';
    316 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrátor nemůže použít tuto metodu.';
    317312$lang['this email address is already in use'] = 'Tato e-mailová adresa je již používána';
    318313$lang['Album results for'] = 'Alba výsledky pro';
  • trunk/language/da_DK/common.lang.php

    r10351 r11992  
    9393$lang['New on %s'] = 'Ny på %s';
    9494$lang['New password confirmation does not correspond'] = 'Nyt password stemmer ikke';
    95 $lang['New password sent by email'] = 'Nyt password er sendt via email';
    96 $lang['No email address'] = 'Ingen email addresse';
    97 $lang['No classic user matches this email address'] = 'Ingen bruger matcher denne email addresse';
    9895$lang['Notification'] = 'RSS feed';
    9996$lang['Number of items'] = 'Antal af fotos';
     
    116113$lang['Search'] = 'Søg';
    117114$lang['display available tags'] = 'Se tilgængelige tags';
    118 $lang['Send new password'] = 'Send nyt password';
    119115$lang['Since'] = 'Siden';
    120116$lang['Sort by'] = 'Sorter ';
     
    313309$lang['Album: %s'] = 'kategori: %s';
    314310$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Forket status for gæste bruger. Kontakt webmaster.';
    315 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster and specielle brugere akn ikke bruge denne metode';
    316311$lang['this email address is already in use'] = 'en bruger bruger allerede denne mail addresse';
    317312$lang['Album results for'] = 'kategori resulter for';
  • trunk/language/de_DE/common.lang.php

    r11954 r11992  
    9191$lang['New on %s'] = 'Neu am %s';
    9292$lang['New password confirmation does not correspond'] = 'Fehler bei der Bestätigung des Passwortes';
    93 $lang['New password sent by email'] = 'Neues Passwort per E-Mail zugesendet';
    94 $lang['No email address'] = 'Keine E-Mail-Adresse';
    95 $lang['No classic user matches this email address'] = 'Diese E-Mail-Adresse ist nicht bekannt';
    9693$lang['Notification'] = 'RSS-Feed';
    9794$lang['Number of items'] = 'Anzahl der Elemente';
     
    113110$lang['Search'] = 'Suchen';
    114111$lang['display available tags'] = 'alle verfügbaren Stichworte';
    115 $lang['Send new password'] = 'Sende mir ein neues Passwort';
    116112$lang['Since'] = 'Seit';
    117113$lang['Sort by'] = 'Sortieren nach';
     
    308304$lang['Album: %s'] = 'Album: %s';
    309305$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Status, der Benutzer "guest" nicht entspricht, Verwendung des Standardstatus. Bitte kontaktieren Sie den Webmaster.';
    310 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, Webmaster und spezielle Benutzer können diese Methode nicht verwenden';
    311306$lang['this email address is already in use'] = 'diese E-Mail-Adresse wird bereits verwendet';
    312307$lang['Album results for'] = 'Albumresultate für';
  • trunk/language/dv_MV/common.lang.php

    r11805 r11992  
    105105$lang['month'][9] = "ސެޕްޓެމްބަރ";
    106106$lang['New password confirmation does not correspond'] = 'އާ ސިއްރުބަސް ދިމައެއްނުވޭ';
    107 $lang['New password sent by email'] = 'އީމެއިލް މެދުވެރިކޮށް އާ ސިއްރުބަސް ފޮނުވިއްޖެ';
    108 $lang['No email address'] = 'އީމެއިލް އެޑްރެސްއެއް ނެތް';
    109 $lang['No classic user matches this email address'] = 'އެއްވެސް ކްލާސިކް ޔޫސާ އަކާ މި އީމެއިލް އެޑްރެސް އަކާ ދިމައެއްނުވޭ';
    110107$lang['Notification'] = 'އެންގުންތައް';
    111108$lang['Number of items'] = 'ތަކެތީގެ އަދަދު';
     
    128125$lang['Search'] = 'ހޯދާ';
    129126$lang['display available tags'] = 'ހުރި ޓެގުތައް ދައްކަވާ';
    130 $lang['Send new password'] = 'އާ ސިއްރުބަސް ލިބިވަޑައިގަންނަވާ';
    131127$lang['Since'] = 'އިން ފެށިގެން';
    132128$lang['Sort by'] = 'ގޮތަކަށް އަތުރާ';
  • trunk/language/el_GR/common.lang.php

    r11810 r11992  
    5151$lang['Creation date'] = "Ημερομηνία λήψης";
    5252$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Σφάλμα για το χρήστη \"επισκέπτης\", θα χρησιμοποιηθεί η προεπιλεγμένη ρύθμιση. Παρακαλώ ενημερώστε τον διαχειριστή.";
    53 $lang['Administrator, webmaster and special user cannot use this method'] = "Διαχειριστές, υπεύθυνοι και ειδικοί χρήστες δεν μπορούν να χρησιμοποιήσουν αυτή τη μέθοδο";
    5453$lang['Album results for'] = "Αποτελέσματα λευκωμάτων για ";
    5554$lang['Tag results for'] = "Αποτελέσματα ετικετών για";
     
    284283$lang['New on %s'] = 'Καινούργιο στις %s';
    285284$lang['New password confirmation does not correspond'] = 'Οι νέοι κωδικοί διαφέρουν μεταξύ τους';
    286 $lang['New password sent by email'] = 'Ο νέος κωδικός έχει σταλεί με μήνυμα ηλεκτρονικού ταχυδρομείου';
    287 $lang['No email address'] = 'Δεν υπάρχει διεύθυνση ηλεκτρονικού ταχυδρομείου';
    288 $lang['No classic user matches this email address'] = 'Δεν υπάρχει χρήστης με αυτή τη διεύθυνση ηλεκτρονικού ταχυδρομείου';
    289285$lang['Notification'] = 'Ενημερώσεις';
    290286$lang['Number of items'] = 'Αριθμός αντικειμένων';
     
    305301$lang['Search'] = 'Αναζήτηση';
    306302$lang['display available tags'] = 'εμφάνιση διαθέσιμων ετικετών';
    307 $lang['Send new password'] = 'Αποστολή νέου κωδικού';
    308303$lang['Since'] = 'Από';
    309304$lang['Sort by'] = 'Ταξινόμηση βάση';
  • trunk/language/en_UK/common.lang.php

    r11839 r11992  
    9191$lang['New on %s'] = "New on %s";
    9292$lang['New password confirmation does not correspond'] = "New password confirmation does not match";
    93 $lang['New password sent by email'] = "New password sent by email";
    94 $lang['No email address'] = "No email address";
    95 $lang['No classic user matches this email address'] = "No classic user matches this email address";
    9693$lang['Notification'] = "Notification";
    9794$lang['Number of items'] = "Number of items";
     
    114111$lang['Search'] = "Search";
    115112$lang['display available tags'] = "display available tags";
    116 $lang['Send new password'] = "Send new password";
    117113$lang['Since'] = "Since";
    118114$lang['Sort by'] = "Sort by";
     
    310306$lang['Album: %s'] = "Album: %s";
    311307$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Bad status for user \"guest\", default status will be used. Please notify the webmaster.";
    312 $lang['Administrator, webmaster and special user cannot use this method'] = "Administrator, webmaster and special user cannot use this method";
    313308$lang['this email address is already in use'] = "this email address is already in use";
    314309$lang['Album results for'] = "Album results for";
     
    357352$lang['validate this comment'] = 'validate this comment';
    358353$lang['html tags are not allowed in login'] = 'html tags are not allowed in login';
     354$lang['Enter a username or email address'] = 'Enter a username or email address';
     355$lang['Invalid username or email'] = 'Invalid username or email';
     356$lang['Password reset is not allowed for this user'] = 'Password reset is not allowed for this user';
     357$lang['User "%s" has no email address, password reset is not possible'] = 'User "%s" has no email address, password reset is not possible';
     358$lang['Someone requested that the password be reset for the following user account:'] = 'Someone requested that the password be reset for the following user account:';
     359$lang['Username "%s" on gallery %s'] = 'Username "%s" on gallery %s';
     360$lang['To reset your password, visit the following address:'] = 'To reset your password, visit the following address:';
     361$lang['If this was a mistake, just ignore this email and nothing will happen.'] = 'If this was a mistake, just ignore this email and nothing will happen.';
     362$lang['Password Reset'] = 'Password Reset';
     363$lang['Check your email for the confirmation link'] = 'Check your email for the confirmation link';
     364$lang['Invalid key'] = 'Invalid key';
     365$lang['The passwords do not match'] = 'The passwords do not match';
     366$lang['Your password has been reset'] = 'Your password has been reset';
     367$lang['Return to home page'] = 'Return to home page';
     368$lang['Please enter your username or email address.'] = 'Please enter your username or email address.';
     369$lang['You will receive a link to create a new password via email.'] = 'You will receive a link to create a new password via email.';
     370$lang['Username or email'] = 'Username or email';
     371$lang['Change my password'] = 'Change my password';
     372$lang['Enter your new password below.'] = 'Enter your new password below.';
    359373?>
  • trunk/language/es_AR/common.lang.php

    r10351 r11992  
    9292$lang['New on %s'] = 'Nuevo el %s';
    9393$lang['New password confirmation does not correspond'] = 'La confirmacion de su contraseña no corresponde';
    94 $lang['New password sent by email'] = 'Nueva contraseña enviada por correo electrónico';
    95 $lang['No email address'] = 'No hay dirección de correo electrónico';
    96 $lang['No classic user matches this email address'] = 'No existe ningún usuario con tal dirección de correo electrónico';
    9794$lang['Notification'] = 'Notificación';
    9895$lang['Number of items'] = 'Cantidad de elementos';
     
    115112$lang['Search'] = 'Buscar';
    116113$lang['display available tags'] = 'Ver tags disponibles';
    117 $lang['Send new password'] = 'Enviar la nueva contraseña';
    118114$lang['Since'] = 'Desde';
    119115$lang['Sort by'] = 'Clasificar por';
     
    312308$lang['Album: %s'] = 'Categoría: %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'El estatuto de usuario "huésped" no corresponde, se utilizará el estatuto por defecto. Por favor avísele al webmaster.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administradores, webmasters y usuarios especiales no pueden usar ese método';
    315310$lang['this email address is already in use'] = 'ya existe un usuario con esa misma dirección de correo electrónico';
    316311$lang['Album results for'] = 'Resultados de categorías para';
  • trunk/language/es_ES/common.lang.php

    r10351 r11992  
    9393$lang['New on %s'] = 'Nuevo el %s';
    9494$lang['New password confirmation does not correspond'] = 'Los valores de la contraseña no coinciden';
    95 $lang['New password sent by email'] = 'Nueva contraseña enviada por correo electrónico';
    96 $lang['No email address'] = 'Ninguna dirección electrónica';
    97 $lang['No classic user matches this email address'] = 'Falta cumplimentar la direccíon electrónica no corresponde a ningún usuario';
    9895$lang['Notification'] = 'Notificación RSS';
    9996$lang['Number of items'] = 'Número de artículos';
     
    116113$lang['Search'] = 'Búsqueda';
    117114$lang['display available tags'] = 'Ver las etiquetas disponibles';
    118 $lang['Send new password'] = 'Enviar una nueva contraseña';
    119115$lang['Since'] = 'Desde';
    120116$lang['Sort by'] = 'Clasificar según';
     
    312308$lang['Album: %s'] = 'Album : %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'El estatus del usuario "guest" no es conforme, se utilizará el estatus por defecto. Por favor, informe al administrador del sitio.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'El Administrador, el administrador del sitio y el usuario especial no pueden utilizar este método';
    315310$lang['this email address is already in use'] = 'Otro usuario ya utiliza esta dirección e-mail';
    316311$lang['Album results for'] = 'Résultados de los  àlbumes por';
  • trunk/language/et_EE/common.lang.php

    r11803 r11992  
    105105$lang['month'][9] = 'September';
    106106$lang['New password confirmation does not correspond'] = 'Uus paroolikinnitus ei sobi';
    107 $lang['New password sent by email'] = 'Uus parool saadetud e-postiga';
    108 $lang['No email address'] = 'E-posti aadress puudu';
    109 $lang['No classic user matches this email address'] = 'Mitte ükski klassikaline kasutaja ei sobitu selle e-postiga';
    110107$lang['Notification'] = 'Teadaanne';
    111108$lang['Number of items'] = 'Ühikute arv';
     
    128125$lang['Search'] = 'Otsi';
    129126$lang['display available tags'] = 'kuva võimalikud märksõnad';
    130 $lang['Send new password'] = 'Saada uus parool';
    131127$lang['Since'] = 'Alates';
    132128$lang['Sort by'] = 'Sorteeri';
  • trunk/language/fa_IR/common.lang.php

    r10352 r11992  
    9292$lang['New on %s'] = "جدید در %s";
    9393$lang['New password confirmation does not correspond'] = "تایید گذرواژه با گذرواژه مطابقت ندارند!";
    94 $lang['New password sent by email'] = "گذرواژه جدید با ایمیل ارسال شد.";
    95 $lang['No email address'] = "آدرس ایمیل یافت نشد.";
    96 $lang['No classic user matches this email address'] = "هیچ کاربری یا این آدرس ایمیل مطابقت ندارد";
    9794$lang['Notification'] = "خبرنامه";
    9895$lang['Number of items'] = "تعداد آیتم‌ها";
     
    115112$lang['Search'] = "جستجو";
    116113$lang['display available tags'] = "نمایش برچسب‌های موجود";
    117 $lang['Send new password'] = "ارسال گذرواژه جدید";
    118114$lang['Since'] = "Since";
    119115$lang['Sort by'] = "مرتب سازی با";
     
    309305$lang['Album: %s'] = "Category: %s";
    310306$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "وضعیت بد برای کاربر \"میهمان\" ، وضعیت پیش‌فرض . لطفا این موضوع را با وبمستر(مدیر‌سایت) در میان بگذارید.";
    311 $lang['Administrator, webmaster and special user cannot use this method'] = "مدیر ، وب‌مستر و کاربر ویژه نمی‌توانند از این متد استفاده نمایند.";
    312307$lang['this email address is already in use'] = "یک کاربر دیگر این آدرس ایمیل را در سیستم ثبت کرده است.";
    313308$lang['Album results for'] = "نتایج دسته برای";
  • trunk/language/fr_CA/common.lang.php

    r10351 r11992  
    9292$lang['New on %s'] = 'Nouveau le %s';
    9393$lang['New password confirmation does not correspond'] = 'Erreur de confirmation de mot de passe';
    94 $lang['New password sent by email'] = 'Nouveau mot de passe envoyé par courriel';
    95 $lang['No email address'] = 'Pas d\'adresse de courriel';
    96 $lang['No classic user matches this email address'] = 'Cette adresse de courriel ne correspond à aucun utilisateur classique';
    9794$lang['Notification'] = 'Notifications RSS';
    9895$lang['Number of items'] = 'Nombre d\'élément';
     
    115112$lang['Search'] = 'Rechercher';
    116113$lang['display available tags'] = 'Voir les mots clés disponibles';
    117 $lang['Send new password'] = 'Envoyer le nouveau mot de passe';
    118114$lang['Since'] = 'Depuis';
    119115$lang['Sort by'] = 'Trier selon';
     
    314310$lang['Album: %s'] = 'Catégorie : %s';
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Statut de l\'utilisateur "guest" non conforme, utilisation du statut par défaut. Veuillez prévenir le webmestre.';
    316 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrateur, webmestre et utilisateur spécial ne peuvent pas utiliser cette méthode';
    317312$lang['this email address is already in use'] = 'un autre utilisateur utilise déjà cette adresse de courriel';
    318313$lang['Album results for'] = 'Résultats des catégories pour';
  • trunk/language/fr_FR/common.lang.php

    r10351 r11992  
    9292$lang['New on %s'] = 'Nouveau le %s';
    9393$lang['New password confirmation does not correspond'] = 'Erreur de confirmation de mot de passe';
    94 $lang['New password sent by email'] = 'Nouveau mot de passe envoyé par e-mail';
    95 $lang['No email address'] = 'Pas d\'adresse e-mail';
    96 $lang['No classic user matches this email address'] = 'Cette adresse e-mail ne correspond à aucun utilisateur classique';
    9794$lang['Notification'] = 'Notifications RSS';
    9895$lang['Number of items'] = 'Nombre d\'élément';
     
    115112$lang['Search'] = 'Recherche';
    116113$lang['display available tags'] = 'Voir les tags disponibles';
    117 $lang['Send new password'] = 'Envoyer le nouveau mot de passe';
    118114$lang['Since'] = 'Depuis';
    119115$lang['Sort by'] = 'Trier selon';
     
    311307$lang['Album: %s'] = 'Album : %s';
    312308$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Statut de l\'utilisateur "guest" non conforme, utilisation du statut par défaut. Veuillez prévenir le webmestre.';
    313 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrateur, webmestre et utilisateur spécial ne peuvent pas utiliser cette méthode';
    314309$lang['this email address is already in use'] = 'un autre utilisateur utilise déjà cette adresse e-mail';
    315310$lang['Album results for'] = 'Résultats des albums pour';
     
    358353$lang['validate this comment'] = 'valider ce commentaire';
    359354$lang['html tags are not allowed in login'] = 'les balises html ne sont pas autorisées dans le login';
     355$lang['Enter a username or email address'] = 'Entrez votre nom d\'utilisateur ou votre adresse email';
     356$lang['Invalid username or email'] = 'Nom d\'utilisateur ou adresse email invalide';
     357$lang['Password reset is not allowed for this user'] = 'Le renouvellement du mot de passe n\'est pas permise pour cet utilisateur';
     358$lang['User "%s" has no email address, password reset is not possible'] = 'L\'utilisateur "%s" n\'a pas d\'adresse email, le renouvellement du mot de passe est impossible';
     359$lang['Someone requested that the password be reset for the following user account:'] = 'Quelqu\'un a demandé le renouvellement de votre mot de passe pour l\'utilisateur suivant :';
     360$lang['Username "%s" on gallery %s'] = 'Utilisateur "%s" sur la galerie %s';
     361$lang['To reset your password, visit the following address:'] = 'Pour renouveler votre mot de passe, cliquez sur le lien suivant :';
     362$lang['If this was a mistake, just ignore this email and nothing will happen.'] = 'S\'il s\'agit d\'une erreur, ignorez ce message et la demande ne sera pas prise en compte.';
     363$lang['Password Reset'] = 'Renouvellement de votre mot de passe';
     364$lang['Check your email for the confirmation link'] = 'Vérifiez vos emails pour trouver le lien de confirmation';
     365$lang['Invalid key'] = 'Clef invalide';
     366$lang['The passwords do not match'] = 'Les mots de passe ne correspondent pas';
     367$lang['Your password has been reset'] = 'Votre mot de passe a été réinitialisé';
     368$lang['Return to home page'] = 'Retourner sur la page d\'accueil';
     369$lang['Please enter your username or email address.'] = 'Merci d\'entrer votre nom d\'utilisateur ou votre adresse email.';
     370$lang['You will receive a link to create a new password via email.'] = 'Par email, vous recevrez un lien à cliquer pour renouveler votre mot de passe.';
     371$lang['Username or email'] = 'Nom d\'utilisateur ou adresse email';
     372$lang['Change my password'] = 'Changer mon mot de passe';
     373$lang['Enter your new password below.'] = 'Entrez votre nouveau mot de passe ci-dessous.';
    360374?>
  • trunk/language/he_IL/common.lang.php

    r11353 r11992  
    9191$lang['New on %s'] = "חדש ב %s";
    9292$lang['New password confirmation does not correspond'] = "אישור סיסמה חדשה אינו תואם";
    93 $lang['New password sent by email'] = "סיסמה חדשה נשלחה בדואר";
    94 $lang['No email address'] = "אין כתובת דואר אלקטרוני";
    95 $lang['No classic user matches this email address'] = "אין משתמש קיים עם הדואר האלקטרוני הזה";
    9693$lang['Notification'] = "הודעה";
    9794$lang['Number of items'] = "מספר הפריטים";
     
    114111$lang['Search'] = "חיפוש";
    115112$lang['display available tags'] = "ראה תוויות אפשריות";
    116 $lang['Send new password'] = "שלח סיסמה חדשה";
    117113$lang['Since'] = "מ";
    118114$lang['Sort by'] = "מיין לפי";
     
    309305$lang['Album: %s'] = "קטגוריה: %s";
    310306$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'מצב לא טוב עבור המשתמש "האורח", השתמש במצב ברירת מחדל. עדכן בבקשה את מנהל האתר.';
    311 $lang['Administrator, webmaster and special user cannot use this method'] = "מנהל ראשי, מנהל האתר ו ומשתמשים מסויימים לא יכולים להשתמש בmethod הזה";
    312307$lang['this email address is already in use'] = "משתמש אחר כבר משתמש בדואר האלקטרוני הזה";
    313308$lang['Album results for'] = "תוצאות עבור הקטגוריה";
  • trunk/language/hr_HR/common.lang.php

    r11543 r11992  
    9393$lang['New on %s'] = 'Novi na on %s';
    9494$lang['New password confirmation does not correspond'] = 'Potvrda nove zaporke ne odgovara';
    95 $lang['New password sent by email'] = 'Nova zaporka poslana e-mail porukom';
    96 $lang['No email address'] = 'Nema e-mail adrese';
    97 $lang['No classic user matches this email address'] = 'Nijedan korisnik se ne poklapa s ovom e-mail adresom';
    9895$lang['Notification'] = 'Obavijest';
    9996$lang['Number of items'] = 'Broj stavki';
     
    116113$lang['Search'] = 'Pretraživanje';
    117114$lang['display available tags'] = 'Pogledaj dostupne tagove';
    118 $lang['Send new password'] = 'Pošalji novu zaporku';
    119115$lang['Since'] = 'Od';
    120116$lang['Sort by'] = 'Složeno po';
     
    312308$lang['Album: %s'] = 'Skupina: %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Loš status za korisnika "guest", koristi se pretpostavljeni status. Molimo obavjestite webmaster-a.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'Upravitelj, webmaster i posebni korisnik ne mogu koristiti ovu metodu';
    315310$lang['this email address is already in use'] = 'korisnik već koristi ovu e-mail adresu';
    316311$lang['Album results for'] = 'Ishodi skupine za ';
  • trunk/language/hu_HU/common.lang.php

    r11868 r11992  
    9494$lang['New on %s'] = 'Új %s';
    9595$lang['New password confirmation does not correspond'] = 'Az új jelszó megerősítése nem sikerült';
    96 $lang['New password sent by email'] = 'Új jelszavát elküldtük e-mailben.';
    97 $lang['No email address'] = 'Nincs e-mail cím megadva';
    98 $lang['No classic user matches this email address'] = 'Ilyen e-mail címmel nincs regisztrált felhasználó';
    9996$lang['Notification'] = 'RSS';
    10097$lang['Number of items'] = 'Tételek száma';
     
    117114$lang['Search'] = 'Keresés';
    118115$lang['display available tags'] = 'Lehetséges címkék';
    119 $lang['Send new password'] = 'Új jelszó elküldése';
    120116$lang['Since'] = 'óta';
    121117$lang['Sort by'] = 'Rendezés';
     
    314310$lang['Album: %s'] = 'Album: %s';
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Rossz felhasználói állapot "vendég", az alapértelmezett állapot. Kérjük, küldjön értesítést a webmesternek.';
    316 $lang['Administrator, webmaster and special user cannot use this method'] = 'Adminisztrátor, webmester és különleges felhasználó nem használja ezt a módszert';
    317312$lang['this email address is already in use'] = 'Ezt az e-mail címet már egy másik felhasználó használja.';
    318313$lang['Album results for'] = 'Album eredményei';
  • trunk/language/is_IS/common.lang.php

    r11760 r11992  
    105105$lang['New on %s'] = 'Nýtt á %s';
    106106$lang['New password confirmation does not correspond'] = 'Staðfesting á nýju lykilorði passar ekki';
    107 $lang['New password sent by email'] = 'Nýtt lykilorð verður sent með tölvupósti';
    108 $lang['No email address'] = 'Ekkert tölvupóstfang';
    109 $lang['No classic user matches this email address'] = 'Engin notandi passar við þetta netfang';
    110107$lang['Notification'] = 'Tilkynning';
    111108$lang['Number of items'] = 'fjöldi atriða';
     
    128125$lang['Search'] = 'Leita';
    129126$lang['display available tags'] = 'Sýna tiltæk merki';
    130 $lang['Send new password'] = 'Senda nýtt lykilorð';
    131127$lang['Since'] = 'Frá';
    132128$lang['Sort by'] = 'Flokka eftir';
     
    309305$lang['Album: %s'] = 'Albúm: %s';
    310306$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Slæm staða fyrir notanda "gestur", sjálfgefin staða verðu notuð. Vinsamlegast tilkynnið til vefstjóra.';
    311 $lang['Administrator, webmaster and special user cannot use this method'] = 'Stjórnandi, vefstjóri og sérstakir notendur geta ekki notað þessa aðferð';
    312307$lang['this email address is already in use'] = 'þetta netfange er nú þegar í notkun';
    313308$lang['Album results for'] = 'Albúm noðurstöðut fyrir';
  • trunk/language/it_IT/common.lang.php

    r11988 r11992  
    9292$lang['New on %s'] = 'Nuovo il %s';
    9393$lang['New password confirmation does not correspond'] = 'La conferma della nuova password non corrisponde';
    94 $lang['New password sent by email'] = 'La nuova password ti è stata inviata via email';
    95 $lang['No email address'] = 'Nessun indirizzo email';
    96 $lang['No classic user matches this email address'] = 'Non esiste nessun utente con questo indirizzo email';
    9794$lang['Notification'] = 'Notifiche RSS';
    9895$lang['Number of items'] = 'Numero di elementi';
     
    115112$lang['Search'] = 'Cerca';
    116113$lang['display available tags'] = 'Mostra i tags disponibili';
    117 $lang['Send new password'] = 'Inviare una nuova password';
    118114$lang['Since'] = 'Dal';
    119115$lang['Sort by'] = 'Ordina per';
     
    311307$lang['Album: %s'] = 'Album: %s';
    312308$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Lo status dell\'utente "guest" non è conforme, viene usato lo status di default. Per favore avvisa il webmaster.';
    313 $lang['Administrator, webmaster and special user cannot use this method'] = 'Amministratore, webmaster e utente speciale non possono utilizzare questo metodo';
    314309$lang['this email address is already in use'] = 'un utente usa già questo indirizzo mail';
    315310$lang['Album results for'] = 'Risultati degli album per';
  • trunk/language/ja_JP/common.lang.php

    r11280 r11992  
    9393$lang['New on %s'] = '最新投稿 - %s';
    9494$lang['New password confirmation does not correspond'] = '新しいパスワードの承認が合致しません。';
    95 $lang['New password sent by email'] = '新しいパスワードがメール送信しました。';
    96 $lang['No email address'] = 'メールアドレスがありません。';
    97 $lang['No classic user matches this email address'] = 'このメールアドレスに合致するユーザは存在しません。';
    9895$lang['Notification'] = '通知';
    9996$lang['Number of items'] = 'アイテム数';
     
    116113$lang['Search'] = '検索';
    117114$lang['display available tags'] = '利用可能なタグを表示する';
    118 $lang['Send new password'] = '新しいパスワードを送信する';
    119115$lang['Since'] = 'Since';
    120116$lang['Sort by'] = '並び替え';
     
    310306$lang['Album: %s'] = 'カテゴリ: %s';
    311307$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'デフォルトステータスの使用に関して、ユーザ「ゲスト」は正しくないステータスです。ウェブマスタにご連絡ください。';
    312 $lang['Administrator, webmaster and special user cannot use this method'] = '管理者、ウェブマスタおよび特別ユーザは、この方法を使用できません。';
    313308$lang['this email address is already in use'] = 'このメールアドレスは、すでに他のユーザに使用されています。';
    314309$lang['Album results for'] = 'カテゴリ検索結果:';
  • trunk/language/ka_GE/common.lang.php

    r10933 r11992  
    9393$lang['New on %s'] = 'ახალი %s';
    9494$lang['New password confirmation does not correspond'] = 'New password confirmation does not correspond';
    95 $lang['New password sent by email'] = 'ახალი პაროლი გამოგზავნილია email–ზე';
    96 $lang['No email address'] = 'email–ი უცნობია';
    97 $lang['No classic user matches this email address'] = 'მომხმარებელი ესეთი email–ით არ არსებობს';
    9895$lang['Notification'] = 'RSS-შეტყობინება';
    9996$lang['Number of items'] = 'რაოდენობა გვერდზე';
     
    116113$lang['Search'] = 'ძიება';
    117114$lang['display available tags'] = 'შესაძლო ტეგების ნახვა';
    118 $lang['Send new password'] = 'ახალი პაროლის მოთხოვნა';
    119115$lang['Since'] = 'პერიოდი';
    120116$lang['Sort by'] = 'სორტირება';
     
    314310$lang['Album: %s'] = 'კატეგორია: %s';
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'მომხმარებლის არასწორი სტატუსი "სტუმარი", გამოიყენეთ ძირითადი სტატუსი. გთხოვთ შეატყობინოთ ადმინისტრატორს.';
    316 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster and special user cannot use this method';
    317312$lang['this email address is already in use'] = 'მომხმარებელი ასეთი მისამართით უკვე არსებობს';
    318313$lang['Album results for'] = 'დღის კატეგორიების რეზულტატი';
     
    361356$lang['%d Kb'] = '%d კბ';
    362357$lang['New password confirmation does not correspond'] = 'ახალი პაროლის დასტური არ მოსულა';
    363 $lang['Administrator, webmaster and special user cannot use this method'] = 'ადმინისტრატორს, წებმასტერს და სპეციალურ მომხმარებლებს არ შეუძლიათ გამოიყენონ ეს მეთოდი';
    364358$lang['Reduce diaporama speed'] = 'შევამციროთ პანორამის სიჩქარე';
    365359$lang['Accelerate diaporama speed'] = 'გავზარდოთ პანორამის სიჩქარე';
  • trunk/language/ko_KR/common.lang.php

    r11804 r11992  
    8686$lang['Keyword'] = '키워드';
    8787$lang['New password confirmation does not correspond'] = '새로운 비밀번호 확인이 일치하지 않습니다.';
    88 $lang['New password sent by email'] = '새 비밀번호가 이메일로 전송되었습니다';
    89 $lang['No email address'] = '이메일 주소가 없습니다';
    90 $lang['No classic user matches this email address'] = '이 이메일 주소와 일치하는 사용자가 없습니다';
    9188$lang['Notification'] = '알림';
    9289$lang['Number of items'] = '항목 수';
     
    109106$lang['Search'] = '검색';
    110107$lang['display available tags'] = '사용 가능한 태그 보이기';
    111 $lang['Send new password'] = '새 비밀번호를 보냅니다';
    112108$lang['Since'] = '기간';
    113109$lang['Sort by'] = '정렬 기준';
  • trunk/language/lv_LV/common.lang.php

    r11879 r11992  
    9090$lang['New on %s'] = "Jauns %s";
    9191$lang['New password confirmation does not correspond'] = "Jaunas paroles apstiprinājums nesakrīt";
    92 $lang['New password sent by email'] = "Jaunā parole izsūtīta pa e-pastu";
    93 $lang['No email address'] = "Nav e-pasta adreses";
    94 $lang['No classic user matches this email address'] = "Klasiskā lietotāja e-pasta adrese nesakrīt ar šo adresi";
    9592$lang['Notification'] = "Paziņojums";
    9693$lang['Number of items'] = "Vienību skaits";
     
    112109$lang['Search'] = "Meklēt";
    113110$lang['display available tags'] = "Skatīt pieejamos tagus";
    114 $lang['Send new password'] = "Sūtīt jaunu paroli";
    115111$lang['Since'] = "Kopš";
    116112$lang['Sort by'] = "Sarindot pēc";
     
    308304$lang['Album: %s'] = 'Albūms: %s';
    309305$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Lietotāja \"viesis\" nepareizs satuss, lietojiet statusu pēc noklusējuma. Lūdzu informējiet webmasteru.";
    310 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrātors, webmāsters un īpašais lietotājs var izmantot šo metodi';
    311306$lang['this email address is already in use'] = "cits lietotājs jau lieto šo pasta adresi";
    312307$lang['Album results for'] = 'Albūma rezultāti priekš';
  • trunk/language/mk_MK/common.lang.php

    r10352 r11992  
    101101$lang['New on %s'] = 'Нова на %s';
    102102$lang['New password confirmation does not correspond'] = 'Повторената нова лозинка не е точна. Пробајте повторно.';
    103 $lang['New password sent by email'] = 'Новата лозинка беше испратена на вашата email адреса.';
    104 $lang['No email address'] = 'Нема email адреса';
    105 $lang['No classic user matches this email address'] = 'Нема член со таква email адреса.';
    106103$lang['Notification'] = 'RSS';
    107104$lang['Number of items'] = 'Број на елементи';
     
    125122$lang['Search'] = 'Пребарување';
    126123$lang['display available tags'] = 'Погледни ги етикетите';
    127 $lang['Send new password'] = 'Прати нова лозинка';
    128124$lang['Since'] = 'Од';
    129125$lang['Sort by'] = 'Подреди ги по';
     
    325321$lang['delete this comment'] = 'Избриши го коментарот';
    326322$lang['Comment: %s'] = 'Коментар: %s';
    327 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster and special user cannot use this method';
    328323$lang['Album results for'] = 'Резултат на Албуми за';
    329324$lang['Tag results for'] = 'Таг резултати за';
  • trunk/language/nl_NL/common.lang.php

    r11882 r11992  
    9191$lang['New on %s'] = 'Nieuw op %s';
    9292$lang['New password confirmation does not correspond'] = 'Nieuw wachtwoord bevestiging komt niet overeen';
    93 $lang['New password sent by email'] = 'Nieuw wachtwoord is verzonden per email';
    94 $lang['No email address'] = 'Geen email-adres';
    95 $lang['No classic user matches this email address'] = 'Geen gebruiker gevonden met dit email-adres';
    9693$lang['Notification'] = 'Meldingen';
    9794$lang['Number of items'] = 'Aantal items';
     
    113110$lang['Search'] = 'Zoeken';
    114111$lang['display available tags'] = 'Toon beschikbare tags';
    115 $lang['Send new password'] = 'Stuur nieuw wachtwoord';
    116112$lang['Since'] = 'Sinds';
    117113$lang['Sort by'] = 'Sorteren op';
     
    310306$lang['Album: %s'] = 'Categorie: %s';
    311307$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Foutieve status voor gebruiker "guest", gebruik standaard status. Waarschuw de webbeheerder.';
    312 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webbeheerder en speciale gebruiker kunnen deze methode niet gebruiken';
    313308$lang['this email address is already in use'] = 'Een andere gebruiker maakt al gebruik van dit email-adres';
    314309$lang['Album results for'] = 'Categorie resultaten voor';
  • trunk/language/no_NO/common.lang.php

    r10351 r11992  
    4848$lang['Registration of %s'] = "Registrering av %s";
    4949$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Feil status for bruker \"gjest\", default status vil bli brukt. Vennligst kontakt webmaster.";
    50 $lang['Administrator, webmaster and special user cannot use this method'] = "Administrator, webmaster og spesial bruker kan ikke bruke denne metoden";
    5150$lang['this email address is already in use'] = "En annen bruker har allerede denne mail addressen";
    5251$lang['Tag results for'] = "Tag resultat for";
     
    150149$lang['Average rate'] = 'Gjennomsnittlig rate';
    151150$lang['New password confirmation does not correspond'] = 'Nytt passord bekreftelse er ikke lik';
    152 $lang['New password sent by email'] = 'Nytt passord sendt via email';
    153 $lang['No email address'] = 'Ingen email addresse';
    154 $lang['No classic user matches this email address'] = 'Ingen kjent bruker har denne email addressen';
    155151$lang['Notification'] = 'Til informasjon';
    156152$lang['Number of items'] = 'Antall poster';
     
    173169$lang['Search'] = 'Søk';
    174170$lang['display available tags'] = 'Se tilgjengelige tags';
    175 $lang['Send new password'] = 'Send nytt passord';
    176171$lang['Since'] = 'Siden';
    177172$lang['Sort by'] = 'Sorter etter';
  • trunk/language/pl_PL/common.lang.php

    r10352 r11992  
    9393$lang['New on %s'] = 'Nowe %s';
    9494$lang['New password confirmation does not correspond'] = 'Potwierdzenie podczas potwierdzania nowego hasła';
    95 $lang['New password sent by email'] = 'Nowe hasło wysłane na pocztą email';
    96 $lang['No email address'] = 'Brak adresu email';
    97 $lang['No classic user matches this email address'] = 'Brak użytkowników odpowiadających danemu adresowi email';
    9895$lang['Notification'] = 'Powiadamianie';
    9996$lang['Number of items'] = 'Liczba obiektów';
     
    116113$lang['Search'] = 'Szukaj';
    117114$lang['display available tags'] = 'Zobacz dostępne tagi';
    118 $lang['Send new password'] = 'Prześlij nowe hasło';
    119115$lang['Since'] = 'Od';
    120116$lang['Sort by'] = 'Sortuj po';
     
    313309$lang['Album: %s'] = 'Album: %s';
    314310$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Zły status dla użytkownika "gość", używam domyślnego';
    315 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster i special user nie mogą używać tej metody';
    316311$lang['this email address is already in use'] = 'użytkownik już używa tego adresu email';
    317312$lang['Album results for'] = 'Wyniki albumu dla';
  • trunk/language/pt_BR/common.lang.php

    r10351 r11992  
    9393$lang['New on %s'] = 'Novo em %s';
    9494$lang['New password confirmation does not correspond'] = 'Erro na confirmação da senha';
    95 $lang['New password sent by email'] = 'Nova senha enviada por email';
    96 $lang['No email address'] = 'Falta o endereço de email';
    97 $lang['No classic user matches this email address'] = 'O endereço de email não corresponde a usário algum';
    9895$lang['Notification'] = 'Notificação';
    9996$lang['Number of items'] = 'Número de itens';
     
    116113$lang['Search'] = 'Pesquisa';
    117114$lang['display available tags'] = 'Ver as tags disponíveis';
    118 $lang['Send new password'] = 'Enviar a nova senha';
    119115$lang['Since'] = 'Desde ';
    120116$lang['Sort by'] = 'Listado por';
     
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Status ruim para o usuário "guest", será usado status padrão. Por favor, avise o administrador do site.';
    316312// --------- Starting below: New or revised $lang ---- from Butterfly (2.0)
    317 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrador, webmaster e utilizador especial não podem utilizar este método';
    318313$lang['this email address is already in use'] = 'um outro usuário já utiliza este email';
    319314$lang['Album results for'] = 'Resultados da categoria para';
  • trunk/language/pt_PT/common.lang.php

    r11556 r11992  
    9393$lang['New on %s'] = 'Novo em %s';
    9494$lang['New password confirmation does not correspond'] = 'Erro na confirmação da palavra-passe';
    95 $lang['New password sent by email'] = 'Nova palavra-passe enviada por email';
    96 $lang['No email address'] = 'Falta o endereço de email';
    97 $lang['No classic user matches this email address'] = 'O endereço de email não corresponde a nenhum utilizador';
    9895$lang['Notification'] = 'Notificação';
    9996$lang['Number of items'] = 'Número de items';
     
    116113$lang['Search'] = 'Pesquisa';
    117114$lang['display available tags'] = 'Ver as etiquetas disponíveis';
    118 $lang['Send new password'] = 'Enviar nova palavra-passe';
    119115$lang['Since'] = 'Desde ';
    120116$lang['Sort by'] = 'Ordenar por';
     
    312308$lang['Album: %s'] = 'Álbum: %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'O utilizador "guest" tem um erro. Estado padrão será usado. Por favor, contacte o administrador do site.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrador, webmaster e utilizador especial não podem utilizar este método';
    315310$lang['this email address is already in use'] = 'um outro utilizador já utiliza este email';
    316311$lang['Album results for'] = 'Resultados de álbum para';
  • trunk/language/ro_RO/common.lang.php

    r11636 r11992  
    9292$lang['New on %s'] = 'Nou pe %s';
    9393$lang['New password confirmation does not correspond'] = 'Noua confirmare a parolei nu se potriveşte';
    94 $lang['New password sent by email'] = 'Noua parolă a fost trimisă prin email';
    95 $lang['No email address'] = 'Nici o adresă de email';
    96 $lang['No classic user matches this email address'] = 'Nici un utilizator clasic nu corespunde acestei adrese de e-mail';
    9794$lang['Notification'] = 'Notificare';
    9895$lang['Number of items'] = 'Numărul de articole';
     
    115112$lang['Search'] = 'Caută';
    116113$lang['display available tags'] = 'Vezi etichetele disponibile';
    117 $lang['Send new password'] = 'Trimite parola nouă';
    118114$lang['Since'] = 'De la';
    119115$lang['Sort by'] = 'Sortare după';
     
    301297$lang['Album: %s'] = 'Categorie : %s';
    302298$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Statutul utilizatorului "invitat" este eronat, se vor folosi  parametrii impliciţi. Va rugăm sa informaţi webmasterul.';
    303 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administratorul, webmasterul şi utilizatorul special nu pot folosi aceasta metodă';
    304299$lang['this email address is already in use'] = 'un alt utilizator foloseşte deja acest e-mail';
    305300$lang['Album results for'] = 'Rezultatele categoriilor pentru';
  • trunk/language/ru_RU/common.lang.php

    r11571 r11992  
    9393$lang['New on %s'] = 'Новое в %s';
    9494$lang['New password confirmation does not correspond'] = 'New password confirmation does not correspond';
    95 $lang['New password sent by email'] = 'Новый пароль отправлен по электронной почте';
    96 $lang['No email address'] = 'Не указан email';
    97 $lang['No classic user matches this email address'] = 'Нет пользователей с таким адресом электронной почты';
    9895$lang['Notification'] = 'RSS-уведомления';
    9996$lang['Number of items'] = 'Кол-во на странице';
     
    116113$lang['Search'] = 'Поиск';
    117114$lang['display available tags'] = 'Просмотр доступных тэгов';
    118 $lang['Send new password'] = 'Потребовать новый пароль';
    119115$lang['Since'] = 'За период';
    120116$lang['Sort by'] = 'Признак сортировки';
     
    311307$lang['Album: %s'] = 'Альбом: %s';
    312308$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Неверный статус пользователя "гость", используйте статус по умолчанию. Пожалуйста сообщите вебмастеру.';
    313 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster and special user cannot use this method';
    314309$lang['this email address is already in use'] = 'пользователь с таким адресом уже есть';
    315310$lang['Album results for'] = 'Альбом определен для';
     
    358353$lang['%d Kb'] = '%d Кб';
    359354$lang['New password confirmation does not correspond'] = 'Подтверждение нового пароля не получено';
    360 $lang['Administrator, webmaster and special user cannot use this method'] = 'Администраторы, вебмастер и специальные пользователи не могут использовать этот метод';
    361355$lang['Reduce diaporama speed'] = 'Уменьшить скорость панорамы';
    362356$lang['Accelerate diaporama speed'] = 'Увеличить скорость панорамы';
  • trunk/language/sh_RS/common.lang.php

    r10351 r11992  
    9393$lang['New on %s'] = 'Novi na on %s';
    9494$lang['New password confirmation does not correspond'] = 'Potvrda nove lozinke ne odgovara';
    95 $lang['New password sent by email'] = 'Nova lozinka poslana e-mail porukom';
    96 $lang['No email address'] = 'Nema e-mail adrese';
    97 $lang['No classic user matches this email address'] = 'Nijedan korisnik se ne poklapa s ovom e-mail adresom';
    9895$lang['Notification'] = 'Obaveštenje';
    9996$lang['Number of items'] = 'Broj stavki';
     
    116113$lang['Search'] = 'Pretraživanje';
    117114$lang['display available tags'] = 'Pogledaj dostupne tagove';
    118 $lang['Send new password'] = 'Pošalji novu lozinku';
    119115$lang['Since'] = 'Od';
    120116$lang['Sort by'] = 'Složeno po';
     
    312308$lang['Album: %s'] = 'Kategorija: %s';
    313309$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Loš status za korisnika "guest", koristi se podrazumevani status. Molimo obavestite webmaster-a.';
    314 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster i posebni korisnik ne mogu koristiti ovu metodu';
    315310$lang['this email address is already in use'] = 'korisnik već koristi ovu e-mail adresu';
    316311$lang['Album results for'] = 'Rezultati kategorije za ';
  • trunk/language/sk_SK/common.lang.php

    r11883 r11992  
    9595$lang['New on %s'] = 'Nový na %s';
    9696$lang['New password confirmation does not correspond'] = 'Zadané heslá sa nezhodujú.';
    97 $lang['New password sent by email'] = 'Nové heslo bolo zaslané e-mailom';
    98 $lang['No email address'] = 'Bez e-mailovej adresy';
    99 $lang['No classic user matches this email address'] = 'Nebol nájdený žiaden používateľ so zadanou e-mailovou adresou';
    10097$lang['Notification'] = 'RSS vlákno';
    10198$lang['Number of items'] = 'Počet položiek';
     
    117114$lang['Search'] = 'Vyhľadať';
    118115$lang['display available tags'] = 'Ukázať dostupné kľúčové slová';
    119 $lang['Send new password'] = 'Poslať nové heslo';
    120116$lang['Since'] = 'Od';
    121117$lang['Sort by'] = 'Zoradiť podľa';
     
    314310$lang['Album: %s'] = 'Album: %s';
    315311$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Zlý stav pre používateľa "hosť", bude použitý východzí stav. Prosím informujte webmastra.';
    316 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrátor, webmaster a špeciálny používateľ nemôžu použiť túto metódu.';
    317312$lang['this email address is already in use'] = 'táto e-mailová adresa je už používaná';
    318313$lang['Album results for'] = 'Výsledky pre album';
  • trunk/language/sl_SL/common.lang.php

    r11909 r11992  
    8989$lang['New on %s'] = 'Nov na %s';
    9090$lang['New password confirmation does not correspond'] = 'Potrditveno geslo se ne ujema';
    91 $lang['New password sent by email'] = 'Novo geslo je poslano po e-pošti';
    92 $lang['No email address'] = 'Brez e-pošte';
    93 $lang['No classic user matches this email address'] = 'Noben uporabnik ne pripada e-pošti';
    9491$lang['Notification'] = 'Obvestilo';
    9592$lang['Number of items'] = 'Število ';
     
    156153$lang['Search'] = 'Išci';
    157154$lang['display available tags'] = 'Prikaži možne označbe';
    158 $lang['Send new password'] = 'Pošlji novo geslo';
    159155$lang['Since'] = 'Odkar';
    160156$lang['Sort by'] = 'Uredi po';
     
    288284$lang['Album: %s'] = 'Kategorija: %s';
    289285$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Nepravilen status uporabnika "guest", uporabljen bo privzeti status. Prosim obvestite skrbnika.';
    290 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, skrbnik in posebni uporabnik ne morejo uporabljati te metode';
    291286$lang['this email address is already in use'] = 'email uporablja že drug uporabnik';
    292287$lang['Album results for'] = 'Category results for';
  • trunk/language/sr_RS/common.lang.php

    r11960 r11992  
    9191$lang['New on %s'] = 'Нови на %s';
    9292$lang['New password confirmation does not correspond'] = 'Потврда нове лозинке не одговара';
    93 $lang['New password sent by email'] = 'Нова лозинка послана електронском поруком';
    94 $lang['No email address'] = 'Нема електронске адресе';
    95 $lang['No classic user matches this email address'] = 'Ниједан корисник се не поклапа с овом електронском адресом';
    9693$lang['Notification'] = 'Обавештење';
    9794$lang['Number of items'] = 'Број ставки';
     
    113110$lang['Search'] = 'Претраживање';
    114111$lang['display available tags'] = 'Погледај доступне ознаке';
    115 $lang['Send new password'] = 'Пошаљи нову лозинку';
    116112$lang['Since'] = 'Од';
    117113$lang['Sort by'] = 'Сложено по';
     
    307303$lang['Album: %s'] = 'Категорија: %s';
    308304$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Лош статус за корисника "гост", користи се подразумевани статус. Молимо обавестите мајстора интернет страница.';
    309 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administrator, webmaster и посебни корисник не могу користити ову методу';
    310305$lang['this email address is already in use'] = 'корисник већ користи ову адресу електронске поште';
    311306$lang['Album results for'] = 'Резултати категорије за ';
  • trunk/language/sv_SE/common.lang.php

    r11863 r11992  
    5050$lang['Album: %s'] = 'Album: %s';
    5151$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Användarstatus för \"gäst\" är ogiltig, standard status kommer användas. Vänligen informera webbansvarig.';
    52 $lang['Administrator, webmaster and special user cannot use this method'] = 'Administratör, webmaster och speciell användare kan inte använda denna metod';
    5352$lang['this email address is already in use'] = 'en annan användare använder redan denna e-post';
    5453$lang['Album results for'] = 'Albumresultat för';
     
    127126$lang['Links'] = 'Länkar';
    128127$lang['New password confirmation does not correspond'] = 'Bekräftelse av det nya lösenordet matchar inte';
    129 $lang['New password sent by email'] = 'Nytt lösenord har skickats';
    130 $lang['No email address'] = 'E-postadress saknas';
    131 $lang['No classic user matches this email address'] = 'Ingen träff på e-postadressen';
    132128$lang['Notification'] = 'Meddelande';
    133129$lang['Number of items'] = 'Antal';
     
    149145$lang['Search'] = 'Sök';
    150146$lang['display available tags'] = 'visa tillgängliga taggar';
    151 $lang['Send new password'] = 'Skicka nytt lösenord';
    152147$lang['Since'] = 'Sedan';
    153148$lang['Sort by'] = 'Sortera efter';
  • trunk/language/th_TH/common.lang.php

    r11779 r11992  
    8787$lang['Keyword'] = 'คำค้น';
    8888$lang['New password confirmation does not correspond'] = 'รหัสผ่านและยืนยันรหัสผ่านต้องเหมือนกัน';
    89 $lang['New password sent by email'] = 'รหัสผ่านใหม่ส่งไปที่เมล์ของท่านแล้ว';
    90 $lang['No email address'] = 'ไม่มีเมล์';
    91 $lang['No classic user matches this email address'] = 'ไม่มีเมล์นี้ในระบบ';
    9289$lang['Notification'] = 'การแจ้งเตือน';
    9390$lang['Number of items'] = 'จำนวนหน่วย';
     
    110107$lang['Search'] = 'ค้นหา';
    111108$lang['display available tags'] = 'แสดงแท็คที่ใช้ได้';
    112 $lang['Send new password'] = 'ส่งรหัสผ่านใหม่';
    113109$lang['Since'] = 'ตั้งแต';
    114110$lang['Sort by'] = 'จัดเรียงโดย';
  • trunk/language/tr_TR/common.lang.php

    r11383 r11992  
    9191$lang['New on %s'] = 'Yeni %s';
    9292$lang['New password confirmation does not correspond'] = 'Parola dogrulama hatası';
    93 $lang['New password sent by email'] = 'Yeni parolanız e-postanıza yollandı';
    94 $lang['No email address'] = 'E-posta adresi yok';
    95 $lang['No classic user matches this email address'] = 'Bu e-posta adresiyle kayıtlı böyle bir kullanıcı yok.';
    9693$lang['Notification'] = 'Hatırlatma';
    9794$lang['Number of items'] = 'Ürün adedi';
     
    114111$lang['Search'] = 'Arama';
    115112$lang['display available tags'] = 'Uygun Etiketler';
    116 $lang['Send new password'] = 'Yeni Parola Gönder';
    117113$lang['Since'] = 'Şu tarihten beri:';
    118114$lang['Sort by'] = 'Sırala';
     
    275271$lang['Album: %s'] = 'Albüm: %s';
    276272$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Kullanıcı için kötü statü "ziyaretçi", varsayılan statü kullanılıyor. Lütfen webmaster\'a bildirin';
    277 $lang['Administrator, webmaster and special user cannot use this method'] = 'Yönetici, webmaster ve özel kullanıcı bu metodu kullanamaz';
    278273$lang['this email address is already in use'] = 'bu e-posta adresi başka bir kullanıcı tarafından kullanılmaktadır.';
    279274$lang['Album results for'] = 'Albüm sonuçları';
  • trunk/language/uk_UA/common.lang.php

    r11906 r11992  
    105105$lang['month'][9] = "Вересень";
    106106$lang['New password confirmation does not correspond'] = 'Підтвердження нового пароля не співпадає';
    107 $lang['New password sent by email'] = 'Новий пароль висланий електронною поштою';
    108 $lang['No email address'] = 'Немає адреси електронної пошти';
    109 $lang['No classic user matches this email address'] = 'Немає користувачів з такою адресою електронної пошти';
    110107$lang['Notification'] = 'Повідомлення';
    111108$lang['Number of items'] = 'Кількість елементів';
     
    127124$lang['Search'] = 'Пошук';
    128125$lang['display available tags'] = 'відображати доступні теги';
    129 $lang['Send new password'] = 'Відправити новий пароль';
    130126$lang['Since'] = 'З';
    131127$lang['Sort by'] = 'Сортувати за';
     
    351347$lang['validate this comment'] = 'перевірити цей коментар';
    352348$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "Невірний статус для користувача \"гість\", буде використовуватись статус за замовчуванням. Будь ласка, повідомте вебмайстра.";
    353 $lang['Administrator, webmaster and special user cannot use this method'] = "Адміністратор, вебмайстер та спеціальний користувач не можуть використовувати цей метод";
    354349$lang['N/A'] = 'невідомий';
    355350$lang['IP: %s'] = "IP: %s";
  • trunk/language/vi_VN/common.lang.php

    r11898 r11992  
    9090$lang['New on %s'] = 'hình mới ở %s';
    9191$lang['New password confirmation does not correspond'] = 'Xác nhận mật khẩu mới không được phản hồi';
    92 $lang['New password sent by email'] = 'Mật khẩu mới đã được gởi qua email của bạn';
    93 $lang['No email address'] = 'Không có địa chỉ email';
    94 $lang['No classic user matches this email address'] = 'Không có thành viên nào có địa chỉ email trùng với email này.';
    9592$lang['Notification'] = 'Thông báo';
    9693$lang['Number of items'] = 'Số lượng hình';
     
    112109$lang['Search'] = 'Tìm kiếm';
    113110$lang['display available tags'] = 'Xem các tag được dùng';
    114 $lang['Send new password'] = 'Gởi mật khẩu mới';
    115111$lang['Since'] = 'Từ';
    116112$lang['Sort by'] = 'Sắp xếp theo';
     
    306302$lang['Album: %s'] = 'Đề mục: %s';
    307303$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = 'Status xấu đối với thành viên đăng thuộc nhóm "khách", sử dụng status mặc định. Thông báo ngay cho Quản trị';
    308 $lang['Administrator, webmaster and special user cannot use this method'] = 'Quản trị viên và thành viên đặc biệt không thể sử dụng cách này';
    309304$lang['this email address is already in use'] = 'đã có thành viên sử dụng địa chỉ email này';
    310305$lang['Album results for'] = 'Kết quả đề mục cho';
  • trunk/language/zh_CN/common.lang.php

    r11908 r11992  
    9191$lang['New on %s'] = "有新的在 %s";
    9292$lang['New password confirmation does not correspond'] = "新密码确认时不匹配";
    93 $lang['New password sent by email'] = "新密码已通过电子邮件发送";
    94 $lang['No email address'] = "没有电子邮件地址";
    95 $lang['No classic user matches this email address'] = "没有用户对应此电子邮件";
    9693$lang['Notification'] = "提醒";
    9794$lang['Number of items'] = "项目数量";
     
    113110$lang['Search'] = "搜索";
    114111$lang['display available tags'] = "显示可用标签";
    115 $lang['Send new password'] = "发送新密码";
    116112$lang['Since'] = "从";
    117113$lang['Sort by'] = "分类参考";
     
    307303$lang['Album: %s'] = "图片集: %s";
    308304$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = "“访客”账户出现问题,正在使用默认设置,请提醒管理员。";
    309 $lang['Administrator, webmaster and special user cannot use this method'] = "管理员,网管和特殊用户不能使用此手段。";
    310305$lang['this email address is already in use'] = "这个电子邮件地址已经被占用了";
    311306$lang['Album results for'] = "相册结果对应";
  • trunk/language/zh_TW/common.lang.php

    r11271 r11992  
    9393$lang['New on %s'] = '新創於 %s';
    9494$lang['New password confirmation does not correspond'] = '前後密碼不一致';
    95 $lang['New password sent by email'] = '新密碼已發送';
    96 $lang['No email address'] = '沒有郵箱地址';
    97 $lang['No classic user matches this email address'] = '此郵箱地址不存在';
    9895$lang['Notification'] = '通知';
    9996$lang['Number of items'] = '總數';
     
    116113$lang['Search'] = '搜索';
    117114$lang['display available tags'] = '查看現有標籤';
    118 $lang['Send new password'] = '發送新密碼';
    119115$lang['Since'] = '自從';
    120116$lang['Sort by'] = '排序';
     
    310306$lang['Album: %s'] = '相冊: %s';
    311307$lang['Bad status for user "guest", using default status. Please notify the webmaster.'] = '如果遊客反常擁有普通用戶才擁有狀態,請向網絡管理員報告。';
    312 $lang['Administrator, webmaster and special user cannot use this method'] = '管理員, 網管和特定用戶不能使用此方法功能';
    313308$lang['this email address is already in use'] = '郵箱地址已存在';
    314309$lang['Album results for'] = '相冊的結果';
  • trunk/password.php

    r10824 r11992  
    3333// | Check Access and exit when user status is not ok                      |
    3434// +-----------------------------------------------------------------------+
     35
    3536check_status(ACCESS_FREE);
    3637
    3738// +-----------------------------------------------------------------------+
    38 // |                          send a new password                          |
     39// | Functions                                                             |
     40// +-----------------------------------------------------------------------+
     41
     42/**
     43 * checks the validity of input parameters, fills $page['errors'] and
     44 * $page['infos'] and send an email with confirmation link
     45 *
     46 * @return bool (true if email was sent, false otherwise)
     47 */
     48function process_password_request()
     49{
     50  global $page, $conf;
     51 
     52  if (empty($_POST['username_or_email']))
     53  {
     54    array_push($page['errors'], l10n('Enter a username or email address'));
     55    return false;
     56  }
     57 
     58  $user_id = get_userid_by_email($_POST['username_or_email']);
     59   
     60  if (!is_numeric($user_id))
     61  {
     62    $user_id = get_userid($_POST['username_or_email']);
     63  }
     64
     65  if (!is_numeric($user_id))
     66  {
     67    array_push($page['errors'], l10n('Invalid username or email'));
     68    return false;
     69  }
     70
     71  $userdata = getuserdata($user_id, false);
     72
     73  // password request is not possible for guest/generic users
     74  $status = $userdata['status'];
     75  if (is_a_guest($status) or is_generic($status))
     76  {
     77    array_push($page['errors'], l10n('Password reset is not allowed for this user'));
     78    return false;
     79  }
     80
     81  if (empty($userdata['email']))
     82  {
     83    array_push(
     84      $page['errors'],
     85      sprintf(
     86        l10n('User "%s" has no email address, password reset is not possible'),
     87        $userdata['username']
     88        )
     89      );
     90    return false;
     91  }
     92
     93  if (empty($userdata['activation_key']))
     94  {
     95    $activation_key = get_user_activation_key();
     96
     97    single_update(
     98      USER_INFOS_TABLE,
     99      array('activation_key' => $activation_key),
     100      array('user_id' => $user_id)
     101      );
     102
     103    $userdata['activation_key'] = $activation_key;
     104  }
     105
     106  set_make_full_url();
     107 
     108  $message = l10n('Someone requested that the password be reset for the following user account:') . "\r\n\r\n";
     109  $message.= sprintf(
     110    l10n('Username "%s" on gallery %s'),
     111    $userdata['username'],
     112    get_gallery_home_url()
     113    );
     114  $message.= "\r\n\r\n";
     115  $message.= l10n('To reset your password, visit the following address:') . "\r\n";
     116  $message.= get_gallery_home_url().'/password.php?key='.$userdata['activation_key']."\r\n\r\n";
     117  $message.= l10n('If this was a mistake, just ignore this email and nothing will happen.')."\r\n";
     118
     119  unset_make_full_url();
     120
     121  $message = trigger_event('render_lost_password_mail_content', $message);
     122
     123  $email_params = array(
     124    'subject' => '['.$conf['gallery_title'].'] '.l10n('Password Reset'),
     125    'content' => $message,
     126    'email_format' => 'text/plain',
     127    );
     128
     129  if (pwg_mail($userdata['email'], $email_params))
     130  {
     131    array_push($page['infos'], l10n('Check your email for the confirmation link'));
     132    return true;
     133  }
     134  else
     135  {
     136    array_push($page['errors'], l10n('Error sending email'));
     137    return false;
     138  }
     139}
     140
     141/**
     142 *  checks the activation key: does it match the expected pattern? is it
     143 *  linked to a user? is this user allowed to reset his password?
     144 *
     145 * @return mixed (user_id if OK, false otherwise)
     146 */
     147function check_password_reset_key($key)
     148{
     149  global $page;
     150 
     151  if (!preg_match('/^[a-z0-9]{20}$/i', $key))
     152  {
     153    array_push($page['errors'], l10n('Invalid key'));
     154    return false;
     155  }
     156
     157  $query = '
     158SELECT
     159    user_id,
     160    status
     161  FROM '.USER_INFOS_TABLE.'
     162  WHERE activation_key = \''.$key.'\'
     163;';
     164  $result = pwg_query($query);
     165
     166  if (pwg_db_num_rows($result) == 0)
     167  {
     168    array_push($page['errors'], l10n('Invalid key'));
     169    return false;
     170  }
     171 
     172  $userdata = pwg_db_fetch_assoc($result);
     173
     174  if (is_a_guest($userdata['status']) or is_generic($userdata['status']))
     175  {
     176    array_push($page['errors'], l10n('Password reset is not allowed for this user'));
     177    return false;
     178  }
     179
     180  return $userdata['user_id'];
     181}
     182
     183/**
     184 * checks the passwords, checks that user is allowed to reset his password,
     185 * update password, fills $page['errors'] and $page['infos'].
     186 *
     187 * @return bool (true if password was reset, false otherwise)
     188 */
     189function reset_password()
     190{
     191  global $page, $user, $conf;
     192
     193  if ($_POST['use_new_pwd'] != $_POST['passwordConf'])
     194  {
     195    array_push($page['errors'], l10n('The passwords do not match'));
     196    return false;
     197  }
     198
     199  if (isset($_GET['key']))
     200  {
     201    $user_id = check_password_reset_key($_GET['key']);
     202    if (!is_numeric($user_id))
     203    {
     204      array_push($page['errors'], l10n('Invalid key'));
     205      return false;
     206    }
     207  }
     208  else
     209  {
     210    // we check the currently logged in user
     211    if (is_a_guest() or is_generic())
     212    {
     213      array_push($page['errors'], l10n('Password reset is not allowed for this user'));
     214      return false;
     215    }
     216
     217    $user_id = $user['id'];
     218  }
     219   
     220  single_update(
     221    USERS_TABLE,
     222    array($conf['user_fields']['password'] => $conf['pass_convert']($_POST['use_new_pwd'])),
     223    array($conf['user_fields']['id'] => $user_id)
     224    );
     225
     226  array_push($page['infos'], l10n('Your password has been reset'));
     227
     228  if (isset($_GET['key']))
     229  {
     230    array_push($page['infos'], '<a href="'.get_root_url().'identification.php">'.l10n('Login').'</a>');
     231  }
     232  else
     233  {
     234    array_push($page['infos'], '<a href="'.get_gallery_home_url().'">'.l10n('Return to home page').'</a>');
     235  }
     236
     237  return true;
     238}
     239
     240// +-----------------------------------------------------------------------+
     241// | Process form                                                          |
    39242// +-----------------------------------------------------------------------+
    40243
     
    44247if (isset($_POST['submit']))
    45248{
    46   $mailto =
    47     '<a href="mailto:'.get_webmaster_mail_address().'">'
    48     .l10n('Contact webmaster')
    49     .'</a>'
    50     ;
    51 
    52   if (isset($_POST['no_mail_address']) and $_POST['no_mail_address'] == 1)
    53   {
    54     array_push($page['infos'], l10n('Email address is missing. Please specify an email address.'));
    55     array_push($page['infos'], $mailto);
    56   }
    57   else if (isset($_POST['mail_address']) and !empty($_POST['mail_address']))
    58   {
    59     $mail_address = pwg_db_real_escape_string($_POST['mail_address']);
    60    
    61     $query = '
    62 SELECT '.$conf['user_fields']['id'].' AS id
    63      , '.$conf['user_fields']['username'].' AS username
    64      , '.$conf['user_fields']['email'].' AS email
    65 FROM '.USERS_TABLE.' as u
    66   INNER JOIN '.USER_INFOS_TABLE.' AS ui
    67       ON u.'.$conf['user_fields']['id'].' = ui.user_id
    68 WHERE '.$conf['user_fields']['email'].' = \''.$mail_address.'\'
    69   AND ui.status = \'normal\'
    70 ;';
    71     $result = pwg_query($query);
    72 
    73     if (pwg_db_num_rows($result) > 0)
    74     {
    75       $error_on_mail = false;
    76       $datas = array();
    77      
    78       while ($row = pwg_db_fetch_assoc($result))
    79       {
    80         $new_password = generate_key(6);
    81 
    82         $infos =
    83           l10n('Username').': '.stripslashes($row['username'])
    84           ."\n".l10n('Password').': '.$new_password
    85           ;
    86 
    87         $infos = trigger_event('render_lost_password_mail_content', $infos);
    88 
    89         if (pwg_mail($row['email'],
    90               array('subject' => l10n('password updated'), 'content' => $infos)))
    91         {
    92           $data =
    93             array(
    94               $conf['user_fields']['id']
    95               => $row['id'],
    96              
    97               $conf['user_fields']['password']
    98               => $conf['pass_convert']($new_password)
    99               );
    100 
    101           array_push($datas, $data);
    102         }
    103         else
    104         {
    105           $error_on_mail = true;
    106         }
    107       }
    108      
    109       if ($error_on_mail)
    110       {
    111         array_push($page['errors'], l10n('Error sending email'));
    112         array_push($page['errors'], $mailto);
    113       }
    114       else
    115       {
    116         include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
    117         mass_updates(
    118           USERS_TABLE,
    119           array(
    120             'primary' => array($conf['user_fields']['id']),
    121             'update' => array($conf['user_fields']['password'])
    122           ),
    123           $datas
    124           );
    125 
    126         array_push($page['infos'], l10n('New password sent by email'));
    127       }
    128     }
    129     else
    130     {
    131       array_push($page['errors'], l10n('No classic user matches this email address'));
    132       array_push($page['errors'], l10n('Administrator, webmaster and special user cannot use this method'));
    133       array_push($page['errors'], $mailto);
    134     }
    135   }
    136 }
    137 
    138 // +-----------------------------------------------------------------------+
    139 // |                        template initialization                        |
    140 // +-----------------------------------------------------------------------+
    141 
    142 $title = l10n('Forgot your password?');
     249  check_pwg_token();
     250 
     251  if ('lost' == $_GET['action'])
     252  {
     253    if (process_password_request())
     254    {
     255      $page['action'] = 'none';
     256    }
     257  }
     258
     259  if ('reset' == $_GET['action'])
     260  {
     261    if (reset_password())
     262    {
     263      $page['action'] = 'none';
     264    }
     265  }
     266}
     267
     268// +-----------------------------------------------------------------------+
     269// | key and action                                                        |
     270// +-----------------------------------------------------------------------+
     271
     272// a connected user can't reset the password from a mail
     273if (isset($_GET['key']) and !is_a_guest())
     274{
     275  unset($_GET['key']);
     276}
     277
     278if (isset($_GET['key']))
     279{
     280  $user_id = check_password_reset_key($_GET['key']);
     281  if (is_numeric($user_id))
     282  {
     283    $userdata = getuserdata($user_id, false);
     284    $page['username'] = $userdata['username'];
     285    $template->assign('key', $_GET['key']);
     286
     287    if (!isset($page['action']))
     288    {
     289      $page['action'] = 'reset';
     290    }
     291  }
     292  else
     293  {
     294    $page['action'] = 'none';
     295  }
     296}
     297
     298if (!isset($page['action']))
     299{
     300  if (!isset($_GET['action']))
     301  {
     302    $page['action'] = 'lost';
     303  }
     304  elseif (in_array($_GET['action'], array('lost', 'reset', 'none')))
     305  {
     306    $page['action'] = $_GET['action'];
     307  }
     308}
     309
     310if ('reset' == $page['action'] and !isset($_GET['key']) and (is_a_guest() or is_generic()))
     311{
     312  redirect(get_gallery_home_url());
     313}
     314
     315if ('lost' == $page['action'] and !is_a_guest())
     316{
     317  redirect(get_gallery_home_url());
     318}
     319
     320// +-----------------------------------------------------------------------+
     321// | template initialization                                               |
     322// +-----------------------------------------------------------------------+
     323
     324$title = l10n('Reset Password');
     325if ('lost' == $page['action'])
     326{
     327  $title = l10n('Forgot your password?');
     328
     329  if (isset($_POST['username_or_email']))
     330  {
     331    $template->assign('username_or_email', stripslashes($_POST['username_or_email']));
     332  }
     333}
     334
    143335$page['body_id'] = 'thePasswordPage';
    144336
    145337$template->set_filenames(array('password'=>'password.tpl'));
    146 $template->assign( array(
    147     'F_ACTION'=> get_root_url().'password.php'
     338$template->assign(
     339  array(
     340    'title' => $title,
     341    'form_action'=> get_root_url().'password.php',
     342    'action' => $page['action'],
     343    'username' => isset($page['username']) ? $page['username'] : $user['username'],
     344    'PWG_TOKEN' => get_pwg_token(),
    148345    )
    149346  );
     347
    150348// +-----------------------------------------------------------------------+
    151349// |                        infos & errors display                         |
    152350// +-----------------------------------------------------------------------+
     351
    153352$template->assign('errors', $page['errors']);
    154353$template->assign('infos', $page['infos']);
     
    164363// |                           html code display                           |
    165364// +-----------------------------------------------------------------------+
     365
    166366include(PHPWG_ROOT_PATH.'include/page_header.php');
    167367$template->pparse('password');
  • trunk/themes/Sylvia/theme.css

    r11200 r11992  
    464464        background-image: url(../default/s26/outline_ff7700.png);
    465465}
     466
     467.message {
     468  color:white;
     469  background-color:#666;
     470}
  • trunk/themes/dark/theme.css

    r8462 r11992  
    7676}
    7777
     78.message {
     79  color:white;
     80  background-color:#666;
     81}
  • trunk/themes/default/template/password.tpl

    r10824 r11992  
    11{if isset($MENUBAR)}{$MENUBAR}{/if}
    22<div id="content" class="content">
     3  <div class="titrePage">
     4    <ul class="categoryActions">
     5      <li>
     6        <a href="{$U_HOME}" title="{'Home'|@translate}" class="pwg-state-default pwg-button">
     7          <span class="pwg-icon pwg-icon-home">&nbsp;</span><span class="pwg-button-text">{'Home'|@translate}</span>
     8        </a>
     9      </li>
     10    </ul>
    311
    4         <div class="titrePage">
    5                 <ul class="categoryActions">
    6       <li><a href="{$U_HOME}" title="{'Home'|@translate}" class="pwg-state-default pwg-button">
    7         <span class="pwg-icon pwg-icon-home">&nbsp;</span><span class="pwg-button-text">{'Home'|@translate}</span>
    8       </a></li>
    9     </ul>
    10                 <h2>{'Password forgotten'|@translate}</h2>
    11         </div>
     12    <h2>{$title}</h2>
     13  </div>
    1214
    1315  {if count($errors)}
     
    3133  {/if}
    3234
    33 <form action="{$F_ACTION}" method="post" class="properties">
    34   <fieldset>
    35     <legend>{'Retrieve password'|@translate}</legend>
     35{if $action ne 'none'}
     36<form id="lostPassword" action="{$form_action}?action={$action}{if isset($key)}&amp;key={$key}{/if}" method="post">
     37  <input type="hidden" name="pwg_token" value="{$PWG_TOKEN}">
    3638
    37     <ul>
    38       <li>
    39         <span class="property">
    40           <label for="mail_address">{'Email address'|@translate}</label>
    41         </span>
    42         <input class="login" type="text" name="mail_address" id="mail_address" size="40" maxlength="40" >
    43       </li>
    44       <li>
    45         <span class="property">
    46           <label for="no_mail_address">{'No email address'|@translate}</label>
    47         </span>
    48         <input type="checkbox" id="no_mail_address" name="no_mail_address" value="1">
    49       </li>
    50     </ul>
    51   </fieldset>
     39  {if $action eq 'lost'}
     40  <div class="message">{'Please enter your username or email address.'|@translate} {'You will receive a link to create a new password via email.'|@translate}</div>
    5241
    53   <p><input class="submit" type="submit" name="submit" value="{'Send new password'|@translate}"></p>
     42  <p>
     43    <label>
     44      {'Username or email'|@translate}
     45      <br>
     46      <input type="text" id="username_or_email" name="username_or_email" size="40" maxlength="40"{if isset($username_or_email)} value="{$username_or_email}"{/if}>
     47    </label>
     48  </p>
     49
     50  <p class="bottomButtons"><input class="submit" type="submit" name="submit" value="{'Change my password'|@translate}"></p>
     51  {elseif $action eq 'reset'}
     52
     53  <div class="message">{'Hello'|@translate} <em>{$username}</em>. {'Enter your new password below.'|@translate}</div>
     54
     55  <p>
     56    <label>
     57      {'New password'|@translate}
     58      <br>
     59      <input type="password" name="use_new_pwd" id="use_new_pwd" value="">
     60    </label>
     61  </p>
     62
     63  <p>
     64    <label>
     65      {'Confirm Password'|@translate}
     66      <br>
     67      <input type="password" name="passwordConf" id="passwordConf" value="">
     68    </label>
     69  </p>
     70
     71  <p class="bottomButtons"><input class="submit" type="submit" name="submit" value="{'Submit'|@translate}"></p>
     72  {/if}
     73
    5474</form>
     75{/if} {* $action ne 'none' *}
     76
     77<script type="text/javascript">
     78{if $action eq 'lost'}
     79{literal}try{document.getElementById('username_or_email').focus();}catch(e){}{/literal}
     80{elseif $action eq 'reset'}
     81{literal}try{document.getElementById('use_new_pwd').focus();}catch(e){}{/literal}
     82{/if}
     83</script>
    5584
    5685</div> <!-- content -->
  • trunk/themes/default/theme.css

    r11182 r11992  
    788788#linkToPiwigo {text-align:center;}
    789789
     790.message {
     791  background-color: lightyellow;
     792  color:#333;
     793  /* margin: 0.5em 1em 0.5em 1em; */
     794  margin-bottom:1em;
     795  padding: 12px;
     796  -moz-border-radius: 3px;
     797  -khtml-border-radius: 3px;
     798  -webkit-border-radius: 3px;
     799  border-radius: 3px;
     800}
     801
     802#thePasswordPage form#lostPassword {
     803  padding: 1em;
     804}
     805
     806#thePasswordPage form#lostPassword p {
     807  text-align: left;
     808  margin: 0 0 1em 0;
     809  line-height: 1.5em;
     810}
     811
     812#thePasswordPage form#lostPassword p.bottomButtons {
     813  margin-top:2em;
     814}
Note: See TracChangeset for help on using the changeset viewer.