Skip to content

Commit 9859f6b

Browse files
authored
gravatar 2.0: Fix gravatar, remove twitter and identica (#878)
* Fix gravatar avatars * Remove defunct identica avatar option * Remove defunct twitter avatar option * Remove references to removed avatar option mybloglog * Update links to avatar descriptions * Reimplement Favatar fetch to make it more reliable to redirects Use the serendipity_request_url wrapper to fetch the favicon. This follows redirects by defaults and will save maintenance work in the future. * Simplify pavatar fetch * Replace md5 based plugin urls with sha256, restore cache * Update wavatar, avoid php 8 notices for other local avatars * Document changes, raise version number * Mention and provide license Wavatars being originally a wordpress plugin is under GPL, which means the gravatar plugin has to be as well.
1 parent 058c237 commit 9859f6b

17 files changed

+836
-300
lines changed

docs/NEWS

+4
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ Version 2.6-alpha1 ()
1010
have set a custom value for imagemagick_thumb_parameters in your
1111
local config file.
1212

13+
* Update bundled avatar plugin: Fix gravatar image fetching, remove
14+
defunct options for identica and twitter avatars, and clean up
15+
documentation,
16+
1317
* PHP 8.4 fix: Remove deprecated constant E_STRICT
1418

1519
* PHP 8 compatibility fixes for bundled XML/RPC.php

plugins/serendipity_event_gravatar/ChangeLog

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
Version 2.0:
2+
------------------------------------------------------------------------
3+
* Fix gravatar: Avatars could not be fetched
4+
* Remove the defunct avatar options identica and twitter
5+
* Reimplement favatar and pavatar options for better reliability
6+
* Update wavatar generator
7+
* Update documentation and translation
8+
* Additional fixes for PH 8 compatibility
9+
110
Version 1.63.1:
211
------------------------------------------------------------------------
312
* PHP 8 compatibility

plugins/serendipity_event_gravatar/LICENSE

+338
Large diffs are not rendered by default.

plugins/serendipity_event_gravatar/UTF-8/lang_cs.inc.php

+2-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99

1010
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Avatar Plugin');
11-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar, Favatar a MyBlogLog.');
11+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar a Favatar.');
1212

1313
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Tvořit smarty tag');
1414
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'Pokud je tato volba zapnuta, obrázky avatarů nejsou zapsány přímo do textu komentáře, ale je místo toho vygenerován tag {$comment.avatar} pro šablonovací systém smarty. Pak budou avatary zobrazovat pouze styly vzhledu, které tento tag používají. Nejjednodušší způsob, jak zjistit, jestli Váš styl vzhledu podporuje avatary, je vyzkoušet zapnout toto nastavení.');
@@ -51,10 +51,9 @@
5151

5252
@define('PLUGIN_EVENT_GRAVATAR_LONG_DESCRIPTION', '<b><a href="http://www.gravatar.com" target="_blank">Gravatar</a></b> je centrální úložiště obrázků uživatelů spřažené s emailovou adresou, ' .
5353
'<b><a href="http://www.peej.co.uk/projects/favatars.html" target="_blank">Favatar</a></b> poskytuje favicony načtené z osobních stránek uživatele, <b><a href="http://www.pavatar.com" target="_blank">Pavatar</a></b> ' .
54-
'jsou obrázky uložené na osobních stránkách pisatele, <b><a href="http://www.mybloglog.com" target="_blank">MyBlogLog avatar</a></b> jsou centrálně ukládané obrázky a ' .
5554
'<b><a href="http://www.splitbrain.org/go/monsterid" target="_blank">Monster ID</a></b>, <b><a href="http://scott.sherrillmix.com/blog/blogger/wp_identicon/" target="_blank">Identicon</a></b> a <b><a href="http://www.shamusyoung.com/twentysidedtale/?p=1462" target="_blank">Wavatar</a></b> avatary jsou nahrávané obrázky vytvořené jednotlivými uživateli.');
5655
@define('PLUGIN_EVENT_GRAVATAR_EXTLING_WARNING', '<font color="red">POZOR!</font> Tento plugin musí být zařazen před všemi pluginy, které mění odkazy (jako např. plugin "exit tracking plugin")! ' .
57-
'<font color="red">Jinak nebudou pracovat avatary služeb Pavatar, Favatar a MayBlogLog!</font>');
56+
'<font color="red">Jinak nebudou pracovat avatary služeb Pavatar a Favatar!</font>');
5857

