Index: /extensions/SmartAlbums/admin/album.php
===================================================================
--- /extensions/SmartAlbums/admin/album.php	(revision 16923)
+++ /extensions/SmartAlbums/admin/album.php	(revision 16924)
@@ -134,8 +134,8 @@
 
 /* select options, for html_options */
-$template->assign(
-  'options', 
-  array(
-    'tags' => array(
+$options = array(
+  'tags' => array(
+    'name' => l10n('Tags'),
+    'options' => array(
       'all'   => l10n('All these tags'),
       'one'   => l10n('One of these tags'),
@@ -143,5 +143,8 @@
       'only'  => l10n('Only these tags'),
       ),
-    'date' => array(
+    ),
+  'date' => array(
+    'name' => l10n('Date'),
+    'options' => array(
       'the_post'      => l10n('Added on'),
       'before_post'   => l10n('Added before'),
@@ -151,6 +154,8 @@
       'after_taken'   => l10n('Created after'),
       ),
-    
-    'name' => array(
+    ),
+  'name' => array(
+    'name' => l10n('Photo name'),
+    'options' => array(
       'contain'     => l10n('Contains'),
       'begin'       => l10n('Begins with'),
@@ -160,5 +165,8 @@
       'not_end'     => l10n('Doesn\'t end with'),
       ),
-    'author' => array(
+    ),
+  'author' => array(
+    'name' => l10n('Author'),
+    'options' => array(
       'is'      => l10n('Is'),
       'in'      => l10n('Is in'),
@@ -166,12 +174,29 @@
       'not_in'  => l10n('Is not in'),
       ),
-    'hit' => array(
+    ),
+  'hit' => array(
+    'name' => l10n('Hits'),
+    'options' => array(
       'less' => l10n('Bellow'),
       'more' => l10n('Above'),
       ),
-    'level' => array('level' => 'level'), // second filter not used
-    'limit' => array('limit' => 'limit'), // second filter not used
-    )
+    ),
+  'rating_score' => array(
+    'name' => l10n('Rating score'),
+    'options' => array(
+      'less' => l10n('Bellow'),
+      'more' => l10n('Above'),
+      ),
+    ),
+  'level' => array(
+    'name' => l10n('Privacy level'),
+    'options' => array(),
+    ),
+  'limit' => array(
+    'name' => l10n('Max. number of photos'),
+    'options' => array(),
+    ),
   );
+$template->assign('options', $options);
 
 /* get filters for this album */
@@ -205,4 +230,5 @@
     'COND' => $filter['cond'],
     'VALUE' => $filter['value'],
+    'CAPTION' => $options[ $filter['type'] ]['name'],
   ));
 }
Index: /extensions/SmartAlbums/admin/template/album.tpl
===================================================================
--- /extensions/SmartAlbums/admin/template/album.tpl	(revision 16923)
+++ /extensions/SmartAlbums/admin/template/album.tpl	(revision 16924)
@@ -8,6 +8,6 @@
 
 {foreach from=$options item=details key=mode}
-  lang['{$mode}_filter'] = '{$mode|cat:'_filter'|@translate|escape:javascript}';
-  {capture assign="option_content"}{html_options options=$details}{/capture}
+  lang['{$mode}_filter'] = '{$details.name|escape:javascript}';
+  {capture assign="option_content"}{html_options options=$details.options}{/capture}
   options['{$mode}'] = "{$option_content|escape:javascript}";
 {/foreach}
@@ -144,10 +144,10 @@
             <a href="#" class="removeFilter" title="{'remove this filter'|@translate}"><span>[x]</span></a>
             <input type="hidden" name="filters[{$i}][type]" value="{$filter.TYPE}"/>
-            {$filter.TYPE|cat:'_filter'|@translate}
+            {$filter.CAPTION}
           </span>
           
           <span class="filter-cond">
             <select name="filters[{$i}][cond]">
-              {html_options options=$options[$filter.TYPE] selected=$filter.COND}
+              {html_options options=$options[$filter.TYPE].options selected=$filter.COND}
             </select>
           </span>
@@ -182,11 +182,12 @@
           <option value="-1">{'Add a filter'|@translate}</option>
           <option disabled="disabled">------------------</option>
-          <option value="tags">{'tags_filter'|@translate}</option>
-          <option value="date">{'date_filter'|@translate}</option>
-          <option value="name">{'name_filter'|@translate}</option>
-          <option value="author">{'author_filter'|@translate}</option>
-          <option value="hit">{'hit_filter'|@translate}</option>
-          <option value="level">{'level_filter'|@translate}</option>
-          <option value="limit">{'limit_filter'|@translate}</option>
+          <option value="tags">{'Tags'|@translate}</option>
+          <option value="date">{'Date'|@translate}</option>
+          <option value="name">{'Photo name'|@translate}</option>
+          <option value="author">{'Author'|@translate}</option>
+          <option value="hit">{'Hits'|@translate}</option>
+          <option value="rating_score">{'Rating score'|@translate}</option>
+          <option value="level">{'Privacy level'|@translate}</option>
+          <option value="limit">{'Max. number of photos'|@translate}</option>
         </select>
         <a id="removeFilters">{'Remove all filters'|@translate}</a>
Index: /extensions/SmartAlbums/include/functions.inc.php
===================================================================
--- /extensions/SmartAlbums/include/functions.inc.php	(revision 16923)
+++ /extensions/SmartAlbums/include/functions.inc.php	(revision 16924)
@@ -296,4 +296,20 @@
       }
       
+      // rating_score
+      case 'rating_score':
+      {
+        switch ($filter['cond'])
+        {
+          case 'less':
+            $where[] = 'rating_score < '.$filter['value'].'';
+            break;
+          case 'more':
+            $where[] = 'rating_score >= '.$filter['value'].'';
+            break;
+        }
+        
+        break;
+      }
+      
       // level
       case 'level':
@@ -404,4 +420,13 @@
       $error = true;
       array_push($page['errors'], l10n('Hits must be an integer'));
+    }
+  }
+  # rating_score
+  else if ($filter['type'] == 'rating_score')
+  {
+    if (!preg_match('#([0-9]{1,})#', $filter['value']))
+    {
+      $error = true;
+      array_push($page['errors'], l10n('Rating score must be an integer'));
     }
   }
