Limit parameter to all pictures and all fragments. JS to add rmn keywords to fragment's keywords. Language updated.
authorcavaliet
Wed, 20 Feb 2013 16:28:09 +0100
changeset 49 df024e5f011d
parent 48 4c0838a3a8b6
child 50 7350d2a9971a
Limit parameter to all pictures and all fragments. JS to add rmn keywords to fragment's keywords. Language updated.
src/egonomy/locale/en/LC_MESSAGES/django.po
src/egonomy/locale/fr/LC_MESSAGES/django.po
src/egonomy/static/egonomy/css/egonomy.css
src/egonomy/templates/egonomy_create_fragment.html
src/egonomy/views.py
--- a/src/egonomy/locale/en/LC_MESSAGES/django.po	Tue Feb 19 16:29:53 2013 +0100
+++ b/src/egonomy/locale/en/LC_MESSAGES/django.po	Wed Feb 20 16:28:09 2013 +0100
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-02-06 06:09-0600\n"
+"POT-Creation-Date: 2013-02-20 09:10-0600\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -17,139 +17,161 @@
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
 
-#: settings.py:129
+#: settings.py:138
 msgid "French"
 msgstr ""
 
-#: settings.py:130
+#: settings.py:139
 msgid "English"
 msgstr ""
 
 #: templates/egonomy_all_fragments.html:7
-#: templates/egonomy_all_fragments.html:12 templates/egonomy_home.html:59
+#: templates/egonomy_all_fragments.html:18 templates/egonomy_home.html:48
 msgid "All fragments"
 msgstr ""
 
-#: templates/egonomy_all_fragments.html:40
-#: templates/egonomy_all_pictures.html:40
-#: templates/egonomy_annotate_picture.html:98
-#: templates/egonomy_create_fragment.html:99 templates/egonomy_home.html:50
-#: templates/egonomy_home.html.py:92 templates/egonomy_view_fragment.html:89
+#: templates/egonomy_all_fragments.html:14
+#: templates/egonomy_all_pictures.html:14
+msgid "No results for"
+msgstr ""
+
+#: templates/egonomy_all_fragments.html:16
+#: templates/egonomy_all_pictures.html:16
+msgid "Search results for"
+msgstr ""
+
+#: templates/egonomy_all_fragments.html:20
+#: templates/egonomy_all_pictures.html:7
+#: templates/egonomy_all_pictures.html:18
+#: templates/egonomy_all_pictures.html:20 templates/egonomy_home.html:13
+msgid "All pictures"
+msgstr ""
+
+#: templates/egonomy_all_fragments.html:56
+#: templates/egonomy_annotate_picture.html:107
+#: templates/egonomy_create_fragment.html:124 templates/egonomy_home.html:81
+#: templates/egonomy_view_fragment.html:100
 msgid "Annotated by"
 msgstr ""
 
-#: templates/egonomy_all_pictures.html:7
-#: templates/egonomy_all_pictures.html:12 templates/egonomy_home.html:23
-msgid "All pictures"
+#: templates/egonomy_all_pictures.html:48
+#: templates/egonomy_annotate_picture.html:12 templates/egonomy_home.html:39
+#: templates/egonomy_home.html.py:80
+msgid "No title"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:6
-msgid "Annotate a picture"
-msgstr ""
-
-#: templates/egonomy_annotate_picture.html:26
-msgid "Description"
-msgstr ""
-
-#: templates/egonomy_annotate_picture.html:30
+#: templates/egonomy_all_pictures.html:49
+#: templates/egonomy_annotate_picture.html:39 templates/egonomy_home.html:40
 msgid "Author"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:34
+#: templates/egonomy_all_pictures.html:49 templates/egonomy_home.html:40
+msgid "Not documented"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:7
+msgid "Annotate a picture"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:35
+msgid "Description"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:43
 msgid "Period"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:38
+#: templates/egonomy_annotate_picture.html:47
 msgid "Production site"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:42
+#: templates/egonomy_annotate_picture.html:51
 msgid "Localization"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:46