5958
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK', 'Gravatar fallback');
6059
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK_DESC', 'Gravatar má implementovaných několik návratových metod pro případ, že pro požadovaného uživatele není znám žádný avatar. Implementovány jsou též Moster ID, Identicon a Wavatar. Pokud vyberete některý z těchto zíněných, nebudou uskutečňovány žádné další pokusy o načtení avataru, pokud uživatel zadá email.');

plugins/serendipity_event_gravatar/UTF-8/lang_cz.inc.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99

1010
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Avatar Plugin');
11-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar, Favatar a MyBlogLog.');
11+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar a Favatar.');
1212

1313
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Tvořit smarty tag');
1414
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'Pokud je tato volba zapnuta, obrázky avatarů nejsou zapsány přímo do textu komentáře, ale je místo toho vygenerován tag {$comment.avatar} pro šablonovací systém smarty. Pak budou avatary zobrazovat pouze styly vzhledu, které tento tag používají. Nejjednodušší způsob, jak zjistit, jestli Váš styl vzhledu podporuje avatary, je vyzkoušet zapnout toto nastavení.');

plugins/serendipity_event_gravatar/UTF-8/lang_de.inc.php

+5-8
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99

1010
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Avatar Plugin');
11-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Avatare bei Kommentaren anzeigen. Unterstützt werden Gravatare, Pavatare, Favatare, Twitter, Identica und MyBlogLog Avatare');
11+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Avatare bei Kommentaren anzeigen. Unterstützt werden Gravatare und Alternativen wie Favatare.');
1212

1313
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Smarty Tag erzeugen');
1414
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'Wenn diese Option eingeschaltet ist, so wird das Avatar Bild nicht direkt in den Kommentar geschrieben, sondern es wird ein Smarty Tag {$comment.avatar} erzeugt, in dem der HTML Code des Images steht. Sie sollten diese Option nur einschalten, wenn sie wissen, dass ihr Template dieses Smarty Tag unterstützt. Ob das der Fall ist, sollten sie einfach ausprobieren.');
@@ -49,14 +49,11 @@
4949
@define('PLUGIN_EVENT_GRAVATAR_AUTOR_ALT_DESC', 'Normaler Weise wird der Autorenname im TITLE Attribut des Avatar Bildes angegeben, das ALT Attribut wird mit einem * gefüllt, um das Seitenlayout nicht zu zerstören, wenn der Browser das Bild nicht laden kann. Allerdings wird blinden Lesern das ALT Attribut vorgelesen. Falls Sie diese Leser unterstützen wollen, sollten Sie diese Option einschalten.');
5050