Index: /extensions/SmartAlbums/language/cs_CZ/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/cs_CZ/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/cs_CZ/plugin.lang.php	(revision 16924)
@@ -52,9 +52,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'Vytvořit nové SmartAlbum';
-$lang['date_filter'] = 'Datum';
-$lang['hit_filter'] = 'Počet návštěv';
-$lang['level_filter'] = 'Úroveň';
-$lang['limit_filter'] = 'Max. počet fotek';
-$lang['name_filter'] = 'Název fotky';
-$lang['tags_filter'] = 'Tagy';
+$lang['Hits'] = 'Počet návštěv';
+$lang['Max. number of photos'] = 'Max. počet fotek';
 ?>
Index: /extensions/SmartAlbums/language/de_DE/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/de_DE/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/de_DE/plugin.lang.php	(revision 16924)
@@ -52,9 +52,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'Neues Smart Album erstellen';
-$lang['date_filter'] = 'Datum';
-$lang['hit_filter'] = 'Zugriffe';
-$lang['level_filter'] = 'Ebene';
-$lang['limit_filter'] = 'Max. Anzahl Bilder';
-$lang['name_filter'] = 'Bild Name';
-$lang['tags_filter'] = 'Schlagwörter';
+$lang['Hits'] = 'Zugriffe';
+$lang['Max. number of photos'] = 'Max. Anzahl Bilder';
 ?>
Index: /extensions/SmartAlbums/language/el_GR/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/el_GR/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/el_GR/plugin.lang.php	(revision 16924)
@@ -70,10 +70,6 @@
 $lang['author_filter'] = 'Δημιουργός';
 $lang['create a new SmartAlbum'] = 'δημιουργήστε ένα νέο SmartAlbum';