+#: templates/egonomy_annotate_picture.html:55
+#: templates/egonomy_create_fragment.html:79
 msgid "RMN keywords"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:51
-#: templates/egonomy_view_fragment.html:42
-msgid "Save keywords"
-msgstr ""
-
-#: templates/egonomy_annotate_picture.html:54
-msgid "Last fragment created"
-msgstr ""
-
-#: templates/egonomy_annotate_picture.html:55 templates/egonomy_base.html:22
-#: templates/egonomy_view_fragment.html:46
-msgid "by"
-msgstr ""
-
 #: templates/egonomy_annotate_picture.html:60
-#: templates/egonomy_view_fragment.html:51
+#: templates/egonomy_view_fragment.html:53
+msgid "Save keywords"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:63
+msgid "Last fragment created"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:64 templates/egonomy_base.html:36
+#: templates/egonomy_view_fragment.html:57
+msgid "by"
+msgstr ""
+
+#: templates/egonomy_annotate_picture.html:69
+#: templates/egonomy_view_fragment.html:62
 msgid "Create a fragment"
 msgstr ""
 
-#: templates/egonomy_annotate_picture.html:66
-#: templates/egonomy_create_fragment.html:67
-#: templates/egonomy_view_fragment.html:57
+#: templates/egonomy_annotate_picture.html:75
+#: templates/egonomy_create_fragment.html:92
+#: templates/egonomy_view_fragment.html:68
 msgid "Fragments from this picture"
 msgstr ""
 
-#: templates/egonomy_base.html:24
+#: templates/egonomy_base.html:38
 msgid "Search"
 msgstr ""
 
-#: templates/egonomy_base.html:29
+#: templates/egonomy_base.html:47
 msgid "Log out"
 msgstr ""
 
-#: templates/egonomy_base.html:31
+#: templates/egonomy_base.html:49
 msgid "Log in"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:6
+#: templates/egonomy_create_fragment.html:7
 msgid "Create or edit a fragment"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:19
+#: templates/egonomy_create_fragment.html:32
 msgid "Erase the drawing"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:20
+#: templates/egonomy_create_fragment.html:33
 msgid "Back to the original drawing"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:21
+#: templates/egonomy_create_fragment.html:34
 msgid "New fragment"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:39
-#: templates/egonomy_view_fragment.html:29
+#: templates/egonomy_create_fragment.html:62
+#: templates/egonomy_view_fragment.html:40
 msgid "Source picture"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:43
-#: templates/egonomy_create_fragment.html:44
+#: templates/egonomy_create_fragment.html:66
+#: templates/egonomy_create_fragment.html:67
 msgid "Fragment's title"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:47
-#: templates/egonomy_view_fragment.html:33
+#: templates/egonomy_create_fragment.html:70
+#: templates/egonomy_view_fragment.html:44
 msgid "Fragment's description"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:51
-#: templates/egonomy_view_fragment.html:37
+#: templates/egonomy_create_fragment.html:74
+#: templates/egonomy_view_fragment.html:48
 msgid "Users keywords"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:55
-#: templates/egonomy_view_fragment.html:45
-msgid "Last modification"
+#: templates/egonomy_create_fragment.html:80
+msgid "Add RMN keywords to yours"
 msgstr ""
 
-#: templates/egonomy_create_fragment.html:60
+#: templates/egonomy_create_fragment.html:85
 msgid "Save the fragment"
 msgstr ""
 
@@ -158,37 +180,25 @@
 msgstr ""
 
 #: templates/egonomy_home.html:12
-msgid "No results for"
-msgstr ""
-
-#: templates/egonomy_home.html:14
-msgid "Search results for"
-msgstr ""
-
-#: templates/egonomy_home.html:22
-msgid "Corresponding pictures"
-msgstr ""
-
-#: templates/egonomy_home.html:22
 msgid "Last annotated pictures"
 msgstr ""
 
-#: templates/egonomy_home.html:58
-msgid "Corresponding fragments"
-msgstr ""
-
-#: templates/egonomy_home.html:58
+#: templates/egonomy_home.html:47
 msgid "Last created fragments"
 msgstr ""
 
