diff options
-rw-r--r-- | application/NetscapeBookmarkUtils.php | 4 | ||||
-rw-r--r-- | application/config/ConfigManager.php | 2 | ||||
-rw-r--r-- | docker/alpine/Dockerfile.latest | 26 | ||||
-rw-r--r-- | docker/alpine/Dockerfile.master | 26 | ||||
-rw-r--r-- | inc/languages/fr/LC_MESSAGES/shaarli.po | 228 | ||||
-rw-r--r-- | index.php | 33 | ||||
-rw-r--r-- | tests/NetscapeBookmarkUtils/BookmarkImportTest.php | 15 | ||||
-rw-r--r-- | tests/NetscapeBookmarkUtils/input/lowercase_doctype.htm | 8 |
8 files changed, 212 insertions, 130 deletions
diff --git a/application/NetscapeBookmarkUtils.php b/application/NetscapeBookmarkUtils.php index dd7057f8..2aa2da3b 100644 --- a/application/NetscapeBookmarkUtils.php +++ b/application/NetscapeBookmarkUtils.php | |||
@@ -108,7 +108,7 @@ class NetscapeBookmarkUtils | |||
108 | $filesize = $files['filetoupload']['size']; | 108 | $filesize = $files['filetoupload']['size']; |
109 | $data = file_get_contents($files['filetoupload']['tmp_name']); | 109 | $data = file_get_contents($files['filetoupload']['tmp_name']); |
110 | 110 | ||
111 | if (strpos($data, '<!DOCTYPE NETSCAPE-Bookmark-file-1>') === false) { | 111 | if (preg_match('/<!DOCTYPE NETSCAPE-Bookmark-file-1>/i', $data) === 0) { |
112 | return self::importStatus($filename, $filesize); | 112 | return self::importStatus($filename, $filesize); |
113 | } | 113 | } |
114 | 114 | ||
@@ -160,7 +160,7 @@ class NetscapeBookmarkUtils | |||
160 | } else if ($post['privacy'] == 'public') { | 160 | } else if ($post['privacy'] == 'public') { |
161 | // all imported links are public | 161 | // all imported links are public |
162 | $private = 0; | 162 | $private = 0; |
163 | } | 163 | } |
164 | 164 | ||
165 | $newLink = array( | 165 | $newLink = array( |
166 | 'title' => $bkm['title'], | 166 | 'title' => $bkm['title'], |
diff --git a/application/config/ConfigManager.php b/application/config/ConfigManager.php index 9e4c9f63..82f4a368 100644 --- a/application/config/ConfigManager.php +++ b/application/config/ConfigManager.php | |||
@@ -123,7 +123,7 @@ class ConfigManager | |||
123 | * Supports nested settings with dot separated keys. | 123 | * Supports nested settings with dot separated keys. |
124 | * | 124 | * |
125 | * @param string $setting Asked setting, keys separated with dots. | 125 | * @param string $setting Asked setting, keys separated with dots. |
126 | * @param string $value Value to set. | 126 | * @param mixed $value Value to set. |
127 | * @param bool $write Write the new setting in the config file, default false. | 127 | * @param bool $write Write the new setting in the config file, default false. |
128 | * @param bool $isLoggedIn User login state, default false. | 128 | * @param bool $isLoggedIn User login state, default false. |
129 | * | 129 | * |
diff --git a/docker/alpine/Dockerfile.latest b/docker/alpine/Dockerfile.latest index dd4a173c..e9015c13 100644 --- a/docker/alpine/Dockerfile.latest +++ b/docker/alpine/Dockerfile.latest | |||
@@ -1,9 +1,19 @@ | |||
1 | # Stage 1: | ||
2 | # - Get Shaarli sources | ||
3 | # - Resolve PHP dependencies with Composer | ||
4 | FROM composer:latest as composer | ||
5 | RUN curl -L https://github.com/shaarli/Shaarli/archive/latest.tar.gz | tar xzf - \ | ||
6 | && mv Shaarli-latest shaarli \ | ||
7 | && cd shaarli \ | ||
8 | && composer --prefer-dist --no-dev install | ||
9 | |||
10 | # Stage 2: | ||
11 | # - Shaarli image | ||
1 | FROM alpine:3.6 | 12 | FROM alpine:3.6 |
2 | MAINTAINER Shaarli Community | 13 | LABEL maintainer="Shaarli Community" |
3 | 14 | ||
4 | RUN apk --update --no-cache add \ | 15 | RUN apk --update --no-cache add \ |
5 | ca-certificates \ | 16 | ca-certificates \ |
6 | curl \ | ||
7 | nginx \ | 17 | nginx \ |
8 | php7 \ | 18 | php7 \ |
9 | php7-ctype \ | 19 | php7-ctype \ |
@@ -15,7 +25,6 @@ RUN apk --update --no-cache add \ | |||
15 | php7-json \ | 25 | php7-json \ |
16 | php7-mbstring \ | 26 | php7-mbstring \ |
17 | php7-openssl \ | 27 | php7-openssl \ |
18 | php7-phar \ | ||
19 | php7-session \ | 28 | php7-session \ |
20 | php7-xml \ | 29 | php7-xml \ |
21 | php7-zlib \ | 30 | php7-zlib \ |
@@ -25,22 +34,15 @@ COPY nginx.conf /etc/nginx/nginx.conf | |||
25 | COPY php-fpm.conf /etc/php7/php-fpm.conf | 34 | COPY php-fpm.conf /etc/php7/php-fpm.conf |
26 | COPY services.d /etc/services.d | 35 | COPY services.d /etc/services.d |
27 | 36 | ||
28 | RUN curl -sS https://getcomposer.org/installer | php7 -- --install-dir=/usr/local/bin --filename=composer \ | 37 | RUN rm -rf /etc/php7/php-fpm.d/www.conf \ |
29 | && rm -rf /etc/php7/php-fpm.d/www.conf \ | ||
30 | && sed -i 's/post_max_size.*/post_max_size = 10M/' /etc/php7/php.ini \ | 38 | && sed -i 's/post_max_size.*/post_max_size = 10M/' /etc/php7/php.ini \ |
31 | && sed -i 's/upload_max_filesize.*/upload_max_filesize = 10M/' /etc/php7/php.ini | 39 | && sed -i 's/upload_max_filesize.*/upload_max_filesize = 10M/' /etc/php7/php.ini |
32 | 40 | ||
33 | 41 | ||
34 | WORKDIR /var/www | 42 | WORKDIR /var/www |
35 | RUN curl -L https://github.com/shaarli/Shaarli/archive/latest.tar.gz | tar xzf - \ | 43 | COPY --from=composer /app/shaarli shaarli |
36 | && mv Shaarli-latest shaarli \ | ||
37 | && cd shaarli \ | ||
38 | && composer --prefer-dist --no-dev install \ | ||
39 | && rm -rf ~/.composer \ | ||
40 | && chown -R nginx:nginx . | ||
41 | 44 | ||
42 | VOLUME /var/www/shaarli/data | 45 | VOLUME /var/www/shaarli/data |
43 | |||
44 | EXPOSE 80 | 46 | EXPOSE 80 |
45 | 47 | ||
46 | ENTRYPOINT ["/bin/s6-svscan", "/etc/services.d"] | 48 | ENTRYPOINT ["/bin/s6-svscan", "/etc/services.d"] |
diff --git a/docker/alpine/Dockerfile.master b/docker/alpine/Dockerfile.master index 58f7c6e7..9cb4dec4 100644 --- a/docker/alpine/Dockerfile.master +++ b/docker/alpine/Dockerfile.master | |||
@@ -1,9 +1,19 @@ | |||
1 | # Stage 1: | ||
2 | # - Get Shaarli sources | ||
3 | # - Resolve PHP dependencies with Composer | ||
4 | FROM composer:latest as composer | ||
5 | RUN curl -L https://github.com/shaarli/Shaarli/archive/master.tar.gz | tar xzf - \ | ||
6 | && mv Shaarli-master shaarli \ | ||
7 | && cd shaarli \ | ||
8 | && composer --prefer-dist --no-dev install | ||
9 | |||
10 | # Stage 2: | ||
11 | # - Shaarli image | ||
1 | FROM alpine:3.6 | 12 | FROM alpine:3.6 |
2 | MAINTAINER Shaarli Community | 13 | LABEL maintainer="Shaarli Community" |
3 | 14 | ||
4 | RUN apk --update --no-cache add \ | 15 | RUN apk --update --no-cache add \ |
5 | ca-certificates \ | 16 | ca-certificates \ |
6 | curl \ | ||
7 | nginx \ | 17 | nginx \ |
8 | php7 \ | 18 | php7 \ |
9 | php7-ctype \ | 19 | php7-ctype \ |
@@ -15,7 +25,6 @@ RUN apk --update --no-cache add \ | |||
15 | php7-json \ | 25 | php7-json \ |
16 | php7-mbstring \ | 26 | php7-mbstring \ |
17 | php7-openssl \ | 27 | php7-openssl \ |
18 | php7-phar \ | ||
19 | php7-session \ | 28 | php7-session \ |
20 | php7-xml \ | 29 | php7-xml \ |
21 | php7-zlib \ | 30 | php7-zlib \ |
@@ -25,20 +34,15 @@ COPY nginx.conf /etc/nginx/nginx.conf | |||
25 | COPY php-fpm.conf /etc/php7/php-fpm.conf | 34 | COPY php-fpm.conf /etc/php7/php-fpm.conf |
26 | COPY services.d /etc/services.d | 35 | COPY services.d /etc/services.d |
27 | 36 | ||
28 | RUN curl -sS https://getcomposer.org/installer | php7 -- --install-dir=/usr/local/bin --filename=composer \ | 37 | RUN rm -rf /etc/php7/php-fpm.d/www.conf \ |
29 | && rm -rf /etc/php7/php-fpm.d/www.conf \ | ||
30 | && sed -i 's/post_max_size.*/post_max_size = 10M/' /etc/php7/php.ini \ | 38 | && sed -i 's/post_max_size.*/post_max_size = 10M/' /etc/php7/php.ini \ |
31 | && sed -i 's/upload_max_filesize.*/upload_max_filesize = 10M/' /etc/php7/php.ini | 39 | && sed -i 's/upload_max_filesize.*/upload_max_filesize = 10M/' /etc/php7/php.ini |
32 | 40 | ||
33 | 41 | ||
34 | WORKDIR /var/www | 42 | WORKDIR /var/www |
35 | RUN curl -L https://github.com/shaarli/Shaarli/archive/master.tar.gz | tar xzf - \ | 43 | COPY --from=composer /app/shaarli shaarli |
36 | && mv Shaarli-master shaarli \ | ||
37 | && cd shaarli \ | ||
38 | && composer --prefer-dist --no-dev install \ | ||
39 | && rm -rf ~/.composer \ | ||
40 | && chown -R nginx:nginx . | ||
41 | 44 | ||
45 | RUN chown -R nginx:nginx . | ||
42 | VOLUME /var/www/shaarli/data | 46 | VOLUME /var/www/shaarli/data |
43 | 47 | ||
44 | EXPOSE 80 | 48 | EXPOSE 80 |
diff --git a/inc/languages/fr/LC_MESSAGES/shaarli.po b/inc/languages/fr/LC_MESSAGES/shaarli.po index 857b13c7..fd47217e 100644 --- a/inc/languages/fr/LC_MESSAGES/shaarli.po +++ b/inc/languages/fr/LC_MESSAGES/shaarli.po | |||
@@ -1,8 +1,9 @@ | |||
1 | msgid "" | 1 | msgid "" |
2 | msgstr "" | 2 | msgstr "" |
3 | "Project-Id-Version: Shaarli\n" | 3 | "Project-Id-Version: Shaarli\n" |
4 | "POT-Creation-Date: 2018-01-24 18:43+0100\n" | 4 | "Report-Msgid-Bugs-To: \n" |
5 | "PO-Revision-Date: 2018-01-24 18:44+0100\n" | 5 | "POT-Creation-Date: 2018-02-24 12:39+0100\n" |
6 | "PO-Revision-Date: 2018-02-24 12:43+0100\n" | ||
6 | "Last-Translator: \n" | 7 | "Last-Translator: \n" |
7 | "Language-Team: Shaarli\n" | 8 | "Language-Team: Shaarli\n" |
8 | "Language: fr_FR\n" | 9 | "Language: fr_FR\n" |
@@ -15,6 +16,8 @@ msgstr "" | |||
15 | "X-Poedit-SourceCharset: UTF-8\n" | 16 | "X-Poedit-SourceCharset: UTF-8\n" |
16 | "X-Poedit-KeywordsList: t:1,2;t\n" | 17 | "X-Poedit-KeywordsList: t:1,2;t\n" |
17 | "X-Poedit-SearchPath-0: .\n" | 18 | "X-Poedit-SearchPath-0: .\n" |
19 | "X-Poedit-SearchPathExcluded-0: node_modules\n" | ||
20 | "X-Poedit-SearchPathExcluded-1: vendor\n" | ||
18 | 21 | ||
19 | #: application/ApplicationUtils.php:153 | 22 | #: application/ApplicationUtils.php:153 |
20 | #, php-format | 23 | #, php-format |
@@ -66,15 +69,15 @@ msgstr "Le fichier d'historique n'est pas accessible en lecture ou en écriture" | |||
66 | msgid "Could not parse history file" | 69 | msgid "Could not parse history file" |
67 | msgstr "Format incorrect pour le fichier d'historique" | 70 | msgstr "Format incorrect pour le fichier d'historique" |
68 | 71 | ||
69 | #: application/Languages.php:159 | 72 | #: application/Languages.php:161 |
70 | msgid "Automatic" | 73 | msgid "Automatic" |
71 | msgstr "Automatique" | 74 | msgstr "Automatique" |
72 | 75 | ||
73 | #: application/Languages.php:160 | 76 | #: application/Languages.php:162 |
74 | msgid "English" | 77 | msgid "English" |
75 | msgstr "Anglais" | 78 | msgstr "Anglais" |
76 | 79 | ||
77 | #: application/Languages.php:161 | 80 | #: application/Languages.php:163 |
78 | msgid "French" | 81 | msgid "French" |
79 | msgstr "Français" | 82 | msgstr "Français" |
80 | 83 | ||
@@ -249,62 +252,135 @@ msgstr "Vous n'êtes pas autorisé à modifier la configuration." | |||
249 | msgid "Error accessing" | 252 | msgid "Error accessing" |
250 | msgstr "Une erreur s'est produite en accédant à " | 253 | msgstr "Une erreur s'est produite en accédant à " |
251 | 254 | ||
252 | #: index.php:135 | 255 | #: index.php:142 |
253 | msgid "Shared links on " | 256 | msgid "Shared links on " |
254 | msgstr "Liens partagés sur " | 257 | msgstr "Liens partagés sur " |
255 | 258 | ||
256 | #: index.php:157 | 259 | #: index.php:164 |
257 | msgid "Insufficient permissions:" | 260 | msgid "Insufficient permissions:" |
258 | msgstr "Permissions insuffisantes :" | 261 | msgstr "Permissions insuffisantes :" |
259 | 262 | ||
260 | #: index.php:384 | 263 | #: index.php:303 |
261 | msgid "I said: NO. You are banned for the moment. Go away." | 264 | msgid "I said: NO. You are banned for the moment. Go away." |
262 | msgstr "NON. Vous êtes banni pour le moment. Revenez plus tard." | 265 | msgstr "NON. Vous êtes banni pour le moment. Revenez plus tard." |
263 | 266 | ||
264 | #: index.php:449 | 267 | #: index.php:368 |
265 | msgid "Wrong login/password." | 268 | msgid "Wrong login/password." |
266 | msgstr "Nom d'utilisateur ou mot de passe incorrects." | 269 | msgstr "Nom d'utilisateur ou mot de passe incorrects." |
267 | 270 | ||
268 | #: index.php:1103 | 271 | #: index.php:576 tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:42 |
272 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:42 | ||
273 | msgid "Daily" | ||
274 | msgstr "Quotidien" | ||
275 | |||
276 | #: index.php:681 tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:28 | ||
277 | #: tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:44 | ||
278 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:71 | ||
279 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:95 | ||
280 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:71 | ||
281 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:95 | ||
282 | msgid "Login" | ||
283 | msgstr "Connexion" | ||
284 | |||
285 | #: index.php:722 tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:39 | ||
286 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:39 | ||
287 | msgid "Picture wall" | ||
288 | msgstr "Mur d'images" | ||
289 | |||
290 | #: index.php:770 tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:36 | ||
291 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:36 | ||
292 | #: tmp/tag.cloud.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 | ||
293 | msgid "Tag cloud" | ||
294 | msgstr "Nuage de tags" | ||
295 | |||
296 | #: index.php:803 tmp/tag.list.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 | ||
297 | msgid "Tag list" | ||
298 | msgstr "Liste des tags" | ||
299 | |||
300 | #: index.php:1028 tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:31 | ||
301 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:31 | ||
302 | msgid "Tools" | ||
303 | msgstr "Outils" | ||
304 | |||
305 | #: index.php:1037 | ||
269 | msgid "You are not supposed to change a password on an Open Shaarli." | 306 | msgid "You are not supposed to change a password on an Open Shaarli." |
270 | msgstr "" | 307 | msgstr "" |
271 | "Vous n'êtes pas censé modifier le mot de passe d'un Shaarli en mode ouvert." | 308 | "Vous n'êtes pas censé modifier le mot de passe d'un Shaarli en mode ouvert." |
272 | 309 | ||
273 | #: index.php:1108 index.php:1149 index.php:1225 index.php:1255 index.php:1355 | 310 | #: index.php:1042 index.php:1084 index.php:1162 index.php:1193 index.php:1293 |
274 | msgid "Wrong token." | 311 | msgid "Wrong token." |
275 | msgstr "Jeton invalide." | 312 | msgstr "Jeton invalide." |
276 | 313 | ||
277 | #: index.php:1113 | 314 | #: index.php:1047 |
278 | msgid "The old password is not correct." | 315 | msgid "The old password is not correct." |
279 | msgstr "L'ancien mot de passe est incorrect." | 316 | msgstr "L'ancien mot de passe est incorrect." |
280 | 317 | ||
281 | #: index.php:1133 | 318 | #: index.php:1067 |
282 | msgid "Your password has been changed" | 319 | msgid "Your password has been changed" |
283 | msgstr "Votre mot de passe a été modifié" | 320 | msgstr "Votre mot de passe a été modifié" |
284 | 321 | ||
285 | #: index.php:1186 | 322 | #: index.php:1072 |
323 | #: tmp/changepassword.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 | ||
324 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 | ||
325 | msgid "Change password" | ||
326 | msgstr "Modification du mot de passe" | ||
327 | |||
328 | #: index.php:1121 | ||
286 | msgid "Configuration was saved." | 329 | msgid "Configuration was saved." |
287 | msgstr "La configuration a été sauvegardé." | 330 | msgstr "La configuration a été sauvegardé." |
288 | 331 | ||
289 | #: index.php:1237 | 332 | #: index.php:1145 tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:24 |
333 | msgid "Configure" | ||
334 | msgstr "Configurer" | ||
335 | |||
336 | #: index.php:1156 tmp/changetag.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 | ||
337 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:36 | ||
338 | msgid "Manage tags" | ||
339 | msgstr "Gérer les tags" | ||
340 | |||
341 | #: index.php:1174 | ||
290 | #, php-format | 342 | #, php-format |
291 | msgid "The tag was removed from %d link." | 343 | msgid "The tag was removed from %d link." |
292 | msgid_plural "The tag was removed from %d links." | 344 | msgid_plural "The tag was removed from %d links." |
293 | msgstr[0] "Le tag a été supprimé de %d lien." | 345 | msgstr[0] "Le tag a été supprimé de %d lien." |
294 | msgstr[1] "Le tag a été supprimé de %d liens." | 346 | msgstr[1] "Le tag a été supprimé de %d liens." |
295 | 347 | ||
296 | #: index.php:1238 | 348 | #: index.php:1175 |
297 | #, php-format | 349 | #, php-format |
298 | msgid "The tag was renamed in %d link." | 350 | msgid "The tag was renamed in %d link." |
299 | msgid_plural "The tag was renamed in %d links." | 351 | msgid_plural "The tag was renamed in %d links." |
300 | msgstr[0] "Le tag a été renommé dans %d lien." | 352 | msgstr[0] "Le tag a été renommé dans %d lien." |
301 | msgstr[1] "Le tag a été renommé dans %d liens." | 353 | msgstr[1] "Le tag a été renommé dans %d liens." |
302 | 354 | ||
303 | #: index.php:1454 | 355 | #: index.php:1183 tmp/addlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 |
356 | msgid "Shaare a new link" | ||
357 | msgstr "Partager un nouveau lien" | ||
358 | |||
359 | #: index.php:1353 tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:14 | ||
360 | #: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:170 | ||
361 | msgid "Edit" | ||
362 | msgstr "Modifier" | ||
363 | |||
364 | #: index.php:1353 index.php:1418 | ||
365 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | ||
366 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:26 | ||
367 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:26 | ||
368 | msgid "Shaare" | ||
369 | msgstr "Shaare" | ||
370 | |||
371 | #: index.php:1387 | ||
304 | msgid "Note: " | 372 | msgid "Note: " |
305 | msgstr "Note : " | 373 | msgstr "Note : " |
306 | 374 | ||
307 | #: index.php:1563 | 375 | #: index.php:1427 tmp/export.b91ef64efc3688266305ea9b42e5017e.rtpl.php:65 |
376 | msgid "Export" | ||
377 | msgstr "Exporter" | ||
378 | |||
379 | #: index.php:1489 tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:83 | ||
380 | msgid "Import" | ||
381 | msgstr "Importer" | ||
382 | |||
383 | #: index.php:1499 | ||
308 | #, php-format | 384 | #, php-format |
309 | msgid "" | 385 | msgid "" |
310 | "The file you are trying to upload is probably bigger than what this " | 386 | "The file you are trying to upload is probably bigger than what this " |
@@ -314,7 +390,16 @@ msgstr "" | |||
314 | "le serveur web peut accepter (%s). Merci de l'envoyer en parties plus " | 390 | "le serveur web peut accepter (%s). Merci de l'envoyer en parties plus " |
315 | "légères." | 391 | "légères." |
316 | 392 | ||
317 | #: index.php:1983 | 393 | #: index.php:1538 tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:26 |
394 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:22 | ||
395 | msgid "Plugin administration" | ||
396 | msgstr "Administration des extensions" | ||
397 | |||
398 | #: index.php:1703 | ||
399 | msgid "Search: " | ||
400 | msgstr "Recherche : " | ||
401 | |||
402 | #: index.php:1930 | ||
318 | #, php-format | 403 | #, php-format |
319 | msgid "" | 404 | msgid "" |
320 | "<pre>Sessions do not seem to work correctly on your server.<br>Make sure the " | 405 | "<pre>Sessions do not seem to work correctly on your server.<br>Make sure the " |
@@ -333,7 +418,7 @@ msgstr "" | |||
333 | "cookies. Nous vous recommandons d'accéder à votre serveur depuis son adresse " | 418 | "cookies. Nous vous recommandons d'accéder à votre serveur depuis son adresse " |
334 | "IP ou un <em>Fully Qualified Domain Name</em>.<br>" | 419 | "IP ou un <em>Fully Qualified Domain Name</em>.<br>" |
335 | 420 | ||
336 | #: index.php:1993 | 421 | #: index.php:1940 |
337 | msgid "Click to try again." | 422 | msgid "Click to try again." |
338 | msgstr "Cliquer ici pour réessayer." | 423 | msgstr "Cliquer ici pour réessayer." |
339 | 424 | ||
@@ -358,7 +443,7 @@ msgstr "Voir sur archive.org" | |||
358 | msgid "For each link, add an Archive.org icon." | 443 | msgid "For each link, add an Archive.org icon." |
359 | msgstr "Pour chaque lien, ajoute une icône pour Archive.org." | 444 | msgstr "Pour chaque lien, ajoute une icône pour Archive.org." |
360 | 445 | ||
361 | #: plugins/demo_plugin/demo_plugin.php:469 | 446 | #: plugins/demo_plugin/demo_plugin.php:465 |
362 | msgid "" | 447 | msgid "" |
363 | "A demo plugin covering all use cases for template designers and plugin " | 448 | "A demo plugin covering all use cases for template designers and plugin " |
364 | "developers." | 449 | "developers." |
@@ -383,19 +468,19 @@ msgstr "" | |||
383 | msgid "Isso server URL (without 'http://')" | 468 | msgid "Isso server URL (without 'http://')" |
384 | msgstr "URL du serveur Isso (sans 'http://')" | 469 | msgstr "URL du serveur Isso (sans 'http://')" |
385 | 470 | ||
386 | #: plugins/markdown/markdown.php:159 | 471 | #: plugins/markdown/markdown.php:158 |
387 | msgid "Description will be rendered with" | 472 | msgid "Description will be rendered with" |
388 | msgstr "La description sera générée avec" | 473 | msgstr "La description sera générée avec" |
389 | 474 | ||
390 | #: plugins/markdown/markdown.php:160 | 475 | #: plugins/markdown/markdown.php:159 |
391 | msgid "Markdown syntax documentation" | 476 | msgid "Markdown syntax documentation" |
392 | msgstr "Documentation sur la syntaxe Markdown" | 477 | msgstr "Documentation sur la syntaxe Markdown" |
393 | 478 | ||
394 | #: plugins/markdown/markdown.php:161 | 479 | #: plugins/markdown/markdown.php:160 |
395 | msgid "Markdown syntax" | 480 | msgid "Markdown syntax" |
396 | msgstr "la syntaxe Markdown" | 481 | msgstr "la syntaxe Markdown" |
397 | 482 | ||
398 | #: plugins/markdown/markdown.php:340 | 483 | #: plugins/markdown/markdown.php:339 |
399 | msgid "" | 484 | msgid "" |
400 | "Render shaare description with Markdown syntax.<br><strong>Warning</" | 485 | "Render shaare description with Markdown syntax.<br><strong>Warning</" |
401 | "strong>:\n" | 486 | "strong>:\n" |
@@ -507,19 +592,10 @@ msgstr[1] "Rechercher" | |||
507 | msgid "Sorry, nothing to see here." | 592 | msgid "Sorry, nothing to see here." |
508 | msgstr "Désolé, il y a rien à voir ici." | 593 | msgstr "Désolé, il y a rien à voir ici." |
509 | 594 | ||
510 | #: tmp/addlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 | ||
511 | msgid "Shaare a new link" | ||
512 | msgstr "Partager un nouveau lien" | ||
513 | |||
514 | #: tmp/addlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | 595 | #: tmp/addlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 |
515 | msgid "URL or leave empty to post a note" | 596 | msgid "URL or leave empty to post a note" |
516 | msgstr "URL ou laisser vide pour créer une note" | 597 | msgstr "URL ou laisser vide pour créer une note" |
517 | 598 | ||
518 | #: tmp/changepassword.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 | ||
519 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 | ||
520 | msgid "Change password" | ||
521 | msgstr "Modification du mot de passe" | ||
522 | |||
523 | #: tmp/changepassword.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | 599 | #: tmp/changepassword.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 |
524 | msgid "Current password" | 600 | msgid "Current password" |
525 | msgstr "Mot de passe actuel" | 601 | msgstr "Mot de passe actuel" |
@@ -532,11 +608,6 @@ msgstr "Nouveau mot de passe" | |||
532 | msgid "Change" | 608 | msgid "Change" |
533 | msgstr "Changer" | 609 | msgstr "Changer" |
534 | 610 | ||
535 | #: tmp/changetag.b91ef64efc3688266305ea9b42e5017e.rtpl.php:13 | ||
536 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:36 | ||
537 | msgid "Manage tags" | ||
538 | msgstr "Gérer les tags" | ||
539 | |||
540 | #: tmp/changetag.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | 611 | #: tmp/changetag.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 |
541 | #: tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:77 | 612 | #: tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:77 |
542 | msgid "Tag" | 613 | msgid "Tag" |
@@ -568,10 +639,6 @@ msgstr "Vous pouvez aussi modifier les tags dans la" | |||
568 | msgid "tag list" | 639 | msgid "tag list" |
569 | msgstr "liste des tags" | 640 | msgstr "liste des tags" |
570 | 641 | ||
571 | #: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:24 | ||
572 | msgid "Configure" | ||
573 | msgstr "Configurer" | ||
574 | |||
575 | #: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 | 642 | #: tmp/configure.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 |
576 | msgid "title" | 643 | msgid "title" |
577 | msgstr "titre" | 644 | msgstr "titre" |
@@ -697,17 +764,6 @@ msgstr "Tous les liens d'un jour sur une page." | |||
697 | msgid "Next day" | 764 | msgid "Next day" |
698 | msgstr "Jour suivant" | 765 | msgstr "Jour suivant" |
699 | 766 | ||
700 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:14 | ||
701 | #: tmp/linklist.b91ef64efc3688266305ea9b42e5017e.rtpl.php:170 | ||
702 | msgid "Edit" | ||
703 | msgstr "Modifier" | ||
704 | |||
705 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | ||
706 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:26 | ||
707 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:26 | ||
708 | msgid "Shaare" | ||
709 | msgstr "Shaare" | ||
710 | |||
711 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:25 | 767 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:25 |
712 | msgid "Created:" | 768 | msgid "Created:" |
713 | msgstr "Création :" | 769 | msgstr "Création :" |
@@ -740,7 +796,7 @@ msgstr "Privé" | |||
740 | 796 | ||
741 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:74 | 797 | #: tmp/editlink.b91ef64efc3688266305ea9b42e5017e.rtpl.php:74 |
742 | msgid "Apply Changes" | 798 | msgid "Apply Changes" |
743 | msgstr "Appliquer les changements" | 799 | msgstr "Appliquer" |
744 | 800 | ||
745 | #: tmp/export.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | 801 | #: tmp/export.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 |
746 | msgid "Export Database" | 802 | msgid "Export Database" |
@@ -766,10 +822,6 @@ msgstr "Préfixer les liens de notes avec l'URL de l'instance de Shaarli" | |||
766 | msgid "Useful to import bookmarks in a web browser" | 822 | msgid "Useful to import bookmarks in a web browser" |
767 | msgstr "Utile pour importer les marques-pages dans un navigateur" | 823 | msgstr "Utile pour importer les marques-pages dans un navigateur" |
768 | 824 | ||
769 | #: tmp/export.b91ef64efc3688266305ea9b42e5017e.rtpl.php:65 | ||
770 | msgid "Export" | ||
771 | msgstr "Exporter" | ||
772 | |||
773 | #: tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 | 825 | #: tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:16 |
774 | msgid "Import Database" | 826 | msgid "Import Database" |
775 | msgstr "Importer des données" | 827 | msgstr "Importer des données" |
@@ -807,10 +859,6 @@ msgstr "Les doublons s'appuient sur les URL" | |||
807 | msgid "Add default tags" | 859 | msgid "Add default tags" |
808 | msgstr "Ajouter des tags par défaut" | 860 | msgstr "Ajouter des tags par défaut" |
809 | 861 | ||
810 | #: tmp/import.b91ef64efc3688266305ea9b42e5017e.rtpl.php:83 | ||
811 | msgid "Import" | ||
812 | msgstr "Importer" | ||
813 | |||
814 | #: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:22 | 862 | #: tmp/install.b91ef64efc3688266305ea9b42e5017e.rtpl.php:22 |
815 | msgid "Install Shaarli" | 863 | msgid "Install Shaarli" |
816 | msgstr "Installation de Shaarli" | 864 | msgstr "Installation de Shaarli" |
@@ -967,15 +1015,6 @@ msgstr "" | |||
967 | "Vous avez été banni après trop d'échec d'authentification. Merci de " | 1015 | "Vous avez été banni après trop d'échec d'authentification. Merci de " |
968 | "réessayer plus tard." | 1016 | "réessayer plus tard." |
969 | 1017 | ||
970 | #: tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:28 | ||
971 | #: tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:44 | ||
972 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:71 | ||
973 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:95 | ||
974 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:71 | ||
975 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:95 | ||
976 | msgid "Login" | ||
977 | msgstr "Connexion" | ||
978 | |||
979 | #: tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:41 | 1018 | #: tmp/loginform.b91ef64efc3688266305ea9b42e5017e.rtpl.php:41 |
980 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:151 | 1019 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:151 |
981 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:151 | 1020 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:151 |
@@ -1009,27 +1048,6 @@ msgstr "Déplier tout" | |||
1009 | msgid "Are you sure you want to delete this link?" | 1048 | msgid "Are you sure you want to delete this link?" |
1010 | msgstr "Êtes-vous sûr de vouloir supprimer ce lien ?" | 1049 | msgstr "Êtes-vous sûr de vouloir supprimer ce lien ?" |
1011 | 1050 | ||
1012 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:31 | ||
1013 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:31 | ||
1014 | msgid "Tools" | ||
1015 | msgstr "Outils" | ||
1016 | |||
1017 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:36 | ||
1018 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:36 | ||
1019 | #: tmp/tag.cloud.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 | ||
1020 | msgid "Tag cloud" | ||
1021 | msgstr "Nuage de tags" | ||
1022 | |||
1023 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:39 | ||
1024 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:39 | ||
1025 | msgid "Picture wall" | ||
1026 | msgstr "Mur d'images" | ||
1027 | |||
1028 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:42 | ||
1029 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:42 | ||
1030 | msgid "Daily" | ||
1031 | msgstr "Quotidien" | ||
1032 | |||
1033 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:61 | 1051 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:61 |
1034 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:86 | 1052 | #: tmp/page.header.b91ef64efc3688266305ea9b42e5017e.rtpl.php:86 |
1035 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:61 | 1053 | #: tmp/page.header.cedf684561d925457130839629000a81.rtpl.php:61 |
@@ -1067,11 +1085,6 @@ msgid "You need to enable Javascript to change plugin loading order." | |||
1067 | msgstr "" | 1085 | msgstr "" |
1068 | "Vous devez activer Javascript pour pouvoir modifier l'ordre des extensions." | 1086 | "Vous devez activer Javascript pour pouvoir modifier l'ordre des extensions." |
1069 | 1087 | ||
1070 | #: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:26 | ||
1071 | #: tmp/tools.b91ef64efc3688266305ea9b42e5017e.rtpl.php:22 | ||
1072 | msgid "Plugin administration" | ||
1073 | msgstr "Administration des extensions" | ||
1074 | |||
1075 | #: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 | 1088 | #: tmp/pluginsadmin.b91ef64efc3688266305ea9b42e5017e.rtpl.php:29 |
1076 | msgid "Enabled Plugins" | 1089 | msgid "Enabled Plugins" |
1077 | msgstr "Extensions activées" | 1090 | msgstr "Extensions activées" |
@@ -1137,10 +1150,6 @@ msgstr "tags" | |||
1137 | msgid "List all links with those tags" | 1150 | msgid "List all links with those tags" |
1138 | msgstr "Lister tous les liens avec ces tags" | 1151 | msgstr "Lister tous les liens avec ces tags" |
1139 | 1152 | ||
1140 | #: tmp/tag.list.b91ef64efc3688266305ea9b42e5017e.rtpl.php:19 | ||
1141 | msgid "Tag list" | ||
1142 | msgstr "List des tags" | ||
1143 | |||
1144 | #: tmp/tag.sort.b91ef64efc3688266305ea9b42e5017e.rtpl.php:3 | 1153 | #: tmp/tag.sort.b91ef64efc3688266305ea9b42e5017e.rtpl.php:3 |
1145 | #: tmp/tag.sort.cedf684561d925457130839629000a81.rtpl.php:3 | 1154 | #: tmp/tag.sort.cedf684561d925457130839629000a81.rtpl.php:3 |
1146 | msgid "Sort by:" | 1155 | msgid "Sort by:" |
@@ -1289,6 +1298,21 @@ msgstr "" | |||
1289 | "Glisser ce lien dans votre barre de favoris ou cliquer droit dessus et « " | 1298 | "Glisser ce lien dans votre barre de favoris ou cliquer droit dessus et « " |
1290 | "Ajouter aux favoris »" | 1299 | "Ajouter aux favoris »" |
1291 | 1300 | ||
1301 | #, fuzzy | ||
1302 | #~| msgid "Change" | ||
1303 | #~ msgid "range" | ||
1304 | #~ msgstr "Changer" | ||
1305 | |||
1306 | #, fuzzy | ||
1307 | #~| msgid "Description" | ||
1308 | #~ msgid "Declaration" | ||
1309 | #~ msgstr "Description" | ||
1310 | |||
1311 | #, fuzzy | ||
1312 | #~| msgid "for" | ||
1313 | #~ msgid "foo" | ||
1314 | #~ msgstr "pour" | ||
1315 | |||
1292 | #~ msgid "Filter links by visibility" | 1316 | #~ msgid "Filter links by visibility" |
1293 | #~ msgstr "Filtrer les liens par visibilité" | 1317 | #~ msgstr "Filtrer les liens par visibilité" |
1294 | 1318 | ||
@@ -573,6 +573,7 @@ function showDaily($pageBuilder, $LINKSDB, $conf, $pluginManager) | |||
573 | $pageBuilder->assign($key, $value); | 573 | $pageBuilder->assign($key, $value); |
574 | } | 574 | } |
575 | 575 | ||
576 | $pageBuilder->assign('pagetitle', t('Daily') .' - '. $conf->get('general.title', 'Shaarli')); | ||
576 | $pageBuilder->renderPage('daily'); | 577 | $pageBuilder->renderPage('daily'); |
577 | exit; | 578 | exit; |
578 | } | 579 | } |
@@ -677,6 +678,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
677 | // add default state of the 'remember me' checkbox | 678 | // add default state of the 'remember me' checkbox |
678 | $PAGE->assign('remember_user_default', $conf->get('privacy.remember_user_default')); | 679 | $PAGE->assign('remember_user_default', $conf->get('privacy.remember_user_default')); |
679 | $PAGE->assign('user_can_login', $loginManager->canLogin($_SERVER)); | 680 | $PAGE->assign('user_can_login', $loginManager->canLogin($_SERVER)); |
681 | $PAGE->assign('pagetitle', t('Login') .' - '. $conf->get('general.title', 'Shaarli')); | ||
680 | $PAGE->renderPage('loginform'); | 682 | $PAGE->renderPage('loginform'); |
681 | exit; | 683 | exit; |
682 | } | 684 | } |
@@ -717,6 +719,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
717 | $PAGE->assign($key, $value); | 719 | $PAGE->assign($key, $value); |
718 | } | 720 | } |
719 | 721 | ||
722 | $PAGE->assign('pagetitle', t('Picture wall') .' - '. $conf->get('general.title', 'Shaarli')); | ||
720 | $PAGE->renderPage('picwall'); | 723 | $PAGE->renderPage('picwall'); |
721 | exit; | 724 | exit; |
722 | } | 725 | } |
@@ -752,8 +755,9 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
752 | ); | 755 | ); |
753 | } | 756 | } |
754 | 757 | ||
758 | $searchTags = implode(' ', escape($filteringTags)); | ||
755 | $data = array( | 759 | $data = array( |
756 | 'search_tags' => implode(' ', escape($filteringTags)), | 760 | 'search_tags' => $searchTags, |
757 | 'tags' => $tagList, | 761 | 'tags' => $tagList, |
758 | ); | 762 | ); |
759 | $pluginManager->executeHooks('render_tagcloud', $data, array('loggedin' => isLoggedIn())); | 763 | $pluginManager->executeHooks('render_tagcloud', $data, array('loggedin' => isLoggedIn())); |
@@ -762,6 +766,8 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
762 | $PAGE->assign($key, $value); | 766 | $PAGE->assign($key, $value); |
763 | } | 767 | } |
764 | 768 | ||
769 | $searchTags = ! empty($searchTags) ? $searchTags .' - ' : ''; | ||
770 | $PAGE->assign('pagetitle', $searchTags. t('Tag cloud') .' - '. $conf->get('general.title', 'Shaarli')); | ||
765 | $PAGE->renderPage('tag.cloud'); | 771 | $PAGE->renderPage('tag.cloud'); |
766 | exit; | 772 | exit; |
767 | } | 773 | } |
@@ -782,8 +788,9 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
782 | alphabetical_sort($tags, false, true); | 788 | alphabetical_sort($tags, false, true); |
783 | } | 789 | } |
784 | 790 | ||
791 | $searchTags = implode(' ', escape($filteringTags)); | ||
785 | $data = [ | 792 | $data = [ |
786 | 'search_tags' => implode(' ', escape($filteringTags)), | 793 | 'search_tags' => $searchTags, |
787 | 'tags' => $tags, | 794 | 'tags' => $tags, |
788 | ]; | 795 | ]; |
789 | $pluginManager->executeHooks('render_taglist', $data, ['loggedin' => isLoggedIn()]); | 796 | $pluginManager->executeHooks('render_taglist', $data, ['loggedin' => isLoggedIn()]); |
@@ -792,6 +799,8 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
792 | $PAGE->assign($key, $value); | 799 | $PAGE->assign($key, $value); |
793 | } | 800 | } |
794 | 801 | ||
802 | $searchTags = ! empty($searchTags) ? $searchTags .' - ' : ''; | ||
803 | $PAGE->assign('pagetitle', $searchTags . t('Tag list') .' - '. $conf->get('general.title', 'Shaarli')); | ||
795 | $PAGE->renderPage('tag.list'); | 804 | $PAGE->renderPage('tag.list'); |
796 | exit; | 805 | exit; |
797 | } | 806 | } |
@@ -1016,6 +1025,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1016 | $PAGE->assign($key, $value); | 1025 | $PAGE->assign($key, $value); |
1017 | } | 1026 | } |
1018 | 1027 | ||
1028 | $PAGE->assign('pagetitle', t('Tools') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1019 | $PAGE->renderPage('tools'); | 1029 | $PAGE->renderPage('tools'); |
1020 | exit; | 1030 | exit; |
1021 | } | 1031 | } |
@@ -1059,6 +1069,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1059 | } | 1069 | } |
1060 | else // show the change password form. | 1070 | else // show the change password form. |
1061 | { | 1071 | { |
1072 | $PAGE->assign('pagetitle', t('Change password') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1062 | $PAGE->renderPage('changepassword'); | 1073 | $PAGE->renderPage('changepassword'); |
1063 | exit; | 1074 | exit; |
1064 | } | 1075 | } |
@@ -1131,6 +1142,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1131 | $PAGE->assign('api_secret', $conf->get('api.secret')); | 1142 | $PAGE->assign('api_secret', $conf->get('api.secret')); |
1132 | $PAGE->assign('languages', Languages::getAvailableLanguages()); | 1143 | $PAGE->assign('languages', Languages::getAvailableLanguages()); |
1133 | $PAGE->assign('language', $conf->get('translation.language')); | 1144 | $PAGE->assign('language', $conf->get('translation.language')); |
1145 | $PAGE->assign('pagetitle', t('Configure') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1134 | $PAGE->renderPage('configure'); | 1146 | $PAGE->renderPage('configure'); |
1135 | exit; | 1147 | exit; |
1136 | } | 1148 | } |
@@ -1141,6 +1153,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1141 | { | 1153 | { |
1142 | if (empty($_POST['fromtag']) || (empty($_POST['totag']) && isset($_POST['renametag']))) { | 1154 | if (empty($_POST['fromtag']) || (empty($_POST['totag']) && isset($_POST['renametag']))) { |
1143 | $PAGE->assign('fromtag', ! empty($_GET['fromtag']) ? escape($_GET['fromtag']) : ''); | 1155 | $PAGE->assign('fromtag', ! empty($_GET['fromtag']) ? escape($_GET['fromtag']) : ''); |
1156 | $PAGE->assign('pagetitle', t('Manage tags') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1144 | $PAGE->renderPage('changetag'); | 1157 | $PAGE->renderPage('changetag'); |
1145 | exit; | 1158 | exit; |
1146 | } | 1159 | } |
@@ -1167,6 +1180,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1167 | // -------- User wants to add a link without using the bookmarklet: Show form. | 1180 | // -------- User wants to add a link without using the bookmarklet: Show form. |
1168 | if ($targetPage == Router::$PAGE_ADDLINK) | 1181 | if ($targetPage == Router::$PAGE_ADDLINK) |
1169 | { | 1182 | { |
1183 | $PAGE->assign('pagetitle', t('Shaare a new link') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1170 | $PAGE->renderPage('addlink'); | 1184 | $PAGE->renderPage('addlink'); |
1171 | exit; | 1185 | exit; |
1172 | } | 1186 | } |
@@ -1336,6 +1350,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1336 | $PAGE->assign($key, $value); | 1350 | $PAGE->assign($key, $value); |
1337 | } | 1351 | } |
1338 | 1352 | ||
1353 | $PAGE->assign('pagetitle', t('Edit') .' '. t('Shaare') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1339 | $PAGE->renderPage('editlink'); | 1354 | $PAGE->renderPage('editlink'); |
1340 | exit; | 1355 | exit; |
1341 | } | 1356 | } |
@@ -1400,6 +1415,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1400 | $PAGE->assign($key, $value); | 1415 | $PAGE->assign($key, $value); |
1401 | } | 1416 | } |
1402 | 1417 | ||
1418 | $PAGE->assign('pagetitle', t('Shaare') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1403 | $PAGE->renderPage('editlink'); | 1419 | $PAGE->renderPage('editlink'); |
1404 | exit; | 1420 | exit; |
1405 | } | 1421 | } |
@@ -1408,6 +1424,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1408 | // Export links as a Netscape Bookmarks file | 1424 | // Export links as a Netscape Bookmarks file |
1409 | 1425 | ||
1410 | if (empty($_GET['selection'])) { | 1426 | if (empty($_GET['selection'])) { |
1427 | $PAGE->assign('pagetitle', t('Export') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1411 | $PAGE->renderPage('export'); | 1428 | $PAGE->renderPage('export'); |
1412 | exit; | 1429 | exit; |
1413 | } | 1430 | } |
@@ -1469,6 +1486,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1469 | true | 1486 | true |
1470 | ) | 1487 | ) |
1471 | ); | 1488 | ); |
1489 | $PAGE->assign('pagetitle', t('Import') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1472 | $PAGE->renderPage('import'); | 1490 | $PAGE->renderPage('import'); |
1473 | exit; | 1491 | exit; |
1474 | } | 1492 | } |
@@ -1517,6 +1535,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, | |||
1517 | 1535 | ||
1518 | $PAGE->assign('enabledPlugins', $enabledPlugins); | 1536 | $PAGE->assign('enabledPlugins', $enabledPlugins); |
1519 | $PAGE->assign('disabledPlugins', $disabledPlugins); | 1537 | $PAGE->assign('disabledPlugins', $disabledPlugins); |
1538 | $PAGE->assign('pagetitle', t('Plugin administration') .' - '. $conf->get('general.title', 'Shaarli')); | ||
1520 | $PAGE->renderPage('pluginsadmin'); | 1539 | $PAGE->renderPage('pluginsadmin'); |
1521 | exit; | 1540 | exit; |
1522 | } | 1541 | } |
@@ -1680,6 +1699,16 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager) | |||
1680 | // If there is only a single link, we change on-the-fly the title of the page. | 1699 | // If there is only a single link, we change on-the-fly the title of the page. |
1681 | if (count($linksToDisplay) == 1) { | 1700 | if (count($linksToDisplay) == 1) { |
1682 | $data['pagetitle'] = $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title'); | 1701 | $data['pagetitle'] = $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title'); |
1702 | } elseif (! empty($searchterm) || ! empty($searchtags)) { | ||
1703 | $data['pagetitle'] = t('Search: '); | ||
1704 | $data['pagetitle'] .= ! empty($searchterm) ? $searchterm .' ' : ''; | ||
1705 | $bracketWrap = function ($tag) { | ||
1706 | return '['. $tag .']'; | ||
1707 | }; | ||
1708 | $data['pagetitle'] .= ! empty($searchtags) | ||
1709 | ? implode(' ', array_map($bracketWrap, preg_split('/\s+/', $searchtags))).' ' | ||
1710 | : ''; | ||
1711 | $data['pagetitle'] .= '- '. $conf->get('general.title'); | ||
1683 | } | 1712 | } |
1684 | 1713 | ||
1685 | $pluginManager->executeHooks('render_linklist', $data, array('loggedin' => isLoggedIn())); | 1714 | $pluginManager->executeHooks('render_linklist', $data, array('loggedin' => isLoggedIn())); |
diff --git a/tests/NetscapeBookmarkUtils/BookmarkImportTest.php b/tests/NetscapeBookmarkUtils/BookmarkImportTest.php index 4961aa2c..f0a958cb 100644 --- a/tests/NetscapeBookmarkUtils/BookmarkImportTest.php +++ b/tests/NetscapeBookmarkUtils/BookmarkImportTest.php | |||
@@ -127,6 +127,21 @@ class BookmarkImportTest extends PHPUnit_Framework_TestCase | |||
127 | } | 127 | } |
128 | 128 | ||
129 | /** | 129 | /** |
130 | * Attempt to import bookmarks from a file with a lowercase Doctype | ||
131 | */ | ||
132 | public function testImportLowecaseDoctype() | ||
133 | { | ||
134 | $files = file2array('lowercase_doctype.htm'); | ||
135 | $this->assertStringMatchesFormat( | ||
136 | 'File lowercase_doctype.htm (386 bytes) was successfully processed in %d seconds:' | ||
137 | .' 2 links imported, 0 links overwritten, 0 links skipped.', | ||
138 | NetscapeBookmarkUtils::import(null, $files, $this->linkDb, $this->conf, $this->history) | ||
139 | ); | ||
140 | $this->assertEquals(2, count($this->linkDb)); | ||
141 | } | ||
142 | |||
143 | |||
144 | /** | ||
130 | * Ensure IE dumps are supported | 145 | * Ensure IE dumps are supported |
131 | */ | 146 | */ |
132 | public function testImportInternetExplorerEncoding() | 147 | public function testImportInternetExplorerEncoding() |
diff --git a/tests/NetscapeBookmarkUtils/input/lowercase_doctype.htm b/tests/NetscapeBookmarkUtils/input/lowercase_doctype.htm new file mode 100644 index 00000000..8911ad19 --- /dev/null +++ b/tests/NetscapeBookmarkUtils/input/lowercase_doctype.htm | |||
@@ -0,0 +1,8 @@ | |||
1 | <!DOCTYPE netscape-bookmark-file-1> | ||
2 | <TITLE>Bookmarks</TITLE> | ||
3 | <H1>Bookmarks</H1> | ||
4 | <DL><p> | ||
5 | <DT><A HREF="https://private.tld" ADD_DATE="10/Oct/2000:13:55:36 +0300" PRIVATE="1" TAGS="private secret">Secret stuff</A> | ||
6 | <DD>Super-secret stuff you're not supposed to know about | ||
7 | <DT><A HREF="http://public.tld" ADD_DATE="1456433748" PRIVATE="0" TAGS="public hello world">Public stuff</A> | ||
8 | </DL><p> | ||