diff --git a/advancedcontentfilter/advancedcontentfilter.php b/advancedcontentfilter/advancedcontentfilter.php
index 866b0b11f..c539075bb 100644
--- a/advancedcontentfilter/advancedcontentfilter.php
+++ b/advancedcontentfilter/advancedcontentfilter.php
@@ -65,13 +65,6 @@ function advancedcontentfilter_install(App $a)
Logger::log("installed advancedcontentfilter");
}
-function advancedcontentfilter_uninstall()
-{
- Hook::unregister('dbstructure_definition' , __FILE__, 'advancedcontentfilter_dbstructure_definition');
- Hook::unregister('prepare_body_content_filter', __FILE__, 'advancedcontentfilter_prepare_body_content_filter');
- Hook::unregister('addon_settings' , __FILE__, 'advancedcontentfilter_addon_settings');
-}
-
/*
* Hooks
*/
diff --git a/blackout/blackout.php b/blackout/blackout.php
index 19f99f1e8..83b2dbc1a 100644
--- a/blackout/blackout.php
+++ b/blackout/blackout.php
@@ -54,9 +54,6 @@ function blackout_install() {
Hook::register('page_header', 'addon/blackout/blackout.php', 'blackout_redirect');
}
-function blackout_uninstall() {
- Hook::unregister('page_header', 'addon/blackout/blackout.php', 'blackout_redirect');
-}
function blackout_redirect ($a, $b) {
// if we have a logged in user, don't throw her out
if (local_user()) {
diff --git a/blackout/lang/it/messages.po b/blackout/lang/it/messages.po
index 1b0c6f628..d00fd11e5 100644
--- a/blackout/lang/it/messages.po
+++ b/blackout/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014,2018
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2014-06-22 13:18+0200\n"
-"PO-Revision-Date: 2018-03-19 19:50+0000\n"
-"Last-Translator: fabrixxm \n"
+"POT-Creation-Date: 2019-03-12 09:26+0100\n"
+"PO-Revision-Date: 2020-08-31 15:28+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -19,34 +20,48 @@ msgstr ""
"Language: it\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: blackout.php:99
+#: blackout.php:101
+msgid ""
+"The end-date is prior to the start-date of the blackout, you should fix this"
+msgstr "La data di fine è precedente alla data di inizio blackout, dovresti sistemarle"
+
+#: blackout.php:103
+#, php-format
+msgid ""
+"Please double check that the current settings for the blackout. Begin will "
+"be %s and it will end %s."
+msgstr "Per favore ricontrolla le impostazioni attuali per il blackout. L'inizio sarà il %s e terminerà il %s."
+
+#: blackout.php:106
msgid "Save Settings"
msgstr "Salva Impostazioni"
-#: blackout.php:100
+#: blackout.php:107
msgid "Redirect URL"
msgstr "URL di reindirizzamento"
-#: blackout.php:100
+#: blackout.php:107
msgid "all your visitors from the web will be redirected to this URL"
msgstr "tutti i visitatori dal web verranno reindirizzati a questo URL"
-#: blackout.php:101
+#: blackout.php:108
msgid "Begin of the Blackout"
msgstr "Inzio del blackout"
-#: blackout.php:101
+#: blackout.php:108
msgid ""
-"format is YYYY year, MM month, DD day, "
-"hh hour and mm minute"
-msgstr "il formato è YYYY anno, MM mese, DD giorno, hh ora e mm minuto"
+"Format is YYYY-MM-DD hh:mm; YYYY year, MM month, "
+"DD day, hh hour and mm minute."
+msgstr "Il formato è YYYY-MM-DD hh:mm; YYYY anno, MM mese, DD giorno, hh ora e mm minuto."
-#: blackout.php:102
+#: blackout.php:109
msgid "End of the Blackout"
msgstr "Fine del blackout"
-#: blackout.php:108
+#: blackout.php:111
msgid ""
-"The end-date is prior to the start-date of the blackout, you should fix "
-"this."
-msgstr "La data di fine è precedente alla data di inizio. Dovresti sistemarla."
+"Note: The redirect will be active from the moment you press"
+" the submit button. Users currently logged in will not be "
+"thrown out but can't login again after logging out should the blackout is "
+"still in place."
+msgstr "Nota: Il reindirizzamento sarà attivo dal momento in cui premerai il pulsante di invio. Gli utenti attualmente autenticati non saranno disconnessi ma non potranno accedere in caso di disconnessione fintanto che il blackout sarà attivo."
diff --git a/blackout/lang/it/strings.php b/blackout/lang/it/strings.php
index b0142236c..6aa8b95e3 100644
--- a/blackout/lang/it/strings.php
+++ b/blackout/lang/it/strings.php
@@ -2,13 +2,16 @@
if(! function_exists("string_plural_select_it")) {
function string_plural_select_it($n){
+ $n = intval($n);
return ($n != 1);;
}}
;
+$a->strings["The end-date is prior to the start-date of the blackout, you should fix this"] = "La data di fine è precedente alla data di inizio blackout, dovresti sistemarle";
+$a->strings["Please double check that the current settings for the blackout. Begin will be %s and it will end %s."] = "Per favore ricontrolla le impostazioni attuali per il blackout. L'inizio sarà il %s e terminerà il %s.";
$a->strings["Save Settings"] = "Salva Impostazioni";
$a->strings["Redirect URL"] = "URL di reindirizzamento";
$a->strings["all your visitors from the web will be redirected to this URL"] = "tutti i visitatori dal web verranno reindirizzati a questo URL";
$a->strings["Begin of the Blackout"] = "Inzio del blackout";
-$a->strings["format is YYYY year, MM month, DD day, hh hour and mm minute"] = "il formato è YYYY anno, MM mese, DD giorno, hh ora e mm minuto";
+$a->strings["Format is YYYY-MM-DD hh:mm; YYYY year, MM month, DD day, hh hour and mm minute."] = "Il formato è YYYY-MM-DD hh:mm; YYYY anno, MM mese, DD giorno, hh ora e mm minuto.";
$a->strings["End of the Blackout"] = "Fine del blackout";
-$a->strings["The end-date is prior to the start-date of the blackout, you should fix this."] = "La data di fine è precedente alla data di inizio. Dovresti sistemarla.";
+$a->strings["Note: The redirect will be active from the moment you press the submit button. Users currently logged in will not be thrown out but can't login again after logging out should the blackout is still in place."] = "Nota: Il reindirizzamento sarà attivo dal momento in cui premerai il pulsante di invio. Gli utenti attualmente autenticati non saranno disconnessi ma non potranno accedere in caso di disconnessione fintanto che il blackout sarà attivo.";
diff --git a/blockbot/blockbot.php b/blockbot/blockbot.php
index 6bf709708..b602bf63b 100644
--- a/blockbot/blockbot.php
+++ b/blockbot/blockbot.php
@@ -22,11 +22,6 @@ function blockbot_install() {
Hook::register('init_1', __FILE__, 'blockbot_init_1');
}
-
-function blockbot_uninstall() {
- Hook::unregister('init_1', __FILE__, 'blockbot_init_1');
-}
-
function blockbot_addon_admin(&$a, &$o) {
$t = Renderer::getMarkupTemplate("admin.tpl", "addon/blockbot/");
@@ -42,7 +37,6 @@ function blockbot_addon_admin_post(&$a) {
DI::config()->set('blockbot', 'good_crawlers', $_POST['good_crawlers'] ?? false);
DI::config()->set('blockbot', 'block_gab', $_POST['block_gab'] ?? false);
DI::config()->set('blockbot', 'training', $_POST['training'] ?? false);
- info(DI::l10n()->t('Settings updated.'). EOL);
}
function blockbot_init_1(App $a) {
@@ -54,7 +48,8 @@ function blockbot_init_1(App $a) {
// List of "good" crawlers
$good_agents = ['fediverse.space crawler', 'fediverse.network crawler', 'Active_Pods_CheckBot_3.0',
- 'Social-Relay/', 'Test Certificate Info', 'Uptimebot/', 'GNUSocialBot', 'UptimeRobot/'];
+ 'Social-Relay/', 'Test Certificate Info', 'Uptimebot/', 'GNUSocialBot', 'UptimeRobot/',
+ 'PTST/'];
// List of known crawlers.
$agents = ['SemrushBot', 's~feedly-nikon3', 'Qwantify/Bleriot/', 'ltx71', 'Sogou web spider/',
diff --git a/blockbot/lang/it/messages.po b/blockbot/lang/it/messages.po
new file mode 100644
index 000000000..06db44264
--- /dev/null
+++ b/blockbot/lang/it/messages.po
@@ -0,0 +1,42 @@
+# ADDON blockbot
+# Copyright (C)
+# This file is distributed under the same license as the Friendica blockbot addon package.
+#
+#
+# Translators:
+# Sylke Vicious , 2020
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: \n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2019-08-07 09:03+0200\n"
+"PO-Revision-Date: 2019-08-07 07:43+0000\n"
+"Last-Translator: Sylke Vicious , 2020\n"
+"Language-Team: Italian (https://www.transifex.com/Friendica/teams/12172/it/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Language: it\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
+
+#: blockbot.php:35
+msgid "Save Settings"
+msgstr "Salva Impostazioni"
+
+#: blockbot.php:36
+msgid "Allow \"good\" crawlers"
+msgstr "Permetti crawler \"buoni\""
+
+#: blockbot.php:37
+msgid "Block GabSocial"
+msgstr "Blocca GabSocial"
+
+#: blockbot.php:38
+msgid "Training mode"
+msgstr "Modalità addestramento"
+
+#: blockbot.php:46
+msgid "Settings updated."
+msgstr "Impostazioni aggiornate."
diff --git a/blockbot/lang/it/strings.php b/blockbot/lang/it/strings.php
new file mode 100644
index 000000000..64de6d409
--- /dev/null
+++ b/blockbot/lang/it/strings.php
@@ -0,0 +1,13 @@
+strings["Save Settings"] = "Salva Impostazioni";
+$a->strings["Allow \"good\" crawlers"] = "Permetti crawler \"buoni\"";
+$a->strings["Block GabSocial"] = "Blocca GabSocial";
+$a->strings["Training mode"] = "Modalità addestramento";
+$a->strings["Settings updated."] = "Impostazioni aggiornate.";
diff --git a/blockem/blockem.php b/blockem/blockem.php
index 3a32aa2d4..1880b9be4 100644
--- a/blockem/blockem.php
+++ b/blockem/blockem.php
@@ -23,18 +23,6 @@ function blockem_install()
Hook::register('enotify_store' , 'addon/blockem/blockem.php', 'blockem_enotify_store');
}
-function blockem_uninstall()
-{
- Hook::unregister('prepare_body_content_filter', 'addon/blockem/blockem.php', 'blockem_prepare_body_content_filter');
- Hook::unregister('prepare_body' , 'addon/blockem/blockem.php', 'blockem_prepare_body');
- Hook::unregister('display_item' , 'addon/blockem/blockem.php', 'blockem_display_item');
- Hook::unregister('addon_settings' , 'addon/blockem/blockem.php', 'blockem_addon_settings');
- Hook::unregister('addon_settings_post' , 'addon/blockem/blockem.php', 'blockem_addon_settings_post');
- Hook::unregister('conversation_start' , 'addon/blockem/blockem.php', 'blockem_conversation_start');
- Hook::unregister('item_photo_menu' , 'addon/blockem/blockem.php', 'blockem_item_photo_menu');
- Hook::unregister('enotify_store' , 'addon/blockem/blockem.php', 'blockem_enotify_store');
-}
-
function blockem_addon_settings (App $a, &$s)
{
if (!local_user()) {
@@ -78,7 +66,6 @@ function blockem_addon_settings_post(App $a, array &$b)
if (!empty($_POST['blockem-submit'])) {
DI::pConfig()->set(local_user(), 'blockem', 'words', trim($_POST['blockem-words']));
- info(DI::l10n()->t('BLOCKEM Settings saved.') . EOL);
}
}
@@ -242,6 +229,5 @@ function blockem_init(App $a)
}
DI::pConfig()->set(local_user(), 'blockem', 'words', $words);
- info(DI::l10n()->t('blockem settings updated') . EOL);
exit();
}
diff --git a/blogger/blogger.php b/blogger/blogger.php
index e0b5f5352..5cf0d27b3 100644
--- a/blogger/blogger.php
+++ b/blogger/blogger.php
@@ -11,7 +11,6 @@ use Friendica\Content\Text\BBCode;
use Friendica\Core\Hook;
use Friendica\Core\Logger;
use Friendica\DI;
-use Friendica\Util\Network;
use Friendica\Util\XML;
function blogger_install()
@@ -24,22 +23,6 @@ function blogger_install()
Hook::register('connector_settings_post', 'addon/blogger/blogger.php', 'blogger_settings_post');
}
-function blogger_uninstall()
-{
- Hook::unregister('hook_fork', 'addon/blogger/blogger.php', 'blogger_hook_fork');
- Hook::unregister('post_local', 'addon/blogger/blogger.php', 'blogger_post_local');
- Hook::unregister('notifier_normal', 'addon/blogger/blogger.php', 'blogger_send');
- Hook::unregister('jot_networks', 'addon/blogger/blogger.php', 'blogger_jot_nets');
- Hook::unregister('connector_settings', 'addon/blogger/blogger.php', 'blogger_settings');
- Hook::unregister('connector_settings_post', 'addon/blogger/blogger.php', 'blogger_settings_post');
-
- // obsolete - remove
- Hook::unregister('post_local_end', 'addon/blogger/blogger.php', 'blogger_send');
- Hook::unregister('addon_settings', 'addon/blogger/blogger.php', 'blogger_settings');
- Hook::unregister('addon_settings_post', 'addon/blogger/blogger.php', 'blogger_settings_post');
-}
-
-
function blogger_jot_nets(App $a, array &$jotnets_fields)
{
if (!local_user()) {
@@ -225,7 +208,7 @@ EOT;
Logger::log('blogger: data: ' . $xml, Logger::DATA);
if ($bl_blog !== 'test') {
- $x = Network::post($bl_blog, $xml)->getBody();
+ $x = DI::httpRequest()->post($bl_blog, $xml)->getBody();
}
Logger::log('posted to blogger: ' . (($x) ? $x : ''), Logger::DEBUG);
diff --git a/buffer/buffer.php b/buffer/buffer.php
index b008b52f9..9bbdf21e5 100644
--- a/buffer/buffer.php
+++ b/buffer/buffer.php
@@ -29,16 +29,6 @@ function buffer_install()
Hook::register('connector_settings_post', 'addon/buffer/buffer.php', 'buffer_settings_post');
}
-function buffer_uninstall()
-{
- Hook::unregister('hook_fork', 'addon/buffer/buffer.php', 'buffer_hook_fork');
- Hook::unregister('post_local', 'addon/buffer/buffer.php', 'buffer_post_local');
- Hook::unregister('notifier_normal', 'addon/buffer/buffer.php', 'buffer_send');
- Hook::unregister('jot_networks', 'addon/buffer/buffer.php', 'buffer_jot_nets');
- Hook::unregister('connector_settings', 'addon/buffer/buffer.php', 'buffer_settings');
- Hook::unregister('connector_settings_post', 'addon/buffer/buffer.php', 'buffer_settings_post');
-}
-
function buffer_module()
{
}
@@ -89,8 +79,6 @@ function buffer_addon_admin_post(App $a)
DI::config()->set('buffer', 'client_id' , $client_id);
DI::config()->set('buffer', 'client_secret', $client_secret);
-
- info(DI::l10n()->t('Settings updated.'). EOL);
}
function buffer_connect(App $a)
diff --git a/buglink/buglink.php b/buglink/buglink.php
index 2414a3a32..9ea20b56e 100644
--- a/buglink/buglink.php
+++ b/buglink/buglink.php
@@ -15,11 +15,6 @@ function buglink_install()
Hook::register('page_end', 'addon/buglink/buglink.php', 'buglink_active');
}
-function buglink_uninstall()
-{
- Hook::unregister('page_end', 'addon/buglink/buglink.php', 'buglink_active');
-}
-
function buglink_active(App $a, &$b)
{
$b .= '
';
}
diff --git a/newmemberwidget/lang/it/messages.po b/newmemberwidget/lang/it/messages.po
index b62a779b4..5258d6b6a 100644
--- a/newmemberwidget/lang/it/messages.po
+++ b/newmemberwidget/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2014-06-01 14:12+0200\n"
-"PO-Revision-Date: 2017-09-20 06:08+0000\n"
-"Last-Translator: fabrixxm \n"
+"PO-Revision-Date: 2020-09-17 11:38+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -49,21 +50,21 @@ msgstr "Il tuo messaggio per i nuovi utenti. Puoi usare BBCode"
#: newmemberwidget.php:51
msgid "Add a link to global support forum"
-msgstr "Aggiunge un link al forum di supporto globale"
+msgstr "Aggiunge un collegamento al forum di supporto globale"
#: newmemberwidget.php:51
msgid "Should a link to the global support forum be displayed?"
-msgstr "Mostrare il link al forum di supporto globale?"
+msgstr "Mostrare il collegamento al forum di supporto globale?"
#: newmemberwidget.php:52
msgid "Add a link to the local support forum"
-msgstr "Aggiunge un link al forum di supporto locale"
+msgstr "Aggiunge un collegamento al forum di supporto locale"
#: newmemberwidget.php:52
msgid ""
"If you have a local support forum and wand to have a link displayed in the "
"widget, check this box."
-msgstr "Se hai un forum di supporto locale e vuoi che sia mostrato il link nel widget, seleziona questo box."
+msgstr "Se hai un forum di supporto locale e vuoi che sia mostrato il collegamento nel widget, seleziona questo box."
#: newmemberwidget.php:53
msgid "Name of the local support group"
diff --git a/newmemberwidget/lang/it/strings.php b/newmemberwidget/lang/it/strings.php
index a9a089048..6138ea6a1 100644
--- a/newmemberwidget/lang/it/strings.php
+++ b/newmemberwidget/lang/it/strings.php
@@ -2,6 +2,7 @@
if(! function_exists("string_plural_select_it")) {
function string_plural_select_it($n){
+ $n = intval($n);
return ($n != 1);;
}}
;
@@ -12,9 +13,9 @@ $a->strings["Local Support Forum"] = "Forum Locale di Supporto";
$a->strings["Save Settings"] = "Salva Impostazioni";
$a->strings["Message"] = "Messaggio";
$a->strings["Your message for new members. You can use bbcode here."] = "Il tuo messaggio per i nuovi utenti. Puoi usare BBCode";
-$a->strings["Add a link to global support forum"] = "Aggiunge un link al forum di supporto globale";
-$a->strings["Should a link to the global support forum be displayed?"] = "Mostrare il link al forum di supporto globale?";
-$a->strings["Add a link to the local support forum"] = "Aggiunge un link al forum di supporto locale";
-$a->strings["If you have a local support forum and wand to have a link displayed in the widget, check this box."] = "Se hai un forum di supporto locale e vuoi che sia mostrato il link nel widget, seleziona questo box.";
+$a->strings["Add a link to global support forum"] = "Aggiunge un collegamento al forum di supporto globale";
+$a->strings["Should a link to the global support forum be displayed?"] = "Mostrare il collegamento al forum di supporto globale?";
+$a->strings["Add a link to the local support forum"] = "Aggiunge un collegamento al forum di supporto locale";
+$a->strings["If you have a local support forum and wand to have a link displayed in the widget, check this box."] = "Se hai un forum di supporto locale e vuoi che sia mostrato il collegamento nel widget, seleziona questo box.";
$a->strings["Name of the local support group"] = "Nome del gruppo locale di supporto";
$a->strings["If you checked the above, specify the nickname of the local support group here (i.e. helpers)"] = "Se hai selezionato il box sopra, specifica qui il nome utente del gruppo locale di supporto (e.s. 'supporto')";
diff --git a/newmemberwidget/newmemberwidget.php b/newmemberwidget/newmemberwidget.php
index 585568135..d748816e0 100644
--- a/newmemberwidget/newmemberwidget.php
+++ b/newmemberwidget/newmemberwidget.php
@@ -19,11 +19,6 @@ function newmemberwidget_install()
Logger::log('newmemberwidget installed');
}
-function newmemberwidget_uninstall()
-{
- Hook::unregister( 'network_mod_init', 'addon/newmemberwidget/newmemberwidget.php', 'newmemberwidget_network_mod_init');
-}
-
function newmemberwidget_network_mod_init ($a, $b)
{
if (empty($_SESSION['new_member'])) {
diff --git a/notifyall/lang/ru/messages.po b/notifyall/lang/ru/messages.po
new file mode 100644
index 000000000..63d448468
--- /dev/null
+++ b/notifyall/lang/ru/messages.po
@@ -0,0 +1,60 @@
+# ADDON notifyall
+# Copyright (C)
+# This file is distributed under the same license as the Friendica notifyall addon package.
+#
+#
+# Translators:
+# Alexander An , 2020
+#
+#, fuzzy
+msgid ""
+msgstr ""
+"Project-Id-Version: \n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2016-08-14 16:41+0200\n"
+"PO-Revision-Date: 2016-08-14 19:29+0000\n"
+"Last-Translator: Alexander An , 2020\n"
+"Language-Team: Russian (https://www.transifex.com/Friendica/teams/12172/ru/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Language: ru\n"
+"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
+
+#: notifyall.php:26
+msgid "Send email to all members"
+msgstr "Послать почту всем пользователям"
+
+#: notifyall.php:42
+#, php-format
+msgid "%s Administrator"
+msgstr "%s Администратор"
+
+#: notifyall.php:44
+#, php-format
+msgid "%1$s, %2$s Administrator"
+msgstr "%1$s, %2$s Администратор"
+
+#: notifyall.php:60
+msgid "No recipients found."
+msgstr "Получатели не найдены."
+
+#: notifyall.php:78
+msgid "Emails sent"
+msgstr "Сообщения высланы."
+
+#: notifyall.php:86
+msgid "Send email to all members of this Friendica instance."
+msgstr "Выслать почтовое сообщение всем пользователям этого узла Friendica."
+
+#: notifyall.php:91
+msgid "Message subject"
+msgstr "Тема сообщения"
+
+#: notifyall.php:92
+msgid "Test mode (only send to administrator)"
+msgstr "Пробный режим (отправить только администратору)"
+
+#: notifyall.php:93
+msgid "Submit"
+msgstr "Отправить"
diff --git a/notifyall/lang/ru/strings.php b/notifyall/lang/ru/strings.php
new file mode 100644
index 000000000..4d394daef
--- /dev/null
+++ b/notifyall/lang/ru/strings.php
@@ -0,0 +1,17 @@
+=2 && $n%10<=4 && ($n%100<12 || $n%100>14) ? 1 : $n%10==0 || ($n%10>=5 && $n%10<=9) || ($n%100>=11 && $n%100<=14)? 2 : 3);;
+}}
+;
+$a->strings["Send email to all members"] = "Послать почту всем пользователям";
+$a->strings["%s Administrator"] = "%s Администратор";
+$a->strings["%1\$s, %2\$s Administrator"] = "%1\$s, %2\$s Администратор";
+$a->strings["No recipients found."] = "Получатели не найдены.";
+$a->strings["Emails sent"] = "Сообщения высланы.";
+$a->strings["Send email to all members of this Friendica instance."] = "Выслать почтовое сообщение всем пользователям этого узла Friendica.";
+$a->strings["Message subject"] = "Тема сообщения";
+$a->strings["Test mode (only send to administrator)"] = "Пробный режим (отправить только администратору)";
+$a->strings["Submit"] = "Отправить";
diff --git a/notifyall/notifyall.php b/notifyall/notifyall.php
index 6d1793804..e5e94c7ec 100644
--- a/notifyall/notifyall.php
+++ b/notifyall/notifyall.php
@@ -15,16 +15,6 @@ use Friendica\Core\Logger;
use Friendica\Core\Renderer;
use Friendica\DI;
-function notifyall_install()
-{
- Logger::log("installed notifyall");
-}
-
-function notifyall_uninstall()
-{
- Logger::log("removed notifyall");
-}
-
function notifyall_module() {}
function notifyall_addon_admin(App $a, &$o)
@@ -66,7 +56,7 @@ function notifyall_post(App $a)
DI::emailer()->send($notifyEmail->withRecipient($recipient['email']));
}
- notice(DI::l10n()->t('Emails sent'));
+ info(DI::l10n()->t('Emails sent'));
DI::baseUrl()->redirect('admin');
}
diff --git a/notimeline/notimeline.php b/notimeline/notimeline.php
index a0765b962..b99501c3a 100644
--- a/notimeline/notimeline.php
+++ b/notimeline/notimeline.php
@@ -16,12 +16,6 @@ function notimeline_install()
Hook::register('addon_settings_post', 'addon/notimeline/notimeline.php', 'notimeline_settings_post');
}
-function notimeline_uninstall()
-{
- Hook::unregister('addon_settings', 'addon/notimeline/notimeline.php', 'notimeline_settings');
- Hook::unregister('addon_settings_post', 'addon/notimeline/notimeline.php', 'notimeline_settings_post');
-}
-
function notimeline_settings_post($a, $post)
{
if (!local_user() || empty($_POST['notimeline-submit'])) {
@@ -29,7 +23,6 @@ function notimeline_settings_post($a, $post)
}
DI::pConfig()->set(local_user(), 'system', 'no_wall_archive_widget', intval($_POST['notimeline']));
- info(DI::l10n()->t('No Timeline settings updated.') . EOL);
}
function notimeline_settings(&$a, &$s)
diff --git a/nsfw/lang/it/messages.po b/nsfw/lang/it/messages.po
index abb605cd4..a84d0a136 100644
--- a/nsfw/lang/it/messages.po
+++ b/nsfw/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014-2015,2018
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-04-01 11:11-0400\n"
-"PO-Revision-Date: 2018-05-28 09:01+0000\n"
-"Last-Translator: fabrixxm \n"
+"PO-Revision-Date: 2020-09-17 11:25+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -29,7 +30,7 @@ msgid ""
" can be used to filter content tagged with for instance #NSFW that may be "
"deemed inappropriate at certain times or places, such as being at work. It "
"is also useful for hiding irrelevant or annoying content from direct view."
-msgstr "Questo componente aggiuntivo cerca per le parole specificate nei messaggi e li collassa. Può essere usato per filtrare contenuto taggato, per esempio, #NSFW (non sicuro per il lavoro), che puo' risultare inappropriato in certi orari o in certi luoghi, come appunto al lavoro. È anche utile per nascondere contenuto irrilevante o fastidioso."
+msgstr "Questo componente aggiuntivo cerca per le parole specificate nei messaggi e li collassa. Può essere usato per filtrare contenuto taggato, per esempio, #NSFW (non sicuro per il lavoro), che può risultare inappropriato in certi orari o in certi luoghi, come appunto al lavoro. È anche utile per nascondere contenuto irrilevante o fastidioso."
#: nsfw.php:86
msgid "Enable Content filter"
diff --git a/nsfw/lang/it/strings.php b/nsfw/lang/it/strings.php
index 18ecfb164..69d9e287d 100644
--- a/nsfw/lang/it/strings.php
+++ b/nsfw/lang/it/strings.php
@@ -7,7 +7,7 @@ function string_plural_select_it($n){
}}
;
$a->strings["Content Filter (NSFW and more)"] = "Filtro Contenuto (NSFW e altro)";
-$a->strings["This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view."] = "Questo componente aggiuntivo cerca per le parole specificate nei messaggi e li collassa. Può essere usato per filtrare contenuto taggato, per esempio, #NSFW (non sicuro per il lavoro), che puo' risultare inappropriato in certi orari o in certi luoghi, come appunto al lavoro. È anche utile per nascondere contenuto irrilevante o fastidioso.";
+$a->strings["This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view."] = "Questo componente aggiuntivo cerca per le parole specificate nei messaggi e li collassa. Può essere usato per filtrare contenuto taggato, per esempio, #NSFW (non sicuro per il lavoro), che può risultare inappropriato in certi orari o in certi luoghi, come appunto al lavoro. È anche utile per nascondere contenuto irrilevante o fastidioso.";
$a->strings["Enable Content filter"] = "Abilita il Filtro Contenuti";
$a->strings["Comma separated list of keywords to hide"] = "Elenco separato da virgole di parole da nascondere";
$a->strings["Save Settings"] = "Salva Impostazioni";
diff --git a/nsfw/lang/nl/messages.po b/nsfw/lang/nl/messages.po
index e7af8746c..a012eee14 100644
--- a/nsfw/lang/nl/messages.po
+++ b/nsfw/lang/nl/messages.po
@@ -4,14 +4,15 @@
#
#
# Translators:
+# Casper , 2020
# Jeroen De Meerleer , 2018
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-04-01 11:11-0400\n"
-"PO-Revision-Date: 2018-08-24 13:43+0000\n"
-"Last-Translator: Jeroen De Meerleer \n"
+"PO-Revision-Date: 2020-09-04 21:08+0000\n"
+"Last-Translator: Casper \n"
"Language-Team: Dutch (http://www.transifex.com/Friendica/friendica/language/nl/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -29,7 +30,7 @@ msgid ""
" can be used to filter content tagged with for instance #NSFW that may be "
"deemed inappropriate at certain times or places, such as being at work. It "
"is also useful for hiding irrelevant or annoying content from direct view."
-msgstr ""
+msgstr "Deze add-on zoekt naar gespecificeerde woorden / tekst in berichten en vouwt ze samen. Het kan worden gebruikt om inhoud te filteren die is getagd met bijvoorbeeld #NSFW die op bepaalde tijden of plaatsen als ongepast kan worden beschouwd, zoals op het werk. Het is ook handig om irrelevante of irritante inhoud voor direct zicht te verbergen."
#: nsfw.php:86
msgid "Enable Content filter"
diff --git a/nsfw/lang/nl/strings.php b/nsfw/lang/nl/strings.php
index d1a121a7c..83dc72413 100644
--- a/nsfw/lang/nl/strings.php
+++ b/nsfw/lang/nl/strings.php
@@ -7,7 +7,7 @@ function string_plural_select_nl($n){
}}
;
$a->strings["Content Filter (NSFW and more)"] = "Inhoud filter (NSFW en meer)";
-$a->strings["This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view."] = "";
+$a->strings["This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view."] = "Deze add-on zoekt naar gespecificeerde woorden / tekst in berichten en vouwt ze samen. Het kan worden gebruikt om inhoud te filteren die is getagd met bijvoorbeeld #NSFW die op bepaalde tijden of plaatsen als ongepast kan worden beschouwd, zoals op het werk. Het is ook handig om irrelevante of irritante inhoud voor direct zicht te verbergen.";
$a->strings["Enable Content filter"] = "Content filter inschakelen";
$a->strings["Comma separated list of keywords to hide"] = "";
$a->strings["Save Settings"] = "Instellingen opslaan";
diff --git a/nsfw/lang/ru/messages.po b/nsfw/lang/ru/messages.po
new file mode 100644
index 000000000..caa7ef3aa
--- /dev/null
+++ b/nsfw/lang/ru/messages.po
@@ -0,0 +1,62 @@
+# ADDON nsfw
+# Copyright (C)
+# This file is distributed under the same license as the Friendica nsfw addon package.
+#
+#
+# Translators:
+# Alexander An , 2020
+msgid ""
+msgstr ""
+"Project-Id-Version: friendica\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2018-04-01 11:11-0400\n"
+"PO-Revision-Date: 2020-09-01 05:38+0000\n"
+"Last-Translator: Alexander An \n"
+"Language-Team: Russian (http://www.transifex.com/Friendica/friendica/language/ru/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Language: ru\n"
+"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
+
+#: nsfw.php:77 nsfw.php:81
+msgid "Content Filter (NSFW and more)"
+msgstr "Фильтр контента (NSFW и прочее)"
+
+#: nsfw.php:85
+msgid ""
+"This addon searches for specified words/text in posts and collapses them. It"
+" can be used to filter content tagged with for instance #NSFW that may be "
+"deemed inappropriate at certain times or places, such as being at work. It "
+"is also useful for hiding irrelevant or annoying content from direct view."
+msgstr "Это дополнение ищет указанные слова и выражения в записях и сворачивает запись, если найдёт. Это можно использовать для скрытия записей с тэгом #NSFW, просмотр которых может быть нежелателен в определённое время, например, на работе. Так же можно использовать для скрытия иного контента."
+
+#: nsfw.php:86
+msgid "Enable Content filter"
+msgstr "Включить фильтр контента"
+
+#: nsfw.php:89
+msgid "Comma separated list of keywords to hide"
+msgstr "Ключевые слова для скрытия, через запятую"
+
+#: nsfw.php:93
+msgid "Save Settings"
+msgstr "Сохранить настройки"
+
+#: nsfw.php:94
+msgid "Use /expression/ to provide regular expressions"
+msgstr "Используйте формат /expression/ для регулярных выражений"
+
+#: nsfw.php:109
+msgid "NSFW Settings saved."
+msgstr "Настройки NSFW сохранены"
+
+#: nsfw.php:162
+#, php-format
+msgid "Filtered tag: %s"
+msgstr "Скрыт тэг: %s"
+
+#: nsfw.php:164
+#, php-format
+msgid "Filtered word: %s"
+msgstr "Скрыто слово: %s"
diff --git a/nsfw/lang/ru/strings.php b/nsfw/lang/ru/strings.php
index 7e821ed88..d16d1195d 100644
--- a/nsfw/lang/ru/strings.php
+++ b/nsfw/lang/ru/strings.php
@@ -1,10 +1,17 @@
-strings["Not Safe For Work (General Purpose Content Filter) settings"] = "";
-$a->strings["This addon looks in posts for the words/text you specify below, and collapses any content containing those keywords so it is not displayed at inappropriate times, such as sexual innuendo that may be improper in a work setting. It is polite and recommended to tag any content containing nudity with #NSFW. This filter can also match any other word/text you specify, and can thereby be used as a general purpose content filter."] = "";
-$a->strings["Enable Content filter"] = "Включить фильтр содержимого";
-$a->strings["Comma separated list of keywords to hide"] = "ключевые слова, которые скрыть (список через запятую)";
-$a->strings["Submit"] = "Подтвердить";
-$a->strings["Use /expression/ to provide regular expressions"] = "";
-$a->strings["NSFW Settings saved."] = "NSFW Настройки сохранены.";
-$a->strings["%s - Click to open/close"] = "%s - Нажмите для открытия / закрытия";
+=2 && $n%10<=4 && ($n%100<12 || $n%100>14) ? 1 : $n%10==0 || ($n%10>=5 && $n%10<=9) || ($n%100>=11 && $n%100<=14)? 2 : 3);;
+}}
+;
+$a->strings["Content Filter (NSFW and more)"] = "Фильтр контента (NSFW и прочее)";
+$a->strings["This addon searches for specified words/text in posts and collapses them. It can be used to filter content tagged with for instance #NSFW that may be deemed inappropriate at certain times or places, such as being at work. It is also useful for hiding irrelevant or annoying content from direct view."] = "Это дополнение ищет указанные слова и выражения в записях и сворачивает запись, если найдёт. Это можно использовать для скрытия записей с тэгом #NSFW, просмотр которых может быть нежелателен в определённое время, например, на работе. Так же можно использовать для скрытия иного контента.";
+$a->strings["Enable Content filter"] = "Включить фильтр контента";
+$a->strings["Comma separated list of keywords to hide"] = "Ключевые слова для скрытия, через запятую";
+$a->strings["Save Settings"] = "Сохранить настройки";
+$a->strings["Use /expression/ to provide regular expressions"] = "Используйте формат /expression/ для регулярных выражений";
+$a->strings["NSFW Settings saved."] = "Настройки NSFW сохранены";
+$a->strings["Filtered tag: %s"] = "Скрыт тэг: %s";
+$a->strings["Filtered word: %s"] = "Скрыто слово: %s";
diff --git a/nsfw/nsfw.php b/nsfw/nsfw.php
index 85260c7f7..9f81b29d8 100644
--- a/nsfw/nsfw.php
+++ b/nsfw/nsfw.php
@@ -17,14 +17,6 @@ function nsfw_install()
Hook::register('addon_settings_post', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings_post');
}
-function nsfw_uninstall()
-{
- Hook::unregister('prepare_body_content_filter', 'addon/nsfw/nsfw.php', 'nsfw_prepare_body_content_filter');
- Hook::unregister('prepare_body', 'addon/nsfw/nsfw.php', 'nsfw_prepare_body');
- Hook::unregister('addon_settings', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings');
- Hook::unregister('addon_settings_post', 'addon/nsfw/nsfw.php', 'nsfw_addon_settings_post');
-}
-
// This function isn't perfect and isn't trying to preserve the html structure - it's just a
// quick and dirty filter to pull out embedded photo blobs because 'nsfw' seems to come up
// inside them quite often. We don't need anything fancy, just pull out the data blob so we can
@@ -105,7 +97,6 @@ function nsfw_addon_settings_post(&$a, &$b)
$enable = (!empty($_POST['nsfw-enable']) ? intval($_POST['nsfw-enable']) : 0);
$disable = 1 - $enable;
DI::pConfig()->set(local_user(), 'nsfw', 'disable', $disable);
- info(DI::l10n()->t('NSFW Settings saved.') . EOL);
}
}
diff --git a/numfriends/numfriends.php b/numfriends/numfriends.php
index 9143fb494..f12badeb4 100644
--- a/numfriends/numfriends.php
+++ b/numfriends/numfriends.php
@@ -17,16 +17,6 @@ function numfriends_install() {
Logger::log("installed numfriends");
}
-
-function numfriends_uninstall() {
-
- Hook::unregister('addon_settings', 'addon/numfriends/numfriends.php', 'numfriends_settings');
- Hook::unregister('addon_settings_post', 'addon/numfriends/numfriends.php', 'numfriends_settings_post');
-
-
- Logger::log("removed numfriends");
-}
-
/**
*
* Callback from the settings post function.
@@ -40,7 +30,6 @@ function numfriends_settings_post($a,$post) {
return;
DI::pConfig()->set(local_user(),'system','display_friend_count',intval($_POST['numfriends']));
- info( DI::l10n()->t('Numfriends settings updated.') . EOL);
}
diff --git a/openstreetmap/openstreetmap.php b/openstreetmap/openstreetmap.php
index 5df1c7d7d..168d3d2ff 100644
--- a/openstreetmap/openstreetmap.php
+++ b/openstreetmap/openstreetmap.php
@@ -9,13 +9,12 @@
*
*/
-use Friendica\DI;
use Friendica\Core\Cache\Duration;
use Friendica\Core\Hook;
use Friendica\Core\Logger;
use Friendica\Core\Renderer;
+use Friendica\DI;
use Friendica\Util\ConfigFileLoader;
-use Friendica\Util\Network;
use Friendica\Util\Strings;
const OSM_TMS = 'https://www.openstreetmap.org';
@@ -35,18 +34,6 @@ function openstreetmap_install()
Logger::log("installed openstreetmap");
}
-function openstreetmap_uninstall()
-{
- Hook::unregister('load_config', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_load_config');
- Hook::unregister('render_location', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_location');
- Hook::unregister('generate_map', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_generate_map');
- Hook::unregister('generate_named_map', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_generate_named_map');
- Hook::unregister('Map::getCoordinates', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_get_coordinates');
- Hook::unregister('page_header', 'addon/openstreetmap/openstreetmap.php', 'openstreetmap_alterheader');
-
- Logger::log("removed openstreetmap");
-}
-
function openstreetmap_load_config(\Friendica\App $a, ConfigFileLoader $loader)
{
$a->getConfigCache()->load($loader->loadAddonConfig('openstreetmap'));
@@ -132,7 +119,7 @@ function openstreetmap_get_coordinates($a, &$b)
$j = DI::cache()->get($cachekey);
if (is_null($j)) {
- $curlResult = Network::curl($nomserver . $args);
+ $curlResult = DI::httpRequest()->get($nomserver . $args);
if ($curlResult->isSuccess()) {
$j = json_decode($curlResult->getBody(), true);
DI::cache()->set($cachekey, $j, Duration::MONTH);
@@ -223,6 +210,4 @@ function openstreetmap_addon_admin_post(&$a)
DI::config()->set('openstreetmap', 'nomserver', $urlnom);
DI::config()->set('openstreetmap', 'zoom', $zoom);
DI::config()->set('openstreetmap', 'marker', $marker);
-
- info(DI::l10n()->t('Settings updated.') . EOL);
}
diff --git a/pageheader/lang/ru/messages.po b/pageheader/lang/ru/messages.po
new file mode 100644
index 000000000..f637afa42
--- /dev/null
+++ b/pageheader/lang/ru/messages.po
@@ -0,0 +1,42 @@
+# ADDON pageheader
+# Copyright (C)
+# This file is distributed under the same license as the Friendica pageheader addon package.
+#
+#
+# Translators:
+# Alexander An , 2020
+msgid ""
+msgstr ""
+"Project-Id-Version: friendica\n"
+"Report-Msgid-Bugs-To: \n"
+"POT-Creation-Date: 2018-03-11 18:52+0100\n"
+"PO-Revision-Date: 2020-09-01 05:29+0000\n"
+"Last-Translator: Alexander An \n"
+"Language-Team: Russian (http://www.transifex.com/Friendica/friendica/language/ru/)\n"
+"MIME-Version: 1.0\n"
+"Content-Type: text/plain; charset=UTF-8\n"
+"Content-Transfer-Encoding: 8bit\n"
+"Language: ru\n"
+"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
+
+#: pageheader.php:53
+msgid "\"pageheader\" Settings"
+msgstr ""
+
+#: pageheader.php:54
+msgid "Message"
+msgstr "Сообщение"
+
+#: pageheader.php:54
+msgid ""
+"Message to display on every page on this server (or put a pageheader.html "
+"file in your docroot)"
+msgstr "Сообщение для отображения на каждой странице этого сервера (или поместите файл pageheader.html в корневую папку веб-сервера)"
+
+#: pageheader.php:55
+msgid "Save Settings"
+msgstr "Сохранить настройки"
+
+#: pageheader.php:69
+msgid "pageheader Settings saved."
+msgstr "pageheader Настройки сохранены."
diff --git a/pageheader/lang/ru/strings.php b/pageheader/lang/ru/strings.php
index edf7ea453..39e28e218 100644
--- a/pageheader/lang/ru/strings.php
+++ b/pageheader/lang/ru/strings.php
@@ -1,5 +1,13 @@
-strings["\"pageheader\" Settings"] = "";
-$a->strings["Submit"] = "Подтвердить";
-$a->strings["pageheader Settings saved."] = "";
+=2 && $n%10<=4 && ($n%100<12 || $n%100>14) ? 1 : $n%10==0 || ($n%10>=5 && $n%10<=9) || ($n%100>=11 && $n%100<=14)? 2 : 3);;
+}}
+;
+$a->strings["\"pageheader\" Settings"] = "";
+$a->strings["Message"] = "Сообщение";
+$a->strings["Message to display on every page on this server (or put a pageheader.html file in your docroot)"] = "Сообщение для отображения на каждой странице этого сервера (или поместите файл pageheader.html в корневую папку веб-сервера)";
+$a->strings["Save Settings"] = "Сохранить настройки";
+$a->strings["pageheader Settings saved."] = "pageheader Настройки сохранены.";
diff --git a/pageheader/pageheader.php b/pageheader/pageheader.php
index 201df3221..f0d75400e 100644
--- a/pageheader/pageheader.php
+++ b/pageheader/pageheader.php
@@ -51,7 +51,6 @@ function pageheader_addon_admin_post(App $a)
if (isset($_POST['pageheader-words'])) {
DI::config()->set('pageheader', 'text', trim(strip_tags($_POST['pageheader-words'])));
}
- info(DI::l10n()->t('pageheader Settings saved.'));
}
}
diff --git a/phpmailer/phpmailer.php b/phpmailer/phpmailer.php
index e9a3c66ea..5b43c8f19 100644
--- a/phpmailer/phpmailer.php
+++ b/phpmailer/phpmailer.php
@@ -90,9 +90,14 @@ function phpmailer_emailer_send_prepare(App $a, IEmail &$email)
// additional headers
if (!empty($email->getAdditionalMailHeader())) {
- foreach (explode("\n", trim($email->getAdditionalMailHeader())) as $header_line) {
- list($name, $value) = explode(':', $header_line, 2);
- $mailer->addCustomHeader(trim($name), trim($value));
+ foreach ($email->getAdditionalMailHeader() as $name => $values) {
+ // Set the "Message-ID" header for PHP-Mailer directly
+ if ($name == 'Message-Id') {
+ // implode all values to one entry, because there's only one value possible
+ $mailer->MessageID = trim(implode("", $values));
+ } else {
+ $mailer->addCustomHeader(trim($name), trim(implode("\n", $values)));
+ }
}
}
diff --git a/piwik/lang/it/messages.po b/piwik/lang/it/messages.po
index e7a070b17..033fc7369 100644
--- a/piwik/lang/it/messages.po
+++ b/piwik/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014-2015,2019
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2019-02-19 10:42+0100\n"
-"PO-Revision-Date: 2019-03-11 14:19+0000\n"
-"Last-Translator: fabrixxm \n"
+"PO-Revision-Date: 2020-09-17 11:39+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -53,7 +54,7 @@ msgstr "ID del sito"
#: piwik.php:107
msgid "Show opt-out cookie link?"
-msgstr "Mostra il link per il cookie opt-out?"
+msgstr "Mostra il collegamento per l'opt-out dei cookie?"
#: piwik.php:108
msgid "Asynchronous tracking"
diff --git a/piwik/lang/it/strings.php b/piwik/lang/it/strings.php
index 0fc1c7638..e523a69dc 100644
--- a/piwik/lang/it/strings.php
+++ b/piwik/lang/it/strings.php
@@ -12,6 +12,6 @@ $a->strings["Save Settings"] = "Salva Impostazioni";
$a->strings["Matomo (Piwik) Base URL"] = "Indirizzo di base di Matomo (Piwik)";
$a->strings["Absolute path to your Matomo (Piwik) installation. (without protocol (http/s), with trailing slash)"] = "Percorso assoluto alla tua installazione di Matomo (Piwik) (senza il protocollo (http/https), con la barra alla fine)";
$a->strings["Site ID"] = "ID del sito";
-$a->strings["Show opt-out cookie link?"] = "Mostra il link per il cookie opt-out?";
+$a->strings["Show opt-out cookie link?"] = "Mostra il collegamento per l'opt-out dei cookie?";
$a->strings["Asynchronous tracking"] = "Tracciamento asincrono";
$a->strings["Settings updated."] = "Impostazioni aggiornate.";
diff --git a/piwik/piwik.php b/piwik/piwik.php
index 6dba45a34..d461cfd4f 100644
--- a/piwik/piwik.php
+++ b/piwik/piwik.php
@@ -45,13 +45,6 @@ function piwik_install() {
Logger::log("installed piwik addon");
}
-function piwik_uninstall() {
- Hook::unregister('load_config', 'addon/piwik/piwik.php', 'piwik_load_config');
- Hook::unregister('page_end', 'addon/piwik/piwik.php', 'piwik_analytics');
-
- Logger::log("uninstalled piwik addon");
-}
-
function piwik_load_config(\Friendica\App $a, ConfigFileLoader $loader)
{
$a->getConfigCache()->load($loader->loadAddonConfig('piwik'));
@@ -117,5 +110,4 @@ function piwik_addon_admin_post (&$a) {
DI::config()->set('piwik', 'siteid', $id);
DI::config()->set('piwik', 'optout', $optout);
DI::config()->set('piwik', 'async', $async);
- info(DI::l10n()->t('Settings updated.'). EOL);
}
diff --git a/planets/planets.php b/planets/planets.php
index ea543f409..9fed41862 100644
--- a/planets/planets.php
+++ b/planets/planets.php
@@ -35,27 +35,6 @@ function planets_install() {
Logger::log("installed planets");
}
-
-function planets_uninstall() {
-
- /**
- *
- * uninstall unregisters any hooks created with register_hook
- * during install. It may also delete configuration settings
- * and any other cleanup.
- *
- */
-
- Hook::unregister('post_local', 'addon/planets/planets.php', 'planets_post_hook');
- Hook::unregister('addon_settings', 'addon/planets/planets.php', 'planets_settings');
- Hook::unregister('addon_settings_post', 'addon/planets/planets.php', 'planets_settings_post');
-
-
- Logger::log("removed planets");
-}
-
-
-
function planets_post_hook($a, &$item) {
/**
diff --git a/public_server/public_server.php b/public_server/public_server.php
index 41c628325..549020bd2 100644
--- a/public_server/public_server.php
+++ b/public_server/public_server.php
@@ -27,15 +27,6 @@ function public_server_install()
Hook::register('logged_in', 'addon/public_server/public_server.php', 'public_server_login');
}
-function public_server_uninstall()
-{
- Hook::unregister('load_config', 'addon/public_server/public_server.php', 'public_server_load_config');
- Hook::unregister('register_account', 'addon/public_server/public_server.php', 'public_server_register_account');
- Hook::unregister('cron', 'addon/public_server/public_server.php', 'public_server_cron');
- Hook::unregister('enotify', 'addon/public_server/public_server.php', 'public_server_enotify');
- Hook::unregister('logged_in', 'addon/public_server/public_server.php', 'public_server_login');
-}
-
function public_server_load_config(App $a, ConfigFileLoader $loader)
{
$a->getConfigCache()->load($loader->loadAddonConfig('public_server'));
@@ -160,7 +151,6 @@ function public_server_addon_admin_post(&$a)
DI::config()->set('public_server', 'flagusers', $flagusers);
DI::config()->set('public_server', 'flagposts', $flagposts);
DI::config()->set('public_server', 'flagpostsexpire', $flagpostsexpire);
- info(DI::l10n()->t('Settings saved').EOL);
}
function public_server_addon_admin(&$a, &$o)
diff --git a/pumpio/pumpio.php b/pumpio/pumpio.php
index 87e3344d0..2e2ca98cb 100644
--- a/pumpio/pumpio.php
+++ b/pumpio/pumpio.php
@@ -23,7 +23,6 @@ use Friendica\Protocol\Activity;
use Friendica\Protocol\ActivityNamespace;
use Friendica\Util\ConfigFileLoader;
use Friendica\Util\DateTimeFormat;
-use Friendica\Util\Network;
use Friendica\Util\Strings;
use Friendica\Util\XML;
@@ -46,19 +45,6 @@ function pumpio_install()
Hook::register('check_item_notification', 'addon/pumpio/pumpio.php', 'pumpio_check_item_notification');
}
-function pumpio_uninstall()
-{
- Hook::unregister('load_config', 'addon/pumpio/pumpio.php', 'pumpio_load_config');
- Hook::unregister('hook_fork', 'addon/pumpio/pumpio.php', 'pumpio_hook_fork');
- Hook::unregister('post_local', 'addon/pumpio/pumpio.php', 'pumpio_post_local');
- Hook::unregister('notifier_normal', 'addon/pumpio/pumpio.php', 'pumpio_send');
- Hook::unregister('jot_networks', 'addon/pumpio/pumpio.php', 'pumpio_jot_nets');
- Hook::unregister('connector_settings', 'addon/pumpio/pumpio.php', 'pumpio_settings');
- Hook::unregister('connector_settings_post', 'addon/pumpio/pumpio.php', 'pumpio_settings_post');
- Hook::unregister('cron', 'addon/pumpio/pumpio.php', 'pumpio_cron');
- Hook::unregister('check_item_notification', 'addon/pumpio/pumpio.php', 'pumpio_check_item_notification');
-}
-
function pumpio_module() {}
function pumpio_content(App $a)
@@ -925,8 +911,6 @@ function pumpio_dounlike(App $a, $uid, $self, $post, $own_id)
function pumpio_dolike(App $a, $uid, $self, $post, $own_id, $threadcompletion = true)
{
- require_once('include/items.php');
-
if (empty($post->object->id)) {
Logger::log('Got empty like: '.print_r($post, true), Logger::DEBUG);
return;
@@ -1071,7 +1055,7 @@ function pumpio_get_contact($uid, $contact, $no_insert = false)
}
if (!empty($contact->image->url)) {
- Contact::updateAvatar($contact->image->url, $uid, $contact_id);
+ Contact::updateAvatar($contact_id, $contact->image->url);
}
return $contact_id;
@@ -1096,8 +1080,6 @@ function pumpio_dodelete(App $a, $uid, $self, $post, $own_id)
function pumpio_dopost(App $a, $client, $uid, $self, $post, $own_id, $threadcompletion = true)
{
- require_once('include/items.php');
-
if (($post->verb == "like") || ($post->verb == "favorite")) {
return pumpio_dolike($a, $uid, $self, $post, $own_id);
}
@@ -1609,7 +1591,7 @@ function pumpio_fetchallcomments(App $a, $uid, $id)
function pumpio_reachable($url)
{
- return Network::curl($url, false, ['timeout' => 10])->isSuccess();
+ return DI::httpRequest()->get($url, false, ['timeout' => 10])->isSuccess();
}
/*
diff --git a/qcomment/qcomment.css b/qcomment/qcomment.css
deleted file mode 100644
index 3e5513bbc..000000000
--- a/qcomment/qcomment.css
+++ /dev/null
@@ -1,19 +0,0 @@
-
-#qcomment-label {
- float: left;
- width: 300px;
- margin-top: 10px;
-}
-
-#qcomment-words {
- float: left;
- margin-top: 10px;
- width: 100px;
- height: 150px;
-
-}
-
-#qcomment-submit {
- margin-top: 15px;
-}
-
diff --git a/qcomment/qcomment.js b/qcomment/qcomment.js
new file mode 100644
index 000000000..1f5c3496f
--- /dev/null
+++ b/qcomment/qcomment.js
@@ -0,0 +1,18 @@
+function qCommentInsert(obj, id)
+{
+ let $textarea = $('#comment-edit-text-' + id);
+
+ if ($textarea.val() === '') {
+ $textarea.addClass('comment-edit-text-full');
+ $textarea.removeClass('comment-edit-text-empty');
+ openMenu('comment-edit-submit-wrapper-' + id);
+ }
+
+ var ins = $(obj).val();
+ ins = ins.replace('<', '<');
+ ins = ins.replace('>', '>');
+ ins = ins.replace('&', '&');
+ ins = ins.replace('"', '"');
+ $textarea.val($textarea.val() + ins);
+ $(obj).val('');
+}
diff --git a/qcomment/qcomment.php b/qcomment/qcomment.php
index 1ce092053..ed110f667 100644
--- a/qcomment/qcomment.php
+++ b/qcomment/qcomment.php
@@ -21,16 +21,16 @@ use Friendica\Core\Hook;
use Friendica\DI;
use Friendica\Util\XML;
-function qcomment_install() {
- Hook::register('addon_settings', 'addon/qcomment/qcomment.php', 'qcomment_addon_settings');
- Hook::register('addon_settings_post', 'addon/qcomment/qcomment.php', 'qcomment_addon_settings_post');
-
+function qcomment_install()
+{
+ Hook::register('addon_settings' , __FILE__, 'qcomment_addon_settings');
+ Hook::register('addon_settings_post', __FILE__, 'qcomment_addon_settings_post');
+ Hook::register('footer' , __FILE__, 'qcomment_footer');
}
-function qcomment_uninstall() {
- Hook::unregister('addon_settings', 'addon/qcomment/qcomment.php', 'qcomment_addon_settings');
- Hook::unregister('addon_settings_post', 'addon/qcomment/qcomment.php', 'qcomment_addon_settings_post');
-
+function qcomment_footer(\Friendica\App $a, &$b)
+{
+ DI::page()->registerFooterScript(__DIR__ . '/qcomment.js');
}
function qcomment_addon_settings(&$a, &$s)
@@ -39,24 +39,16 @@ function qcomment_addon_settings(&$a, &$s)
return;
}
- /* Add our stylesheet to the page so we can make our settings look nice */
-
- DI::page()['htmlhead'] .= '' . "\r\n";
-
$words = DI::pConfig()->get(local_user(), 'qcomment', 'words', DI::l10n()->t(':-)') . "\n" . DI::l10n()->t(':-(') . "\n" . DI::l10n()->t('lol'));
- $s .= '
';
- $s .= '
' . DI::l10n()->t('Quick Comment Settings') . '
';
- $s .= '
';
- $s .= '
' . DI::l10n()->t("Quick comments are found near comment boxes, sometimes hidden. Click them to provide simple replies.") . '
';
- $s .= '';
- $s .= '';
- $s .= '
';
-
- $s .= '';
- $s .= '
';
-
- return;
+ $t = \Friendica\Core\Renderer::getMarkupTemplate('settings.tpl', 'addon/qcomment/');
+ $s .= \Friendica\Core\Renderer::replaceMacros($t, [
+ '$postpost' => isset($_POST['qcomment-words']),
+ '$header' => DI::l10n()->t('Quick Comment Settings'),
+ '$description' => DI::l10n()->t("Quick comments are found near comment boxes, sometimes hidden. Click them to provide simple replies."),
+ '$save' => DI::l10n()->t('Save Settings'),
+ '$words' => ['qcomment-words', DI::l10n()->t('Enter quick comments, one per line'), $words, null, ' rows="10"'],
+ ]);
}
function qcomment_addon_settings_post(&$a, &$b)
@@ -65,8 +57,7 @@ function qcomment_addon_settings_post(&$a, &$b)
return;
}
- if ($_POST['qcomment-submit']) {
+ if (isset($_POST['qcomment-words'])) {
DI::pConfig()->set(local_user(), 'qcomment', 'words', XML::escape($_POST['qcomment-words']));
- info(DI::l10n()->t('Quick Comment settings saved.') . EOL);
}
}
diff --git a/qcomment/templates/settings.tpl b/qcomment/templates/settings.tpl
new file mode 100644
index 000000000..31ccea86d
--- /dev/null
+++ b/qcomment/templates/settings.tpl
@@ -0,0 +1,21 @@
+
+
diff --git a/randplace/randplace.php b/randplace/randplace.php
index 886d79d12..3576fef85 100644
--- a/randplace/randplace.php
+++ b/randplace/randplace.php
@@ -52,17 +52,12 @@ function randplace_uninstall() {
/**
*
- * uninstall unregisters any hooks created with register_hook
- * during install. It may also delete configuration settings
- * and any other cleanup.
+ * This function should undo anything that was done in name_install()
+ *
+ * Except hooks, they are all unregistered automatically and don't need to be unregistered manually.
*
*/
- Hook::unregister('post_local', 'addon/randplace/randplace.php', 'randplace_post_hook');
- Hook::unregister('addon_settings', 'addon/randplace/randplace.php', 'randplace_settings');
- Hook::unregister('addon_settings_post', 'addon/randplace/randplace.php', 'randplace_settings_post');
-
-
Logger::log("removed randplace");
}
diff --git a/remote_permissions/remote_permissions.php b/remote_permissions/remote_permissions.php
index 268171828..6fe75f169 100644
--- a/remote_permissions/remote_permissions.php
+++ b/remote_permissions/remote_permissions.php
@@ -19,12 +19,6 @@ function remote_permissions_install() {
Hook::register('addon_settings_post', 'addon/remote_permissions/remote_permissions.php', 'remote_permissions_settings_post');
}
-function remote_permissions_uninstall() {
- Hook::unregister('lockview_content', 'addon/remote_permissions/remote_permissions.php', 'remote_permissions_content');
- Hook::unregister('addon_settings', 'addon/remote_permissions/remote_permissions.php', 'remote_permissions_settings');
- Hook::unregister('addon_settings_post', 'addon/remote_permissions/remote_permissions.php', 'remote_permissions_settings_post');
-}
-
function remote_permissions_settings(&$a,&$o) {
if(! local_user())
@@ -60,7 +54,6 @@ function remote_permissions_settings_post($a,$post) {
return;
DI::pConfig()->set(local_user(),'remote_perms','show',intval($_POST['remote-perms']));
- info(DI::l10n()->t('Remote Permissions settings updated.') . EOL);
}
function remote_permissions_content($a, $item_copy) {
@@ -209,5 +202,4 @@ function remote_permissions_addon_admin(&$a, &$o){
function remote_permissions_addon_admin_post(&$a){
$choice = (!empty($_POST['remotepermschoice']) ? Strings::escapeTags(trim($_POST['remotepermschoice'])) : '');
DI::config()->set('remote_perms','global',($choice == 1 ? 1 : 0));
- info(DI::l10n()->t('Settings updated.'). EOL);
}
diff --git a/rendertime/rendertime.php b/rendertime/rendertime.php
index c44d0a305..acc6521a5 100644
--- a/rendertime/rendertime.php
+++ b/rendertime/rendertime.php
@@ -14,12 +14,6 @@ function rendertime_install() {
Hook::register('page_end', 'addon/rendertime/rendertime.php', 'rendertime_page_end');
}
-
-function rendertime_uninstall() {
- Hook::unregister('init_1', 'addon/rendertime/rendertime.php', 'rendertime_init_1');
- Hook::unregister('page_end', 'addon/rendertime/rendertime.php', 'rendertime_page_end');
-}
-
function rendertime_init_1(&$a) {
}
diff --git a/securemail/SecureTestEmail.php b/securemail/SecureTestEmail.php
index e15ef601f..8341f5451 100644
--- a/securemail/SecureTestEmail.php
+++ b/securemail/SecureTestEmail.php
@@ -54,6 +54,6 @@ class SecureTestEmail extends Email
parent::__construct($sitename, $sender_email, $sender_email, $a->user['email'],
$subject, "
{$message}
", $message,
- '', local_user());
+ [], local_user());
}
}
diff --git a/securemail/securemail.php b/securemail/securemail.php
index 115ba4729..fb801a4ce 100644
--- a/securemail/securemail.php
+++ b/securemail/securemail.php
@@ -26,16 +26,6 @@ function securemail_install()
Logger::log('installed securemail');
}
-function securemail_uninstall()
-{
- Hook::unregister('addon_settings', 'addon/securemail/securemail.php', 'securemail_settings');
- Hook::unregister('addon_settings_post', 'addon/securemail/securemail.php', 'securemail_settings_post');
-
- Hook::unregister('emailer_send_prepare', 'addon/securemail/securemail.php', 'securemail_emailer_send_prepare');
-
- Logger::log('removed securemail');
-}
-
/**
* @brief Build user settings form
*
@@ -86,7 +76,6 @@ function securemail_settings_post(App &$a, array &$b)
DI::pConfig()->set(local_user(), 'securemail', 'pkey', trim($_POST['securemail-pkey']));
$enable = (!empty($_POST['securemail-enable']) ? 1 : 0);
DI::pConfig()->set(local_user(), 'securemail', 'enable', $enable);
- info(DI::l10n()->t('Secure Mail Settings saved.') . EOL);
if ($_POST['securemail-submit'] == DI::l10n()->t('Save and send test')) {
diff --git a/showmore/showmore.php b/showmore/showmore.php
index 277c29ced..7583fd33d 100644
--- a/showmore/showmore.php
+++ b/showmore/showmore.php
@@ -18,13 +18,6 @@ function showmore_install()
Hook::register('addon_settings_post', 'addon/showmore/showmore.php', 'showmore_addon_settings_post');
}
-function showmore_uninstall()
-{
- Hook::unregister('prepare_body', 'addon/showmore/showmore.php', 'showmore_prepare_body');
- Hook::unregister('addon_settings', 'addon/showmore/showmore.php', 'showmore_addon_settings');
- Hook::unregister('addon_settings_post', 'addon/showmore/showmore.php', 'showmore_addon_settings_post');
-}
-
function showmore_addon_settings(&$a, &$s)
{
if (!local_user()) {
@@ -73,7 +66,6 @@ function showmore_addon_settings_post(&$a, &$b)
$enable = (!empty($_POST['showmore-enable']) ? intval($_POST['showmore-enable']) : 0);
$disable = 1-$enable;
DI::pConfig()->set(local_user(), 'showmore', 'disable', $disable);
- info(DI::l10n()->t('Show More Settings saved.') . EOL);
}
}
diff --git a/smiley_pack/lang/smiley_pack_es/smiley_pack_es.php b/smiley_pack/lang/smiley_pack_es/smiley_pack_es.php
index 892b4a70b..329b7282a 100644
--- a/smiley_pack/lang/smiley_pack_es/smiley_pack_es.php
+++ b/smiley_pack/lang/smiley_pack_es/smiley_pack_es.php
@@ -13,12 +13,6 @@ function smiley_pack_es_install() {
Hook::register('smilie', 'addon/smiley_pack_es/smiley_pack_es.php', 'smiley_pack_smilies_es');
}
-function smiley_pack_es_uninstall() {
- Hook::unregister('smilie', 'addon/smiley_pack_es/smiley_pack_es.php', 'smiley_pack_smilies');
-}
-
-
-
function smiley_pack_smilies_es(&$a,&$b) {
#Smileys are split into various directories by the intended range of emotions. This is in case we get too big and need to modularise things. We can then cut and paste the right lines, move the right directory, and just change the name of the addon to happy_smilies or whatever.
diff --git a/smiley_pack/lang/smiley_pack_fr/smiley_pack_fr.php b/smiley_pack/lang/smiley_pack_fr/smiley_pack_fr.php
index 7472bd1cb..bcefa7c3f 100644
--- a/smiley_pack/lang/smiley_pack_fr/smiley_pack_fr.php
+++ b/smiley_pack/lang/smiley_pack_fr/smiley_pack_fr.php
@@ -15,12 +15,6 @@ function smiley_pack_fr_install() {
Hook::register('smilie', 'addon/smiley_pack_fr/smiley_pack_fr.php', 'smiley_pack_fr_smilies');
}
-function smiley_pack_fr_uninstall() {
- Hook::unregister('smilie', 'addon/smiley_pack_fr/smiley_pack_fr.php', 'smiley_pack_fr_smilies');
-}
-
-
-
function smiley_pack_fr_smilies(&$a,&$b) {
#Smileys are split into various directories by the intended range of emotions. This is in case we get too big and need to modularise things. We can then cut and paste the right lines, move the right directory, and just change the name of the addon to happy_smilies or whatever.
diff --git a/smiley_pack/smiley_pack.php b/smiley_pack/smiley_pack.php
index a80ab717c..6562e29bf 100644
--- a/smiley_pack/smiley_pack.php
+++ b/smiley_pack/smiley_pack.php
@@ -14,12 +14,6 @@ function smiley_pack_install() {
Hook::register('smilie', 'addon/smiley_pack/smiley_pack.php', 'smiley_pack_smilies');
}
-function smiley_pack_uninstall() {
- Hook::unregister('smilie', 'addon/smiley_pack/smiley_pack.php', 'smiley_pack_smilies');
-}
-
-
-
function smiley_pack_smilies(&$a,&$b) {
#Smileys are split into various directories by the intended range of emotions. This is in case we get too big and need to modularise things. We can then cut and paste the right lines, move the right directory, and just change the name of the addon to happy_smilies or whatever.
diff --git a/smileybutton/smileybutton.php b/smileybutton/smileybutton.php
index 9d4916372..fc4207736 100644
--- a/smileybutton/smileybutton.php
+++ b/smileybutton/smileybutton.php
@@ -16,16 +16,6 @@ function smileybutton_install() {
Logger::log("installed smileybutton");
}
-
-function smileybutton_uninstall() {
- //Delet registered hooks
- Hook::unregister('jot_tool', 'addon/smileybutton/smileybutton.php', 'show_button');
-
- Logger::log("removed smileybutton");
-}
-
-
-
function show_button(Friendica\App $a, &$b) {
// Disable if theme is quattro
// TODO add style for quattro
diff --git a/smilies_adult/smilies_adult.php b/smilies_adult/smilies_adult.php
index 84bb24cf5..b55a0a2fe 100644
--- a/smilies_adult/smilies_adult.php
+++ b/smilies_adult/smilies_adult.php
@@ -15,12 +15,6 @@ function smilies_adult_install() {
Hook::register('smilie', 'addon/smilies_adult/smilies_adult.php', 'smilies_adult_smilies');
}
-function smilies_adult_uninstall() {
- Hook::unregister('smilie', 'addon/smilies_adult/smilies_adult.php', 'smilies_adult_smilies');
-}
-
-
-
function smilies_adult_smilies(&$a,&$b) {
$b['texts'][] = '(o)(o)';
diff --git a/sniper/sniper.php b/sniper/sniper.php
index 97d26b7b9..31c97a843 100644
--- a/sniper/sniper.php
+++ b/sniper/sniper.php
@@ -16,11 +16,6 @@ function sniper_install() {
Hook::register('app_menu', 'addon/sniper/sniper.php', 'sniper_app_menu');
}
-function sniper_uninstall() {
- Hook::unregister('app_menu', 'addon/sniper/sniper.php', 'sniper_app_menu');
-
-}
-
function sniper_app_menu($a,&$b) {
$b['app_menu'][] = '
';
}
diff --git a/startpage/startpage.php b/startpage/startpage.php
index 9192b5a8e..8cdf444f1 100644
--- a/startpage/startpage.php
+++ b/startpage/startpage.php
@@ -15,13 +15,6 @@ function startpage_install() {
Hook::register('addon_settings_post', 'addon/startpage/startpage.php', 'startpage_settings_post');
}
-function startpage_uninstall()
-{
- Hook::unregister('home_init', 'addon/startpage/startpage.php', 'startpage_home_init');
- Hook::unregister('addon_settings', 'addon/startpage/startpage.php', 'startpage_settings');
- Hook::unregister('addon_settings_post', 'addon/startpage/startpage.php', 'startpage_settings_post');
-}
-
function startpage_home_init($a, $b)
{
if (!local_user()) {
diff --git a/statusnet/lang/it/messages.po b/statusnet/lang/it/messages.po
index c2c3404f2..9216db8f8 100644
--- a/statusnet/lang/it/messages.po
+++ b/statusnet/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014-2015
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2015-07-27 07:21+0200\n"
-"PO-Revision-Date: 2017-09-20 06:08+0000\n"
-"Last-Translator: fabrixxm \n"
+"PO-Revision-Date: 2020-09-17 11:40+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -127,7 +128,7 @@ msgid ""
"details from unknown viewers?) the link potentially included in public "
"postings relayed to GNU Social will lead the visitor to a blank page "
"informing the visitor that the access to your profile has been restricted."
-msgstr "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il link potenzialmente incluse nei messaggi pubblici inviati a GNU Social porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato."
+msgstr "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il collegamento potenzialmente incluso nei messaggi pubblici inviati a GNU Social porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato."
#: statusnet.php:385
msgid "Allow posting to GNU Social"
diff --git a/statusnet/lang/it/strings.php b/statusnet/lang/it/strings.php
index e96776841..8f44cf772 100644
--- a/statusnet/lang/it/strings.php
+++ b/statusnet/lang/it/strings.php
@@ -2,6 +2,7 @@
if(! function_exists("string_plural_select_it")) {
function string_plural_select_it($n){
+ $n = intval($n);
return ($n != 1);;
}}
;
@@ -26,7 +27,7 @@ $a->strings["Current GNU Social API is"] = "Le API GNU Social correnti sono";
$a->strings["Cancel GNU Social Connection"] = "Annulla la connessione a GNU Social";
$a->strings["Currently connected to: "] = "Al momento connesso con:";
$a->strings["If enabled all your public postings can be posted to the associated GNU Social account. You can choose to do so by default (here) or for every posting separately in the posting options when writing the entry."] = "Se abilitato tutti i tuoi messaggi pubblici possono essere inviati all'account GNU Social associato. Puoi scegliere di farlo sempre (qui) o ogni volta che invii, nelle impostazioni di privacy del messaggio.";
-$a->strings["Note: Due your privacy settings (Hide your profile details from unknown viewers?) the link potentially included in public postings relayed to GNU Social will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted."] = "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il link potenzialmente incluse nei messaggi pubblici inviati a GNU Social porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato.";
+$a->strings["Note: Due your privacy settings (Hide your profile details from unknown viewers?) the link potentially included in public postings relayed to GNU Social will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted."] = "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il collegamento potenzialmente incluso nei messaggi pubblici inviati a GNU Social porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato.";
$a->strings["Allow posting to GNU Social"] = "Permetti l'invio a GNU Social";
$a->strings["Send public postings to GNU Social by default"] = "Invia sempre i messaggi pubblici a GNU Social";
$a->strings["Mirror all posts from GNU Social that are no replies or repeated messages"] = "Clona tutti i messaggi da GNU Social che non sono risposte o messaggi ripetuti";
diff --git a/statusnet/statusnet.php b/statusnet/statusnet.php
index f75d23460..0ab711cad 100644
--- a/statusnet/statusnet.php
+++ b/statusnet/statusnet.php
@@ -40,6 +40,7 @@ require_once __DIR__ . DIRECTORY_SEPARATOR . 'library' . DIRECTORY_SEPARATOR . '
use CodebirdSN\CodebirdSN;
use Friendica\App;
use Friendica\Content\OEmbed;
+use Friendica\Content\PageInfo;
use Friendica\Content\Text\HTML;
use Friendica\Content\Text\Plaintext;
use Friendica\Core\Hook;
@@ -56,7 +57,6 @@ use Friendica\Model\Photo;
use Friendica\Model\User;
use Friendica\Protocol\Activity;
use Friendica\Util\DateTimeFormat;
-use Friendica\Util\Network;
use Friendica\Util\Strings;
function statusnet_install()
@@ -74,24 +74,6 @@ function statusnet_install()
Logger::log("installed GNU Social");
}
-function statusnet_uninstall()
-{
- Hook::unregister('connector_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
- Hook::unregister('connector_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
- Hook::unregister('notifier_normal', 'addon/statusnet/statusnet.php', 'statusnet_post_hook');
- Hook::unregister('hook_fork', 'addon/statusnet/statusnet.php', 'statusnet_hook_fork');
- Hook::unregister('post_local', 'addon/statusnet/statusnet.php', 'statusnet_post_local');
- Hook::unregister('jot_networks', 'addon/statusnet/statusnet.php', 'statusnet_jot_nets');
- Hook::unregister('cron', 'addon/statusnet/statusnet.php', 'statusnet_cron');
- Hook::unregister('prepare_body', 'addon/statusnet/statusnet.php', 'statusnet_prepare_body');
- Hook::unregister('check_item_notification', 'addon/statusnet/statusnet.php', 'statusnet_check_item_notification');
-
- // old setting - remove only
- Hook::unregister('post_local_end', 'addon/statusnet/statusnet.php', 'statusnet_post_hook');
- Hook::unregister('addon_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
- Hook::unregister('addon_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
-}
-
function statusnet_check_item_notification(App $a, &$notification_data)
{
if (DI::pConfig()->get($notification_data["uid"], 'statusnet', 'post')) {
@@ -154,7 +136,7 @@ function statusnet_settings_post(App $a, $post)
foreach ($globalsn as $asn) {
if ($asn['apiurl'] == $_POST['statusnet-preconf-apiurl']) {
$apibase = $asn['apiurl'];
- $c = Network::fetchUrl($apibase . 'statusnet/version.xml');
+ $c = DI::httpRequest()->fetch($apibase . 'statusnet/version.xml');
if (strlen($c) > 0) {
DI::pConfig()->set(local_user(), 'statusnet', 'consumerkey', $asn['consumerkey']);
DI::pConfig()->set(local_user(), 'statusnet', 'consumersecret', $asn['consumersecret']);
@@ -172,7 +154,7 @@ function statusnet_settings_post(App $a, $post)
// we'll check the API Version for that, if we don't get one we'll try to fix the path but will
// resign quickly after this one try to fix the path ;-)
$apibase = $_POST['statusnet-baseapi'];
- $c = Network::fetchUrl($apibase . 'statusnet/version.xml');
+ $c = DI::httpRequest()->fetch($apibase . 'statusnet/version.xml');
if (strlen($c) > 0) {
// ok the API path is correct, let's save the settings
DI::pConfig()->set(local_user(), 'statusnet', 'consumerkey', $_POST['statusnet-consumerkey']);
@@ -182,7 +164,7 @@ function statusnet_settings_post(App $a, $post)
} else {
// the API path is not correct, maybe missing trailing / ?
$apibase = $apibase . '/';
- $c = Network::fetchUrl($apibase . 'statusnet/version.xml');
+ $c = DI::httpRequest()->fetch($apibase . 'statusnet/version.xml');
if (strlen($c) > 0) {
// ok the API path is now correct, let's save the settings
DI::pConfig()->set(local_user(), 'statusnet', 'consumerkey', $_POST['statusnet-consumerkey']);
@@ -223,8 +205,6 @@ function statusnet_settings_post(App $a, $post)
if (!intval($_POST['statusnet-mirror']))
DI::pConfig()->delete(local_user(), 'statusnet', 'lastid');
-
- info(DI::l10n()->t('GNU Social settings updated.') . EOL);
}
}
}
@@ -612,7 +592,7 @@ function statusnet_post_hook(App $a, &$b)
}
if ($image != "") {
- $img_str = Network::fetchUrl($image);
+ $img_str = DI::httpRequest()->fetch($image);
$tempfile = tempnam(get_temppath(), "cache");
file_put_contents($tempfile, $img_str);
$postdata = ["status" => $msg, "media[]" => $tempfile];
@@ -896,7 +876,7 @@ function statusnet_fetchtimeline(App $a, $uid)
$_REQUEST["title"] = "";
- $_REQUEST["body"] = add_page_info_to_body($post->text, true);
+ $_REQUEST["body"] = PageInfo::searchAndAppendToBody($post->text, true);
if (is_string($post->place->name)) {
$_REQUEST["location"] = $post->place->name;
}
@@ -1449,7 +1429,7 @@ function statusnet_convertmsg(App $a, $body)
Logger::log("statusnet_convertmsg: expanding url " . $match[1], Logger::DEBUG);
- $expanded_url = Network::finalUrl($match[1]);
+ $expanded_url = DI::httpRequest()->finalUrl($match[1]);
Logger::log("statusnet_convertmsg: fetching data for " . $expanded_url, Logger::DEBUG);
@@ -1473,7 +1453,7 @@ function statusnet_convertmsg(App $a, $body)
} elseif ($oembed_data->type != "link") {
$body = str_replace($search, "[url=" . $expanded_url . "]" . $expanded_url . "[/url]", $body);
} else {
- $img_str = Network::fetchUrl($expanded_url, true, 4);
+ $img_str = DI::httpRequest()->fetch($expanded_url, true, 4);
$tempfile = tempnam(get_temppath(), "cache");
file_put_contents($tempfile, $img_str);
@@ -1494,7 +1474,7 @@ function statusnet_convertmsg(App $a, $body)
}
if ($footerurl != "") {
- $footer = add_page_info($footerurl);
+ $footer = "\n" . PageInfo::getFooterFromUrl($footerurl);
}
if (($footerlink != "") && (trim($footer) != "")) {
diff --git a/superblock/superblock.php b/superblock/superblock.php
index e0b3ff83e..7bf2bc4ce 100644
--- a/superblock/superblock.php
+++ b/superblock/superblock.php
@@ -19,15 +19,6 @@ function superblock_install()
Hook::register('enotify_store', 'addon/superblock/superblock.php', 'superblock_enotify_store');
}
-function superblock_uninstall()
-{
- Hook::unregister('addon_settings', 'addon/superblock/superblock.php', 'superblock_addon_settings');
- Hook::unregister('addon_settings_post', 'addon/superblock/superblock.php', 'superblock_addon_settings_post');
- Hook::unregister('conversation_start', 'addon/superblock/superblock.php', 'superblock_conversation_start');
- Hook::unregister('item_photo_menu', 'addon/superblock/superblock.php', 'superblock_item_photo_menu');
- Hook::unregister('enotify_store', 'addon/superblock/superblock.php', 'superblock_enotify_store');
-}
-
function superblock_addon_settings(&$a, &$s)
{
if (!local_user()) {
@@ -68,11 +59,13 @@ function superblock_addon_settings_post(&$a, &$b)
if (!empty($_POST['superblock-submit'])) {
DI::pConfig()->set(local_user(), 'system', 'blocked',trim($_POST['superblock-words']));
- info(DI::l10n()->t('SUPERBLOCK Settings saved.') . EOL);
}
}
function superblock_enotify_store(&$a,&$b) {
+ if (empty($b['uid'])) {
+ return;
+ }
$words = DI::pConfig()->get($b['uid'], 'system', 'blocked');
if ($words) {
@@ -163,6 +156,5 @@ function superblock_init(&$a)
}
DI::pConfig()->set(local_user(), 'system', 'blocked', $words);
- info(DI::l10n()->t('superblock settings updated') . EOL );
exit();
}
diff --git a/testdrive/testdrive.php b/testdrive/testdrive.php
index cb95babfc..1806ea2cc 100644
--- a/testdrive/testdrive.php
+++ b/testdrive/testdrive.php
@@ -26,17 +26,6 @@ function testdrive_install() {
}
-
-function testdrive_uninstall() {
-
- Hook::unregister('load_config', 'addon/testdrive/testdrive.php', 'testdrive_load_config');
- Hook::unregister('register_account', 'addon/testdrive/testdrive.php', 'testdrive_register_account');
- Hook::unregister('cron', 'addon/testdrive/testdrive.php', 'testdrive_cron');
- Hook::unregister('enotify','addon/testdrive/testdrive.php', 'testdrive_enotify');
- Hook::unregister('globaldir_update','addon/testdrive/testdrive.php', 'testdrive_globaldir_update');
-
-}
-
function testdrive_load_config(App $a, ConfigFileLoader $loader)
{
$a->getConfigCache()->load($loader->loadAddonConfig('testdrive'));
diff --git a/tictac/tictac.php b/tictac/tictac.php
index 08a8c09c7..47c9e806e 100644
--- a/tictac/tictac.php
+++ b/tictac/tictac.php
@@ -12,11 +12,6 @@ function tictac_install() {
Hook::register('app_menu', 'addon/tictac/tictac.php', 'tictac_app_menu');
}
-function tictac_uninstall() {
- Hook::unregister('app_menu', 'addon/tictac/tictac.php', 'tictac_app_menu');
-
-}
-
function tictac_app_menu($a,&$b) {
$b['app_menu'][] = '
';
}
diff --git a/tumblr/tumblr.php b/tumblr/tumblr.php
index e42e97aaf..4504534cb 100644
--- a/tumblr/tumblr.php
+++ b/tumblr/tumblr.php
@@ -29,16 +29,6 @@ function tumblr_install()
Hook::register('connector_settings_post', 'addon/tumblr/tumblr.php', 'tumblr_settings_post');
}
-function tumblr_uninstall()
-{
- Hook::unregister('hook_fork', 'addon/tumblr/tumblr.php', 'tumblr_hook_fork');
- Hook::unregister('post_local', 'addon/tumblr/tumblr.php', 'tumblr_post_local');
- Hook::unregister('notifier_normal', 'addon/tumblr/tumblr.php', 'tumblr_send');
- Hook::unregister('jot_networks', 'addon/tumblr/tumblr.php', 'tumblr_jot_nets');
- Hook::unregister('connector_settings', 'addon/tumblr/tumblr.php', 'tumblr_settings');
- Hook::unregister('connector_settings_post', 'addon/tumblr/tumblr.php', 'tumblr_settings_post');
-}
-
function tumblr_module()
{
}
@@ -90,8 +80,6 @@ function tumblr_addon_admin_post(App $a)
DI::config()->set('tumblr', 'consumer_key',$consumer_key);
DI::config()->set('tumblr', 'consumer_secret',$consumer_secret);
-
- info(DI::l10n()->t('Settings updated.'). EOL);
}
function tumblr_connect(App $a)
diff --git a/twitter/lang/it/messages.po b/twitter/lang/it/messages.po
index 7ce7330aa..253f17d24 100644
--- a/twitter/lang/it/messages.po
+++ b/twitter/lang/it/messages.po
@@ -5,13 +5,14 @@
#
# Translators:
# fabrixxm , 2014-2015,2018
+# Sylke Vicious , 2020
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-06-02 10:25+0700\n"
-"PO-Revision-Date: 2018-06-06 15:03+0000\n"
-"Last-Translator: fabrixxm \n"
+"PO-Revision-Date: 2020-09-17 11:44+0000\n"
+"Last-Translator: Sylke Vicious \n"
"Language-Team: Italian (http://www.transifex.com/Friendica/friendica/language/it/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
@@ -50,7 +51,7 @@ msgid ""
"button below to get a PIN from Twitter which you have to copy into the input"
" box below and submit the form. Only your public posts will"
" be posted to Twitter."
-msgstr "Il componente aggiuntivo Twitter è abilitato ma non hai ancora collegato i tuoi account Friendica e Twitter. Per farlo, clicca il bottone qui sotto per ricevere un PIN da Twitter che dovrai copiare nel campo qui sotto. Solo i tuoi post pubblici saranno inviati a Twitter."
+msgstr "Il componente aggiuntivo Twitter è abilitato ma non hai ancora collegato i tuoi account Friendica e Twitter. Per farlo, clicca il bottone qui sotto per ricevere un PIN da Twitter che dovrai copiare nel campo qui sotto. Solo i tuoi messaggi pubblici saranno inviati a Twitter."
#: twitter.php:317
msgid "Log in with Twitter"
@@ -89,7 +90,7 @@ msgid ""
"details from unknown viewers?) the link potentially included in public "
"postings relayed to Twitter will lead the visitor to a blank page informing "
"the visitor that the access to your profile has been restricted."
-msgstr "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il link potenzialmente incluso nei messaggi pubblici inviati a Twitter porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato."
+msgstr "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il collegamento potenzialmente incluso nei messaggi pubblici inviati a Twitter porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato."
#: twitter.php:353
msgid "Send public postings to Twitter by default"
@@ -115,7 +116,7 @@ msgid ""
"from whom you would like to see posts here. However if enabled, you cannot "
"merely remove a twitter contact from the Friendica contact list, as it will "
"recreate this contact when they post again."
-msgstr "Questo creerà automaticamente un contatto in Friendica appena ricevi un messaggio da un tuo contatto sulla rete Twitter. Se non abiliti questa opzione, dovrai aggiungere a mano in Friendica i contatti Twitter da cui vuoi ricevere i messaggi. Se abilitato, pero', non potrai semplicemente rimuovere un contatto Twitter dal tuo elenco contatti su Friendica, dato che questo sarà ricreato la prossima volta che invierà un messaggio."
+msgstr "Questo creerà automaticamente un contatto in Friendica appena ricevi un messaggio da un tuo contatto sulla rete Twitter. Se non abiliti questa opzione, dovrai aggiungere a mano in Friendica i contatti Twitter da cui vuoi ricevere i messaggi. Se abilitato, però, non potrai semplicemente rimuovere un contatto Twitter dal tuo elenco contatti su Friendica, dato che questo sarà ricreato la prossima volta che invierà un messaggio."
#: twitter.php:614
msgid "Twitter post failed. Queued for retry."
diff --git a/twitter/lang/it/strings.php b/twitter/lang/it/strings.php
index deb5b4c1b..a0f3c67e5 100644
--- a/twitter/lang/it/strings.php
+++ b/twitter/lang/it/strings.php
@@ -11,7 +11,7 @@ $a->strings["You submitted an empty PIN, please Sign In with Twitter again to ge
$a->strings["Twitter settings updated."] = "Impostazioni di Twitter aggiornate.";
$a->strings["Twitter Import/Export/Mirror"] = "Importa/Esporta/Clona Twitter";
$a->strings["No consumer key pair for Twitter found. Please contact your site administrator."] = "Nessuna coppia di chiavi per Twitter trovata. Contatta l'amministratore del sito.";
-$a->strings["At this Friendica instance the Twitter addon was enabled but you have not yet connected your account to your Twitter account. To do so click the button below to get a PIN from Twitter which you have to copy into the input box below and submit the form. Only your public posts will be posted to Twitter."] = "Il componente aggiuntivo Twitter è abilitato ma non hai ancora collegato i tuoi account Friendica e Twitter. Per farlo, clicca il bottone qui sotto per ricevere un PIN da Twitter che dovrai copiare nel campo qui sotto. Solo i tuoi post pubblici saranno inviati a Twitter.";
+$a->strings["At this Friendica instance the Twitter addon was enabled but you have not yet connected your account to your Twitter account. To do so click the button below to get a PIN from Twitter which you have to copy into the input box below and submit the form. Only your public posts will be posted to Twitter."] = "Il componente aggiuntivo Twitter è abilitato ma non hai ancora collegato i tuoi account Friendica e Twitter. Per farlo, clicca il bottone qui sotto per ricevere un PIN da Twitter che dovrai copiare nel campo qui sotto. Solo i tuoi messaggi pubblici saranno inviati a Twitter.";
$a->strings["Log in with Twitter"] = "Accedi con Twitter";
$a->strings["Copy the PIN from Twitter here"] = "Copia il PIN da Twitter qui";
$a->strings["Save Settings"] = "Salva Impostazioni";
@@ -19,12 +19,12 @@ $a->strings["Currently connected to: "] = "Al momento connesso con:";
$a->strings["Disconnect"] = "Disconnetti";
$a->strings["Allow posting to Twitter"] = "Permetti l'invio a Twitter";
$a->strings["If enabled all your public postings can be posted to the associated Twitter account. You can choose to do so by default (here) or for every posting separately in the posting options when writing the entry."] = "Se abilitato tutti i tuoi messaggi pubblici possono essere inviati all'account Twitter associato. Puoi scegliere di farlo sempre (qui) o ogni volta che invii, nelle impostazioni di privacy del messaggio.";
-$a->strings["Note: Due to your privacy settings (Hide your profile details from unknown viewers?) the link potentially included in public postings relayed to Twitter will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted."] = "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il link potenzialmente incluso nei messaggi pubblici inviati a Twitter porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato.";
+$a->strings["Note: Due to your privacy settings (Hide your profile details from unknown viewers?) the link potentially included in public postings relayed to Twitter will lead the visitor to a blank page informing the visitor that the access to your profile has been restricted."] = "Nota: A causa delle tue impostazioni di privacy(Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?) il collegamento potenzialmente incluso nei messaggi pubblici inviati a Twitter porterà i visitatori a una pagina bianca con una nota che li informa che l'accesso al tuo profilo è stato limitato.";
$a->strings["Send public postings to Twitter by default"] = "Invia sempre i messaggi pubblici a Twitter";
$a->strings["Mirror all posts from twitter that are no replies"] = "Clona tutti i messaggi da Twitter che non sono risposte";
$a->strings["Import the remote timeline"] = "Importa la timeline remota";
$a->strings["Automatically create contacts"] = "Crea automaticamente i contatti";
-$a->strings["This will automatically create a contact in Friendica as soon as you receive a message from an existing contact via the Twitter network. If you do not enable this, you need to manually add those Twitter contacts in Friendica from whom you would like to see posts here. However if enabled, you cannot merely remove a twitter contact from the Friendica contact list, as it will recreate this contact when they post again."] = "Questo creerà automaticamente un contatto in Friendica appena ricevi un messaggio da un tuo contatto sulla rete Twitter. Se non abiliti questa opzione, dovrai aggiungere a mano in Friendica i contatti Twitter da cui vuoi ricevere i messaggi. Se abilitato, pero', non potrai semplicemente rimuovere un contatto Twitter dal tuo elenco contatti su Friendica, dato che questo sarà ricreato la prossima volta che invierà un messaggio.";
+$a->strings["This will automatically create a contact in Friendica as soon as you receive a message from an existing contact via the Twitter network. If you do not enable this, you need to manually add those Twitter contacts in Friendica from whom you would like to see posts here. However if enabled, you cannot merely remove a twitter contact from the Friendica contact list, as it will recreate this contact when they post again."] = "Questo creerà automaticamente un contatto in Friendica appena ricevi un messaggio da un tuo contatto sulla rete Twitter. Se non abiliti questa opzione, dovrai aggiungere a mano in Friendica i contatti Twitter da cui vuoi ricevere i messaggi. Se abilitato, però, non potrai semplicemente rimuovere un contatto Twitter dal tuo elenco contatti su Friendica, dato che questo sarà ricreato la prossima volta che invierà un messaggio.";
$a->strings["Twitter post failed. Queued for retry."] = "Invio a Twitter fallito. In coda per riprovare.";
$a->strings["Settings updated."] = "Impostazioni aggiornate.";
$a->strings["Consumer key"] = "Consumer key";
diff --git a/twitter/twitter.php b/twitter/twitter.php
index 4c9701d84..375e264cd 100644
--- a/twitter/twitter.php
+++ b/twitter/twitter.php
@@ -67,6 +67,7 @@ use Abraham\TwitterOAuth\TwitterOAuthException;
use Codebird\Codebird;
use Friendica\App;
use Friendica\Content\OEmbed;
+use Friendica\Content\PageInfo;
use Friendica\Content\Text\BBCode;
use Friendica\Content\Text\Plaintext;
use Friendica\Core\Hook;
@@ -88,7 +89,6 @@ use Friendica\Protocol\Activity;
use Friendica\Util\ConfigFileLoader;
use Friendica\Util\DateTimeFormat;
use Friendica\Util\Images;
-use Friendica\Util\Network;
use Friendica\Util\Strings;
require_once __DIR__ . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php';
@@ -240,9 +240,9 @@ function twitter_settings_post(App $a)
DI::pConfig()->set(local_user(), 'twitter', 'oauthsecret', $token['oauth_token_secret']);
DI::pConfig()->set(local_user(), 'twitter', 'post', 1);
} catch(Exception $e) {
- info($e->getMessage());
+ notice($e->getMessage());
} catch(TwitterOAuthException $e) {
- info($e->getMessage());
+ notice($e->getMessage());
}
// reload the Addon Settings page, if we don't do it see Bug #42
DI::baseUrl()->redirect('settings/connectors');
@@ -258,8 +258,6 @@ function twitter_settings_post(App $a)
if (!intval($_POST['twitter-mirror'])) {
DI::pConfig()->delete(local_user(), 'twitter', 'lastid');
}
-
- info(DI::l10n()->t('Twitter settings updated.') . EOL);
}
}
}
@@ -673,7 +671,7 @@ function twitter_post_hook(App $a, array &$b)
continue;
}
- $img_str = Network::fetchUrl($image['url']);
+ $img_str = DI::httpRequest()->fetch($image['url']);
$tempfile = tempnam(get_temppath(), 'cache');
file_put_contents($tempfile, $img_str);
@@ -736,7 +734,6 @@ function twitter_addon_admin_post(App $a)
$consumersecret = !empty($_POST['consumersecret']) ? Strings::escapeTags(trim($_POST['consumersecret'])) : '';
DI::config()->set('twitter', 'consumerkey', $consumerkey);
DI::config()->set('twitter', 'consumersecret', $consumersecret);
- info(DI::l10n()->t('Settings updated.') . EOL);
}
function twitter_addon_admin(App $a, &$o)
@@ -1126,12 +1123,12 @@ function twitter_fetch_contact($uid, $data, $create_user)
if (DBA::isResult($pcontact)) {
$cid = $pcontact['id'];
} else {
- $cid = Contact::getIdForURL($fields['url'], 0, true, $fields);
+ $cid = Contact::getIdForURL($fields['url'], 0, false, $fields);
}
if (!empty($cid)) {
DBA::update('contact', $fields, ['id' => $cid]);
- Contact::updateAvatar($avatar, 0, $cid);
+ Contact::updateAvatar($cid, $avatar);
}
$contact = DBA::selectFirst('contact', [], ['uid' => $uid, 'alias' => "twitter::" . $data->id_str]);
@@ -1163,7 +1160,7 @@ function twitter_fetch_contact($uid, $data, $create_user)
Group::addMember(User::getDefaultGroup($uid), $contact_id);
- Contact::updateAvatar($avatar, $uid, $contact_id);
+ Contact::updateAvatar($contact_id, $avatar);
} else {
if ($contact["readonly"] || $contact["blocked"]) {
Logger::log("twitter_fetch_contact: Contact '" . $contact["nick"] . "' is blocked or readonly.", Logger::DEBUG);
@@ -1179,7 +1176,7 @@ function twitter_fetch_contact($uid, $data, $create_user)
$update = true;
}
- Contact::updateAvatar($avatar, $uid, $contact['id']);
+ Contact::updateAvatar($contact['id'], $avatar);
if ($contact['name'] != $data->name) {
$fields['name-date'] = $fields['uri-date'] = DateTimeFormat::utcNow();
@@ -1296,7 +1293,7 @@ function twitter_expand_entities($body, stdClass $status, $picture)
$expanded_url = $url->expanded_url;
- $final_url = Network::finalUrl($url->expanded_url);
+ $final_url = DI::httpRequest()->finalUrl($url->expanded_url);
$oembed_data = OEmbed::fetchURL($final_url);
@@ -1317,7 +1314,7 @@ function twitter_expand_entities($body, stdClass $status, $picture)
} elseif ($oembed_data->type != 'link') {
$replace = '[url=' . $expanded_url . ']' . $url->display_url . '[/url]';
} else {
- $img_str = Network::fetchUrl($final_url, true, 4);
+ $img_str = DI::httpRequest()->fetch($final_url, true, 4);
$tempfile = tempnam(get_temppath(), 'cache');
file_put_contents($tempfile, $img_str);
@@ -1356,7 +1353,7 @@ function twitter_expand_entities($body, stdClass $status, $picture)
if (empty($status->quoted_status)) {
$footer = '';
if ($attachmentUrl) {
- $footer = add_page_info($attachmentUrl, false, $picture);
+ $footer = "\n" . PageInfo::getFooterFromUrl($attachmentUrl, false, $picture);
}
if (trim($footer)) {
@@ -1364,11 +1361,11 @@ function twitter_expand_entities($body, stdClass $status, $picture)
} elseif ($picture) {
$body .= "\n\n[img]" . $picture . "[/img]\n";
} else {
- $body = add_page_info_to_body($body);
+ $body = PageInfo::searchAndAppendToBody($body);
}
}
- return ['body' => $body, 'plain' => $plain, 'taglist' => $taglist];
+ return ['body' => $body, 'plain' => trim($plain), 'taglist' => $taglist];
}
/**
diff --git a/unicode_smilies/unicode_smilies.php b/unicode_smilies/unicode_smilies.php
index af286276e..ef7bb6150 100644
--- a/unicode_smilies/unicode_smilies.php
+++ b/unicode_smilies/unicode_smilies.php
@@ -13,10 +13,6 @@ function unicode_smilies_install() {
Hook::register('smilie', 'addon/unicode_smilies/unicode_smilies.php', 'unicode_smilies_smilies');
}
-function unicode_smilies_uninstall() {
- Hook::unregister('smilie', 'addon/unicode_smilies/unicode_smilies.php', 'unicode_smilies_smilies');
-}
-
function unicode_smilies_smilies(&$a,&$b) {
Smilies::add($b, ':-)', '😀');
Smilies::add($b, ':)', '😀');
diff --git a/viewsrc/viewsrc.php b/viewsrc/viewsrc.php
index 10f883593..cbdf54617 100644
--- a/viewsrc/viewsrc.php
+++ b/viewsrc/viewsrc.php
@@ -16,13 +16,6 @@ function viewsrc_install() {
Hook::register('page_end', 'addon/viewsrc/viewsrc.php', 'viewsrc_page_end');
}
-
-function viewsrc_uninstall() {
- Hook::unregister('item_photo_menu', 'addon/viewsrc/viewsrc.php', 'viewsrc_item_photo_menu');
- Hook::unregister('page_end', 'addon/viewsrc/viewsrc.php', 'viewsrc_page_end');
-
-}
-
function viewsrc_page_end(&$a, &$o){
DI::page()['htmlhead'] .= <<< EOS