-#: templates/egonomy_home.html:91
+#: templates/egonomy_home.html:80
 msgid "Fragment from"
 msgstr ""
 
-#: templates/egonomy_view_fragment.html:6
+#: templates/egonomy_view_fragment.html:7
 msgid "View a fragment"
 msgstr ""
 
+#: templates/egonomy_view_fragment.html:56
+msgid "Last modification"
+msgstr ""
+
 #: templates/registration/login.html:5
 msgid "Login"
 msgstr ""
--- a/src/egonomy/locale/fr/LC_MESSAGES/django.po	Tue Feb 19 16:29:53 2013 +0100
+++ b/src/egonomy/locale/fr/LC_MESSAGES/django.po	Wed Feb 20 16:28:09 2013 +0100
@@ -8,7 +8,7 @@
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-02-06 06:09-0600\n"
+"POT-Creation-Date: 2013-02-20 09:10-0600\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -18,144 +18,168 @@
 "Content-Transfer-Encoding: 8bit\n"
 "Plural-Forms: nplurals=2; plural=(n > 1)\n"
 
-#: settings.py:129
+#: settings.py:138
 msgid "French"
 msgstr "Français"
 
-#: settings.py:130
+#: settings.py:139
 msgid "English"
 msgstr "Anglais"
 
 #: templates/egonomy_all_fragments.html:7
-#: templates/egonomy_all_fragments.html:12
-#: templates/egonomy_home.html:59
+#: templates/egonomy_all_fragments.html:18
+#: templates/egonomy_home.html:48
 msgid "All fragments"
 msgstr "Tous les fragments"
 
-#: templates/egonomy_all_fragments.html:40
-#: templates/egonomy_all_pictures.html:40
-#: templates/egonomy_annotate_picture.html:98
-#: templates/egonomy_create_fragment.html:99
-#: templates/egonomy_home.html:50
-#: templates/egonomy_home.html.py:92
-#: templates/egonomy_view_fragment.html:89
+#: templates/egonomy_all_fragments.html:14
+#: templates/egonomy_all_pictures.html:14
+msgid "No results for"
+msgstr "Pas de résultats pour"
+
+#: templates/egonomy_all_fragments.html:16
+#: templates/egonomy_all_pictures.html:16
+msgid "Search results for"
+msgstr "Résultats de recherche pour"
+
+#: templates/egonomy_all_fragments.html:20
+#: templates/egonomy_all_pictures.html:7
+#: templates/egonomy_all_pictures.html:18
+#: templates/egonomy_all_pictures.html:20
+#: templates/egonomy_home.html:13
+msgid "All pictures"
+msgstr "Toutes les images"
+
+#: templates/egonomy_all_fragments.html:56
+#: templates/egonomy_annotate_picture.html:107
+#: templates/egonomy_create_fragment.html:124
+#: templates/egonomy_home.html:81
+#: templates/egonomy_view_fragment.html:100
 msgid "Annotated by"
 msgstr "Annoté par"
 
-#: templates/egonomy_all_pictures.html:7
-#: templates/egonomy_all_pictures.html:12
-#: templates/egonomy_home.html:23
-msgid "All pictures"
-msgstr "Toutes les images"
+#: templates/egonomy_all_pictures.html:48
+#: templates/egonomy_annotate_picture.html:12
+#: templates/egonomy_home.html:39
+#: templates/egonomy_home.html.py:80
+msgid "No title"
+msgstr "Sans titre"
 
-#: templates/egonomy_annotate_picture.html:6
+#: templates/egonomy_all_pictures.html:49
+#: templates/egonomy_annotate_picture.html:39
+#: templates/egonomy_home.html:40
+msgid "Author"
+msgstr "Auteur"
+
+#: templates/egonomy_all_pictures.html:49
+#: templates/egonomy_home.html:40
+msgid "Not documented"
+msgstr "Non renseigné"
+
+#: templates/egonomy_annotate_picture.html:7
 msgid "Annotate a picture"
 msgstr "Annoter une image"
 
-#: templates/egonomy_annotate_picture.html:26
+#: templates/egonomy_annotate_picture.html:35
 msgid "Description"
 msgstr "Description"
 