-$lang['date_filter'] = 'Ημερομηνία';
-$lang['hit_filter'] = 'Επισκέψεις';
-$lang['level_filter'] = 'Επίπεδο';
-$lang['limit_filter'] = 'Μέγιστος αριθμός εικόνων';
-$lang['name_filter'] = 'Όνομα φωτογραφίας ';
-$lang['tags_filter'] = 'Ετικέτες';
+$lang['Hits'] = 'Επισκέψεις';
+$lang['Max. number of photos'] = 'Μέγιστος αριθμός εικόνων';
 $lang['Filters'] = 'Φίλτρα';
 ?>
Index: /extensions/SmartAlbums/language/en_UK/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/en_UK/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/en_UK/plugin.lang.php	(revision 16924)
@@ -38,13 +38,9 @@
 $lang['Hits must be an integer'] = 'Hits must be an integer';
 $lang['Limit must be an integer'] = 'Limit must be an integer';
+$lang['Rating score must be an integer'] = 'Rating score must be an integer';
 $lang['You can\'t use more than one limit filter'] = 'You can\'t use more than one limit filter';
 $lang['You can\'t use more than one level filter'] = 'You can\'t use more than one level filter';
-$lang['tags_filter'] = 'Tags';
-$lang['date_filter'] = 'Date';
-$lang['name_filter'] = 'Photo name';
-$lang['author_filter'] = 'Author';
-$lang['hit_filter'] = 'Hits';
-$lang['level_filter'] = 'Level';
-$lang['limit_filter'] = 'Max. number of photos';
+$lang['Hits'] = 'Hits';
+$lang['Max. number of photos'] = 'Max. number of photos';
 $lang['For "Is (not) in", separate each author by a comma'] = 'For "Is (not) in", separate each author by a comma';
 $lang['limit_filter'] = 'Max. number of photos';
Index: /extensions/SmartAlbums/language/es_ES/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/es_ES/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/es_ES/plugin.lang.php	(revision 16924)
@@ -52,9 +52,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'Crear un nuevo álbum inteligente';
-$lang['date_filter'] = 'Fecha';
-$lang['hit_filter'] = 'Visitas';
-$lang['level_filter'] = 'Nivel';
-$lang['limit_filter'] = 'Número máximo de fotos';
-$lang['name_filter'] = 'Nombre de la foto';
-$lang['tags_filter'] = 'Etiquetas';
+$lang['Hits'] = 'Visitas';
+$lang['Max. number of photos'] = 'Número máximo de fotos';
 ?>
Index: /extensions/SmartAlbums/language/fr_FR/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/fr_FR/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/fr_FR/plugin.lang.php	(revision 16924)
@@ -38,13 +38,9 @@
 $lang['Hits must be an integer'] = 'Le nombre de vues doit être un entier';
 $lang['Limit must be an integer'] = 'La nombre d\'éléments doit être un entier';
+$lang['Rating score must be an integer'] = 'Le score doit être un entier';
 $lang['You can\'t use more than one limit filter'] = 'Vous ne pouvez choisir qu\'une seule limite de nombre d\'éléments';
 $lang['You can\'t use more than one level filter'] = 'Vous ne pouvez choisir qu\'un seul niveau de confidentialité';
-$lang['tags_filter'] = 'Tags';
-$lang['date_filter'] = 'Date';
-$lang['name_filter'] = 'Nom de la photo';
-$lang['author_filter'] = 'Auteur';
-$lang['hit_filter'] = 'Nombre de vues';
-$lang['level_filter'] = 'Niveau de confidentialité';
-$lang['limit_filter'] = 'Nombre max. d\'éléments';
+$lang['Hits'] = 'Nombre de vues';
+$lang['Max. number of photos'] = 'Nombre max. d\'éléments';
 $lang['For "Is (not) in", separate each author by a comma'] = 'Pour "Est/N\'est pas dans", séparez chaque auteur par une virgule';
 $lang['This album is a SmartAlbum'] = 'Cet album est un SmartAlbum';
Index: /extensions/SmartAlbums/language/hu_HU/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/hu_HU/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/hu_HU/plugin.lang.php	(revision 16924)
@@ -71,9 +71,5 @@
 $lang['author_filter'] = 'Szerző';
 $lang['create a new SmartAlbum'] = 'Új dinamikus album létrehozása';