5151
@define('PLUGIN_EVENT_GRAVATAR_LONG_DESCRIPTION', '<b><a href="http://www.gravatar.com" target="_blank">Gravatare</a></b> werden von einem zentralem Server anhand der EMail Information des Kommentators abgeholt, ' .
52-
'<b><a href="http://www.peej.co.uk/projects/favatars.html" target="_blank">Favatare</a></b> sind die favicons auf der Homepage, die der Kommentator angegeben hat, ' .
53-
'<b><a href="http://twitter.com" target="_blank">Twitter</a></b> lädt Bilder aus Twitter Profilen, ' .
54-
'<b><a href="http://identi.ca" target="_blank">Identica</a></b> lädt Bilder aus Identica Profilen, ' .
55-
'<b><a href="http://www.pavatar.com" target="_blank">Pavatare</a></b> zeigen auf ein Bild, das der Besucher auf seiner Homepage hat, ' .
56-
'<b><a href="http://www.mybloglog.com" target="_blank">MyBlogLog Avatare</a></b> werden von einem zentralen Server geladen und ' .
57-
'<b><a href="http://www.splitbrain.org/go/monsterid" target="_blank">Monster ID</a></b>, <b><a href="http://scott.sherrillmix.com/blog/blogger/wp_identicon/" target="_blank">Identicon</a></b> und <b><a href="http://www.shamusyoung.com/twentysidedtale/?p=1462" target="_blank">Wavatar</a></b> Avatare sind lokal erstellte und für jeden Schreiber einzigartige Bilder.');
52+
'<b>Favatare</b> sind die Favicons auf der Homepage, die der Kommentator angegeben hat, ' .
53+
'<b><a href="http://pavatar.github.io/pavatar/" target="_blank">Pavatare</a></b> zeigen auf ein Bild, das der Besucher auf seiner Homepage hat, ' .
54+
'<b><a href="https://www.splitbrain.org/go/monsterid" target="_blank">Monster ID</a></b>, <b><a href="http://scott.sherrillmix.com/blog/blogger/wp_identicon/" target="_blank">Identicon</a></b> und <b><a href="https://www.shamusyoung.com/twentysidedtale/?p=1462" target="_blank">Wavatar</a></b> Avatare sind lokal erstellte und für jeden Schreiber einzigartige Bilder.');
5855
@define('PLUGIN_EVENT_GRAVATAR_EXTLING_WARNING', '<font color="red">ACHTUNG!</font> Dieses Plugin muss vor allen Plugins ausgeführt werden, die Links verändern (wie z.B. das Exit Tracking Plugin)!<br/>' .
59-
'<font color="red">Ansonsten werden Pavatare, Favatare und MyBlogLog Avatare nicht funktionieren!</font>');
56+
'<font color="red">Ansonsten werden Pavatare und Favatare nicht funktionieren!</font>');
6057

6158
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK', 'Gravatar Fallback');
6259
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK_DESC', 'Gravatar implementiert einige eigene Fallback Methoden für den Fal, dass kein Gravatar für den Benutzer gefunden wurde. Es wurde ebenso Moster ID, Identicon und Wavatar. Wenn Du einen dieser Fallbacks einstellst, so wird keine weitere Methode nach Gravatar versucht, falls der Benutzer eine EMail angegeben hat.');

plugins/serendipity_event_gravatar/UTF-8/lang_pl.inc.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88

99
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Avatar Plugin');
10-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Pokazuje avatary w komentarzach. Gravatars, Pavatars, Favatars und MyBlogLog avatars are supported.');
10+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Pokazuje avatary w komentarzach.');
1111

1212
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Produce smarty tag');
1313
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'If this option is switched on, the avatar images are not written directly into the comment output but a smarty tag {$comment.avatar} is produced. Only templates, that support this smarty tag, will display the avatar, if this option is set to true. The best way is to try it, if your template supports this smarty tag.');

plugins/serendipity_event_gravatar/UTF-8/lang_ru.inc.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

33
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Плагин аватаров');
4-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Показ аватаров внутри комментариев. Поддерживаются Gravatar, Pavatar, Favatar, Twitter, Identica и MyBlogLog.');
4+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Показ аватаров внутри комментариев. Поддерживаются Gravatar, Pavatar и Favatar');
55