-#: templates/egonomy_annotate_picture.html:30
-msgid "Author"
-msgstr "Auteur"
-
-#: templates/egonomy_annotate_picture.html:34
+#: templates/egonomy_annotate_picture.html:43
 msgid "Period"
 msgstr "Période"
 
-#: templates/egonomy_annotate_picture.html:38
+#: templates/egonomy_annotate_picture.html:47
 msgid "Production site"
 msgstr "Site de production"
 
-#: templates/egonomy_annotate_picture.html:42
+#: templates/egonomy_annotate_picture.html:51
 msgid "Localization"
 msgstr "Localisation"
 
-#: templates/egonomy_annotate_picture.html:46
+#: templates/egonomy_annotate_picture.html:55
+#: templates/egonomy_create_fragment.html:79
 msgid "RMN keywords"
 msgstr "Mots-clés RMN"
 
-#: templates/egonomy_annotate_picture.html:51
-#: templates/egonomy_view_fragment.html:42
+#: templates/egonomy_annotate_picture.html:60
+#: templates/egonomy_view_fragment.html:53
 msgid "Save keywords"
 msgstr "Enregistrer les mots-clés"
 
-#: templates/egonomy_annotate_picture.html:54
+#: templates/egonomy_annotate_picture.html:63
 msgid "Last fragment created"
 msgstr "Dernier fragment créé"
 
-#: templates/egonomy_annotate_picture.html:55
-#: templates/egonomy_base.html:22
-#: templates/egonomy_view_fragment.html:46
+#: templates/egonomy_annotate_picture.html:64
+#: templates/egonomy_base.html:36
+#: templates/egonomy_view_fragment.html:57
 msgid "by"
 msgstr "par"
 
-#: templates/egonomy_annotate_picture.html:60
-#: templates/egonomy_view_fragment.html:51
+#: templates/egonomy_annotate_picture.html:69
+#: templates/egonomy_view_fragment.html:62
 msgid "Create a fragment"
 msgstr "Créer un fragment"
 
-#: templates/egonomy_annotate_picture.html:66
-#: templates/egonomy_create_fragment.html:67
-#: templates/egonomy_view_fragment.html:57
+#: templates/egonomy_annotate_picture.html:75
+#: templates/egonomy_create_fragment.html:92
+#: templates/egonomy_view_fragment.html:68
 msgid "Fragments from this picture"
-msgstr "Fragments de cette image"
+msgstr "Fragments issus de cette image"
 
-#: templates/egonomy_base.html:24
+#: templates/egonomy_base.html:38
 msgid "Search"
 msgstr "Rechercher"
 
-#: templates/egonomy_base.html:29
+#: templates/egonomy_base.html:47
 msgid "Log out"
 msgstr "Se déconnecter"
 
-#: templates/egonomy_base.html:31
+#: templates/egonomy_base.html:49
 msgid "Log in"
 msgstr "Se connecter"
 
-#: templates/egonomy_create_fragment.html:6
+#: templates/egonomy_create_fragment.html:7
 msgid "Create or edit a fragment"
 msgstr "Créer ou modifier un fragment"
 
-#: templates/egonomy_create_fragment.html:19
+#: templates/egonomy_create_fragment.html:32
 msgid "Erase the drawing"
 msgstr "Effacer le tracé"
 
-#: templates/egonomy_create_fragment.html:20
+#: templates/egonomy_create_fragment.html:33
 msgid "Back to the original drawing"
 msgstr "Revenir au tracé d'origine"
 
-#: templates/egonomy_create_fragment.html:21
+#: templates/egonomy_create_fragment.html:34
 msgid "New fragment"
 msgstr "Nouveau fragment"
 
-#: templates/egonomy_create_fragment.html:39
-#: templates/egonomy_view_fragment.html:29
+#: templates/egonomy_create_fragment.html:62
+#: templates/egonomy_view_fragment.html:40
 msgid "Source picture"
 msgstr "Image source"
 