-$lang['date_filter'] = 'Dátum';
-$lang['hit_filter'] = 'Találatok száma';
-$lang['level_filter'] = 'Hozzáférési szint';
-$lang['limit_filter'] = 'Képek max. száma';
-$lang['name_filter'] = 'Kép neve';
-$lang['tags_filter'] = 'Címkék';
+$lang['Hits'] = 'Találatok száma';
+$lang['Max. number of photos'] = 'Képek max. száma';
 ?>
Index: /extensions/SmartAlbums/language/it_IT/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/it_IT/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/it_IT/plugin.lang.php	(revision 16924)
@@ -40,11 +40,6 @@
 $lang['You can\'t use more than one limit filter'] = 'Potete scegliere un solo limite per il numero di elementi';
 $lang['You can\'t use more than one level filter'] = 'Potete scegliere un solo livello di privacy';
-$lang['tags_filter'] = 'Tag';
-$lang['date_filter'] = 'Data';
-$lang['name_filter'] = 'Nome della foto';
-$lang['author_filter'] = 'Autore';
-$lang['hit_filter'] = 'Numero di visite';
-$lang['level_filter'] = 'Livello di confidenzialità';
-$lang['limit_filter'] = 'Numero massimo di elementi';
+$lang['Hits'] = 'Numero di visite';
+$lang['Max. number of photos'] = 'Numero massimo di elementi';
 $lang['For "Is (not) in", separate each author by a comma'] = 'Per "È/Non è nel", separare ogni autore da una virgola';
 $lang['This album is a SmartAlbum'] = 'Questo album è uno SmartAlbum';
Index: /extensions/SmartAlbums/language/lv_LV/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/lv_LV/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/lv_LV/plugin.lang.php	(revision 16924)
@@ -52,9 +52,5 @@
 $lang['author_filter'] = 'Autors';
 $lang['create a new SmartAlbum'] = 'izveidot jaunu ViedoAlbumu (SmartAlbum)';
-$lang['date_filter'] = 'Datums';
-$lang['hit_filter'] = 'Skatījumi';
-$lang['level_filter'] = 'Līmenis';
-$lang['limit_filter'] = 'Foto maksimālais skaits';
-$lang['name_filter'] = 'Foto nosaukums';
-$lang['tags_filter'] = 'Cilnes (tegi)';
+$lang['Hits'] = 'Skatījumi';
+$lang['Max. number of photos'] = 'Foto maksimālais skaits';
 ?>
Index: /extensions/SmartAlbums/language/nl_NL/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/nl_NL/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/nl_NL/plugin.lang.php	(revision 16924)
@@ -52,9 +52,5 @@
 $lang['author_filter'] = 'Auteur';
 $lang['create a new SmartAlbum'] = 'maak een nieuwe SmartAlbum';
-$lang['date_filter'] = 'Datum';
-$lang['hit_filter'] = 'Hits';
-$lang['level_filter'] = 'Niveau';
-$lang['limit_filter'] = 'Max. aantal foto\'s';
-$lang['name_filter'] = 'Foto naam';
-$lang['tags_filter'] = 'Tags';
+$lang['Hits'] = 'Hits';
+$lang['Max. number of photos'] = 'Max. aantal foto\'s';
 ?>
Index: /extensions/SmartAlbums/language/pl_PL/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/pl_PL/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/pl_PL/plugin.lang.php	(revision 16924)
@@ -71,9 +71,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'stwórz nowy SmartAlbum';
-$lang['date_filter'] = 'Data';
-$lang['hit_filter'] = 'Wyświetlenia';
-$lang['level_filter'] = 'Poziom';
-$lang['limit_filter'] = 'Maksymalna liczba zdjęć';
-$lang['name_filter'] = 'Nazwa zdjęcia';
-$lang['tags_filter'] = 'Tagi';
+$lang['Hits'] = 'Wyświetlenia';
+$lang['Max. number of photos'] = 'Maksymalna liczba zdjęć';
 ?>