66
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Создать тег Smarty');
77
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'Если эта опция включена, изображения аватара не записываются непосредственно в вывод комментария, но создаётся тег smarty {$comment.avatar}. Только шаблоны, поддерживающие этот тег Smarty, будут отображать аватар, если для этой опции установлено значение "Да". Лучший способ - попробовать это, если Ваш шаблон поддерживает этот тег Smarty.');
@@ -46,7 +46,6 @@
4646
'<b><a href="http://www.peej.co.uk/projects/favatars.html" target="_blank">Favatar</a></b> являются иконками сайта (favicon) писателя, ' .
4747
'<b><a href="http://www.pavatar.com" target="_blank">Pavatar</a></b> являются изображениями на сайте автора, ' .
4848
'<b><a href="http://twitter.com" target="_blank">Twitter</a></b> загружает изображения профиля в Twitter, ' .
49-
'<b><a href="http://identi.ca" target="_blank">Identica</a></b> загружает изображения профиля identi.ca, ' .
5049
'<b><a href="http://www.mybloglog.com" target="_blank">Аватары MyBlogLog</a></b> снова являются централизованными изображениями аватаров и ' .
5150
'<b><a href="http://www.splitbrain.org/go/monsterid" target="_blank">Monster ID</a></b>, <b><a href="http://scott.sherrillmix.com/blog/blogger/wp_identicon/" target="_blank">Identicon</a></b> и <b><a href="http://www.shamusyoung.com/twentysidedtale/?p=1462" target="_blank">Wavatar</a></b> являются локально созданными изображениями монстров, уникальными для каждого автора.');
5251
@define('PLUGIN_EVENT_GRAVATAR_EXTLING_WARNING', '<font color="red">ОСТОРОЖНО!</font> Этот плагин должен быть запущен перед любым плагином, изменяющим ссылки (например, плагин отслеживания выхода)! ' .

plugins/serendipity_event_gravatar/documentation_de.html

-21
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,6 @@ <h2>Inhalt</h2>
1818
<li><a href="#avt_gravatar">Gravatar</a></li>
1919
<li><a href="#avt_pavatar">Pavatar</a></li>
2020
<li><a href="#avt_favatar">Favatar</a></li>
21-
<li><a href="#avt_twitter">Twitter</a></li>
22-
<li><a href="#avt_identica">Identica</a></li>
23-
<li><a href="#avt_mybloglog">MyBlogLog</a></li>
2421
<li><a href="#avt_wavatar">Wavatar</a></li>
2522
<li><a href="#avt_monsterid">MonsterID</a></li>
2623
<li><a href="#avt_identicon">Identicon/YCon</a></li>
@@ -74,24 +71,6 @@ <h3>Favatar</h3>
7471
<p>Das Blog holt sich hier einfach das favicon der Homepage, die der Benutzer als seine URL angegeben hat. Dafür ist das favicon aber eben ein Icon und somit normaler Weise auch recht klein und nicht immer als Avatar geeignet.</p>
7572
<p><a href="#top">top</a></p>
7673

77-
<a name="avt_twitter"></a>
78-
<h3>Twitter</h3>
79-
<p>Falls der Kommentator als URL ein <a href="http://twitter.com" target="_blank">Twitter Profil</a> angegeben hat, dann wird versucht, hier das Profilbild für diesen Benutzer zu laden.</p>
80-
<p><i>Anmerkung</i>: Falls auch Favatare geladen werden sollen, dann muss Twitter vor diesen versucht werden, sonst wird das Favicon von Twitter geladen. Dies kann allerdings auch gewollt sein, um z.B. "Tweetbacks" von Twitter klar zu markieren.</p>
81-
<p><a href="#top">top</a></p>
82-
83-
<a name="avt_identica"></a>
84-
<h3>Identica</h3>
85-
<p>Dies ist ein spezielles Avatar für <a href="http://identi.ca" target="_blank">Identica</a> Pingbacks. Es wird versucht, das Profilbild des Benutzers zu laden, der den Pingback ausgelöst hat.</p>
86-
<p><i>Anmerkung</i>: Falls auch Favatare geladen werden sollen, dann muss Identica vor diesen versucht werden, sonst wird das Favicon von Identica geladen. Dies kann allerdings auch gewollt sein, um z.B. "Tweetbacks" von Identica klar zu markieren.</p>
87-
<p><a href="#top">top</a></p>
88-
89-
<a name="avt_mybloglog"></a>
90-
<h3>MyBlogLog</h3>
91-
<p>Dies ist wieder ein (dem Gravatar Service sehr ähnlicher) zentraler Service. MyBlogLog ist eigentlich ein Blog Community Service, aber man kann aus diesem ebenfalls Avatare ermitteln</p>
92-
<p>Das Vorhandensein eines MyBlogLog Avatars wird über die Homepage Angabe des Kommentators ermittelt.</p>
93-
<p><a href="#top">top</a></p>
94-
9574
<a name="avt_wavatar"></a>
9675
<h3>Wavatar</h3>
9776
<p>Das Wavatar wird dynamisch erzeugt aus der Eingabe von Hompage und EMail des Kommentators. Es liefert für jeden Benutzer ein anderes aber immer selbes Avatar. Da es <strong>immer</strong> ein Avatar liefert, werden alle nachfolgenden Avatar Methoden ignoriert. Wavatare sehen in etwa wie folgt aus:</p>

plugins/serendipity_event_gravatar/lang_cs.inc.php

+2-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99

1010
@define('PLUGIN_EVENT_GRAVATAR_NAME', 'Avatar Plugin');
11-
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar, Favatar a MyBlogLog.');
11+
@define('PLUGIN_EVENT_GRAVATAR_DESC', 'Zobrazuje avatary (ikona či obrázek přispěvatele) v komentářích. Podporovány jsou služby Gravatar, Pavatar a Favatar.');
1212

1313
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY', 'Tvořit smarty tag');
1414
@define('PLUGIN_EVENT_GRAVATAR_USE_SMARTY_DESC', 'Pokud je tato volba zapnuta, obrázky avatarů nejsou zapsány přímo do textu komentáře, ale je místo toho vygenerován tag {$comment.avatar} pro šablonovací systém smarty. Pak budou avatary zobrazovat pouze styly vzhledu, které tento tag používají. Nejjednodušší způsob, jak zjistit, jestli Váš styl vzhledu podporuje avatary, je vyzkoušet zapnout toto nastavení.');
@@ -51,10 +51,9 @@
5151

5252
@define('PLUGIN_EVENT_GRAVATAR_LONG_DESCRIPTION', '<b><a href="http://www.gravatar.com" target="_blank">Gravatar</a></b> je centrální úložiště obrázků uživatelů spřažené s emailovou adresou, ' .
5353
'<b><a href="http://www.peej.co.uk/projects/favatars.html" target="_blank">Favatar</a></b> poskytuje favicony načtené z osobních stránek uživatele, <b><a href="http://www.pavatar.com" target="_blank">Pavatar</a></b> ' .
54-
'jsou obrázky uložené na osobních stránkách pisatele, <b><a href="http://www.mybloglog.com" target="_blank">MyBlogLog avatar</a></b> jsou centrálně ukládané obrázky a ' .
5554
'<b><a href="http://www.splitbrain.org/go/monsterid" target="_blank">Monster ID</a></b>, <b><a href="http://scott.sherrillmix.com/blog/blogger/wp_identicon/" target="_blank">Identicon</a></b> a <b><a href="http://www.shamusyoung.com/twentysidedtale/?p=1462" target="_blank">Wavatar</a></b> avatary jsou nahrávané obrázky vytvořené jednotlivými uživateli.');
5655
@define('PLUGIN_EVENT_GRAVATAR_EXTLING_WARNING', '<font color="red">POZOR!</font> Tento plugin musí být zařazen před všemi pluginy, které mění odkazy (jako např. plugin "exit tracking plugin")! ' .
57-
'<font color="red">Jinak nebudou pracovat avatary služeb Pavatar, Favatar a MayBlogLog!</font>');
56+
'<font color="red">Jinak nebudou pracovat avatary služeb Pavatar a Favatar!</font>');
5857

5958
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK', 'Gravatar fallback');
6059
@define('PLUGIN_EVENT_GRAVATAR_FALLBACK_DESC', 'Gravatar má implementovaných několik návratových metod pro případ, že pro požadovaného uživatele není znám žádný avatar. Implementovány jsou též Moster ID, Identicon a Wavatar. Pokud vyberete některý z těchto zíněných, nebudou uskutečňovány žádné další pokusy o načtení avataru, pokud uživatel zadá email.');

0 commit comments

Comments
 (0)