-#: templates/egonomy_create_fragment.html:43
-#: templates/egonomy_create_fragment.html:44
+#: templates/egonomy_create_fragment.html:66
+#: templates/egonomy_create_fragment.html:67
 msgid "Fragment's title"
 msgstr "Titre du fragment"
 
-#: templates/egonomy_create_fragment.html:47
-#: templates/egonomy_view_fragment.html:33
+#: templates/egonomy_create_fragment.html:70
+#: templates/egonomy_view_fragment.html:44
 msgid "Fragment's description"
 msgstr "Description du fragment"
 
-#: templates/egonomy_create_fragment.html:51
-#: templates/egonomy_view_fragment.html:37
+#: templates/egonomy_create_fragment.html:74
+#: templates/egonomy_view_fragment.html:48
 msgid "Users keywords"
 msgstr "Mots-clés Utilisateurs"
 
-#: templates/egonomy_create_fragment.html:55
-#: templates/egonomy_view_fragment.html:45
-msgid "Last modification"
-msgstr "Dernière modification"
+#: templates/egonomy_create_fragment.html:80
+msgid "Add RMN keywords to yours"
+msgstr "Ajouter les mots-clés RMN aux votres"
 
-#: templates/egonomy_create_fragment.html:60
+#: templates/egonomy_create_fragment.html:85
 msgid "Save the fragment"
 msgstr "Enregistrer le fragment"
 
@@ -164,37 +188,25 @@
 msgstr "Accueil"
 
 #: templates/egonomy_home.html:12
-msgid "No results for"
-msgstr "Pas de résultats pour"
-
-#: templates/egonomy_home.html:14
-msgid "Search results for"
-msgstr "Résultats de recherche pour"
-
-#: templates/egonomy_home.html:22
-msgid "Corresponding pictures"
-msgstr "Images correspondantes"
-
-#: templates/egonomy_home.html:22
 msgid "Last annotated pictures"
 msgstr "Dernières images annotées"
 
-#: templates/egonomy_home.html:58
-msgid "Corresponding fragments"
-msgstr "Fragments correspondants"
-
-#: templates/egonomy_home.html:58
+#: templates/egonomy_home.html:47
 msgid "Last created fragments"
 msgstr "Derniers fragments créés"
 
-#: templates/egonomy_home.html:91
+#: templates/egonomy_home.html:80
 msgid "Fragment from"
 msgstr "Fragment de"
 
-#: templates/egonomy_view_fragment.html:6
+#: templates/egonomy_view_fragment.html:7
 msgid "View a fragment"
 msgstr "Voir un fragment"
 
+#: templates/egonomy_view_fragment.html:56
+msgid "Last modification"
+msgstr "Dernière modification"
+
 #: templates/registration/login.html:5
 msgid "Login"
 msgstr "Se connecter"
--- a/src/egonomy/static/egonomy/css/egonomy.css	Tue Feb 19 16:29:53 2013 +0100
+++ b/src/egonomy/static/egonomy/css/egonomy.css	Wed Feb 20 16:28:09 2013 +0100
@@ -341,3 +341,9 @@
 #loginform_div, #loginform_div ul, #loginform_div li{
     margin: 10px 0 5px;
 }
+
+/* add tags buttons style */
+.add_tag_btn:hover{
+    text-decoration: underline;
+    cursor: hand; cursor: pointer;
+}
--- a/src/egonomy/templates/egonomy_create_fragment.html	Tue Feb 19 16:29:53 2013 +0100
+++ b/src/egonomy/templates/egonomy_create_fragment.html	Wed Feb 20 16:28:09 2013 +0100
@@ -11,6 +11,22 @@
         <script type="text/javascript" src="{% static 'egonomy/lib/raphael-min.js' %}"></script>
         <script type="text/javascript" src="{% static 'egonomy/js/cutout.js' %}"></script>
 {% endblock %}
+{% block js_inline %}
+{{block.super}}
+        <script type="text/javascript">
+            window.onload = function() {
+            	if($("#add_rmn_tags")){
+	                $("#add_rmn_tags").click(function() {
+	                    var s = $("#users_keywords").val();
+	                    if(s!="" && s.substring(s.length - 1)!=",") {
+	                        s = s + ",";
+	                    }
+	                    $("#users_keywords").val(s + $("#rmn_tags").html());
+	                });
+            	}
+           	};
+        </script>
+{% endblock %}
 
 {% block content %}
                 <div class="fullwidth">