Index: /extensions/SmartAlbums/language/pt_PT/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/pt_PT/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/pt_PT/plugin.lang.php	(revision 16924)
@@ -72,9 +72,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'Criar um novo SmartAlbum';
-$lang['date_filter'] = 'Data';
-$lang['hit_filter'] = 'Número de vistas ';
-$lang['level_filter'] = 'Nível ';
-$lang['limit_filter'] = 'Número máximo de fotos';
-$lang['name_filter'] = 'Nome da fotografia ';
-$lang['tags_filter'] = 'Tags';
+$lang['Hits'] = 'Número de vistas ';
+$lang['Max. number of photos'] = 'Número máximo de fotos';
 ?>
Index: /extensions/SmartAlbums/language/ru_RU/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/ru_RU/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/ru_RU/plugin.lang.php	(revision 16924)
@@ -70,10 +70,6 @@
 $lang['author_filter'] = 'Автор';
 $lang['create a new SmartAlbum'] = 'создать новый Умный Альбом';
-$lang['date_filter'] = 'Дата';
-$lang['hit_filter'] = 'Просмотры';
-$lang['level_filter'] = 'Уровень';
-$lang['limit_filter'] = 'Максимальное число фотографий';
-$lang['name_filter'] = 'Название фото';
-$lang['tags_filter'] = 'Тэги';
+$lang['Hits'] = 'Просмотры';
+$lang['Max. number of photos'] = 'Максимальное число фотографий';
 $lang['Filters'] = 'Фильтры';
 ?>
Index: /extensions/SmartAlbums/language/sk_SK/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/sk_SK/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/sk_SK/plugin.lang.php	(revision 16924)
@@ -71,9 +71,5 @@
 $lang['author_filter'] = 'Autor';
 $lang['create a new SmartAlbum'] = 'vytvor nov&yacute; SmartAlbum';
-$lang['date_filter'] = 'D&aacute;tum';
-$lang['hit_filter'] = 'Pr&iacute;stupov';
-$lang['level_filter'] = '&Uacute;rove&#328;';
-$lang['limit_filter'] = 'Max. po&#269;et fotiek';
-$lang['name_filter'] = 'N&aacute;zov fotky';
-$lang['tags_filter'] = 'Tagov';
+$lang['Hits'] = 'Pr&iacute;stupov';
+$lang['Max. number of photos'] = 'Max. po&#269;et fotiek';
 ?>
Index: /extensions/SmartAlbums/language/tr_TR/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/tr_TR/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/tr_TR/plugin.lang.php	(revision 16924)
@@ -71,9 +71,5 @@
 $lang['author_filter'] = 'Yazar';
 $lang['create a new SmartAlbum'] = 'yeni bir SmartAlbum yarat';
-$lang['date_filter'] = 'Tarih';
-$lang['hit_filter'] = 'Tıklanma sayısı';
-$lang['level_filter'] = 'Seviye';
-$lang['limit_filter'] = 'Maks. fotoğraf sayısı';
-$lang['name_filter'] = 'Fotoğraf ismi';
-$lang['tags_filter'] = 'Etiketler';
+$lang['Hits'] = 'Tıklanma sayısı';
+$lang['Max. number of photos'] = 'Maks. fotoğraf sayısı';
 ?>
Index: /extensions/SmartAlbums/language/vi_VN/plugin.lang.php
===================================================================
--- /extensions/SmartAlbums/language/vi_VN/plugin.lang.php	(revision 16923)
+++ /extensions/SmartAlbums/language/vi_VN/plugin.lang.php	(revision 16924)
@@ -51,9 +51,5 @@
 $lang['author_filter'] = 'Tác giả';
 $lang['create a new SmartAlbum'] = 'Tạo SmartAlbum';
-$lang['date_filter'] = 'Ngày';
-$lang['hit_filter'] = 'Số lần truy cập';
-$lang['level_filter'] = 'Cấp';
-$lang['limit_filter'] = 'Số hình tối đa';
-$lang['name_filter'] = 'Tên hình (ảnh)';
-$lang['tags_filter'] = 'Thẻ';
+$lang['Hits'] = 'Số lần truy cập';
+$lang['Max. number of photos'] = 'Số hình tối đa';
 ?>