@@ -39,7 +55,7 @@
 	                                <div class="cutout-canvas"></div>
 	                            </div>
                             </div>
-                            <input name="fragment_path" id="fragment_path" type="text" class="fragment-path column-half" value="M0.1 0.5L0.5 0.1L0.9 0.5L0.5 0.9Z" />
+                            <input name="fragment_path" id="fragment_path" type="hidden" class="fragment-path column-half" value="" />
                             <input name="image_id" id="image_id" type="hidden" value="{{ img.id }}" />
                         {% csrf_token %}
                         </div>
@@ -61,10 +77,12 @@
                                     <th>{% trans 'Users keywords' %}&nbsp;:</th>
                                     <td><textarea class="user-keywords" name="users_keywords" id="users_keywords"></textarea></td>
                                 </tr>
-                                <!--tr>
-                                    <th>{% trans 'Last modification' %}&nbsp;:</th>
-                                    <td>le 23 janvier 2013 par Utilisateur17</td>
-                                </tr-->
+                                {% if img.metadata.mots_cles %}
+                                <tr>
+                                    <th>{% trans 'RMN keywords' %}&nbsp;:</th>
+                                    <td><span id="rmn_tags">{{ img.metadata.mots_cles }}</span><br/><br/><span id="add_rmn_tags" class="right add_tag_btn">+ {% trans 'Add RMN keywords to yours' %}</span></td>
+                                </tr>
+                                {% endif %}
                             </table>
                             <div class="fullwidth">
                                 <input class="user-submit" type="submit" value="{% trans 'Save the fragment' %}" />
--- a/src/egonomy/views.py	Tue Feb 19 16:29:53 2013 +0100
+++ b/src/egonomy/views.py	Wed Feb 20 16:28:09 2013 +0100
@@ -100,7 +100,7 @@
             field = request.GET["field"]
 
     img_list = Image.objects.select_related('info', 'metadata')
-    nb = getattr(settings,"IMAGES_PER_PAGE", 32)
+    nb = request.GET.get("limit") or getattr(settings,"IMAGES_PER_PAGE", 32)
     if search:
         if not field or field == 'all':
             field = 'text'
@@ -116,9 +116,9 @@
     except (EmptyPage, InvalidPage):
         results = paginator.page(paginator.num_pages)
     
-    url_pagination = reverse("all_pictures")
+    url_pagination = reverse("all_pictures") + "?limit=" + str(nb)
     if search:
-        url_pagination = url_pagination + "?search=" + search
+        url_pagination = url_pagination + "&search=" + search
 
     return render_to_response("egonomy_all_pictures.html",
                               {'results':results, 'nb_pages':paginator.num_pages, 'cur_page_nb':cur_page_nb, "search":search, "nb_results":nb_results, "url_pagination":url_pagination},
@@ -140,7 +140,7 @@
             field = request.GET["field"]
 
     frg_list = Fragment.objects.select_related('image', 'image__info', 'image__metadata','author')
-    nb = getattr(settings,"IMAGES_PER_PAGE", 32)
+    nb = request.GET.get("limit") or getattr(settings,"IMAGES_PER_PAGE", 32)
     if search:
         if not field or field == 'all':
             field = 'text'
@@ -156,9 +156,9 @@
     except (EmptyPage, InvalidPage):
         results = paginator.page(paginator.num_pages)
         
-    url_pagination = reverse("all_fragments")
+    url_pagination = reverse("all_fragments") + "?limit=" + str(nb)
     if search:
-        url_pagination = url_pagination + "?search=" + search
+        url_pagination = url_pagination + "&search=" + search
 
     return render_to_response("egonomy_all_fragments.html",
                               {"search_fragment":True, 'results':results, 'nb_pages':paginator.num_pages, 'cur_page_nb':cur_page_nb, "search":search, "nb_results":nb_results, "url_pagination":url_pagination},