****************************************************************************
****************************************************************************
-8. Set up a cron job or scheduled task to run the poller once every 5-10
+8. Set up a cron job or scheduled task to run the worker once every 5-10
minutes to pick up the recent "public" postings of your friends. Example:
- cd /base/directory; /path/to/php include/poller.php
+ cd /base/directory; /path/to/php scripts/worker.php
Change "/base/directory", and "/path/to/php" as appropriate for your situation.
If you are using a Linux server, run "crontab -e" and add a line like the
one shown, substituting for your unique paths and settings:
-*/10 * * * * cd /home/myname/mywebsite; /usr/bin/php include/poller.php
+*/10 * * * * cd /home/myname/mywebsite; /usr/bin/php scripts/worker.php
You can generally find the location of PHP by executing "which php". If you
have troubles with this section please contact your hosting provider for
*/10 * * * * cd /var/www/friendica/friendica/ && sudo -u www-data /usr/bin/php
-d suhosin.executor.func.blacklist=none -d suhosin.executor.eval.blacklist=none
--f include/poller.php
+-f scripts/worker.php
This worked well for simple test cases, but the friendica-cron still failed with
a fatal error:
suhosin[22962]: ALERT - function within blacklist called: proc_open() (attacker
'REMOTE_ADDR not set', file '/var/www/friendica/friendica/boot.php', line 1341)
-After a while I noticed, that include/poller.php calls further php script via
+After a while I noticed, that scripts/worker.php calls further php script via
proc_open. These scripts themselves also use proc_open and fail, because they
are NOT called with -d suhosin.executor.func.blacklist=none.
use Friendica\Core\PConfig;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
use Friendica\Util\Lock;
require_once 'include/network.php';
require_once 'include/identity.php';
require_once 'update.php';
require_once 'include/dbstructure.php';
-require_once 'include/poller.php';
define('FRIENDICA_PLATFORM', 'Friendica');
define('FRIENDICA_CODENAME', 'Asparagus');
/**
* @brief Function to check if request was an AJAX (xmlhttprequest) request.
*
- * @param boolean $via_worker boolean Is the check run via the poller?
+ * @param boolean $via_worker boolean Is the check run via the worker?
*/
function check_db($via_worker)
{
}
if ($build != DB_UPDATE_VERSION) {
// When we cannot execute the database update via the worker, we will do it directly
- if (!Worker::add(PRIORITY_CRITICAL, 'dbupdate') && $via_worker) {
+ if (!Worker::add(PRIORITY_CRITICAL, 'DBUpdate') && $via_worker) {
update_db(get_app());
}
}
if (!$public_contact_id && x($_SESSION, 'authenticated')) {
if (x($_SESSION, 'my_address')) {
// Local user
- $public_contact_id = intval(get_contact($_SESSION['my_address'], 0));
+ $public_contact_id = intval(Contact::getIdForURL($_SESSION['my_address'], 0));
} elseif (x($_SESSION, 'visitor_home')) {
// Remote user
- $public_contact_id = intval(get_contact($_SESSION['visitor_home'], 0));
+ $public_contact_id = intval(Contact::getIdForURL($_SESSION['visitor_home'], 0));
}
} elseif (!x($_SESSION, 'authenticated')) {
$public_contact_id = false;
return ((x($a->config, 'max_import_size')) ? $a->config['max_import_size'] : 0 );
}
-/**
- * @brief compatibilty wrapper for Worker::add function
- *
- * @param (integer|array) priority or parameter array, strings are deprecated and are ignored
- *
- * @return boolean "false" if proc_run couldn't be executed
- */
-function proc_run()
-{
- $proc_args = func_get_args();
- call_user_func_array('Friendica\Core\Worker::add', $proc_args);
-}
function current_theme()
{
return "";
}
-/// @deprecated
-function set_template_engine(App $a, $engine = 'internal')
-{
- /// @note This function is no longer necessary, but keep it as a wrapper to the class method
- /// to avoid breaking themes again unnecessarily
- /// @TODO maybe output a warning here so the theme developer can see it? PHP won't show such warnings like Java does.
-
- $a->set_template_engine($engine);
-}
if (!function_exists('exif_imagetype')) {
function exif_imagetype($file)
"league/html-to-markdown": "~4.4.1",\r
"defuse/php-encryption": "1.*",\r
"pear/Text_LanguageDetect": "1.*",\r
- "pear-pear.php.net/Text_Highlighter": "*"\r
+ "pear-pear.php.net/Text_Highlighter": "*",\r
+ "paragonie/random_compat": "^2.0"\r
},\r
"repositories": [\r
{\r
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
- "content-hash": "a6a3dae4b15752d8f377b1fc1e5a2b47",
+ "content-hash": "a5c0c297b0e8185f2bcd3aad20ec5acc",
"packages": [
{
"name": "defuse/php-encryption",
],
"time": "2017-08-29T18:23:54+00:00"
},
+ {
+ "name": "paragonie/random_compat",
+ "version": "v2.0.11",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/paragonie/random_compat.git",
+ "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8",
+ "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.2.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "4.*|5.*"
+ },
+ "suggest": {
+ "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes."
+ },
+ "type": "library",
+ "autoload": {
+ "files": [
+ "lib/random.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Paragon Initiative Enterprises",
+ "email": "security@paragonie.com",
+ "homepage": "https://paragonie.com"
+ }
+ ],
+ "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7",
+ "keywords": [
+ "csprng",
+ "pseudorandom",
+ "random"
+ ],
+ "time": "2017-09-27T21:40:39+00:00"
+ },
{
"name": "pear-pear.php.net/Archive_Tar",
"version": "1.4.3",
* Look at the first steps that were made (e.g. the clean theme).
Ask us to find out whom to talk to about their experiences.
* Talk to design people if you know any.
-* Let us know about your plans [in the dev forum](https://forum.friendi.ca/profile/developers) and the [theme developer forum](https://friendica.eu/profile/ftdevs).
+* Let us know about your plans [in the dev forum](https://forum.friendi.ca/profile/developers) or the [theme developer forum](https://friendica.eu/profile/ftdevs).
Do not worry about cross-posting.
###Client software
Here is a list of known working clients:
* Android
- * [Friendiqa](https://github.com/lubuwest/friendiqa) (you can find the APK file in the listed files in the repository)
+ * [Friendiqa](https://github.com/lubuwest/friendiqa) (available in Google Playstore or from a binary repository you can add to [F-Droid](https://freunde.ma-nic.de/display/3e98eba8185a13c5bdbf3d1539646854))
* AndStatus
* Twidere
* Mustard and Mustard-Mod
If you get any *critical* failure at this point, it generally indicates the database was not installed correctly.
You might wish to move/rename .htconfig.php to another name and empty (called 'dropping') the database tables, so that you can start fresh.
-###Set up the poller
+###Set up the worker
-Set up a cron job or scheduled task to run the poller once every 5-10 minutes in order to perform background processing.
+Set up a cron job or scheduled task to run the worker once every 5-10 minutes in order to perform background processing.
Example:
- cd /base/directory; /path/to/php include/poller.php
+ cd /base/directory; /path/to/php scripts/worker.php
Change "/base/directory", and "/path/to/php" as appropriate for your situation.
If you are using a Linux server, run "crontab -e" and add a line like the
one shown, substituting for your unique paths and settings:
- */10 * * * * cd /home/myname/mywebsite; /usr/bin/php include/poller.php
+ */10 * * * * cd /home/myname/mywebsite; /usr/bin/php scripts/worker.php
You can generally find the location of PHP by executing "which php".
If you run into trouble with this section please contact your hosting provider for assistance.
Push (pubsubhubbub) feeds arrive via mod/pubsub.php
-DFRN-poll feed imports arrive via include/poller.php as a scheduled task, this implements the local side of the DFRN-poll protocol.
+DFRN-poll feed imports arrive via src/Worker/OnePoll.php as a scheduled task, this implements the local side of the DFRN-poll protocol.
### Scenario #1. Bob posts a public status message
When a PuSH hub is operational, dfrn-poll clients prefer to receive their information through the PuSH channel.
They will fall back on a daily poll in case the hub has delivery issues (this is quite common when using the default Google reference hub).
If there is no specified hub or hubs, DFRN clients will poll at a configurable (per-contact) rate at up to 5-minute intervals.
-Feeds retrieved via dfrn-poll are bbcode and may also contain private conversations which the poller has permissions to see.
+Feeds retrieved via dfrn-poll are bbcode and may also contain private conversations which the worker has permissions to see.
### Scenario #2. Jack replies to Bob's public message. Jack is on the Friendica/DFRN network.
This is the simplest way to enforce site-wide secure access.
Every time a user tries to access any Friendica page by any mean (manual address bar entry or link), the web server issues a Permanent Redirect response with the secure protocol prepended to the requested URL.
-With Apache, simply add the following lines to the [code].htaccess[/code] file in the root folder of your Friendica instance (thanks to [url=https://github.com/AlfredSK]AlfredSK[/url]):
+With Apache, enable the modules rewrite and ssl (with a shared hosting provider, this should be enabled already):
-[code]
-#Force SSL connections
+ sudo a2enmod rewrite ssl
-RewriteEngine On
-RewriteCond %{SERVER_PORT} 80
-RewriteRule ^(.*)$ https://your.friendica.domain/$1 [R=301,L]
-[/code]
+Add the following lines to the .htaccess file in the root folder of your Friendica instance (thanks to [url=https://github.com/AlfredSK]AlfredSK[/url]):
-With nginx, configure your [code]server[/code] directive this way (thanks to [url=https://bjornjohansen.no/redirect-to-https-with-nginx/]Bjørn Johansen[/url]):
+ RewriteEngine On
+ RewriteCond %{SERVER_PORT} 80
+ RewriteRule ^(.*)$ https://your.friendica.domain/$1 [R=301,L]
-[code]
-server {
- listen 80;
- listen [::]:80;
- server_name your.friendica.domain;
- return 301 https://$server_name$request_uri;
-}
-[/code]
+With nginx, configure your server directive this way ([documentation](https://www.nginx.com/blog/creating-nginx-rewrite-rules/)):
+
+ server {
+ listen 80;
+ server_name your.friendica.domain;
+ return 301 https://$server_name$request_uri;
+ }
### SSL Settings
In the Admin Settings, there are three SSL-related settings:
-- **SSL link policy**: this affects how Friendica generates internal links. If your SSL installation was successful, we recommend "Force all links to SSL" just in case your web server configuration can't be altered like described above.
-- **Force SSL**: This forces all external links to HTTPS, which may solve Mixed-Content issues, but not all websites support HTTPS yet. Use at your own risk.
-- **Verify SSL**: Enabling this will prevent Friendica to interact with self-signed SSL sites. We recommend you leave it on as a self-signed SSL certificate can be a vectorfor a man-in-the-middle attack.
\ No newline at end of file
+
+1. **SSL link policy**: this affects how Friendica generates internal links. If your SSL installation was successful, we recommend "Force all links to SSL" just in case your web server configuration can't be altered like described above.
+2. **Force SSL**: This forces all external links to HTTPS, which may solve Mixed-Content issues, but not all websites support HTTPS yet. Use at your own risk.
+3. **Verify SSL**: Enabling this will prevent Friendica to interact with self-signed SSL sites. We recommend you leave it on as a self-signed SSL certificate can be a vectorfor a man-in-the-middle attack.
Hier ist eine Liste von Clients bei denen dies möglich ist, bzw. die speziell für Friendica entwickelt werden:
* Android
- * [Friendiqa](https://github.com/lubuwest/friendiqa) (ydie APK Datei findest du in den gelisteten Dateien im Repository)
+ * [Friendiqa](https://github.com/lubuwest/friendiqa) (Gibt es im Google Playstore oder als [binary Repository](https://freunde.ma-nic.de/display/3e98eba8185a13c5bdbf3d1539646854) für F-Droid)
* AndStatus
* Twidere
* Mustard and Mustard-Mod
* [Beiträge kommentieren, einordnen und löschen](help/Text_comment)
* [Profile](help/Profiles)
* [Referenz der Accesskeys](help/Accesskeys)
- * [Veranstaltungen](help/events) (EN)
+ * [Veranstaltungen](help/events)
* Du und andere Nutzer
* [Konnektoren (Connectors)](help/Connectors)
* [Freunde finden](help/Making-Friends)
7. Erstelle einen Cron job oder einen regelmäßigen Task, um den Poller alle 5-10 Minuten im Hintergrund ablaufen zu lassen. Beispiel:
- `cd /base/directory; /path/to/php include/poller.php`
+ `cd /base/directory; /path/to/php scripts/worker.php`
Ändere "/base/directory" und "/path/to/php" auf deine Systemvorgaben.
Wenn du einen Linux-Server nutzt, benutze den Befehl "crontab -e" und ergänze eine Zeile wie die Folgende; angepasst an dein System
-`*/10 * * * * cd /home/myname/mywebsite; /usr/bin/php include/poller.php`
+`*/10 * * * * cd /home/myname/mywebsite; /usr/bin/php scripts/worker.php`
Du kannst den PHP-Pfad finden, indem du den Befehl „which php“ ausführst.
Wenn du Schwierigkeiten mit diesem Schritt hast, kannst du deinen Hosting-Anbieter kontaktieren.
PuSh-Feeds (pubsubhubbub) kommen via mod/pubsub.php an.
-DFRN-poll Feed-Imports kommen via include/poller.php als geplanter Task an, das implementiert die lokale Bearbeitung (local side) des DFRN-Protokolls.
+DFRN-poll Feed-Imports kommen via src/Worker/OnePoll.php als geplanter Task an, das implementiert die lokale Bearbeitung (local side) des DFRN-Protokolls.
### Szenario #1. Bob schreibt eine öffentliche Statusnachricht
--- /dev/null
+# Veranstaltungen
+
+* [Zur Startseite der Hilfe](help)
+
+Veranstaltungen sind spezielle Postings.
+Die Veranstaltungen, die Du und deine Kontakte teilen, können unter [/events](/events) auf deiner Instanz aufgefunden werden.
+Um da hinzukommen gehe über den Tab "Veranstalltungen", abhänig von dem Theme, das du benutzt, ist der eventuell ein zusätzlicher link im Navigationsmenü der Seite vorhanden.
+
+
+## Veranstaltungsübersicht
+
+Die Übersichtsseite zeigt den Kalender des aktuellen Monats an, plus einige Tage am Beginn und am Ende.
+Angezeit werden alle Veranstalltungen des aktuellen Monats, die von dir angelegt wurden oder die von deinen Kontakten geteilt wurden.
+Dies beinhaltet auch Geburstagserinnerungen, welche mit dir geteilt wurden.
+
+Es gibt Buttons mit denen die Ansicht zwischen Monatlich/Wöchentlich und Täglich wechseln kann.
+Um eine neue Veranstaltung anzulegen, kannst du dem Link "Veranstaltung erstellen" folgen oder einen Doppel-Klick in das Kalenderfeld, in dem die Veranstalltung stehen soll, machen.
+Mit einem Klick auf eine bereits existierende Veranstalltung, öffnet sich ein Pop-up Fenster, welches dir die Veranstaltung anzeigt.
+
+## Erstelle eine neue Veranstaltung
+
+Folge einer der oben beschriebenen Methoden, dann erreichst du das Formular um die Veranstaltungsdaten einzutragen. Felder mit *** müsen ausgefüllt werden.
+
+* **Veranstaltungsbeginn**: trage den Anfang der Veranstaltung ein.
+* **Veranstaltungsende**: trage das Ende der Veranstaltung ein.
+
+Wenn du in eines dieser Felder klickst, wird sich ein Popup Fesnster öffnen, wo du Tag und Uhrzeit eintragen kannst.
+Wenn du einen Doppel-Klick auf die Box im Kalender machst, werden diese Felder automatisch ausgefüllt.
+Das Veranstaltungsende muss nach dem Veranstaltungsanfang liegen.
+Aber du musst es nicht angeben. Wenn eine Veranstaltung ein offenes Ende hat oder das Veranstaltungsende nicht wichtig ist, klicke in die Box zwei Felder darunter.
+
+* **An Zeitzone des Betrachters anpassen**: Wenn du die Box anklickst, wird die Anfangs und Endzeit der Veranstaltung automatisch an die lokale Zeitzone, wie in den Zeitzonen-Einstellung angepasst.
+
+Dies vermeidet verfrühte Geburstagsglückwünsche, oder die Beführchtung, das du den Geburstag deines Freundes auf der anderen Seite der Welt vergisst und ähnliche Ereignisse.
+
+* **Titel**: Titel der Veranstaltung
+* **Beschreibung**: eine längere Beschreibung der Veranstaltung
+* **Ort**: Ort, wo die Veranstaltung stattfinden wird
+
+Diese 3 Felder beschreiben deine Veranstaltung.
+Im Beschreibungs- und Orts-Feld kannst du BBCode zum formatieren des Textes verwenden.
+
+* **Veranstaltung teilen**: wenn diese Box aktiviert wird, kannst du in der ACL auswählen mit wem du diese Veranstaltung teilen willst. Dies funktioniert wie die Kontrolle jedes anderen Postings.
+
+Wenn du Veranstaltungen teilst, werden diese auf deine Pinnwand gepostet mit den Zugriffsberechtigungen, die du ausgewählt hast. Bevor du das machst, kannst du dir die Veranstaltung als Vorschau in einem Popup-Fenster anzeigen lassen.
+
+### Interaktionen mit Veranstaltungen
+
+Wenn du eine Veranstaltung veröffendlichst, kannst du auswählen, wer sie bekommen wird, wie bei einem normalen Posting.
+Die Empfänger sehen deine Veranstaltung in einem Posting in ihrem Network-Stream.
+Zusätzlich wird die Veranstaltung zu ihrem Kalender hinzugefügt und somit in ihrer Veranstaltungsübersicht angezeigt.
+
+Empfänger von einem Veranstaltungs-Posting, können dies kommentieren oder dis-/liken, wie bei einem normalen Posting.
+Zusätzlich können sie sagen ob sie teilnehmen, oder vielleicht teilnehmen an der Veranstaltung mit einem einzigen Klick.
+
+### Kalender exportieren
+
+Wenn du deine öffentlichen Kalender Einträge exportieren möchtest, kannst du dies in den Einstellungen aktivieren (Einstellungen -> Zusätzliche Features -> Allgemeine Features -> Öffentlichen Kalender exportieren).
+Im Anschluss sind auf der Veranstaltungs-Übersichtsseite zwei Links zu den exportierten Einträgen (im ical oder csv Format) verfügbar.
+
Recipients of the event-posting can comment or dis-/like the event, as with a regular posting.
Furthermore they can announce that they will attend, not attend or may-be attend the event with a single click.
-### Addons
+### Calendar Export
-#### OpenStreetMap
+If you want to export your public events to ical or csv, you can activate an additional feature in your user settings (Additional features -> General Features -> Export Public Calendar).
+Afterwards a link will be shown in the events page of your profile to access the calendar.
-If this addon is activated on your friendica node, the content of the location field will be matched with the identification service of OSM when you submit the event.
-Should OSM find anything matching, a map for the location will be embedded automatically at the end of the events view.
-
-#### Calendar Export
-
-If this addon is activated the public events you have created will be published in ical or csv file.
-The URL of the published file is ``example.com/cal/nickname/export/format`` (where format is either ical of csv).
## system ##
* **allowed_link_protocols** (Array) - Allowed protocols in links URLs, add at your own risk. http is always allowed.
+* **always_show_preview** (Boolean) - Only show small preview picures. Default value is false.
* **birthday_input_format** - Default value is "ymd".
* **block_local_dir** (Boolean) - Blocks the access to the directory of the local users.
* **auth_cookie_lifetime** (Integer) - Number of days that should pass without any activity before a user who chose "Remember me" when logging in is considered logged out. Defaults to 7.
* **local_block** (Boolean) - Used in conjunction with "block_public".
* **local_search** (Boolean) - Blocks search for users who are not logged in to prevent crawlers from blocking your system.
* **local_tags** (Boolean) - If activated, all hashtags will point to the local server.
-* **max_connections** - The maximum number of database connections which can be in use before the poller process is deferred to it's next interval. When the system can't detect the maximum numbers of connection then this value can be used.
-* **max_connections_level** - The maximum level of connections that are allowed to let the poller start. It is a percentage value. Default value is 75.
+* **max_connections** - The maximum number of database connections which can be in use before the worker process is deferred to it's next interval. When the system can't detect the maximum numbers of connection then this value can be used.
+* **max_connections_level** - The maximum level of connections that are allowed to let the worker start. It is a percentage value. Default value is 75.
* **max_contact_queue** - Default value is 500.
* **max_batch_queue** - Default value is 1000.
* **max_processes_backend** - Maximum number of concurrent database processes for background tasks. Default value is 5.
$a-> theme_info = array(
'extends' => 'duepuntozero'.
);
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
/* and more stuff e.g. the JavaScript function for the header */
}
function quattro_init(App $a) {
$a->theme_info = array();
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
}
Here we have set the basic theme information, in this case they are empty.
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\PConfig;
-use Friendica\Core\System;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-use Friendica\Protocol\Diaspora;
-use Friendica\Protocol\DFRN;
-
-// Included here for completeness, but this is a very dangerous operation.
-// It is the caller's responsibility to confirm the requestor's intent and
-// authorisation to do this.
-
-function user_remove($uid) {
- if (!$uid) {
- return;
- }
-
- logger('Removing user: ' . $uid);
-
- $r = dba::select('user', array(), array('uid' => $uid), array("limit" => 1));
-
- call_hooks('remove_user',$r);
-
- // save username (actually the nickname as it is guaranteed
- // unique), so it cannot be re-registered in the future.
-
- dba::insert('userd', array('username' => $r['nickname']));
-
- // The user and related data will be deleted in "cron_expire_and_remove_users" (cronjobs.php)
- q("UPDATE `user` SET `account_removed` = 1, `account_expires_on` = UTC_TIMESTAMP() WHERE `uid` = %d", intval($uid));
- Worker::add(PRIORITY_HIGH, "notifier", "removeme", $uid);
-
- // Send an update to the directory
- Worker::add(PRIORITY_LOW, "directory", $r['url']);
-
- if($uid == local_user()) {
- unset($_SESSION['authenticated']);
- unset($_SESSION['uid']);
- goaway(System::baseUrl());
- }
-}
-
-
-function contact_remove($id) {
-
- // We want just to make sure that we don't delete our "self" contact
- $r = q("SELECT `uid` FROM `contact` WHERE `id` = %d AND NOT `self` LIMIT 1",
- intval($id)
- );
- if (!DBM::is_result($r) || !intval($r[0]['uid'])) {
- return;
- }
-
- $archive = PConfig::get($r[0]['uid'], 'system','archive_removed_contacts');
- if ($archive) {
- q("update contact set `archive` = 1, `network` = 'none', `writable` = 0 where id = %d",
- intval($id)
- );
- return;
- }
-
- dba::delete('contact', array('id' => $id));
-
- // Delete the rest in the background
- Worker::add(PRIORITY_LOW, 'remove_contact', $id);
-}
-
-
-// sends an unfriend message. Does not remove the contact
-
-function terminate_friendship($user,$self,$contact) {
-
- /// @TODO Get rid of this, include/datetime.php should care about it by itself
- $a = get_app();
-
- require_once 'include/datetime.php';
-
- if ($contact['network'] === NETWORK_OSTATUS) {
-
- require_once 'include/ostatus.php';
-
- // create an unfollow slap
- $item = array();
- $item['verb'] = NAMESPACE_OSTATUS."/unfollow";
- $item['follow'] = $contact["url"];
- $slap = ostatus::salmon($item, $user);
-
- if ((x($contact,'notify')) && (strlen($contact['notify']))) {
- require_once 'include/salmon.php';
- slapper($user,$contact['notify'],$slap);
- }
- } elseif ($contact['network'] === NETWORK_DIASPORA) {
- Diaspora::send_unshare($user,$contact);
- } elseif ($contact['network'] === NETWORK_DFRN) {
- DFRN::deliver($user,$contact,'placeholder', 1);
- }
-
-}
-
-
-// Contact has refused to recognise us as a friend. We will start a countdown.
-// If they still don't recognise us in 32 days, the relationship is over,
-// and we won't waste any more time trying to communicate with them.
-// This provides for the possibility that their database is temporarily messed
-// up or some other transient event and that there's a possibility we could recover from it.
-
-function mark_for_death($contact) {
-
- if($contact['archive'])
- return;
-
- if ($contact['term-date'] <= NULL_DATE) {
- q("UPDATE `contact` SET `term-date` = '%s' WHERE `id` = %d",
- dbesc(datetime_convert()),
- intval($contact['id'])
- );
-
- if ($contact['url'] != '') {
- q("UPDATE `contact` SET `term-date` = '%s'
- WHERE `nurl` = '%s' AND `term-date` <= '1000-00-00'",
- dbesc(datetime_convert()),
- dbesc(normalise_link($contact['url']))
- );
- }
- } else {
-
- /// @todo
- /// We really should send a notification to the owner after 2-3 weeks
- /// so they won't be surprised when the contact vanishes and can take
- /// remedial action if this was a serious mistake or glitch
-
- /// @todo
- /// Check for contact vitality via probing
-
- $expiry = $contact['term-date'] . ' + 32 days ';
- if(datetime_convert() > datetime_convert('UTC','UTC',$expiry)) {
-
- // relationship is really truly dead.
- // archive them rather than delete
- // though if the owner tries to unarchive them we'll start the whole process over again
-
- q("UPDATE `contact` SET `archive` = 1 WHERE `id` = %d",
- intval($contact['id'])
- );
-
- if ($contact['url'] != '') {
- q("UPDATE `contact` SET `archive` = 1 WHERE `nurl` = '%s'",
- dbesc(normalise_link($contact['url']))
- );
- }
- }
- }
-
-}
-
-function unmark_for_death($contact) {
-
- $r = q("SELECT `term-date` FROM `contact` WHERE `id` = %d AND (`term-date` > '%s' OR `archive`)",
- intval($contact['id']),
- dbesc('1000-00-00 00:00:00')
- );
-
- // We don't need to update, we never marked this contact as dead
- if (!DBM::is_result($r)) {
- return;
- }
-
- // It's a miracle. Our dead contact has inexplicably come back to life.
- $fields = array('term-date' => NULL_DATE, 'archive' => false);
- dba::update('contact', $fields, array('id' => $contact['id']));
-
- if ($contact['url'] != '') {
- dba::update('contact', $fields, array('nurl' => normalise_link($contact['url'])));
- }
-}
-
-/**
- * @brief Get contact data for a given profile link
- *
- * The function looks at several places (contact table and gcontact table) for the contact
- * It caches its result for the same script execution to prevent duplicate calls
- *
- * @param string $url The profile link
- * @param int $uid User id
- * @param array $default If not data was found take this data as default value
- *
- * @return array Contact data
- */
-function get_contact_details_by_url($url, $uid = -1, $default = array()) {
- static $cache = array();
-
- if ($url == '') {
- return $default;
- }
-
- if ($uid == -1) {
- $uid = local_user();
- }
-
- if (isset($cache[$url][$uid])) {
- return $cache[$url][$uid];
- }
-
- $ssl_url = str_replace('http://', 'https://', $url);
-
- // Fetch contact data from the contact table for the given user
- $s = dba::p("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
- FROM `contact` WHERE `nurl` = ? AND `uid` = ?",
- normalise_link($url), $uid);
- $r = dba::inArray($s);
-
- // Fetch contact data from the contact table for the given user, checking with the alias
- if (!DBM::is_result($r)) {
- $s = dba::p("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
- FROM `contact` WHERE `alias` IN (?, ?, ?) AND `uid` = ?",
- normalise_link($url), $url, $ssl_url, $uid);
- $r = dba::inArray($s);
- }
-
- // Fetch the data from the contact table with "uid=0" (which is filled automatically)
- if (!DBM::is_result($r)) {
- $s = dba::p("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
- FROM `contact` WHERE `nurl` = ? AND `uid` = 0",
- normalise_link($url));
- $r = dba::inArray($s);
- }
-
- // Fetch the data from the contact table with "uid=0" (which is filled automatically) - checked with the alias
- if (!DBM::is_result($r)) {
- $s = dba::p("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
- FROM `contact` WHERE `alias` IN (?, ?, ?) AND `uid` = 0",
- normalise_link($url), $url, $ssl_url);
- $r = dba::inArray($s);
- }
-
- // Fetch the data from the gcontact table
- if (!DBM::is_result($r)) {
- $s = dba::p("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, '' AS `xmpp`,
- `keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `contact-type`, `birthday`, 0 AS `self`
- FROM `gcontact` WHERE `nurl` = ?",
- normalise_link($url));
- $r = dba::inArray($s);
- }
-
- if (DBM::is_result($r)) {
- // If there is more than one entry we filter out the connector networks
- if (count($r) > 1) {
- foreach ($r AS $id => $result) {
- if ($result["network"] == NETWORK_STATUSNET) {
- unset($r[$id]);
- }
- }
- }
-
- $profile = array_shift($r);
-
- // "bd" always contains the upcoming birthday of a contact.
- // "birthday" might contain the birthday including the year of birth.
- if ($profile["birthday"] > '0001-01-01') {
- $bd_timestamp = strtotime($profile["birthday"]);
- $month = date("m", $bd_timestamp);
- $day = date("d", $bd_timestamp);
-
- $current_timestamp = time();
- $current_year = date("Y", $current_timestamp);
- $current_month = date("m", $current_timestamp);
- $current_day = date("d", $current_timestamp);
-
- $profile["bd"] = $current_year."-".$month."-".$day;
- $current = $current_year."-".$current_month."-".$current_day;
-
- if ($profile["bd"] < $current) {
- $profile["bd"] = (++$current_year)."-".$month."-".$day;
- }
- } else {
- $profile["bd"] = '0001-01-01';
- }
- } else {
- $profile = $default;
- }
-
- if (($profile["photo"] == "") && isset($default["photo"])) {
- $profile["photo"] = $default["photo"];
- }
-
- if (($profile["name"] == "") && isset($default["name"])) {
- $profile["name"] = $default["name"];
- }
-
- if (($profile["network"] == "") && isset($default["network"])) {
- $profile["network"] = $default["network"];
- }
-
- if (($profile["thumb"] == "") && isset($profile["photo"])) {
- $profile["thumb"] = $profile["photo"];
- }
-
- if (($profile["micro"] == "") && isset($profile["thumb"])) {
- $profile["micro"] = $profile["thumb"];
- }
-
- if ((($profile["addr"] == "") || ($profile["name"] == "")) && ($profile["gid"] != 0) &&
- in_array($profile["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
- Worker::add(PRIORITY_LOW, "update_gcontact", $profile["gid"]);
- }
-
- // Show contact details of Diaspora contacts only if connected
- if (($profile["cid"] == 0) && ($profile["network"] == NETWORK_DIASPORA)) {
- $profile["location"] = "";
- $profile["about"] = "";
- $profile["gender"] = "";
- $profile["birthday"] = '0001-01-01';
- }
-
- $cache[$url][$uid] = $profile;
-
- return $profile;
-}
-
-/**
- * @brief Get contact data for a given address
- *
- * The function looks at several places (contact table and gcontact table) for the contact
- *
- * @param string $addr The profile link
- * @param int $uid User id
- *
- * @return array Contact data
- */
-function get_contact_details_by_addr($addr, $uid = -1) {
- static $cache = array();
-
- if ($addr == '') {
- return array();
- }
-
- if ($uid == -1) {
- $uid = local_user();
- }
-
- // Fetch contact data from the contact table for the given user
- $r = q("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
- FROM `contact` WHERE `addr` = '%s' AND `uid` = %d",
- dbesc($addr), intval($uid));
-
- // Fetch the data from the contact table with "uid=0" (which is filled automatically)
- if (!DBM::is_result($r))
- $r = q("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
- `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
- FROM `contact` WHERE `addr` = '%s' AND `uid` = 0",
- dbesc($addr));
-
- // Fetch the data from the gcontact table
- if (!DBM::is_result($r))
- $r = q("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, '' AS `xmpp`,
- `keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `contact-type`, `birthday`, 0 AS `self`
- FROM `gcontact` WHERE `addr` = '%s'",
- dbesc($addr));
-
- if (!DBM::is_result($r)) {
- $data = Probe::uri($addr);
-
- $profile = get_contact_details_by_url($data['url'], $uid);
- } else {
- $profile = $r[0];
- }
-
- return $profile;
-}
-
-if (! function_exists('contact_photo_menu')) {
-function contact_photo_menu($contact, $uid = 0)
-{
- $a = get_app();
-
- $contact_url = '';
- $pm_url = '';
- $status_link = '';
- $photos_link = '';
- $posts_link = '';
- $contact_drop_link = '';
- $poke_link = '';
-
- if ($uid == 0) {
- $uid = local_user();
- }
-
- if ($contact['uid'] != $uid) {
- if ($uid == 0) {
- $profile_link = zrl($contact['url']);
- $menu = Array('profile' => array(t('View Profile'), $profile_link, true));
-
- return $menu;
- }
-
- $r = q("SELECT * FROM `contact` WHERE `nurl` = '%s' AND `network` = '%s' AND `uid` = %d",
- dbesc($contact['nurl']), dbesc($contact['network']), intval($uid));
- if ($r) {
- return contact_photo_menu($r[0], $uid);
- } else {
- $profile_link = zrl($contact['url']);
- $connlnk = 'follow/?url='.$contact['url'];
- $menu = array(
- 'profile' => array(t('View Profile'), $profile_link, true),
- 'follow' => array(t('Connect/Follow'), $connlnk, true)
- );
-
- return $menu;
- }
- }
-
- $sparkle = false;
- if ($contact['network'] === NETWORK_DFRN) {
- $sparkle = true;
- $profile_link = System::baseUrl() . '/redir/' . $contact['id'];
- } else {
- $profile_link = $contact['url'];
- }
-
- if ($profile_link === 'mailbox') {
- $profile_link = '';
- }
-
- if ($sparkle) {
- $status_link = $profile_link . '?url=status';
- $photos_link = $profile_link . '?url=photos';
- $profile_link = $profile_link . '?url=profile';
- }
-
- if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_DIASPORA))) {
- $pm_url = System::baseUrl() . '/message/new/' . $contact['id'];
- }
-
- if ($contact['network'] == NETWORK_DFRN) {
- $poke_link = System::baseUrl() . '/poke/?f=&c=' . $contact['id'];
- }
-
- $contact_url = System::baseUrl() . '/contacts/' . $contact['id'];
-
- $posts_link = System::baseUrl() . '/contacts/' . $contact['id'] . '/posts';
- $contact_drop_link = System::baseUrl() . '/contacts/' . $contact['id'] . '/drop?confirm=1';
-
- /**
- * menu array:
- * "name" => [ "Label", "link", (bool)Should the link opened in a new tab? ]
- */
- $menu = array(
- 'status' => array(t("View Status"), $status_link, true),
- 'profile' => array(t("View Profile"), $profile_link, true),
- 'photos' => array(t("View Photos"), $photos_link, true),
- 'network' => array(t("Network Posts"), $posts_link, false),
- 'edit' => array(t("View Contact"), $contact_url, false),
- 'drop' => array(t("Drop Contact"), $contact_drop_link, false),
- 'pm' => array(t("Send PM"), $pm_url, false),
- 'poke' => array(t("Poke"), $poke_link, false),
- );
-
-
- $args = array('contact' => $contact, 'menu' => &$menu);
-
- call_hooks('contact_photo_menu', $args);
-
- $menucondensed = array();
-
- foreach ($menu AS $menuname => $menuitem) {
- if ($menuitem[1] != '') {
- $menucondensed[$menuname] = $menuitem;
- }
- }
-
- return $menucondensed;
-}}
-
-
-function random_profile() {
- $r = q("SELECT `url` FROM `gcontact` WHERE `network` = '%s'
- AND `last_contact` >= `last_failure`
- AND `updated` > UTC_TIMESTAMP - INTERVAL 1 MONTH
- ORDER BY rand() LIMIT 1",
- dbesc(NETWORK_DFRN));
-
- if (DBM::is_result($r))
- return dirname($r[0]['url']);
- return '';
-}
-
-
-function contacts_not_grouped($uid,$start = 0,$count = 0) {
-
- if(! $count) {
- $r = q("select count(*) as total from contact where uid = %d and self = 0 and id not in (select distinct(`contact-id`) from group_member where uid = %d) ",
- intval($uid),
- intval($uid)
- );
-
- return $r;
-
-
- }
-
- $r = q("select * from contact where uid = %d and self = 0 and id not in (select distinct(`contact-id`) from group_member where uid = %d) and blocked = 0 and pending = 0 limit %d, %d",
- intval($uid),
- intval($uid),
- intval($start),
- intval($count)
- );
-
- return $r;
-}
-
-/**
- * @brief Fetch the contact id for a given url and user
- *
- * First lookup in the contact table to find a record matching either `url`, `nurl`,
- * `addr` or `alias`.
- *
- * If there's no record and we aren't looking for a public contact, we quit.
- * If there's one, we check that it isn't time to update the picture else we
- * directly return the found contact id.
- *
- * Second, we probe the provided $url wether it's http://server.tld/profile or
- * nick@server.tld. We quit if we can't get any info back.
- *
- * Third, we create the contact record if it doesn't exist
- *
- * Fourth, we update the existing record with the new data (avatar, alias, nick)
- * if there's any updates
- *
- * @param string $url Contact URL
- * @param integer $uid The user id for the contact (0 = public contact)
- * @param boolean $no_update Don't update the contact
- *
- * @return integer Contact ID
- */
-function get_contact($url, $uid = 0, $no_update = false) {
- logger("Get contact data for url ".$url." and user ".$uid." - ".System::callstack(), LOGGER_DEBUG);
-
- $data = array();
- $contact_id = 0;
-
- if ($url == '') {
- return 0;
- }
-
- // We first try the nurl (http://server.tld/nick), most common case
- $contact = dba::select('contact', array('id', 'avatar-date'), array('nurl' => normalise_link($url), 'uid' => $uid), array('limit' => 1));
-
- // Then the addr (nick@server.tld)
- if (!DBM::is_result($contact)) {
- $contact = dba::select('contact', array('id', 'avatar-date'), array('addr' => $url, 'uid' => $uid), array('limit' => 1));
- }
-
- // Then the alias (which could be anything)
- if (!DBM::is_result($contact)) {
- // The link could be provided as http although we stored it as https
- $ssl_url = str_replace('http://', 'https://', $url);
- $r = dba::p("SELECT `id`, `avatar-date` FROM `contact` WHERE `alias` IN (?, ?, ?) AND `uid` = ? LIMIT 1",
- $url, normalise_link($url), $ssl_url, $uid);
- $contact = dba::fetch($r);
- dba::close($r);
- }
-
- if (DBM::is_result($contact)) {
- $contact_id = $contact["id"];
-
- // Update the contact every 7 days
- $update_contact = ($contact['avatar-date'] < datetime_convert('','','now -7 days'));
-
- // We force the update if the avatar is empty
- if ($contact['avatar'] == '') {
- $update_contact = true;
- }
-
- if (!$update_contact || $no_update) {
- return $contact_id;
- }
- } elseif ($uid != 0) {
- // Non-existing user-specific contact, exiting
- return 0;
- }
-
- $data = Probe::uri($url, "", $uid);
-
- // Last try in gcontact for unsupported networks
- if (!in_array($data["network"], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_DIASPORA, NETWORK_PUMPIO, NETWORK_MAIL))) {
- if ($uid != 0) {
- return 0;
- }
-
- // Get data from the gcontact table
- $gcontacts = dba::select('gcontact', array('name', 'nick', 'url', 'photo', 'addr', 'alias', 'network'),
- array('nurl' => normalise_link($url)), array('limit' => 1));
- if (!DBM::is_result($gcontacts)) {
- return 0;
- }
-
- $data = array_merge($data, $gcontacts);
- }
-
- if (!$contact_id && ($data["alias"] != '') && ($data["alias"] != $url)) {
- $contact_id = get_contact($data["alias"], $uid, true);
- }
-
- $url = $data["url"];
- if (!$contact_id) {
- dba::insert('contact', array('uid' => $uid, 'created' => datetime_convert(), 'url' => $data["url"],
- 'nurl' => normalise_link($data["url"]), 'addr' => $data["addr"],
- 'alias' => $data["alias"], 'notify' => $data["notify"], 'poll' => $data["poll"],
- 'name' => $data["name"], 'nick' => $data["nick"], 'photo' => $data["photo"],
- 'keywords' => $data["keywords"], 'location' => $data["location"], 'about' => $data["about"],
- 'network' => $data["network"], 'pubkey' => $data["pubkey"],
- 'rel' => CONTACT_IS_SHARING, 'priority' => $data["priority"],
- 'batch' => $data["batch"], 'request' => $data["request"],
- 'confirm' => $data["confirm"], 'poco' => $data["poco"],
- 'name-date' => datetime_convert(), 'uri-date' => datetime_convert(),
- 'avatar-date' => datetime_convert(), 'writable' => 1, 'blocked' => 0,
- 'readonly' => 0, 'pending' => 0));
-
- $contacts = q("SELECT `id` FROM `contact` WHERE `nurl` = '%s' AND `uid` = %d ORDER BY `id` LIMIT 2",
- dbesc(normalise_link($data["url"])),
- intval($uid));
- if (!DBM::is_result($contacts)) {
- return 0;
- }
-
- $contact_id = $contacts[0]["id"];
-
- // Update the newly created contact from data in the gcontact table
- $gcontact = dba::select('gcontact', array('location', 'about', 'keywords', 'gender'),
- array('nurl' => normalise_link($data["url"])), array('limit' => 1));
- if (DBM::is_result($gcontact)) {
- // Only use the information when the probing hadn't fetched these values
- if ($data['keywords'] != '') {
- unset($gcontact['keywords']);
- }
- if ($data['location'] != '') {
- unset($gcontact['location']);
- }
- if ($data['about'] != '') {
- unset($gcontact['about']);
- }
- dba::update('contact', $gcontact, array('id' => $contact_id));
- }
-
- if (count($contacts) > 1 && $uid == 0 && $contact_id != 0 && $data["url"] != "") {
- dba::delete('contact', array("`nurl` = ? AND `uid` = 0 AND `id` != ? AND NOT `self`",
- normalise_link($data["url"]), $contact_id));
- }
- }
-
- require_once "Photo.php";
-
- update_contact_avatar($data["photo"], $uid, $contact_id);
-
- $contact = dba::select('contact', array('url', 'nurl', 'addr', 'alias', 'name', 'nick', 'keywords', 'location', 'about', 'avatar-date'),
- array('id' => $contact_id), array('limit' => 1));
-
- // This condition should always be true
- if (!DBM::is_result($contact)) {
- return $contact_id;
- }
-
- $updated = array('addr' => $data['addr'],
- 'alias' => $data['alias'],
- 'url' => $data['url'],
- 'nurl' => normalise_link($data['url']),
- 'name' => $data['name'],
- 'nick' => $data['nick']);
-
- if ($data['keywords'] != '') {
- $updated['keywords'] = $data['keywords'];
- }
- if ($data['location'] != '') {
- $updated['location'] = $data['location'];
- }
- if ($data['about'] != '') {
- $updated['about'] = $data['about'];
- }
-
- if (($data["addr"] != $contact["addr"]) || ($data["alias"] != $contact["alias"])) {
- $updated['uri-date'] = datetime_convert();
- }
- if (($data["name"] != $contact["name"]) || ($data["nick"] != $contact["nick"])) {
- $updated['name-date'] = datetime_convert();
- }
-
- $updated['avatar-date'] = datetime_convert();
-
- dba::update('contact', $updated, array('id' => $contact_id), $contact);
-
- return $contact_id;
-}
-
-/**
- * @brief Checks if the contact is blocked
- *
- * @param int $cid contact id
- *
- * @return boolean Is the contact blocked?
- */
-function blockedContact($cid) {
- if ($cid == 0) {
- return false;
- }
-
- $blocked = dba::select('contact', array('blocked'), array('id' => $cid), array('limit' => 1));
- if (!DBM::is_result($blocked)) {
- return false;
- }
- return (bool)$blocked['blocked'];
-}
-
-/**
- * @brief Checks if the contact is hidden
- *
- * @param int $cid contact id
- *
- * @return boolean Is the contact hidden?
- */
-function hiddenContact($cid) {
- if ($cid == 0) {
- return false;
- }
-
- $hidden = dba::select('contact', array('hidden'), array('id' => $cid), array('limit' => 1));
- if (!DBM::is_result($hidden)) {
- return false;
- }
- return (bool)$hidden['hidden'];
-}
-
-/**
- * @brief Returns posts from a given gcontact
- *
- * @param App $a argv application class
- * @param int $gcontact_id Global contact
- *
- * @return string posts in HTML
- */
-function posts_from_gcontact(App $a, $gcontact_id) {
-
- require_once 'include/conversation.php';
-
- // There are no posts with "uid = 0" with connector networks
- // This speeds up the query a lot
- $r = q("SELECT `network` FROM `gcontact` WHERE `id` = %d", dbesc($gcontact_id));
- if (in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, "")))
- $sql = "(`item`.`uid` = 0 OR (`item`.`uid` = %d AND `item`.`private`))";
- else
- $sql = "`item`.`uid` = %d";
-
- $r = q("SELECT `item`.`uri`, `item`.*, `item`.`id` AS `item_id`,
- `author-name` AS `name`, `owner-avatar` AS `photo`,
- `owner-link` AS `url`, `owner-avatar` AS `thumb`
- FROM `item`
- WHERE `gcontact-id` = %d AND $sql AND
- NOT `deleted` AND NOT `moderated` AND `visible`
- ORDER BY `item`.`created` DESC LIMIT %d, %d",
- intval($gcontact_id),
- intval(local_user()),
- intval($a->pager['start']),
- intval($a->pager['itemspage'])
- );
-
- $o = conversation($a, $r, 'community', false);
-
- $o .= alt_pager($a, count($r));
-
- return $o;
-}
-/**
- * @brief Returns posts from a given contact url
- *
- * @param App $a argv application class
- * @param string $contact_url Contact URL
- *
- * @return string posts in HTML
- */
-function posts_from_contact_url(App $a, $contact_url) {
-
- require_once 'include/conversation.php';
-
- // There are no posts with "uid = 0" with connector networks
- // This speeds up the query a lot
- $r = q("SELECT `network`, `id` AS `author-id`, `contact-type` FROM `contact`
- WHERE `contact`.`nurl` = '%s' AND `contact`.`uid` = 0",
- dbesc(normalise_link($contact_url)));
-
- if (!DBM::is_result($r)) {
- return '';
- }
-
- if (in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
- $sql = "(`item`.`uid` = 0 OR (`item`.`uid` = %d AND NOT `item`.`global`))";
- } else {
- $sql = "`item`.`uid` = %d";
- }
-
- $author_id = intval($r[0]["author-id"]);
-
- $contact = ($r[0]["contact-type"] == ACCOUNT_TYPE_COMMUNITY ? 'owner-id' : 'author-id');
-
- $r = q(item_query()." AND `item`.`".$contact."` = %d AND ".$sql.
- " ORDER BY `item`.`created` DESC LIMIT %d, %d",
- intval($author_id),
- intval(local_user()),
- intval($a->pager['start']),
- intval($a->pager['itemspage'])
- );
-
- $o = conversation($a, $r, 'community', false);
-
- $o .= alt_pager($a, count($r));
-
- return $o;
-}
-
-/**
- * @brief Returns a formatted location string from the given profile array
- *
- * @param array $profile Profile array (Generated from the "profile" table)
- *
- * @return string Location string
- */
-function formatted_location($profile) {
- $location = '';
-
- if($profile['locality'])
- $location .= $profile['locality'];
-
- if($profile['region'] && ($profile['locality'] != $profile['region'])) {
- if($location)
- $location .= ', ';
-
- $location .= $profile['region'];
- }
-
- if($profile['country-name']) {
- if($location)
- $location .= ', ';
-
- $location .= $profile['country-name'];
- }
-
- return $location;
-}
-
-/**
- * @brief Returns the account type name
- *
- * The function can be called with either the user or the contact array
- *
- * @param array $contact contact or user array
- */
-function account_type($contact) {
-
- // There are several fields that indicate that the contact or user is a forum
- // "page-flags" is a field in the user table,
- // "forum" and "prv" are used in the contact table. They stand for PAGE_COMMUNITY and PAGE_PRVGROUP.
- // "community" is used in the gcontact table and is true if the contact is PAGE_COMMUNITY or PAGE_PRVGROUP.
- if((isset($contact['page-flags']) && (intval($contact['page-flags']) == PAGE_COMMUNITY))
- || (isset($contact['page-flags']) && (intval($contact['page-flags']) == PAGE_PRVGROUP))
- || (isset($contact['forum']) && intval($contact['forum']))
- || (isset($contact['prv']) && intval($contact['prv']))
- || (isset($contact['community']) && intval($contact['community'])))
- $type = ACCOUNT_TYPE_COMMUNITY;
- else
- $type = ACCOUNT_TYPE_PERSON;
-
- // The "contact-type" (contact table) and "account-type" (user table) are more general then the chaos from above.
- if (isset($contact["contact-type"]))
- $type = $contact["contact-type"];
- if (isset($contact["account-type"]))
- $type = $contact["account-type"];
-
- switch($type) {
- case ACCOUNT_TYPE_ORGANISATION:
- $account_type = t("Organisation");
- break;
- case ACCOUNT_TYPE_NEWS:
- $account_type = t('News');
- break;
- case ACCOUNT_TYPE_COMMUNITY:
- $account_type = t("Forum");
- break;
- default:
- $account_type = "";
- break;
- }
-
- return $account_type;
-}
+++ /dev/null
-<?php
-
-/**
- * @file include/DirSearch.php
- * @brief This file includes the DirSearch class with directory related functions
- */
-
-use Friendica\Core\Config;
-
-/**
- * @brief This class handels directory related functions
- */
-class DirSearch {
-
- /**
- * @brief Search global contact table by nick or name
- *
- * @param string $search Name or nick
- * @param string $mode Search mode (e.g. "community")
- * @return array with search results
- */
- public static function global_search_by_name($search, $mode = '') {
-
- if($search) {
- // check supported networks
- if (Config::get('system','diaspora_enabled'))
- $diaspora = NETWORK_DIASPORA;
- else
- $diaspora = NETWORK_DFRN;
-
- if (!Config::get('system','ostatus_disabled'))
- $ostatus = NETWORK_OSTATUS;
- else
- $ostatus = NETWORK_DFRN;
-
- // check if we search only communities or every contact
- if($mode === "community")
- $extra_sql = " AND `community`";
- else
- $extra_sql = "";
-
- $search .= "%";
-
- $results = q("SELECT `contact`.`id` AS `cid`, `gcontact`.`url`, `gcontact`.`name`, `gcontact`.`nick`, `gcontact`.`photo`,
- `gcontact`.`network`, `gcontact`.`keywords`, `gcontact`.`addr`, `gcontact`.`community`
- FROM `gcontact`
- LEFT JOIN `contact` ON `contact`.`nurl` = `gcontact`.`nurl`
- AND `contact`.`uid` = %d AND NOT `contact`.`blocked`
- AND NOT `contact`.`pending` AND `contact`.`rel` IN ('%s', '%s')
- WHERE (`contact`.`id` > 0 OR (NOT `gcontact`.`hide` AND `gcontact`.`network` IN ('%s', '%s', '%s') AND
- ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`)))) AND
- (`gcontact`.`addr` LIKE '%s' OR `gcontact`.`name` LIKE '%s' OR `gcontact`.`nick` LIKE '%s') $extra_sql
- GROUP BY `gcontact`.`nurl`
- ORDER BY `gcontact`.`nurl` DESC
- LIMIT 1000",
- intval(local_user()), dbesc(CONTACT_IS_SHARING), dbesc(CONTACT_IS_FRIEND),
- dbesc(NETWORK_DFRN), dbesc($ostatus), dbesc($diaspora),
- dbesc(escape_tags($search)), dbesc(escape_tags($search)), dbesc(escape_tags($search)));
-
- return $results;
- }
-
- }
-}
+++ /dev/null
-<?php
-
-use Friendica\Core\PConfig;
-
-require_once('include/email.php');
-
-class Emailer {
- /**
- * Send a multipart/alternative message with Text and HTML versions
- *
- * @param fromName name of the sender
- * @param fromEmail email fo the sender
- * @param replyTo replyTo address to direct responses
- * @param toEmail destination email address
- * @param messageSubject subject of the message
- * @param htmlVersion html version of the message
- * @param textVersion text only version of the message
- * @param additionalMailHeader additions to the smtp mail header
- * @param optional uid user id of the destination user
- */
- public static function send($params) {
-
- call_hooks('emailer_send_prepare', $params);
-
- $email_textonly = False;
- if (x($params,"uid")) {
- $email_textonly = PConfig::get($params['uid'], "system", "email_textonly");
- }
-
- $fromName = email_header_encode(html_entity_decode($params['fromName'],ENT_QUOTES,'UTF-8'),'UTF-8');
- $messageSubject = email_header_encode(html_entity_decode($params['messageSubject'],ENT_QUOTES,'UTF-8'),'UTF-8');
-
- // generate a mime boundary
- $mimeBoundary =rand(0,9)."-"
- .rand(100000000,999999999)."-"
- .rand(100000000,999999999)."=:"
- .rand(10000,99999);
-
- // generate a multipart/alternative message header
- $messageHeader =
- $params['additionalMailHeader'] .
- "From: $fromName <{$params['fromEmail']}>\n" .
- "Reply-To: $fromName <{$params['replyTo']}>\n" .
- "MIME-Version: 1.0\n" .
- "Content-Type: multipart/alternative; boundary=\"{$mimeBoundary}\"";
-
- // assemble the final multipart message body with the text and html types included
- $textBody = chunk_split(base64_encode($params['textVersion']));
- $htmlBody = chunk_split(base64_encode($params['htmlVersion']));
- $multipartMessageBody =
- "--" . $mimeBoundary . "\n" . // plain text section
- "Content-Type: text/plain; charset=UTF-8\n" .
- "Content-Transfer-Encoding: base64\n\n" .
- $textBody . "\n";
-
- if (!$email_textonly && !is_null($params['htmlVersion'])){
- $multipartMessageBody .=
- "--" . $mimeBoundary . "\n" . // text/html section
- "Content-Type: text/html; charset=UTF-8\n" .
- "Content-Transfer-Encoding: base64\n\n" .
- $htmlBody . "\n";
- }
- $multipartMessageBody .=
- "--" . $mimeBoundary . "--\n"; // message ending
-
- // send the message
- $hookdata = array(
- 'to' => $params['toEmail'],
- 'subject' => $messageSubject,
- 'body' => $multipartMessageBody,
- 'headers' => $messageHeader
- );
- //echo "<pre>"; var_dump($hookdata); killme();
- call_hooks("emailer_send", $hookdata);
- $res = mail(
- $hookdata['to'], // send to address
- $hookdata['subject'], // subject
- $hookdata['body'], // message body
- $hookdata['headers'] // message headers
- );
- logger("header " . 'To: ' . $params['toEmail'] . "\n" . $messageHeader, LOGGER_DEBUG);
- logger("return value " . (($res)?"true":"false"), LOGGER_DEBUG);
- return $res;
- }
-}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\System;
-use Friendica\Database\DBM;
-
-/**
- * @file include/ForumManager.php
- * @brief ForumManager class with its methods related to forum functionality *
- */
-
-/**
- * @brief This class handles metheods related to the forum functionality
- */
-class ForumManager {
-
- /**
- * @brief Function to list all forums a user is connected with
- *
- * @param int $uid of the profile owner
- * @param boolean $showhidden
- * Show frorums which are not hidden
- * @param boolean $lastitem
- * Sort by lastitem
- * @param boolean $showprivate
- * Show private groups
- *
- * @returns array
- * 'url' => forum url
- * 'name' => forum name
- * 'id' => number of the key from the array
- * 'micro' => contact photo in format micro
- * 'thumb' => contact photo in format thumb
- */
- public static function get_list($uid, $showhidden = true, $lastitem, $showprivate = false) {
-
- $forumlist = array();
-
- $order = (($showhidden) ? '' : ' AND NOT `hidden` ');
- $order .= (($lastitem) ? ' ORDER BY `last-item` DESC ' : ' ORDER BY `name` ASC ');
- $select = '`forum` ';
- if ($showprivate) {
- $select = '(`forum` OR `prv`)';
- }
-
- $contacts = dba::p("SELECT `contact`.`id`, `contact`.`url`, `contact`.`name`, `contact`.`micro`, `contact`.`thumb` FROM `contact`
- WHERE `network`= 'dfrn' AND $select AND `uid` = ?
- AND NOT `blocked` AND NOT `hidden` AND NOT `pending` AND NOT `archive`
- AND `success_update` > `failure_update`
- $order ",
- $uid
- );
-
- if (!$contacts)
- return($forumlist);
-
- while ($contact = dba::fetch($contacts)) {
- $forumlist[] = array(
- 'url' => $contact['url'],
- 'name' => $contact['name'],
- 'id' => $contact['id'],
- 'micro' => $contact['micro'],
- 'thumb' => $contact['thumb'],
- );
- }
- dba::close($contacts);
-
- return($forumlist);
- }
-
-
- /**
- * @brief Forumlist widget
- *
- * Sidebar widget to show subcribed friendica forums. If activated
- * in the settings, it appears at the notwork page sidebar
- *
- * @param int $uid The ID of the User
- * @param int $cid
- * The contact id which is used to mark a forum as "selected"
- * @return string
- */
- public static function widget($uid,$cid = 0) {
-
- if(! intval(feature_enabled(local_user(),'forumlist_widget')))
- return;
-
- $o = '';
-
- //sort by last updated item
- $lastitem = true;
-
- $contacts = self::get_list($uid,true,$lastitem, true);
- $total = count($contacts);
- $visible_forums = 10;
-
- if (DBM::is_result($contacts)) {
-
- $id = 0;
-
- foreach($contacts as $contact) {
-
- $selected = (($cid == $contact['id']) ? ' forum-selected' : '');
-
- $entry = array(
- 'url' => 'network?f=&cid=' . $contact['id'],
- 'external_url' => 'redir/' . $contact['id'],
- 'name' => $contact['name'],
- 'cid' => $contact['id'],
- 'selected' => $selected,
- 'micro' => System::removedBaseUrl(proxy_url($contact['micro'], false, PROXY_SIZE_MICRO)),
- 'id' => ++$id,
- );
- $entries[] = $entry;
- }
-
- $tpl = get_markup_template('widget_forumlist.tpl');
-
- $o .= replace_macros($tpl,array(
- '$title' => t('Forums'),
- '$forums' => $entries,
- '$link_desc' => t('External link to forum'),
- '$total' => $total,
- '$visible_forums' => $visible_forums,
- '$showmore' => t('show more'),
- ));
- }
-
- return $o;
- }
-
- /**
- * @brief Format forumlist as contact block
- *
- * This function is used to show the forumlist in
- * the advanced profile.
- *
- * @param int $uid The ID of the User
- * @return string
- *
- */
- public static function profile_advanced($uid) {
-
- $profile = intval(feature_enabled($uid,'forumlist_profile'));
- if(! $profile)
- return;
-
- $o = '';
-
- // place holder in case somebody wants configurability
- $show_total = 9999;
-
- //don't sort by last updated item
- $lastitem = false;
-
- $contacts = self::get_list($uid,false,$lastitem,false);
-
- $total_shown = 0;
-
- foreach($contacts as $contact) {
- $forumlist .= micropro($contact,false,'forumlist-profile-advanced');
- $total_shown ++;
- if($total_shown == $show_total)
- break;
- }
-
- if(count($contacts) > 0)
- $o .= $forumlist;
- return $o;
- }
-
- /**
- * @brief count unread forum items
- *
- * Count unread items of connected forums and private groups
- *
- * @return array
- * 'id' => contact id
- * 'name' => contact/forum name
- * 'count' => counted unseen forum items
- *
- */
- public static function count_unseen_items() {
- $r = q("SELECT `contact`.`id`, `contact`.`name`, COUNT(*) AS `count` FROM `item`
- INNER JOIN `contact` ON `item`.`contact-id` = `contact`.`id`
- WHERE `item`.`uid` = %d AND `item`.`visible` AND NOT `item`.`deleted` AND `item`.`unseen`
- AND `contact`.`network`= 'dfrn' AND (`contact`.`forum` OR `contact`.`prv`)
- AND NOT `contact`.`blocked` AND NOT `contact`.`hidden`
- AND NOT `contact`.`pending` AND NOT `contact`.`archive`
- AND `contact`.`success_update` > `failure_update`
- GROUP BY `contact`.`id` ",
- intval(local_user())
- );
-
- return $r;
- }
-
-}
+++ /dev/null
-<?php
-/**
- * Throwable exceptions to return HTTP status code
- *
- * This list of Exception has be extracted from
- * here http://racksburg.com/choosing-an-http-status-code/
- */
-
-class HTTPException extends Exception {
- var $httpcode = 200;
- var $httpdesc = "";
- public function __construct($message="", $code = 0, Exception $previous = null) {
- if ($this->httpdesc=="") {
- $this->httpdesc = preg_replace("|([a-z])([A-Z])|",'$1 $2', str_replace("Exception","",get_class($this)));
- }
- parent::__construct($message, $code, $previous);
- }
-}
-
-// 4xx
-class TooManyRequestsException extends HTTPException {
- var $httpcode = 429;
-}
-
-class UnauthorizedException extends HTTPException {
- var $httpcode = 401;
-}
-
-class ForbiddenException extends HTTPException {
- var $httpcode = 403;
-}
-
-class NotFoundException extends HTTPException {
- var $httpcode = 404;
-}
-
-class GoneException extends HTTPException {
- var $httpcode = 410;
-}
-
-class MethodNotAllowedException extends HTTPException {
- var $httpcode = 405;
-}
-
-class NonAcceptableException extends HTTPException {
- var $httpcode = 406;
-}
-
-class LenghtRequiredException extends HTTPException {
- var $httpcode = 411;
-}
-
-class PreconditionFailedException extends HTTPException {
- var $httpcode = 412;
-}
-
-class UnsupportedMediaTypeException extends HTTPException {
- var $httpcode = 415;
-}
-
-class ExpetationFailesException extends HTTPException {
- var $httpcode = 417;
-}
-
-class ConflictException extends HTTPException {
- var $httpcode = 409;
-}
-
-class UnprocessableEntityException extends HTTPException {
- var $httpcode = 422;
-}
-
-class ImATeapotException extends HTTPException {
- var $httpcode = 418;
- var $httpdesc = "I'm A Teapot";
-}
-
-class BadRequestException extends HTTPException {
- var $httpcode = 400;
-}
-
-// 5xx
-
-class ServiceUnavaiableException extends HTTPException {
- var $httpcode = 503;
-}
-
-class BadGatewayException extends HTTPException {
- var $httpcode = 502;
-}
-
-class GatewayTimeoutException extends HTTPException {
- var $httpcode = 504;
-}
-
-class NotImplementedException extends HTTPException {
- var $httpcode = 501;
-}
-
-class InternalServerErrorException extends HTTPException {
- var $httpcode = 500;
-}
-
-
-
+++ /dev/null
-<?php
-
-/**
- * @file include/Smilies.php
- * @brief This file contains the Smilies class which contains functions to handle smiles
- *
- * @todo Use the shortcodes from here:
- * https://github.com/iamcal/emoji-data/blob/master/emoji_pretty.json?raw=true
- * https://raw.githubusercontent.com/emojione/emojione/master/extras/alpha-codes/eac.json?raw=true
- * https://github.com/johannhof/emoji-helper/blob/master/data/emoji.json?raw=true
- *
- * Have also a look here:
- * https://www.webpagefx.com/tools/emoji-cheat-sheet/
- */
-
-use Friendica\App;
-use Friendica\Core\Config;
-use Friendica\Core\PConfig;
-use Friendica\Core\System;
-
-/**
- * This class contains functions to handle smiles
- */
-
-class Smilies {
-
- /**
- * @brief Replaces/adds the emoticon list
- *
- * This function should be used whenever emoticons are added
- *
- * @param array $b Array of emoticons
- * @param string $smiley The text smilie
- * @param string $representation The replacement
- */
- public static function add(&$b, $smiley, $representation) {
- $found = array_search($smiley, $b['texts']);
-
- if (!is_int($found)) {
- $b['texts'][] = $smiley;
- $b['icons'][] = $representation;
- } else {
- $b['icons'][$found] = $representation;
- }
- }
-
- /**
- * @brief Function to list all smilies
- *
- * Get an array of all smilies, both internal and from addons.
- *
- * @return array
- * 'texts' => smilie shortcut
- * 'icons' => icon in html
- *
- * @hook smilie ('texts' => smilies texts array, 'icons' => smilies html array)
- */
- public static function get_list() {
-
- $texts = array(
- '<3',
- '</3',
- '<\\3',
- ':-)',
- ';-)',
- ':-(',
- ':-P',
- ':-p',
- ':-"',
- ':-"',
- ':-x',
- ':-X',
- ':-D',
- '8-|',
- '8-O',
- ':-O',
- '\\o/',
- 'o.O',
- 'O.o',
- 'o_O',
- 'O_o',
- ":'(",
- ":-!",
- ":-/",
- ":-[",
- "8-)",
- ':beer',
- ':homebrew',
- ':coffee',
- ':facepalm',
- ':like',
- ':dislike',
- '~friendica',
- 'red#',
- 'red#matrix'
-
- );
-
- $icons = array(
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-heart.gif" alt="<3" title="<3" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-brokenheart.gif" alt="</3" title="</3" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-brokenheart.gif" alt="<\\3" title="<\\3" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-smile.gif" alt=":-)" title=":-)" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-wink.gif" alt=";-)" title=";-)" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-frown.gif" alt=":-(" title=":-(" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-tongue-out.gif" alt=":-P" title=":-P" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-tongue-out.gif" alt=":-p" title=":-P" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-\" title=":-\" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-\" title=":-\" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-x" title=":-x" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-X" title=":-X" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-laughing.gif" alt=":-D" title=":-D" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt="8-|" title="8-|" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt="8-O" title="8-O" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt=":-O" title="8-O" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-thumbsup.gif" alt="\\o/" title="\\o/" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="o.O" title="o.O" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="O.o" title="O.o" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="o_O" title="o_O" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="O_o" title="O_o" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-cry.gif" alt=":\'(" title=":\'("/>',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-foot-in-mouth.gif" alt=":-!" title=":-!" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-undecided.gif" alt=":-/" title=":-/" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-embarassed.gif" alt=":-[" title=":-[" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-cool.gif" alt="8-)" title="8-)" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/beer_mug.gif" alt=":beer" title=":beer" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/beer_mug.gif" alt=":homebrew" title=":homebrew" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/coffee.gif" alt=":coffee" title=":coffee" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-facepalm.gif" alt=":facepalm" title=":facepalm" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/like.gif" alt=":like" title=":like" />',
- '<img class="smiley" src="' . System::baseUrl() . '/images/dislike.gif" alt=":dislike" title=":dislike" />',
- '<a href="https://friendi.ca">~friendica <img class="smiley" src="' . System::baseUrl() . '/images/friendica-16.png" alt="~friendica" title="~friendica" /></a>',
- '<a href="http://redmatrix.me/">red<img class="smiley" src="' . System::baseUrl() . '/images/rm-16.png" alt="red#" title="red#" />matrix</a>',
- '<a href="http://redmatrix.me/">red<img class="smiley" src="' . System::baseUrl() . '/images/rm-16.png" alt="red#matrix" title="red#matrix" />matrix</a>'
- );
-
- $params = array('texts' => $texts, 'icons' => $icons);
- call_hooks('smilie', $params);
-
- return $params;
- }
-
- /**
- * @brief Replaces text emoticons with graphical images
- *
- * It is expected that this function will be called using HTML text.
- * We will escape text between HTML pre and code blocks from being
- * processed.
- *
- * At a higher level, the bbcode [nosmile] tag can be used to prevent this
- * function from being executed by the prepare_text() routine when preparing
- * bbcode source for HTML display
- *
- * @param string $s Text that should be replaced
- * @param boolean $sample
- * @param boolean $no_images Only replace emoticons without images
- *
- * @return string HML Output of the Smilie
- */
- public static function replace($s, $sample = false, $no_images = false) {
- if(intval(Config::get('system','no_smilies'))
- || (local_user() && intval(PConfig::get(local_user(),'system','no_smilies'))))
- return $s;
-
- $s = preg_replace_callback('/<pre>(.*?)<\/pre>/ism','self::encode',$s);
- $s = preg_replace_callback('/<code>(.*?)<\/code>/ism','self::encode',$s);
-
- $params = self::get_list();
-
- if ($no_images) {
- $cleaned = array('texts' => array(), 'icons' => array());
- $icons = $params['icons'];
- foreach ($icons AS $key => $icon) {
- if (!strstr($icon, '<img ')) {
- $cleaned['texts'][] = $params['texts'][$key];
- $cleaned['icons'][] = $params['icons'][$key];
- }
- }
- $params = $cleaned;
- }
-
- $params['string'] = $s;
-
- if($sample) {
- $s = '<div class="smiley-sample">';
- for($x = 0; $x < count($params['texts']); $x ++) {
- $s .= '<dl><dt>' . $params['texts'][$x] . '</dt><dd>' . $params['icons'][$x] . '</dd></dl>';
- }
- }
- else {
- $params['string'] = preg_replace_callback('/<(3+)/','self::preg_heart',$params['string']);
- $s = str_replace($params['texts'],$params['icons'],$params['string']);
- }
-
- $s = preg_replace_callback('/<pre>(.*?)<\/pre>/ism','self::decode',$s);
- $s = preg_replace_callback('/<code>(.*?)<\/code>/ism','self::decode',$s);
-
- return $s;
- }
-
- private static function encode($m) {
- return(str_replace($m[1],base64url_encode($m[1]),$m[0]));
- }
-
- private static function decode($m) {
- return(str_replace($m[1],base64url_decode($m[1]),$m[0]));
- }
-
-
- /**
- * @brief expand <3333 to the correct number of hearts
- *
- * @param string $x
- * @return string HTML Output
- *
- * @todo: Rework because it doesn't work correctly
- */
- private static function preg_heart($x) {
- if(strlen($x[1]) == 1)
- return $x[0];
- $t = '';
- for($cnt = 0; $cnt < strlen($x[1]); $cnt ++)
- $t .= '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-heart.gif" alt="<3" />';
- $r = str_replace($x[0],$t,$x[0]);
- return $r;
- }
-}
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
require_once "include/contact_selectors.php";
require_once "include/contact_widgets.php";
-require_once "include/DirSearch.php";
require_once "include/features.php";
require_once "mod/proxy.php";
return $o;
}
-/// @TODO after an optional parameter, no mandadory parameter can follow
/// @TODO find proper type-hints
-function contact_selector($selname, $selclass, $preselected = false, $options) {
-
+function contact_selector($selname, $selclass, $options, $preselected = false)
+{
$a = get_app();
$mutual = false;
);
if (DBM::is_result($r)) {
foreach ($r as $row) {
- $contact = get_contact_details_by_url($row['author-link']);
+ $contact = Contact::getDetailsByURL($row['author-link']);
if (count($contact) > 0) {
$unknown_contacts[] = array(
}
if ($localsearch) {
- $x = DirSearch::global_search_by_name($search, $mode);
+ $x = GlobalContact::searchByName($search, $mode);
return $x;
}
use Friendica\Core\NotificationsManager;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\User;
+use Friendica\Network\HTTPException;
+use Friendica\Network\HTTPException\BadRequestException;
+use Friendica\Network\HTTPException\ForbiddenException;
+use Friendica\Network\HTTPException\InternalServerErrorException;
+use Friendica\Network\HTTPException\MethodNotAllowedException;
+use Friendica\Network\HTTPException\NotFoundException;
+use Friendica\Network\HTTPException\NotImplementedException;
+use Friendica\Network\HTTPException\UnauthorizedException;
+use Friendica\Network\HTTPException\TooManyRequestsException;
+use Friendica\Object\Contact;
use Friendica\Protocol\Diaspora;
use Friendica\Util\XML;
-require_once 'include/HTTPExceptions.php';
require_once 'include/bbcode.php';
require_once 'include/datetime.php';
require_once 'include/conversation.php';
$user = $_SERVER['PHP_AUTH_USER'];
$password = $_SERVER['PHP_AUTH_PW'];
- $encrypted = hash('whirlpool', trim($password));
// allow "user@server" login (but ignore 'server' part)
$at = strstr($user, "@", true);
if (($addon_auth['authenticated']) && (count($addon_auth['user_record']))) {
$record = $addon_auth['user_record'];
} else {
- // process normal login request
- $r = q(
- "SELECT * FROM `user` WHERE (`email` = '%s' OR `nickname` = '%s')
- AND `password` = '%s' AND NOT `blocked` AND NOT `account_expired` AND NOT `account_removed` AND `verified` LIMIT 1",
- dbesc(trim($user)),
- dbesc(trim($user)),
- dbesc($encrypted)
- );
- if (DBM::is_result($r)) {
- $record = $r[0];
+ $user_id = User::authenticate(trim($user), trim($password));
+ if ($user_id) {
+ $record = dba::select('user', [], ['uid' => $user_id], ['limit' => 1]);
}
}
'notifications' => false,
'statusnet_profile_url' => $r[0]["url"],
'uid' => 0,
- 'cid' => get_contact($r[0]["url"], api_user(), true),
+ 'cid' => Contact::getIdForURL($r[0]["url"], api_user(), true),
'self' => 0,
'network' => $r[0]["network"],
);
$network_name = network_to_name($uinfo[0]['network'], $uinfo[0]['url']);
- $pcontact_id = get_contact($uinfo[0]['url'], 0, true);
+ $pcontact_id = Contact::getIdForURL($uinfo[0]['url'], 0, true);
$ret = array(
'id' => intval($pcontact_id),
$data3 = array($root_element => $data2);
- $ret = XML::from_array($data3, $xml, false, $namespaces);
+ $ret = XML::fromArray($data3, $xml, false, $namespaces);
return $ret;
}
}
// now let's delete all photos from the album
- $result = q(
- "DELETE FROM `photo` WHERE `uid` = %d AND `album` = '%s'",
- intval(api_user()),
- dbesc($album)
- );
+ $result = dba::delete('photo', array('uid' => api_user(), 'album' => $album));
// return success of deletion or error message
if ($result) {
throw new BadRequestException("photo not available");
}
// now we can perform on the deletion of the photo
- $result = q(
- "DELETE FROM `photo` WHERE `uid` = %d AND `resource-id` = '%s'",
- intval(api_user()),
- dbesc($photo_id)
- );
+ $result = dba::delete('photo', array('uid' => api_user(), 'resource-id' => $photo_id));
// return success of deletion or error message
if ($result) {
//$user = api_get_user(get_app());
$url = System::baseUrl() . '/profile/' . get_app()->user['nickname'];
if ($url && strlen(Config::get('system', 'directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
- Worker::add(PRIORITY_LOW, 'profile_update', api_user());
+ Worker::add(PRIORITY_LOW, 'ProfileUpdate', api_user());
// output for client
if ($data) {
{
$body = trim($item["body"]);
- if (Diaspora::is_reshare($body, false)===false) {
+ if (Diaspora::isReshare($body, false)===false) {
return false;
}
$attributes = preg_replace("/\[share(.*?)\]\s?(.*?)\s?\[\/share\]\s?/ism", "$1", $body);
/*
* Skip if there is no shared message in there
- * we already checked this in diaspora::is_reshare()
+ * we already checked this in diaspora::isReshare()
* but better one more than one less...
*/
if ($body == $attributes) {
use Friendica\Core\System;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Model\User;
-require_once('include/security.php');
-require_once('include/datetime.php');
+require_once 'include/security.php';
+require_once 'include/datetime.php';
// When the "Friendica" cookie is set, take the value to authenticate and renew the cookie.
if (isset($_COOKIE["Friendica"])) {
$data = json_decode($_COOKIE["Friendica"]);
if (isset($data->uid)) {
- $r = q("SELECT `user`.*, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey`
- FROM `user` WHERE `uid` = %d AND NOT `blocked` AND NOT `account_expired` AND NOT `account_removed` AND `verified` LIMIT 1",
- intval($data->uid)
+
+ $user = dba::select('user',
+ [],
+ [
+ 'uid' => $data->uid,
+ 'blocked' => false,
+ 'account_expired' => false,
+ 'account_removed' => false,
+ 'verified' => true,
+ ],
+ ['limit' => 1]
);
- if ($r) {
- if ($data->hash != cookie_hash($r[0])) {
- logger("Hash for user ".$data->uid." doesn't fit.");
+ if (DBM::is_result($user)) {
+ if ($data->hash != cookie_hash($user)) {
+ logger("Hash for user " . $data->uid . " doesn't fit.");
nuke_session();
goaway(System::baseUrl());
}
// Expires after 7 days by default,
// can be set via system.auth_cookie_lifetime
$authcookiedays = Config::get('system', 'auth_cookie_lifetime', 7);
- new_cookie($authcookiedays*24*60*60, $r[0]);
+ new_cookie($authcookiedays * 24 * 60 * 60, $user);
// Do the authentification if not done by now
if (!isset($_SESSION) || !isset($_SESSION['authenticated'])) {
- authenticate_success($r[0]);
+ authenticate_success($user);
- if (Config::get('system','paranoia'))
+ if (Config::get('system', 'paranoia')) {
$_SESSION['addr'] = $data->ip;
+ }
}
}
}
// login/logout
-if (isset($_SESSION) && x($_SESSION,'authenticated') && (!x($_POST,'auth-params') || ($_POST['auth-params'] !== 'login'))) {
-
- if ((x($_POST,'auth-params') && ($_POST['auth-params'] === 'logout')) || ($a->module === 'logout')) {
-
+if (isset($_SESSION) && x($_SESSION, 'authenticated') && (!x($_POST, 'auth-params') || ($_POST['auth-params'] !== 'login'))) {
+ if ((x($_POST, 'auth-params') && ($_POST['auth-params'] === 'logout')) || ($a->module === 'logout')) {
// process logout request
call_hooks("logging_out");
nuke_session();
- info(t('Logged out.').EOL);
+ info(t('Logged out.') . EOL);
goaway(System::baseUrl());
}
- if (x($_SESSION,'visitor_id') && !x($_SESSION,'uid')) {
+ if (x($_SESSION, 'visitor_id') && !x($_SESSION, 'uid')) {
$r = q("SELECT * FROM `contact` WHERE `id` = %d LIMIT 1",
intval($_SESSION['visitor_id'])
);
}
}
- if (x($_SESSION,'uid')) {
-
+ if (x($_SESSION, 'uid')) {
// already logged in user returning
-
- $check = Config::get('system','paranoia');
+ $check = Config::get('system', 'paranoia');
// extra paranoia - if the IP changed, log them out
if ($check && ($_SESSION['addr'] != $_SERVER['REMOTE_ADDR'])) {
- logger('Session address changed. Paranoid setting in effect, blocking session. '.
- $_SESSION['addr'].' != '.$_SERVER['REMOTE_ADDR']);
+ logger('Session address changed. Paranoid setting in effect, blocking session. ' .
+ $_SESSION['addr'] . ' != ' . $_SERVER['REMOTE_ADDR']);
nuke_session();
goaway(System::baseUrl());
}
- $r = q("SELECT `user`.*, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey`
- FROM `user` WHERE `uid` = %d AND NOT `blocked` AND NOT `account_expired` AND NOT `account_removed` AND `verified` LIMIT 1",
- intval($_SESSION['uid'])
+ $user = dba::select('user',
+ [],
+ [
+ 'uid' => $_SESSION['uid'],
+ 'blocked' => false,
+ 'account_expired' => false,
+ 'account_removed' => false,
+ 'verified' => true,
+ ],
+ ['limit' => 1]
);
-
- if (!DBM::is_result($r)) {
+ if (!DBM::is_result($user)) {
nuke_session();
goaway(System::baseUrl());
}
// stays logged in for a long time, e.g. with "Remember Me"
$login_refresh = false;
if (!x($_SESSION['last_login_date'])) {
- $_SESSION['last_login_date'] = datetime_convert('UTC','UTC');
+ $_SESSION['last_login_date'] = datetime_convert('UTC', 'UTC');
}
- if (strcmp(datetime_convert('UTC','UTC','now - 12 hours'), $_SESSION['last_login_date']) > 0) {
-
- $_SESSION['last_login_date'] = datetime_convert('UTC','UTC');
+ if (strcmp(datetime_convert('UTC', 'UTC', 'now - 12 hours'), $_SESSION['last_login_date']) > 0) {
+ $_SESSION['last_login_date'] = datetime_convert('UTC', 'UTC');
$login_refresh = true;
}
- authenticate_success($r[0], false, false, $login_refresh);
+ authenticate_success($user, false, false, $login_refresh);
}
} else {
-
session_unset();
+ if (
+ !(x($_POST, 'password') && strlen($_POST['password']))
+ && (
+ x($_POST, 'openid_url') && strlen($_POST['openid_url'])
+ || x($_POST, 'username') && strlen($_POST['username'])
+ )
+ ) {
+ $noid = Config::get('system', 'no_openid');
- if (x($_POST,'password') && strlen($_POST['password']))
- $encrypted = hash('whirlpool',trim($_POST['password']));
- else {
- if ((x($_POST,'openid_url')) && strlen($_POST['openid_url']) ||
- (x($_POST,'username')) && strlen($_POST['username'])) {
-
- $noid = Config::get('system','no_openid');
+ $openid_url = trim(strlen($_POST['openid_url']) ? $_POST['openid_url'] : $_POST['username']);
- $openid_url = trim((strlen($_POST['openid_url'])?$_POST['openid_url']:$_POST['username']));
+ // validate_url alters the calling parameter
- // validate_url alters the calling parameter
+ $temp_string = $openid_url;
- $temp_string = $openid_url;
+ // if it's an email address or doesn't resolve to a URL, fail.
- // if it's an email address or doesn't resolve to a URL, fail.
-
- if ($noid || strpos($temp_string,'@') || !validate_url($temp_string)) {
- $a = get_app();
- notice(t('Login failed.').EOL);
- goaway(System::baseUrl());
- // NOTREACHED
- }
-
- // Otherwise it's probably an openid.
-
- try {
- require_once('library/openid.php');
- $openid = new LightOpenID;
- $openid->identity = $openid_url;
- $_SESSION['openid'] = $openid_url;
- $_SESSION['remember'] = $_POST['remember'];
- $openid->returnUrl = System::baseUrl(true).'/openid';
- goaway($openid->authUrl());
- } catch (Exception $e) {
- notice(t('We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID.').'<br /><br >'.t('The error message was:').' '.$e->getMessage());
- }
+ if ($noid || strpos($temp_string, '@') || !validate_url($temp_string)) {
+ $a = get_app();
+ notice(t('Login failed.') . EOL);
+ goaway(System::baseUrl());
// NOTREACHED
}
- }
- if (x($_POST,'auth-params') && $_POST['auth-params'] === 'login') {
+ // Otherwise it's probably an openid.
+
+ try {
+ require_once('library/openid.php');
+ $openid = new LightOpenID;
+ $openid->identity = $openid_url;
+ $_SESSION['openid'] = $openid_url;
+ $_SESSION['remember'] = $_POST['remember'];
+ $openid->returnUrl = System::baseUrl(true) . '/openid';
+ goaway($openid->authUrl());
+ } catch (Exception $e) {
+ notice(t('We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID.') . '<br /><br >' . t('The error message was:') . ' ' . $e->getMessage());
+ }
+ // NOTREACHED
+ }
+ if (x($_POST, 'auth-params') && $_POST['auth-params'] === 'login') {
$record = null;
$addon_auth = array(
* and later plugins should not interfere with an earlier one that succeeded.
*
*/
-
call_hooks('authenticate', $addon_auth);
- if ($addon_auth['authenticated'] && count($addon_auth['user_record']))
+ if ($addon_auth['authenticated'] && count($addon_auth['user_record'])) {
$record = $addon_auth['user_record'];
- else {
-
- // process normal login request
-
- $r = q("SELECT `user`.*, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey`
- FROM `user` WHERE (`email` = '%s' OR `nickname` = '%s')
- AND `password` = '%s' AND NOT `blocked` AND NOT `account_expired` AND NOT `account_removed` AND `verified` LIMIT 1",
- dbesc(trim($_POST['username'])),
- dbesc(trim($_POST['username'])),
- dbesc($encrypted)
- );
- if (DBM::is_result($r))
- $record = $r[0];
+ } else {
+ $user_id = User::authenticate(trim($_POST['username']), trim($_POST['password']));
+ if ($user_id) {
+ $record = dba::select('user', [], ['uid' => $user_id], ['limit' => 1]);
+ }
}
if (!$record || !count($record)) {
- logger('authenticate: failed login attempt: '.notags(trim($_POST['username'])).' from IP '.$_SERVER['REMOTE_ADDR']);
- notice(t('Login failed.').EOL);
+ logger('authenticate: failed login attempt: ' . notags(trim($_POST['username'])) . ' from IP ' . $_SERVER['REMOTE_ADDR']);
+ notice(t('Login failed.') . EOL);
goaway(System::baseUrl());
}
- if (! $_POST['remember']) {
+ if (!$_POST['remember']) {
new_cookie(0); // 0 means delete on browser exit
}
// if we haven't failed up this point, log them in.
$_SESSION['remember'] = $_POST['remember'];
- $_SESSION['last_login_date'] = datetime_convert('UTC','UTC');
+ $_SESSION['last_login_date'] = datetime_convert('UTC', 'UTC');
authenticate_success($record, true, true);
}
}
/**
* @brief Kills the "Friendica" cookie and all session data
*/
-function nuke_session() {
-
+function nuke_session()
+{
new_cookie(-3600); // make sure cookie is deleted on browser close, as a security measure
session_unset();
session_destroy();
+++ /dev/null
-#!/usr/bin/php
-<?php
-/*
- * ejabberd extauth script for the integration with friendica
- *
- * Originally written for joomla by Dalibor Karlovic <dado@krizevci.info>
- * modified for Friendica by Michael Vogel <icarus@dabo.de>
- * published under GPL
- *
- * Latest version of the original script for joomla is available at:
- * http://87.230.15.86/~dado/ejabberd/joomla-login
- *
- * Installation:
- *
- * - Change it's owner to whichever user is running the server, ie. ejabberd
- * $ chown ejabberd:ejabberd /path/to/friendica/include/auth_ejabberd.php
- *
- * - Change the access mode so it is readable only to the user ejabberd and has exec
- * $ chmod 700 /path/to/friendica/include/auth_ejabberd.php
- *
- * - Edit your ejabberd.cfg file, comment out your auth_method and add:
- * {auth_method, external}.
- * {extauth_program, "/path/to/friendica/include/auth_ejabberd.php"}.
- *
- * - Restart your ejabberd service, you should be able to login with your friendica auth info
- *
- * Other hints:
- * - if your users have a space or a @ in their nickname, they'll run into trouble
- * registering with any client so they should be instructed to replace these chars
- * " " (space) is replaced with "%20"
- * "@" is replaced with "(a)"
- *
- */
-
-use Friendica\App;
-use Friendica\Core\Config;
-use Friendica\Database\DBM;
-
-if (sizeof($_SERVER["argv"]) == 0)
- die();
-
-$directory = dirname($_SERVER["argv"][0]);
-
-if (substr($directory, 0, 1) != "/")
- $directory = $_SERVER["PWD"]."/".$directory;
-
-$directory = realpath($directory."/..");
-
-chdir($directory);
-require_once("boot.php");
-
-global $a;
-
-if (empty($a)) {
- $a = new App(dirname(__DIR__));
-}
-
-@include(".htconfig.php");
-require_once("include/dba.php");
-dba::connect($db_host, $db_user, $db_pass, $db_data);
-unset($db_host, $db_user, $db_pass, $db_data);
-
-$oAuth = new exAuth();
-
-class exAuth {
- private $bDebug;
-
- /**
- * @brief Create the class and do the authentification studd
- *
- * @param boolean $bDebug Debug mode
- */
- public function __construct() {
- // setter
- $this->bDebug = (int)Config::get('jabber', 'debug');
-
-
- openlog('auth_ejabberd', LOG_PID, LOG_USER);
-
- $this->writeLog(LOG_NOTICE, "start");
-
- // We are connected to the SQL server.
- while (!feof(STDIN)) {
- // Quit if the database connection went down
- if (!dba::connected()) {
- $this->writeLog(LOG_ERR, "the database connection went down");
- return;
- }
-
- $iHeader = fgets(STDIN, 3);
- $aLength = unpack("n", $iHeader);
- $iLength = $aLength["1"];
-
- // No data? Then quit
- if ($iLength == 0) {
- $this->writeLog(LOG_ERR, "we got no data, quitting");
- return;
- }
-
- // Fetching the data
- $sData = fgets(STDIN, $iLength + 1);
- $this->writeLog(LOG_DEBUG, "received data: ". $sData);
- $aCommand = explode(":", $sData);
- if (is_array($aCommand)) {
- switch ($aCommand[0]) {
- case "isuser":
- // Check the existance of a given username
- $this->isuser($aCommand);
- break;
- case "auth":
- // Check if the givven password is correct
- $this->auth($aCommand);
- break;
- case "setpass":
- // We don't accept the setting of passwords here
- $this->writeLog(LOG_NOTICE, "setpass command disabled");
- fwrite(STDOUT, pack("nn", 2, 0));
- break;
- default:
- // We don't know the given command
- $this->writeLog(LOG_NOTICE, "unknown command ". $aCommand[0]);
- fwrite(STDOUT, pack("nn", 2, 0));
- break;
- }
- } else {
- $this->writeLog(LOG_NOTICE, "invalid command string ".$sData);
- fwrite(STDOUT, pack("nn", 2, 0));
- }
- }
- }
-
- /**
- * @brief Check if the given username exists
- *
- * @param array $aCommand The command array
- */
- private function isuser($aCommand) {
- $a = get_app();
-
- // Check if there is a username
- if (!isset($aCommand[1])) {
- $this->writeLog(LOG_NOTICE, "invalid isuser command, no username given");
- fwrite(STDOUT, pack("nn", 2, 0));
- return;
- }
-
- // Now we check if the given user is valid
- $sUser = str_replace(array("%20", "(a)"), array(" ", "@"), $aCommand[1]);
-
- // Does the hostname match? So we try directly
- if ($a->get_hostname() == $aCommand[2]) {
- $this->writeLog(LOG_INFO, "internal user check for ". $sUser."@".$aCommand[2]);
- $sQuery = "SELECT `uid` FROM `user` WHERE `nickname`='".dbesc($sUser)."'";
- $this->writeLog(LOG_DEBUG, "using query ". $sQuery);
- $r = q($sQuery);
- $found = DBM::is_result($r);
- } else {
- $found = false;
- }
-
- // If the hostnames doesn't match or there is some failure, we try to check remotely
- if (!$found) {
- $found = $this->check_user($aCommand[2], $aCommand[1], true);
- }
-
- if ($found) {
- // The user is okay
- $this->writeLog(LOG_NOTICE, "valid user: ". $sUser);
- fwrite(STDOUT, pack("nn", 2, 1));
- } else {
- // The user isn't okay
- $this->writeLog(LOG_WARNING, "invalid user: ". $sUser);
- fwrite(STDOUT, pack("nn", 2, 0));
- }
- }
-
- /**
- * @brief Check remote user existance via HTTP(S)
- *
- * @param string $host The hostname
- * @param string $user Username
- * @param boolean $ssl Should the check be done via SSL?
- *
- * @return boolean Was the user found?
- */
- private function check_user($host, $user, $ssl) {
-
- $this->writeLog(LOG_INFO, "external user check for ".$user."@".$host);
-
- $url = ($ssl ? "https":"http")."://".$host."/noscrape/".$user;
-
- $data = z_fetch_url($url);
-
- if (!is_array($data))
- return(false);
-
- if ($data["return_code"] != "200")
- return(false);
-
- $json = @json_decode($data["body"]);
- if (!is_object($json))
- return(false);
-
- return($json->nick == $user);
- }
-
- /**
- * @brief Authenticate the givven user and password
- *
- * @param array $aCommand The command array
- */
- private function auth($aCommand) {
- $a = get_app();
-
- // check user authentication
- if (sizeof($aCommand) != 4) {
- $this->writeLog(LOG_NOTICE, "invalid auth command, data missing");
- fwrite(STDOUT, pack("nn", 2, 0));
- return;
- }
-
- // We now check if the password match
- $sUser = str_replace(array("%20", "(a)"), array(" ", "@"), $aCommand[1]);
-
- // Does the hostname match? So we try directly
- if ($a->get_hostname() == $aCommand[2]) {
- $this->writeLog(LOG_INFO, "internal auth for ".$sUser."@".$aCommand[2]);
-
- $sQuery = "SELECT `uid`, `password` FROM `user` WHERE `nickname`='".dbesc($sUser)."'";
- $this->writeLog(LOG_DEBUG, "using query ". $sQuery);
- if ($oResult = q($sQuery)) {
- $uid = $oResult[0]["uid"];
- $Error = ($oResult[0]["password"] != hash('whirlpool',$aCommand[3]));
- } else {
- $this->writeLog(LOG_WARNING, "invalid query: ". $sQuery);
- $Error = true;
- $uid = -1;
- }
- if ($Error) {
- $oConfig = q("SELECT `v` FROM `pconfig` WHERE `uid` = %d AND `cat` = 'xmpp' AND `k`='password' LIMIT 1;", intval($uid));
- $this->writeLog(LOG_INFO, "check against alternate password for ".$sUser."@".$aCommand[2]);
- $Error = ($aCommand[3] != $oConfig[0]["v"]);
- }
- } else {
- $Error = true;
- }
-
- // If the hostnames doesn't match or there is some failure, we try to check remotely
- if ($Error) {
- $Error = !$this->check_credentials($aCommand[2], $aCommand[1], $aCommand[3], true);
- }
-
- if ($Error) {
- $this->writeLog(LOG_WARNING, "authentification failed for user ".$sUser."@". $aCommand[2]);
- fwrite(STDOUT, pack("nn", 2, 0));
- } else {
- $this->writeLog(LOG_NOTICE, "authentificated user ".$sUser."@".$aCommand[2]);
- fwrite(STDOUT, pack("nn", 2, 1));
- }
- }
-
- /**
- * @brief Check remote credentials via HTTP(S)
- *
- * @param string $host The hostname
- * @param string $user Username
- * @param string $password Password
- * @param boolean $ssl Should the check be done via SSL?
- *
- * @return boolean Are the credentials okay?
- */
- private function check_credentials($host, $user, $password, $ssl) {
- $url = ($ssl ? "https":"http")."://".$host."/api/account/verify_credentials.json";
-
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL, $url);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5);
- curl_setopt($ch, CURLOPT_HEADER, true);
- curl_setopt($ch, CURLOPT_NOBODY, true);
- curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);
- curl_setopt($ch, CURLOPT_USERPWD, $user.':'.$password);
-
- $header = curl_exec($ch);
- $curl_info = @curl_getinfo($ch);
- $http_code = $curl_info["http_code"];
- curl_close($ch);
-
- $this->writeLog(LOG_INFO, "external auth for ".$user."@".$host." returned ".$http_code);
-
- return ($http_code == 200);
- }
-
- /**
- * @brief write data to the syslog
- *
- * @param integer $loglevel The syslog loglevel
- * @param string $sMessage The syslog message
- */
- private function writeLog($loglevel, $sMessage) {
- if (!$this->bDebug && ($loglevel >= LOG_DEBUG)) {
- return;
- }
- syslog($loglevel, $sMessage);
- }
-
- /**
- * @brief destroy the class, close the syslog connection.
- */
- public function __destruct() {
- $this->writeLog(LOG_NOTICE, "stop");
- closelog();
- }
-}
use Friendica\App;
use Friendica\Core\System;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
use League\HTMLToMarkdown\HtmlConverter;
return;
}
- $data = get_contact_details_by_addr($match[2]);
+ $data = Contact::getDetailsByAddr($match[2]);
$name = $match[1];
*/
function diaspora_mentions($match) {
- $contact = get_contact_details_by_url($match[3]);
+ $contact = Contact::getDetailsByURL($match[3]);
if (!x($contact, 'addr')) {
$contact = Probe::uri($match[3]);
<?php
use Friendica\App;
+use Friendica\Content\Smilies;
use Friendica\Core\Cache;
use Friendica\Core\System;
use Friendica\Core\Config;
+use Friendica\Object\Contact;
require_once 'include/oembed.php';
require_once 'include/event.php';
require_once 'include/map.php';
require_once 'mod/proxy.php';
-require_once 'include/Contact.php';
require_once 'include/plaintext.php';
-require_once 'include/Smilies.php';
function bb_PictureCacheExt($matches) {
if (strpos($matches[3], "data:image/") === 0) {
$data["title"] = str_replace(array("http://", "https://"), "", $data["title"]);
}
- if (((strpos($data["text"], "[img=") !== false) || (strpos($data["text"], "[img]") !== false)) && ($data["image"] != "")) {
+ if (((strpos($data["text"], "[img=") !== false)
+ || (strpos($data["text"], "[img]") !== false)
+ || Config::get('system', 'always_show_preview'))
+ && ($data["image"] != "")) {
$data["preview"] = $data["image"];
$data["image"] = "";
}
// We only call this so that a previously unknown contact can be added.
// This is important for the function "get_contact_details_by_url".
// This function then can fetch an entry from the contact table.
- get_contact($profile, 0);
+ Contact::getIdForURL($profile, 0);
- $data = get_contact_details_by_url($profile);
+ $data = Contact::getDetailsByURL($profile);
if (isset($data["name"]) && ($data["name"] != "") && isset($data["addr"]) && ($data["addr"] != ""))
$userid_compact = $data["name"]." (".$data["addr"].")";
+++ /dev/null
-<?php
-
-/**
- * @file include/checkversion.php
- *
- * @brief save Friendica upstream version to the DB
- **/
-
-use Friendica\Core\Config;
-
-/**
- * @brief check the git repository VERSION file and save the version to the DB
- *
- * Checking the upstream version is optional (opt-in) and can be done to either
- * the master or the develop branch in the repository.
- */
-function checkversion_run () {
- global $a;
-
- logger('checkversion: start');
-
- $checkurl = Config::get('system', 'check_new_version_url', 'none');
-
- switch ($checkurl) {
- case 'master':
- $checked_url = 'https://raw.githubusercontent.com/friendica/friendica/master/VERSION';
- break;
- case 'develop':
- $checked_url = 'https://raw.githubusercontent.com/friendica/friendica/develop/VERSION';
- break;
- default:
- // don't check
- return;
-}
- logger("Checking VERSION from: ".$checked_url, LOGGER_DEBUG);
-
- // fetch the VERSION file
- $gitversion = dbesc(trim(fetch_url($checked_url)));
- logger("Upstream VERSION is: ".$gitversion, LOGGER_DEBUG);
-
- Config::set('system', 'git_friendica_version', $gitversion);
-
- logger('checkversion: end');
-
- return;
-}
+++ /dev/null
-<?php /** @file */
-
-use Friendica\App;
-use Friendica\Core\Config;
-
-require_once('boot.php');
-
-// Everything we need to boot standalone 'background' processes
-
-function cli_startup() {
- global $a;
-
- if (empty($a)) {
- $a = new App(dirname(__DIR__));
- }
-
- @include(".htconfig.php");
- require_once("dba.php");
- dba::connect($db_host, $db_user, $db_pass, $db_data);
- unset($db_host, $db_user, $db_pass, $db_data);
-
- require_once('include/session.php');
-
- Config::load();
-
- $a->set_baseurl(Config::get('system','url'));
-
- load_hooks();
-}
<?php
-use Friendica\App;
use Friendica\Core\System;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
require_once 'include/contact_selectors.php';
}
function findpeople_widget() {
- require_once 'include/Contact.php';
-
$a = get_app();
$global_dir = Config::get('system', 'directory');
return;
}
- require_once 'include/socgraph.php';
-
if ($cid) {
- $t = count_common_friends($profile_uid, $cid);
+ $t = GlobalContact::countCommonFriends($profile_uid, $cid);
} else {
- $t = count_common_friends_zcid($profile_uid, $zcid);
+ $t = GlobalContact::countCommonFriendsZcid($profile_uid, $zcid);
}
if (! $t) {
return;
}
if ($cid) {
- $r = common_friends($profile_uid, $cid, 0, 5, true);
+ $r = GlobalContact::commonFriends($profile_uid, $cid, 0, 5, true);
} else {
- $r = common_friends_zcid($profile_uid, $zcid, 0, 5, true);
+ $r = GlobalContact::commonFriendsZcid($profile_uid, $zcid, 0, 5, true);
}
return replace_macros(get_markup_template('remote_friends_common.tpl'), array(
- '$desc' => sprintf( tt("%d contact in common", "%d contacts in common", $t), $t),
+ '$desc' => sprintf(tt("%d contact in common", "%d contacts in common", $t), $t),
'$base' => System::baseUrl(),
'$uid' => $profile_uid,
'$cid' => (($cid) ? $cid : '0'),
'$linkmore' => (($t > 5) ? 'true' : ''),
'$more' => t('show more'),
- '$items' => $r
- ));
-
-};
+ '$items' => $r)
+ );
+}
<?php
-
+/**
+ * @file include/conversation.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
+use Friendica\Object\Conversation;
+use Friendica\Object\Item;
require_once "include/bbcode.php";
require_once "include/acl_selectors.php";
function conversation(App $a, $items, $mode, $update, $preview = false) {
require_once 'include/bbcode.php';
- require_once 'include/Contact.php';
require_once 'mod/proxy.php';
$ssl_state = ((local_user()) ? true : false);
}
if (!x($item, 'author-thumb') || ($item['author-thumb'] == "")) {
- $author_contact = get_contact_details_by_url($item['author-link'], $profile_owner);
+ $author_contact = Contact::getDetailsByURL($item['author-link'], $profile_owner);
if ($author_contact["thumb"]) {
$item['author-thumb'] = $author_contact["thumb"];
} else {
}
if (!isset($item['owner-thumb']) || ($item['owner-thumb'] == "")) {
- $owner_contact = get_contact_details_by_url($item['owner-link'], $profile_owner);
+ $owner_contact = Contact::getDetailsByURL($item['owner-link'], $profile_owner);
if ($owner_contact["thumb"]) {
$item['owner-thumb'] = $owner_contact["thumb"];
} else {
list($categories, $folders) = get_cats_and_terms($item);
- if ($a->theme['template_engine'] === 'internal') {
- $profile_name_e = template_escape($profile_name);
- $item['title_e'] = template_escape($item['title']);
- $body_e = template_escape($body);
- $tags_e = template_escape($tags);
- $hashtags_e = template_escape($hashtags);
- $mentions_e = template_escape($mentions);
- $location_e = template_escape($location);
- $owner_name_e = template_escape($owner_name);
- } else {
- $profile_name_e = $profile_name;
- $item['title_e'] = $item['title'];
- $body_e = $body;
- $tags_e = $tags;
- $hashtags_e = $hashtags;
- $mentions_e = $mentions;
- $location_e = $location;
- $owner_name_e = $owner_name;
- }
+ $profile_name_e = $profile_name;
+ $item['title_e'] = $item['title'];
+ $body_e = $body;
+ $tags_e = $tags;
+ $hashtags_e = $hashtags;
+ $mentions_e = $mentions;
+ $location_e = $location;
+ $owner_name_e = $owner_name;
if ($item['item_network'] == "") {
$item['item_network'] = $item['network'];
// Normal View
$page_template = get_markup_template("threaded_conversation.tpl");
- require_once 'object/Conversation.php';
- require_once 'object/Item.php';
-
$conv = new Conversation($mode, $preview);
/*
if ($item['id'] == $item['parent']) {
$item_object = new Item($item);
- $conv->add_thread($item_object);
+ $conv->addThread($item_object);
}
}
- $threads = $conv->get_template_data($conv_responses);
+ $threads = $conv->getTemplateData($conv_responses);
if (!$threads) {
logger('[ERROR] conversation : Failed to get template data.', LOGGER_DEBUG);
return $o;
}
-
-function get_item_children($arr, $parent) {
- $children = array();
- $a = get_app();
- foreach ($arr as $item) {
+/**
+ * Plucks the children of the given parent from a given item list.
+ *
+ * @brief Plucks all the children in the given item list of the given parent
+ *
+ * @param array $item_list
+ * @param array $parent
+ * @param bool $recursive
+ * @return type
+ */
+function get_item_children(array &$item_list, array $parent, $recursive = true)
+{
+ $children = [];
+ foreach ($item_list as $i => $item) {
if ($item['id'] != $item['parent']) {
- if (Config::get('system', 'thread_allow') && $a->theme_thread_allow) {
+ if ($recursive) {
// Fallback to parent-uri if thr-parent is not set
$thr_parent = $item['thr-parent'];
if ($thr_parent == '') {
}
if ($thr_parent == $parent['uri']) {
- $item['children'] = get_item_children($arr, $item);
+ $item['children'] = get_item_children($item_list, $item);
$children[] = $item;
+ unset($item_list[$i]);
}
} elseif ($item['parent'] == $parent['id']) {
$children[] = $item;
+ unset($item_list[$i]);
}
}
}
return $children;
}
-/// @TODO Add type-hint
-function sort_item_children($items) {
+/**
+ * @brief Recursively sorts a tree-like item array
+ *
+ * @param array $items
+ * @return array
+ */
+function sort_item_children(array $items)
+{
$result = $items;
usort($result, 'sort_thr_created_rev');
foreach ($result as $k => $i) {
- if (count($result[$k]['children'])) {
+ if (isset($result[$k]['children'])) {
$result[$k]['children'] = sort_item_children($result[$k]['children']);
}
}
return $result;
}
-/// @TODO Add type-hint
-function add_children_to_list($children, &$arr) {
- foreach ($children as $y) {
- $arr[] = $y;
- if (count($y['children'])) {
- add_children_to_list($y['children'], $arr);
+/**
+ * @brief Recursively add all children items at the top level of a list
+ *
+ * @param array $children List of items to append
+ * @param array $item_list
+ */
+function add_children_to_list(array $children, array &$item_list)
+{
+ foreach ($children as $child) {
+ $item_list[] = $child;
+ if (isset($child['children'])) {
+ add_children_to_list($child['children'], $item_list);
}
}
}
-/// @TODO Add type-hint
-function conv_sort($arr, $order) {
-
- if ((!(is_array($arr) && count($arr)))) {
- return array();
+/**
+ * This recursive function takes the item tree structure created by conv_sort() and
+ * flatten the extraneous depth levels when people reply sequentially, removing the
+ * stairs effect in threaded conversations limiting the available content width.
+ *
+ * The basic principle is the following: if a post item has only one reply and is
+ * the last reply of its parent, then the reply is moved to the parent.
+ *
+ * This process is rendered somewhat more complicated because items can be either
+ * replies or likes, and these don't factor at all in the reply count/last reply.
+ *
+ * @brief Selectively flattens a tree-like item structure to prevent threading stairs
+ *
+ * @param array $parent A tree-like array of items
+ * @return array
+ */
+function smart_flatten_conversation(array $parent)
+{
+ if (! isset($parent['children']) || count($parent['children']) == 0) {
+ return $parent;
}
- $parents = array();
- $children = array();
- $newarr = array();
+ // We use a for loop to ensure we process the newly-moved items
+ for ($i = 0; $i < count($parent['children']); $i++) {
+ $child = $parent['children'][$i];
- /*
- * This is a preparation for having two different items with the same uri in one thread
- * This will otherwise lead to an endless loop.
- */
- foreach ($arr as $x) {
- if (!isset($newarr[$x['uri']])) {
- $newarr[$x['uri']] = $x;
+ if (isset($child['children']) && count($child['children'])) {
+ // This helps counting only the regular posts
+ $count_post_closure = function($var) {
+ return $var['verb'] === ACTIVITY_POST;
+ };
+
+ $child_post_count = count(array_filter($child['children'], $count_post_closure));
+
+ $remaining_post_count = count(array_filter(array_slice($parent['children'], $i), $count_post_closure));
+
+ // If there's only one child's children post and this is the last child post
+ if ($child_post_count == 1 && $remaining_post_count == 1) {
+
+ // Searches the post item in the children
+ $j = 0;
+ while($child['children'][$j]['verb'] !== ACTIVITY_POST && $j < count($child['children'])) {
+ $j ++;
+ }
+
+ $moved_item = $child['children'][$j];
+ unset($parent['children'][$i]['children'][$j]);
+ $parent['children'][] = $moved_item;
+ } else {
+ $parent['children'][$i] = smart_flatten_conversation($child);
+ }
}
}
- $arr = $newarr;
+ return $parent;
+}
+
+
+/**
+ * Expands a flat list of items into corresponding tree-like conversation structures,
+ * sort the top-level posts either on "created" or "commented", and finally
+ * append all the items at the top level (???)
+ *
+ * @brief Expands a flat item list into a conversation array for display
+ *
+ * @param array $item_list A list of items belonging to one or more conversations
+ * @param string $order Either on "created" or "commented"
+ * @return array
+ */
+function conv_sort(array $item_list, $order)
+{
+ $parents = [];
+
+ if (!(is_array($item_list) && count($item_list))) {
+ return $parents;
+ }
+
+ $item_array = [];
- foreach ($arr as $x) {
- if ($x['id'] == $x['parent']) {
- $parents[] = $x;
+ // Dedupes the item list on the uri to prevent infinite loops
+ foreach ($item_list as $item) {
+ $item_array[$item['uri']] = $item;
+ }
+
+ // Extract the top level items
+ foreach ($item_array as $item) {
+ if ($item['id'] == $item['parent']) {
+ $parents[] = $item;
}
}
usort($parents, 'sort_thr_commented');
}
- if (count($parents)) {
- foreach ($parents as $i => $_x) {
- $parents[$i]['children'] = get_item_children($arr, $_x);
- }
+ /*
+ * Plucks children from the item_array, second pass collects eventual orphan
+ * items and add them as children of their top-level post.
+ */
+ foreach ($parents as $i => $parent) {
+ $parents[$i]['children'] =
+ array_merge(get_item_children($item_array, $parent, true),
+ get_item_children($item_array, $parent, false));
}
- /// @TODO Old-lost code?
- /*foreach ($arr as $x) {
- if ($x['id'] != $x['parent']) {
- $p = find_thread_parent_index($parents,$x);
- if ($p !== false)
- $parents[$p]['children'][] = $x;
- }
- }*/
- if (count($parents)) {
- foreach ($parents as $k => $v) {
- if (count($parents[$k]['children'])) {
- $parents[$k]['children'] = sort_item_children($parents[$k]['children']);
- /// @TODO Old-lost code?
- /*$y = $parents[$k]['children'];
- usort($y,'sort_thr_created_rev');
- $parents[$k]['children'] = $y;*/
- }
+ foreach ($parents as $i => $parent) {
+ $parents[$i]['children'] = sort_item_children($parents[$i]['children']);
+ }
+
+ if (PConfig::get(local_user(), 'system', 'smart_threading', 0)) {
+ foreach ($parents as $i => $parent) {
+ $parents[$i] = smart_flatten_conversation($parent);
}
}
- $ret = array();
- if (count($parents)) {
- foreach ($parents as $x) {
- $ret[] = $x;
- if (count($x['children'])) {
- add_children_to_list($x['children'], $ret);
- /// @TODO Old-lost code?
- /*foreach ($x['children'] as $y)
- $ret[] = $y;*/
- }
+ /// @TODO: Stop recusrsively adding all children back to the top level (!!!)
+ /// However, this apparently ensures responses (likes, attendance) display (?!)
+ foreach ($parents as $parent) {
+ if (count($parent['children'])) {
+ add_children_to_list($parent['children'], $parents);
}
}
- return $ret;
+ return $parents;
}
-/// @TODO Add type-hint
-function sort_thr_created($a, $b) {
+/**
+ * @brief usort() callback to sort item arrays by the created key
+ *
+ * @param array $a
+ * @param array $b
+ * @return int
+ */
+function sort_thr_created(array $a, array $b)
+{
return strcmp($b['created'], $a['created']);
}
-/// @TODO Add type-hint
-function sort_thr_created_rev($a, $b) {
+/**
+ * @brief usort() callback to reverse sort item arrays by the created key
+ *
+ * @param array $a
+ * @param array $b
+ * @return int
+ */
+function sort_thr_created_rev(array $a, array $b)
+{
return strcmp($a['created'], $b['created']);
}
-/// @TODO Add type-hint
-function sort_thr_commented($a, $b) {
+/**
+ * @brief usort() callback to sort item arrays by the commented key
+ *
+ * @param array $a
+ * @param array $b
+ * @return type
+ */
+function sort_thr_commented(array $a, array $b)
+{
return strcmp($b['commented'], $a['commented']);
}
-/// @TODO Add type-hint
-function find_thread_parent_index($arr, $x) {
- foreach ($arr as $k => $v) {
- if ($v['id'] == $x['parent']) {
- return $k;
- }
- }
- return false;
-}
-
/// @TODO Add type-hint
function render_location_dummy($item) {
if ($item['location'] != "") {
if (count($ret[$v]['list']) > MAX_LIKERS) {
$ret[$v]['list_part'] = array_slice($ret[$v]['list'], 0, MAX_LIKERS);
array_push($ret[$v]['list_part'], '<a href="#" data-toggle="modal" data-target="#' . $v . 'Modal-'
- . (($ob) ? $ob->get_id() : $item['id']) . '"><b>' . t('View all') . '</b></a>');
+ . (($ob) ? $ob->getId() : $item['id']) . '"><b>' . t('View all') . '</b></a>');
} else {
$ret[$v]['list_part'] = '';
}
+++ /dev/null
-<?php
-/**
- * @file include/create_shadowentry.php
- * @brief This script creates posts with UID = 0 for a given public post.
- *
- * This script is started from mod/item.php to save some time when doing a post.
- */
-
-require_once("include/threads.php");
-
-function create_shadowentry_run($argv, $argc) {
- if ($argc != 2) {
- return;
- }
-
- $message_id = intval($argv[1]);
-
- add_shadow_entry($message_id);
-}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-
-function cron_run(&$argv, &$argc){
- global $a;
-
- require_once 'include/datetime.php';
-
- // Poll contacts with specific parameters
- if ($argc > 1) {
- cron_poll_contacts($argc, $argv);
- return;
- }
-
- $last = Config::get('system', 'last_cron');
-
- $poll_interval = intval(Config::get('system', 'cron_interval'));
- if (! $poll_interval) {
- $poll_interval = 10;
- }
-
- if ($last) {
- $next = $last + ($poll_interval * 60);
- if ($next > time()) {
- logger('cron intervall not reached');
- return;
- }
- }
-
- logger('cron: start');
-
- // run queue delivery process in the background
- Worker::add(PRIORITY_NEGLIGIBLE, "queue");
-
- // run the process to discover global contacts in the background
- Worker::add(PRIORITY_LOW, "discover_poco");
-
- // run the process to update locally stored global contacts in the background
- Worker::add(PRIORITY_LOW, "discover_poco", "checkcontact");
-
- // Expire and remove user entries
- Worker::add(PRIORITY_MEDIUM, "cronjobs", "expire_and_remove_users");
-
- // Call possible post update functions
- Worker::add(PRIORITY_LOW, "cronjobs", "post_update");
-
- // update nodeinfo data
- Worker::add(PRIORITY_LOW, "cronjobs", "nodeinfo");
-
- // Clear cache entries
- Worker::add(PRIORITY_LOW, "cronjobs", "clear_cache");
-
- // Repair missing Diaspora values in contacts
- Worker::add(PRIORITY_LOW, "cronjobs", "repair_diaspora");
-
- // Repair entries in the database
- Worker::add(PRIORITY_LOW, "cronjobs", "repair_database");
-
- // once daily run birthday_updates and then expire in background
- $d1 = Config::get('system', 'last_expire_day');
- $d2 = intval(datetime_convert('UTC', 'UTC', 'now', 'd'));
-
- if ($d2 != intval($d1)) {
-
- Worker::add(PRIORITY_LOW, "cronjobs", "update_contact_birthdays");
-
- Worker::add(PRIORITY_LOW, "discover_poco", "update_server");
-
- Worker::add(PRIORITY_LOW, "discover_poco", "suggestions");
-
- Config::set('system', 'last_expire_day', $d2);
-
- Worker::add(PRIORITY_LOW, 'expire');
-
- Worker::add(PRIORITY_MEDIUM, 'dbclean');
-
- Worker::add(PRIORITY_LOW, "cronjobs", "update_photo_albums");
-
- // Delete all done workerqueue entries
- dba::delete('workerqueue', array('`done` AND `executed` < UTC_TIMESTAMP() - INTERVAL 12 HOUR'));
-
- // check upstream version?
- Worker::add(PRIORITY_LOW, 'checkversion');
- }
-
- // Poll contacts
- cron_poll_contacts($argc, $argv);
-
- logger('cron: end');
-
- Config::set('system', 'last_cron', time());
-
- return;
-}
-
-/**
- * @brief Poll contacts for unreceived messages
- *
- * @param Integer $argc Number of command line arguments
- * @param Array $argv Array of command line arguments
- */
-function cron_poll_contacts($argc, $argv) {
- $manual_id = 0;
- $generation = 0;
- $force = false;
- $restart = false;
-
- if (($argc > 1) && ($argv[1] == 'force')) {
- $force = true;
- }
- if (($argc > 1) && ($argv[1] == 'restart')) {
- $restart = true;
- $generation = intval($argv[2]);
- if (!$generation) {
- killme();
- }
- }
-
- if (($argc > 1) && intval($argv[1])) {
- $manual_id = intval($argv[1]);
- $force = true;
- }
-
- $min_poll_interval = Config::get('system', 'min_poll_interval', 1);
-
- $sql_extra = (($manual_id) ? " AND `id` = $manual_id " : "");
-
- reload_plugins();
-
- $d = datetime_convert();
-
- // Only poll from those with suitable relationships,
- // and which have a polling address and ignore Diaspora since
- // we are unable to match those posts with a Diaspora GUID and prevent duplicates.
-
- $abandon_days = intval(Config::get('system', 'account_abandon_days'));
- if ($abandon_days < 1) {
- $abandon_days = 0;
- }
- $abandon_sql = (($abandon_days)
- ? sprintf(" AND `user`.`login_date` > UTC_TIMESTAMP() - INTERVAL %d DAY ", intval($abandon_days))
- : ''
- );
-
- $contacts = q("SELECT `contact`.`id` FROM `user`
- STRAIGHT_JOIN `contact`
- ON `contact`.`uid` = `user`.`uid` AND `contact`.`rel` IN (%d, %d) AND `contact`.`poll` != ''
- AND `contact`.`network` IN ('%s', '%s', '%s', '%s', '%s', '%s') $sql_extra
- AND NOT `contact`.`self` AND NOT `contact`.`blocked` AND NOT `contact`.`readonly`
- AND NOT `contact`.`archive`
- WHERE NOT `user`.`account_expired` AND NOT `user`.`account_removed` $abandon_sql ORDER BY RAND()",
- intval(CONTACT_IS_SHARING),
- intval(CONTACT_IS_FRIEND),
- dbesc(NETWORK_DFRN),
- dbesc(NETWORK_ZOT),
- dbesc(NETWORK_OSTATUS),
- dbesc(NETWORK_FEED),
- dbesc(NETWORK_MAIL),
- dbesc(NETWORK_MAIL2)
- );
-
- if (!DBM::is_result($contacts)) {
- return;
- }
-
- foreach ($contacts as $c) {
-
- $res = q("SELECT * FROM `contact` WHERE `id` = %d LIMIT 1",
- intval($c['id'])
- );
-
- if (!DBM::is_result($res)) {
- continue;
- }
-
- foreach ($res as $contact) {
-
- $xml = false;
-
- if ($manual_id) {
- $contact['last-update'] = NULL_DATE;
- }
-
- if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
- $contact['priority'] = 2;
- }
-
- if ($contact['subhub'] && in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
- /*
- * We should be getting everything via a hub. But just to be sure, let's check once a day.
- * (You can make this more or less frequent if desired by setting 'pushpoll_frequency' appropriately)
- * This also lets us update our subscription to the hub, and add or replace hubs in case it
- * changed. We will only update hubs once a day, regardless of 'pushpoll_frequency'.
- */
- $poll_interval = Config::get('system', 'pushpoll_frequency');
- $contact['priority'] = (($poll_interval !== false) ? intval($poll_interval) : 3);
- }
-
- if (($contact['priority'] >= 0) && !$force) {
- $update = false;
-
- $t = $contact['last-update'];
-
- /*
- * Based on $contact['priority'], should we poll this site now? Or later?
- */
- switch ($contact['priority']) {
- case 5:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 month")) {
- $update = true;
- }
- break;
- case 4:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 week")) {
- $update = true;
- }
- break;
- case 3:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day")) {
- $update = true;
- }
- break;
- case 2:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 12 hour")) {
- $update = true;
- }
- break;
- case 1:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 hour")) {
- $update = true;
- }
- break;
- case 0:
- default:
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + ".$min_poll_interval." minute")) {
- $update = true;
- }
- break;
- }
- if (!$update) {
- continue;
- }
- }
-
- logger("Polling " . $contact["network"] . " " . $contact["id"] . " " . $contact["nick"] . " " . $contact["name"]);
-
- if (($contact['network'] == NETWORK_FEED) && ($contact['priority'] <= 3)) {
- $priority = PRIORITY_MEDIUM;
- } else {
- $priority = PRIORITY_LOW;
- }
- Worker::add(array('priority' => $priority, 'dont_fork' => true), 'onepoll', (int)$contact['id']);
- }
- }
-}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-
-function cronhooks_run(&$argv, &$argc) {
- global $a;
-
- require_once 'include/datetime.php';
-
- if (($argc == 2) && is_array($a->hooks) && array_key_exists("cron", $a->hooks)) {
- foreach ($a->hooks["cron"] as $hook) {
- if ($hook[1] == $argv[1]) {
- logger("Calling cron hook '" . $hook[1] . "'", LOGGER_DEBUG);
- call_single_hook($a, $name, $hook, $data);
- }
- }
- return;
- }
-
- $last = Config::get('system', 'last_cronhook');
-
- $poll_interval = intval(Config::get('system', 'cronhook_interval'));
- if (! $poll_interval) {
- $poll_interval = 9;
- }
-
- if ($last) {
- $next = $last + ($poll_interval * 60);
- if ($next > time()) {
- logger('cronhook intervall not reached');
- return;
- }
- }
-
- $a->set_baseurl(Config::get('system', 'url'));
-
- logger('cronhooks: start');
-
- $d = datetime_convert();
-
- if (is_array($a->hooks) && array_key_exists("cron", $a->hooks)) {
- foreach ($a->hooks["cron"] as $hook) {
- logger("Calling cronhooks for '" . $hook[1] . "'", LOGGER_DEBUG);
- Worker::add(PRIORITY_MEDIUM, "cronhooks", $hook[1]);
- }
- }
-
- logger('cronhooks: end');
-
- Config::set('system', 'last_cronhook', time());
-
- return;
-}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\Cache;
-use Friendica\Core\Config;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-
-function cronjobs_run(&$argv, &$argc){
- global $a;
-
- require_once 'include/datetime.php';
- require_once 'include/post_update.php';
- require_once 'mod/nodeinfo.php';
- require_once 'include/photos.php';
- require_once 'include/user.php';
- require_once 'include/socgraph.php';
-
- // No parameter set? So return
- if ($argc <= 1) {
- return;
- }
-
- logger("Starting cronjob ".$argv[1], LOGGER_DEBUG);
-
- // Call possible post update functions
- // see include/post_update.php for more details
- if ($argv[1] == 'post_update') {
- post_update();
- return;
- }
-
- // update nodeinfo data
- if ($argv[1] == 'nodeinfo') {
- nodeinfo_cron();
- return;
- }
-
- // Expire and remove user entries
- if ($argv[1] == 'expire_and_remove_users') {
- cron_expire_and_remove_users();
- return;
- }
-
- if ($argv[1] == 'update_contact_birthdays') {
- update_contact_birthdays();
- return;
- }
-
- if ($argv[1] == 'update_photo_albums') {
- cron_update_photo_albums();
- return;
- }
-
- // Clear cache entries
- if ($argv[1] == 'clear_cache') {
- cron_clear_cache($a);
- return;
- }
-
- // Repair missing Diaspora values in contacts
- if ($argv[1] == 'repair_diaspora') {
- cron_repair_diaspora($a);
- return;
- }
-
- // Repair entries in the database
- if ($argv[1] == 'repair_database') {
- cron_repair_database();
- return;
- }
-
- logger("Xronjob ".$argv[1]." is unknown.", LOGGER_DEBUG);
-
- return;
-}
-
-/**
- * @brief Update the cached values for the number of photo albums per user
- */
-function cron_update_photo_albums() {
- $r = q("SELECT `uid` FROM `user` WHERE NOT `account_expired` AND NOT `account_removed`");
- if (!DBM::is_result($r)) {
- return;
- }
-
- foreach ($r AS $user) {
- photo_albums($user['uid'], true);
- }
-}
-
-/**
- * @brief Expire and remove user entries
- */
-function cron_expire_and_remove_users() {
- // expire any expired accounts
- q("UPDATE user SET `account_expired` = 1 where `account_expired` = 0
- AND `account_expires_on` > '%s'
- AND `account_expires_on` < UTC_TIMESTAMP()", dbesc(NULL_DATE));
-
- // delete user records for recently removed accounts
- $r = q("SELECT * FROM `user` WHERE `account_removed` AND `account_expires_on` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
- if (DBM::is_result($r)) {
- foreach ($r as $user) {
- dba::delete('user', array('uid' => $user['uid']));
- }
- }
-}
-
-/**
- * @brief Clear cache entries
- *
- * @param App $a
- */
-function cron_clear_cache(App $a) {
-
- $last = Config::get('system','cache_last_cleared');
-
- if ($last) {
- $next = $last + (3600); // Once per hour
- $clear_cache = ($next <= time());
- } else {
- $clear_cache = true;
- }
-
- if (!$clear_cache) {
- return;
- }
-
- // clear old cache
- Cache::clear();
-
- // clear old item cache files
- clear_cache();
-
- // clear cache for photos
- clear_cache($a->get_basepath(), $a->get_basepath()."/photo");
-
- // clear smarty cache
- clear_cache($a->get_basepath()."/view/smarty3/compiled", $a->get_basepath()."/view/smarty3/compiled");
-
- // clear cache for image proxy
- if (!Config::get("system", "proxy_disabled")) {
- clear_cache($a->get_basepath(), $a->get_basepath()."/proxy");
-
- $cachetime = Config::get('system','proxy_cache_time');
- if (!$cachetime) {
- $cachetime = PROXY_DEFAULT_TIME;
- }
- q('DELETE FROM `photo` WHERE `uid` = 0 AND `resource-id` LIKE "pic:%%" AND `created` < NOW() - INTERVAL %d SECOND', $cachetime);
- }
-
- // Delete the cached OEmbed entries that are older than one year
- q("DELETE FROM `oembed` WHERE `created` < NOW() - INTERVAL 3 MONTH");
-
- // Delete the cached "parse_url" entries that are older than one year
- q("DELETE FROM `parsed_url` WHERE `created` < NOW() - INTERVAL 3 MONTH");
-
- // Maximum table size in megabyte
- $max_tablesize = intval(Config::get('system','optimize_max_tablesize')) * 1000000;
- if ($max_tablesize == 0) {
- $max_tablesize = 100 * 1000000; // Default are 100 MB
- }
- if ($max_tablesize > 0) {
- // Minimum fragmentation level in percent
- $fragmentation_level = intval(Config::get('system','optimize_fragmentation')) / 100;
- if ($fragmentation_level == 0) {
- $fragmentation_level = 0.3; // Default value is 30%
- }
-
- // Optimize some tables that need to be optimized
- $r = q("SHOW TABLE STATUS");
- foreach ($r as $table) {
-
- // Don't optimize tables that are too large
- if ($table["Data_length"] > $max_tablesize) {
- continue;
- }
-
- // Don't optimize empty tables
- if ($table["Data_length"] == 0) {
- continue;
- }
-
- // Calculate fragmentation
- $fragmentation = $table["Data_free"] / ($table["Data_length"] + $table["Index_length"]);
-
- logger("Table ".$table["Name"]." - Fragmentation level: ".round($fragmentation * 100, 2), LOGGER_DEBUG);
-
- // Don't optimize tables that needn't to be optimized
- if ($fragmentation < $fragmentation_level) {
- continue;
- }
-
- // So optimize it
- logger("Optimize Table ".$table["Name"], LOGGER_DEBUG);
- q("OPTIMIZE TABLE `%s`", dbesc($table["Name"]));
- }
- }
-
- Config::set('system','cache_last_cleared', time());
-}
-
-/**
- * @brief Repair missing values in Diaspora contacts
- *
- * @param App $a
- */
-function cron_repair_diaspora(App $a) {
-
- $starttime = time();
-
- $r = q("SELECT `id`, `url` FROM `contact`
- WHERE `network` = '%s' AND (`batch` = '' OR `notify` = '' OR `poll` = '' OR pubkey = '')
- ORDER BY RAND() LIMIT 50", dbesc(NETWORK_DIASPORA));
- if (!DBM::is_result($r)) {
- return;
- }
-
- foreach ($r AS $contact) {
- // Quit the loop after 3 minutes
- if (time() > ($starttime + 180)) {
- return;
- }
-
- if (!poco_reachable($contact["url"])) {
- continue;
- }
-
- $data = Probe::uri($contact["url"]);
- if ($data["network"] != NETWORK_DIASPORA) {
- continue;
- }
-
- logger("Repair contact ".$contact["id"]." ".$contact["url"], LOGGER_DEBUG);
- q("UPDATE `contact` SET `batch` = '%s', `notify` = '%s', `poll` = '%s', pubkey = '%s' WHERE `id` = %d",
- dbesc($data["batch"]), dbesc($data["notify"]), dbesc($data["poll"]), dbesc($data["pubkey"]),
- intval($contact["id"]));
- }
-}
-
-/**
- * @brief Do some repairs in database entries
- *
- */
-function cron_repair_database() {
-
- // Sometimes there seem to be issues where the "self" contact vanishes.
- // We haven't found the origin of the problem by now.
- $r = q("SELECT `uid` FROM `user` WHERE NOT EXISTS (SELECT `uid` FROM `contact` WHERE `contact`.`uid` = `user`.`uid` AND `contact`.`self`)");
- if (DBM::is_result($r)) {
- foreach ($r AS $user) {
- logger('Create missing self contact for user '.$user['uid']);
- user_create_self_contact($user['uid']);
- }
- }
-
- // Set the parent if it wasn't set. (Shouldn't happen - but does sometimes)
- // This call is very "cheap" so we can do it at any time without a problem
- q("UPDATE `item` INNER JOIN `item` AS `parent` ON `parent`.`uri` = `item`.`parent-uri` AND `parent`.`uid` = `item`.`uid` SET `item`.`parent` = `parent`.`id` WHERE `item`.`parent` = 0");
-
- // There was an issue where the nick vanishes from the contact table
- q("UPDATE `contact` INNER JOIN `user` ON `contact`.`uid` = `user`.`uid` SET `nick` = `nickname` WHERE `self` AND `nick`=''");
-
- // Update the global contacts for local users
- $r = q("SELECT `uid` FROM `user` WHERE `verified` AND NOT `blocked` AND NOT `account_removed` AND NOT `account_expired`");
- if (DBM::is_result($r)) {
- foreach ($r AS $user) {
- update_gcontact_for_user($user["uid"]);
- }
- }
-
- /// @todo
- /// - remove thread entries without item
- /// - remove sign entries without item
- /// - remove children when parent got lost
- /// - set contact-id in item when not present
-}
}
}
- if (!self::$connected && function_exists('mysql_connect')) {
- self::$driver = 'mysql';
- self::$db = mysql_connect($serveraddr, $user, $pass);
- if (self::$db && mysql_select_db($db, self::$db)) {
- self::$connected = true;
-
- if (isset($a->config["system"]["db_charset"])) {
- mysql_set_charset($a->config["system"]["db_charset"], self::$db);
- }
- }
- }
-
// No suitable SQL driver was found.
if (!self::$connected) {
self::$db = null;
case 'mysqli':
self::$_server_info = self::$db->server_info;
break;
- case 'mysql':
- self::$_server_info = mysql_get_server_info(self::$db);
- break;
}
}
return self::$_server_info;
return substr(@self::$db->quote($str, PDO::PARAM_STR), 1, -1);
case 'mysqli':
return @self::$db->real_escape_string($str);
- case 'mysql':
- return @mysql_real_escape_string($str,self::$db);
}
}
case 'mysqli':
$connected = self::$db->ping();
break;
- case 'mysql':
- $connected = mysql_ping(self::$db);
- break;
}
return $connected;
}
self::$affected_rows = $retval->affected_rows;
}
break;
- case 'mysql':
- // For the old "mysql" functions we cannot use prepared statements
- $retval = mysql_query(self::replace_parameters($sql, $args), self::$db);
- if (mysql_errno(self::$db)) {
- self::$error = mysql_error(self::$db);
- self::$errorno = mysql_errno(self::$db);
- } else {
- self::$affected_rows = mysql_affected_rows($retval);
-
- // Due to missing mysql_* support this here wasn't tested at all
- // See here: http://php.net/manual/en/function.mysql-num-rows.php
- if (self::$affected_rows <= 0) {
- self::$affected_rows = mysql_num_rows($retval);
- }
- }
- break;
}
// We are having an own error logging in the function "e"
return $stmt->columnCount();
case 'mysqli':
return $stmt->field_count;
- case 'mysql':
- return mysql_affected_rows($stmt);
}
return 0;
}
return $stmt->rowCount();
case 'mysqli':
return $stmt->num_rows;
- case 'mysql':
- return mysql_num_rows($stmt);
}
return 0;
}
$columns[$fields[$param]->name] = $col;
}
return $columns;
- case 'mysql':
- return mysql_fetch_array($stmt, MYSQL_ASSOC);
}
}
* @return boolean was the insert successfull?
*/
public static function insert($table, $param, $on_duplicate_update = false) {
+
+ if (empty($table) || empty($param)) {
+ logger('Table and fields have to be set');
+ return false;
+ }
+
$sql = "INSERT INTO `".self::escape($table)."` (`".implode("`, `", array_keys($param))."`) VALUES (".
substr(str_repeat("?, ", count($param)), 0, -2).")";
case 'mysqli':
$id = self::$db->insert_id;
break;
- case 'mysql':
- $id = mysql_insert_id(self::$db);
- break;
}
return $id;
}
* @return boolean|array was the delete successfull? When $in_process is set: deletion data
*/
public static function delete($table, $param, $in_process = false, &$callstack = array()) {
+
+ if (empty($table) || empty($param)) {
+ logger('Table and condition have to be set');
+ return false;
+ }
+
$commands = array();
// Create a key for the loop prevention
* @return boolean was the update successfull?
*/
public static function update($table, $fields, $condition, $old_fields = array()) {
+
+ if (empty($table) || empty($fields) || empty($condition)) {
+ logger('Table, fields and condition have to be set');
+ return false;
+ }
+
$table = self::escape($table);
- if (count($condition) > 0) {
- $array_element = each($condition);
- $array_key = $array_element['key'];
- if (is_int($array_key)) {
- $condition_string = " WHERE ".array_shift($condition);
- } else {
- $condition_string = " WHERE `".implode("` = ? AND `", array_keys($condition))."` = ?";
- }
+ $array_element = each($condition);
+ $array_key = $array_element['key'];
+ if (is_int($array_key)) {
+ $condition_string = " WHERE ".array_shift($condition);
} else {
- $condition_string = "";
+ $condition_string = " WHERE `".implode("` = ? AND `", array_keys($condition))."` = ?";
}
if (is_bool($old_fields)) {
case 'pdo':
return $stmt->closeCursor();
case 'mysqli':
- return $stmt->free_result();
+ $stmt->free_result();
return $stmt->close();
- case 'mysql':
- return mysql_free_result($stmt);
}
}
}
+++ /dev/null
-<?php
-/**
- * @file include/dbclean.php
- * @brief The script is called from time to time to clean the database entries and remove orphaned data.
- */
-
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-
-function dbclean_run(&$argv, &$argc) {
- if (!Config::get('system', 'dbclean', false)) {
- return;
- }
-
- if ($argc == 2) {
- $stage = intval($argv[1]);
- } else {
- $stage = 0;
- }
-
- // Get the expire days for step 8 and 9
- $days = Config::get('system', 'dbclean-expire-days', 0);
-
- if ($stage == 0) {
- for ($i = 1; $i <= 9; $i++) {
- // Execute the background script for a step when it isn't finished.
- // Execute step 8 and 9 only when $days is defined.
- if (!Config::get('system', 'finished-dbclean-'.$i, false) && (($i < 8) || ($days > 0))) {
- Worker::add(PRIORITY_LOW, 'dbclean', $i);
- }
- }
- } else {
- remove_orphans($stage);
- }
-}
-
-/**
- * @brief Remove orphaned database entries
- * @param integer $stage What should be deleted?
- *
- * Values for $stage:
- * ------------------
- * 1: Old global item entries from item table without user copy.
- * 2: Items without parents.
- * 3: Orphaned data from thread table.
- * 4: Orphaned data from notify table.
- * 5: Orphaned data from notify-threads table.
- * 6: Orphaned data from sign table.
- * 7: Orphaned data from term table.
- * 8: Expired threads.
- * 9: Old global item entries from expired threads
- */
-function remove_orphans($stage = 0) {
- global $db;
-
- $count = 0;
-
- // We split the deletion in many small tasks
- $limit = 1000;
-
- // Get the expire days for step 8 and 9
- $days = Config::get('system', 'dbclean-expire-days', 0);
-
- if ($stage == 1) {
- $last_id = Config::get('system', 'dbclean-last-id-1', 0);
-
- logger("Deleting old global item entries from item table without user copy. Last ID: ".$last_id);
- $r = dba::p("SELECT `id` FROM `item` WHERE `uid` = 0 AND
- NOT EXISTS (SELECT `guid` FROM `item` AS `i` WHERE `item`.`guid` = `i`.`guid` AND `i`.`uid` != 0) AND
- `received` < UTC_TIMESTAMP() - INTERVAL 90 DAY AND `id` >= ?
- ORDER BY `id` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found global item orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('item', array('id' => $orphan["id"]));
- }
- } else {
- logger("No global item orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." old global item entries from item table without user copy. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-1', $last_id);
- } elseif ($stage == 2) {
- $last_id = Config::get('system', 'dbclean-last-id-2', 0);
-
- logger("Deleting items without parents. Last ID: ".$last_id);
- $r = dba::p("SELECT `id` FROM `item`
- WHERE NOT EXISTS (SELECT `id` FROM `item` AS `i` WHERE `item`.`parent` = `i`.`id`)
- AND `id` >= ? ORDER BY `id` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found item orphans without parents: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('item', array('id' => $orphan["id"]));
- }
- } else {
- logger("No item orphans without parents found");
- }
- dba::close($r);
- logger("Done deleting ".$count." items without parents. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-2', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-2', true);
- }
- } elseif ($stage == 3) {
- $last_id = Config::get('system', 'dbclean-last-id-3', 0);
-
- logger("Deleting orphaned data from thread table. Last ID: ".$last_id);
- $r = dba::p("SELECT `iid` FROM `thread`
- WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`parent` = `thread`.`iid`) AND `iid` >= ?
- ORDER BY `iid` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found thread orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["iid"];
- dba::delete('thread', array('iid' => $orphan["iid"]));
- }
- } else {
- logger("No thread orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." orphaned data from thread table. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-3', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-3', true);
- }
- } elseif ($stage == 4) {
- $last_id = Config::get('system', 'dbclean-last-id-4', 0);
-
- logger("Deleting orphaned data from notify table. Last ID: ".$last_id);
- $r = dba::p("SELECT `iid`, `id` FROM `notify`
- WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `notify`.`iid`) AND `id` >= ?
- ORDER BY `id` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found notify orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('notify', array('iid' => $orphan["iid"]));
- }
- } else {
- logger("No notify orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." orphaned data from notify table. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-4', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-4', true);
- }
- } elseif ($stage == 5) {
- $last_id = Config::get('system', 'dbclean-last-id-5', 0);
-
- logger("Deleting orphaned data from notify-threads table. Last ID: ".$last_id);
- $r = dba::p("SELECT `id` FROM `notify-threads`
- WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`parent` = `notify-threads`.`master-parent-item`) AND `id` >= ?
- ORDER BY `id` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found notify-threads orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('notify-threads', array('id' => $orphan["id"]));
- }
- } else {
- logger("No notify-threads orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." orphaned data from notify-threads table. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-5', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-5', true);
- }
- } elseif ($stage == 6) {
- $last_id = Config::get('system', 'dbclean-last-id-6', 0);
-
- logger("Deleting orphaned data from sign table. Last ID: ".$last_id);
- $r = dba::p("SELECT `iid`, `id` FROM `sign`
- WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `sign`.`iid`) AND `id` >= ?
- ORDER BY `id` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found sign orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('sign', array('iid' => $orphan["iid"]));
- }
- } else {
- logger("No sign orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." orphaned data from sign table. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-6', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-6', true);
- }
- } elseif ($stage == 7) {
- $last_id = Config::get('system', 'dbclean-last-id-7', 0);
-
- logger("Deleting orphaned data from term table. Last ID: ".$last_id);
- $r = dba::p("SELECT `oid`, `tid` FROM `term`
- WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `term`.`oid`) AND `tid` >= ?
- ORDER BY `tid` LIMIT ".intval($limit), $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found term orphans: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["tid"];
- dba::delete('term', array('oid' => $orphan["oid"]));
- }
- } else {
- logger("No term orphans found");
- }
- dba::close($r);
- logger("Done deleting ".$count." orphaned data from term table. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-7', $last_id);
-
- if ($count < $limit) {
- Config::set('system', 'finished-dbclean-7', true);
- }
- } elseif ($stage == 8) {
- if ($days <= 0) {
- return;
- }
-
- $last_id = Config::get('system', 'dbclean-last-id-8', 0);
-
- logger("Deleting expired threads. Last ID: ".$last_id);
- $r = dba::p("SELECT `thread`.`iid` FROM `thread`
- INNER JOIN `contact` ON `thread`.`contact-id` = `contact`.`id` AND NOT `notify_new_posts`
- WHERE `thread`.`received` < UTC_TIMESTAMP() - INTERVAL ? DAY
- AND NOT `thread`.`mention` AND NOT `thread`.`starred`
- AND NOT `thread`.`wall` AND NOT `thread`.`origin`
- AND `thread`.`uid` != 0 AND `thread`.`iid` >= ?
- AND NOT `thread`.`iid` IN (SELECT `parent` FROM `item`
- WHERE (`item`.`starred` OR (`item`.`resource-id` != '')
- OR (`item`.`file` != '') OR (`item`.`event-id` != '')
- OR (`item`.`attach` != '') OR `item`.`wall` OR `item`.`origin`)
- AND `item`.`parent` = `thread`.`iid`)
- ORDER BY `thread`.`iid` LIMIT 1000", $days, $last_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found expired threads: ".$count);
- while ($thread = dba::fetch($r)) {
- $last_id = $thread["iid"];
- dba::delete('thread', array('iid' => $thread["iid"]));
- }
- } else {
- logger("No expired threads found");
- }
- dba::close($r);
- logger("Done deleting ".$count." expired threads. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-8', $last_id);
- } elseif ($stage == 9) {
- if ($days <= 0) {
- return;
- }
-
- $last_id = Config::get('system', 'dbclean-last-id-9', 0);
- $till_id = Config::get('system', 'dbclean-last-id-8', 0);
-
- logger("Deleting old global item entries from expired threads from ID ".$last_id." to ID ".$till_id);
- $r = dba::p("SELECT `id` FROM `item` WHERE `uid` = 0 AND
- NOT EXISTS (SELECT `guid` FROM `item` AS `i` WHERE `item`.`guid` = `i`.`guid` AND `i`.`uid` != 0) AND
- `received` < UTC_TIMESTAMP() - INTERVAL 90 DAY AND `id` >= ? AND `id` <= ?
- ORDER BY `id` LIMIT ".intval($limit), $last_id, $till_id);
- $count = dba::num_rows($r);
- if ($count > 0) {
- logger("found global item entries from expired threads: ".$count);
- while ($orphan = dba::fetch($r)) {
- $last_id = $orphan["id"];
- dba::delete('item', array('id' => $orphan["id"]));
- }
- } else {
- logger("No global item entries from expired threads");
- }
- dba::close($r);
- logger("Done deleting ".$count." old global item entries from expired threads. Last ID: ".$last_id);
-
- Config::set('system', 'dbclean-last-id-9', $last_id);
- }
-
- // Call it again if not all entries were purged
- if (($stage != 0) && ($count > 0)) {
- Worker::add(PRIORITY_MEDIUM, 'dbclean');
- }
-}
return($database);
}
-
-
-/*
- * run from command line
- */
-function dbstructure_run(&$argv, &$argc) {
- global $a;
-
- if (empty($a)) {
- $a = new App(dirname(__DIR__));
- }
-
- @include ".htconfig.php";
- require_once "include/dba.php";
- dba::connect($db_host, $db_user, $db_pass, $db_data);
- unset($db_host, $db_user, $db_pass, $db_data);
-
- if ($argc == 2) {
- switch ($argv[1]) {
- case "dryrun":
- update_structure(true, false);
- return;
- case "update":
- update_structure(true, true);
-
- $build = Config::get('system','build');
- if (!x($build)) {
- Config::set('system', 'build', DB_UPDATE_VERSION);
- $build = DB_UPDATE_VERSION;
- }
-
- $stored = intval($build);
- $current = intval(DB_UPDATE_VERSION);
-
- // run any left update_nnnn functions in update.php
- for ($x = $stored; $x < $current; $x ++) {
- $r = run_update_function($x);
- if (!$r) {
- break;
- }
- }
-
- Config::set('system','build',DB_UPDATE_VERSION);
- return;
- case "dumpsql":
- print_structure(db_definition());
- return;
- case "toinnodb":
- convert_to_innodb();
- return;
- }
- }
-
-
- // print help
- echo $argv[0]." <command>\n";
- echo "\n";
- echo "Commands:\n";
- echo "dryrun show database update schema queries without running them\n";
- echo "update update database schema\n";
- echo "dumpsql dump database schema\n";
- echo "toinnodb convert all tables from MyISAM to InnoDB\n";
- return;
-
-}
-
-if (array_search(__FILE__,get_included_files())===0) {
- dbstructure_run($_SERVER["argv"],$_SERVER["argc"]);
- killme();
-}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-
-function dbupdate_run(&$argv, &$argc) {
- global $a;
-
- // We are deleting the latest dbupdate entry.
- // This is done to avoid endless loops because the update was interupted.
- Config::delete('database', 'dbupdate_'.DB_UPDATE_VERSION);
-
- update_db($a);
-}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\System;
-use Friendica\Core\Config;
-use Friendica\Database\DBM;
-use Friendica\Protocol\Diaspora;
-use Friendica\Protocol\DFRN;
-
-require_once 'include/queue_fn.php';
-require_once 'include/html2plain.php';
-require_once 'include/ostatus.php';
-
-function delivery_run(&$argv, &$argc){
- global $a;
-
- require_once 'include/datetime.php';
- require_once 'include/items.php';
- require_once 'include/bbcode.php';
- require_once 'include/email.php';
-
- if ($argc < 3) {
- return;
- }
-
- logger('delivery: invoked: '. print_r($argv,true), LOGGER_DEBUG);
-
- $cmd = $argv[1];
- $item_id = intval($argv[2]);
-
- for ($x = 3; $x < $argc; $x ++) {
-
- $contact_id = intval($argv[$x]);
-
- if (!$item_id || !$contact_id) {
- continue;
- }
-
- $expire = false;
- $mail = false;
- $fsuggest = false;
- $relocate = false;
- $top_level = false;
- $recipients = array();
- $url_recipients = array();
- $followup = false;
-
- $normal_mode = true;
-
- $recipients[] = $contact_id;
-
- if ($cmd === 'mail') {
- $normal_mode = false;
- $mail = true;
- $message = q("SELECT * FROM `mail` WHERE `id` = %d LIMIT 1",
- intval($item_id)
- );
- if (!count($message)) {
- return;
- }
- $uid = $message[0]['uid'];
- $recipients[] = $message[0]['contact-id'];
- $item = $message[0];
- } elseif ($cmd === 'expire') {
- $normal_mode = false;
- $expire = true;
- $items = q("SELECT * FROM `item` WHERE `uid` = %d AND `wall` = 1
- AND `deleted` = 1 AND `changed` > UTC_TIMESTAMP() - INTERVAL 30 MINUTE",
- intval($item_id)
- );
- $uid = $item_id;
- $item_id = 0;
- if (!count($items)) {
- continue;
- }
- } elseif ($cmd === 'suggest') {
- $normal_mode = false;
- $fsuggest = true;
-
- $suggest = q("SELECT * FROM `fsuggest` WHERE `id` = %d LIMIT 1",
- intval($item_id)
- );
- if (!count($suggest)) {
- return;
- }
- $uid = $suggest[0]['uid'];
- $recipients[] = $suggest[0]['cid'];
- $item = $suggest[0];
- } elseif ($cmd === 'relocate') {
- $normal_mode = false;
- $relocate = true;
- $uid = $item_id;
- } else {
- // find ancestors
- $r = q("SELECT * FROM `item` WHERE `id` = %d AND visible = 1 AND moderated = 0 LIMIT 1",
- intval($item_id)
- );
-
- if ((!DBM::is_result($r)) || (!intval($r[0]['parent']))) {
- continue;
- }
-
- $target_item = $r[0];
- $parent_id = intval($r[0]['parent']);
- $uid = $r[0]['uid'];
- $updated = $r[0]['edited'];
-
- $items = q("SELECT `item`.*, `sign`.`signed_text`,`sign`.`signature`,`sign`.`signer`
- FROM `item` LEFT JOIN `sign` ON `sign`.`iid` = `item`.`id` WHERE `parent` = %d AND visible = 1 AND moderated = 0 ORDER BY `id` ASC",
- intval($parent_id)
- );
-
- if (!count($items)) {
- continue;
- }
-
- $icontacts = null;
- $contacts_arr = array();
- foreach ($items as $item) {
- if (!in_array($item['contact-id'],$contacts_arr)) {
- $contacts_arr[] = intval($item['contact-id']);
- }
- }
- if (count($contacts_arr)) {
- $str_contacts = implode(',',$contacts_arr);
- $icontacts = q("SELECT * FROM `contact`
- WHERE `id` IN ( $str_contacts ) "
- );
- }
- if ( !($icontacts && count($icontacts))) {
- continue;
- }
-
- // avoid race condition with deleting entries
-
- if ($items[0]['deleted']) {
- foreach ($items as $item) {
- $item['deleted'] = 1;
- }
- }
-
- // When commenting too fast after delivery, a post wasn't recognized as top level post.
- // The count then showed more than one entry. The additional check should help.
- // The check for the "count" should be superfluous, but I'm not totally sure by now, so we keep it.
- if ((($items[0]['id'] == $item_id) || (count($items) == 1)) && ($items[0]['uri'] === $items[0]['parent-uri'])) {
- logger('delivery: top level post');
- $top_level = true;
- }
- }
-
- $r = q("SELECT `contact`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`,
- `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
- `user`.`page-flags`, `user`.`account-type`, `user`.`prvnets`
- FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
- WHERE `contact`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
- intval($uid)
- );
-
- if (!DBM::is_result($r)) {
- continue;
- }
-
- $owner = $r[0];
-
- $walltowall = ((($top_level) && ($owner['id'] != $items[0]['contact-id'])) ? true : false);
-
- $public_message = true;
-
- if (!($mail || $fsuggest || $relocate)) {
- require_once 'include/group.php';
-
- $parent = $items[0];
-
- // This is IMPORTANT!!!!
-
- // We will only send a "notify owner to relay" or followup message if the referenced post
- // originated on our system by virtue of having our hostname somewhere
- // in the URI, AND it was a comment (not top_level) AND the parent originated elsewhere.
- // if $parent['wall'] == 1 we will already have the parent message in our array
- // and we will relay the whole lot.
-
- // expire sends an entire group of expire messages and cannot be forwarded.
- // However the conversation owner will be a part of the conversation and will
- // be notified during this run.
- // Other DFRN conversation members will be alerted during polled updates.
-
- // Diaspora members currently are not notified of expirations, and other networks have
- // either limited or no ability to process deletions. We should at least fix Diaspora
- // by stringing togther an array of retractions and sending them onward.
-
-
- $localhost = $a->get_hostname();
- if (strpos($localhost,':')) {
- $localhost = substr($localhost,0,strpos($localhost,':'));
- }
- /**
- *
- * Be VERY CAREFUL if you make any changes to the following line. Seemingly innocuous changes
- * have been known to cause runaway conditions which affected several servers, along with
- * permissions issues.
- *
- */
-
- $relay_to_owner = false;
-
- if (!$top_level && ($parent['wall'] == 0) && !$expire && stristr($target_item['uri'],$localhost)) {
- $relay_to_owner = true;
- }
-
- if ($relay_to_owner) {
- logger('followup '.$target_item["guid"], LOGGER_DEBUG);
- // local followup to remote post
- $followup = true;
- }
-
- if ((strlen($parent['allow_cid']))
- || (strlen($parent['allow_gid']))
- || (strlen($parent['deny_cid']))
- || (strlen($parent['deny_gid']))
- || $parent["private"]) {
- $public_message = false; // private recipients, not public
- }
-
- }
-
- $r = q("SELECT * FROM `contact` WHERE `id` = %d AND `blocked` = 0 AND `pending` = 0",
- intval($contact_id)
- );
-
- if (DBM::is_result($r)) {
- $contact = $r[0];
- }
- if ($contact['self']) {
- continue;
- }
- $deliver_status = 0;
-
- logger("main delivery by delivery: followup=$followup mail=$mail fsuggest=$fsuggest relocate=$relocate - network ".$contact['network']);
-
- switch($contact['network']) {
-
- case NETWORK_DFRN:
- logger('notifier: '.$target_item["guid"].' dfrndelivery: '.$contact['name']);
-
- if ($mail) {
- $item['body'] = fix_private_photos($item['body'],$owner['uid'],null,$message[0]['contact-id']);
- $atom = DFRN::mail($item, $owner);
- } elseif ($fsuggest) {
- $atom = DFRN::fsuggest($item, $owner);
- q("DELETE FROM `fsuggest` WHERE `id` = %d LIMIT 1", intval($item['id']));
- } elseif ($relocate) {
- $atom = DFRN::relocate($owner, $uid);
- } elseif ($followup) {
- $msgitems = array();
- foreach ($items as $item) { // there is only one item
- if (!$item['parent']) {
- continue;
- }
- if ($item['id'] == $item_id) {
- logger('followup: item: '. print_r($item,true), LOGGER_DATA);
- $msgitems[] = $item;
- }
- }
- $atom = DFRN::entries($msgitems,$owner);
- } else {
- $msgitems = array();
- foreach ($items as $item) {
- if (!$item['parent']) {
- continue;
- }
-
- // private emails may be in included in public conversations. Filter them.
- if ($public_message && $item['private']) {
- continue;
- }
-
- $item_contact = get_item_contact($item,$icontacts);
- if (!$item_contact) {
- continue;
- }
-
- if ($normal_mode) {
- if ($item_id == $item['id'] || $item['id'] == $item['parent']) {
- $item["entry:comment-allow"] = true;
- $item["entry:cid"] = (($top_level) ? $contact['id'] : 0);
- $msgitems[] = $item;
- }
- } else {
- $item["entry:comment-allow"] = true;
- $msgitems[] = $item;
- }
- }
- $atom = DFRN::entries($msgitems,$owner);
- }
-
- logger('notifier entry: '.$contact["url"].' '.$target_item["guid"].' entry: '.$atom, LOGGER_DEBUG);
-
- logger('notifier: '.$atom, LOGGER_DATA);
- $basepath = implode('/', array_slice(explode('/',$contact['url']),0,3));
-
- // perform local delivery if we are on the same site
-
- if (link_compare($basepath,System::baseUrl())) {
-
- $nickname = basename($contact['url']);
- if ($contact['issued-id']) {
- $sql_extra = sprintf(" AND `dfrn-id` = '%s' ", dbesc($contact['issued-id']));
- } else {
- $sql_extra = sprintf(" AND `issued-id` = '%s' ", dbesc($contact['dfrn-id']));
- }
-
- $x = q("SELECT `contact`.*, `contact`.`uid` AS `importer_uid`,
- `contact`.`pubkey` AS `cpubkey`,
- `contact`.`prvkey` AS `cprvkey`,
- `contact`.`thumb` AS `thumb`,
- `contact`.`url` as `url`,
- `contact`.`name` as `senderName`,
- `user`.*
- FROM `contact`
- INNER JOIN `user` ON `contact`.`uid` = `user`.`uid`
- WHERE `contact`.`blocked` = 0 AND `contact`.`pending` = 0
- AND `contact`.`network` = '%s' AND `user`.`nickname` = '%s'
- $sql_extra
- AND `user`.`account_expired` = 0 AND `user`.`account_removed` = 0 LIMIT 1",
- dbesc(NETWORK_DFRN),
- dbesc($nickname)
- );
-
- if ($x && count($x)) {
- $write_flag = ((($x[0]['rel']) && ($x[0]['rel'] != CONTACT_IS_SHARING)) ? true : false);
- if ((($owner['page-flags'] == PAGE_COMMUNITY) || $write_flag) && !$x[0]['writable']) {
- q("UPDATE `contact` SET `writable` = 1 WHERE `id` = %d",
- intval($x[0]['id'])
- );
- $x[0]['writable'] = 1;
- }
-
- $ssl_policy = Config::get('system','ssl_policy');
- fix_contact_ssl_policy($x[0],$ssl_policy);
-
- // If we are setup as a soapbox we aren't accepting top level posts from this person
-
- if (($x[0]['page-flags'] == PAGE_SOAPBOX) && $top_level) {
- break;
- }
- logger('mod-delivery: local delivery');
- DFRN::import($atom, $x[0]);
- break;
- }
- }
-
- if (!was_recently_delayed($contact['id'])) {
- $deliver_status = DFRN::deliver($owner,$contact,$atom);
- } else {
- $deliver_status = (-1);
- }
-
- logger('notifier: dfrn_delivery to '.$contact["url"].' with guid '.$target_item["guid"].' returns '.$deliver_status);
-
- if ($deliver_status < 0) {
- logger('notifier: delivery failed: queuing message');
- add_to_queue($contact['id'],NETWORK_DFRN,$atom);
-
- // The message could not be delivered. We mark the contact as "dead"
- mark_for_death($contact);
- } else {
- // We successfully delivered a message, the contact is alive
- unmark_for_death($contact);
- }
-
- break;
-
- case NETWORK_OSTATUS:
- // Do not send to otatus if we are not configured to send to public networks
- if ($owner['prvnets']) {
- break;
- }
- if (Config::get('system','ostatus_disabled') || Config::get('system','dfrn_only')) {
- break;
- }
-
- // There is currently no code here to distribute anything to OStatus.
- // This is done in "notifier.php" (See "url_recipients" and "push_notify")
- break;
-
- case NETWORK_MAIL:
- case NETWORK_MAIL2:
-
- if (Config::get('system','dfrn_only')) {
- break;
- }
- // WARNING: does not currently convert to RFC2047 header encodings, etc.
-
- $addr = $contact['addr'];
- if (!strlen($addr)) {
- break;
- }
-
- if ($cmd === 'wall-new' || $cmd === 'comment-new') {
-
- $it = null;
- if ($cmd === 'wall-new') {
- $it = $items[0];
- } else {
- $r = q("SELECT * FROM `item` WHERE `id` = %d AND `uid` = %d LIMIT 1",
- intval($argv[2]),
- intval($uid)
- );
- if (DBM::is_result($r))
- $it = $r[0];
- }
- if (!$it)
- break;
-
-
- $local_user = q("SELECT * FROM `user` WHERE `uid` = %d LIMIT 1",
- intval($uid)
- );
- if (!count($local_user))
- break;
-
- $reply_to = '';
- $r1 = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1",
- intval($uid)
- );
- if ($r1 && $r1[0]['reply_to'])
- $reply_to = $r1[0]['reply_to'];
-
- $subject = (($it['title']) ? email_header_encode($it['title'],'UTF-8') : t("\x28no subject\x29")) ;
-
- // only expose our real email address to true friends
-
- if (($contact['rel'] == CONTACT_IS_FRIEND) && !$contact['blocked']) {
- if ($reply_to) {
- $headers = 'From: '.email_header_encode($local_user[0]['username'],'UTF-8').' <'.$reply_to.'>'."\n";
- $headers .= 'Sender: '.$local_user[0]['email']."\n";
- } else {
- $headers = 'From: '.email_header_encode($local_user[0]['username'],'UTF-8').' <'.$local_user[0]['email'].'>'."\n";
- }
- } else {
- $headers = 'From: '. email_header_encode($local_user[0]['username'],'UTF-8') .' <'. t('noreply') .'@'.$a->get_hostname() .'>'. "\n";
- }
-
- //if ($reply_to)
- // $headers .= 'Reply-to: '.$reply_to . "\n";
-
- $headers .= 'Message-Id: <'. iri2msgid($it['uri']).'>'. "\n";
-
- //logger("Mail: uri: ".$it['uri']." parent-uri ".$it['parent-uri'], LOGGER_DEBUG);
- //logger("Mail: Data: ".print_r($it, true), LOGGER_DEBUG);
- //logger("Mail: Data: ".print_r($it, true), LOGGER_DATA);
-
- if ($it['uri'] !== $it['parent-uri']) {
- $headers .= "References: <".iri2msgid($it["parent-uri"]).">";
-
- // If Threading is enabled, write down the correct parent
- if (($it["thr-parent"] != "") && ($it["thr-parent"] != $it["parent-uri"]))
- $headers .= " <".iri2msgid($it["thr-parent"]).">";
- $headers .= "\n";
-
- if (!$it['title']) {
- $r = q("SELECT `title` FROM `item` WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
- dbesc($it['parent-uri']),
- intval($uid));
-
- if (DBM::is_result($r) && ($r[0]['title'] != '')) {
- $subject = $r[0]['title'];
- } else {
- $r = q("SELECT `title` FROM `item` WHERE `parent-uri` = '%s' AND `uid` = %d LIMIT 1",
- dbesc($it['parent-uri']),
- intval($uid));
-
- if (DBM::is_result($r) && ($r[0]['title'] != ''))
- $subject = $r[0]['title'];
- }
- }
- if (strncasecmp($subject,'RE:',3))
- $subject = 'Re: '.$subject;
- }
- email_send($addr, $subject, $headers, $it);
- }
- break;
-
- case NETWORK_DIASPORA:
- if ($public_message)
- $loc = 'public batch '.$contact['batch'];
- else
- $loc = $contact['name'];
-
- logger('delivery: diaspora batch deliver: '.$loc);
-
- if (Config::get('system','dfrn_only') || (!Config::get('system','diaspora_enabled')))
- break;
-
- if ($mail) {
- Diaspora::send_mail($item,$owner,$contact);
- break;
- }
-
- if (!$normal_mode)
- break;
-
- if (!$contact['pubkey'] && !$public_message)
- break;
-
- if (($target_item['deleted']) && (($target_item['uri'] === $target_item['parent-uri']) || $followup)) {
- // top-level retraction
- logger('diaspora retract: '.$loc);
- Diaspora::send_retraction($target_item,$owner,$contact,$public_message);
- break;
- } elseif ($relocate) {
- Diaspora::sendAccountMigration($owner, $contact, $uid);
- break;
- } elseif ($followup) {
- // send comments and likes to owner to relay
- logger('diaspora followup: '.$loc);
- Diaspora::send_followup($target_item,$owner,$contact,$public_message);
- break;
- } elseif ($target_item['uri'] !== $target_item['parent-uri']) {
- // we are the relay - send comments, likes and relayable_retractions to our conversants
- logger('diaspora relay: '.$loc);
- Diaspora::send_relay($target_item,$owner,$contact,$public_message);
- break;
- } elseif ($top_level && !$walltowall) {
- // currently no workable solution for sending walltowall
- logger('diaspora status: '.$loc);
- Diaspora::send_status($target_item,$owner,$contact,$public_message);
- break;
- }
-
- logger('delivery: diaspora unknown mode: '.$contact['name']);
-
- break;
-
- default:
- break;
- }
- }
-
- return;
-}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-
-function directory_run(&$argv, &$argc){
- $dir = Config::get('system', 'directory');
-
- if (!strlen($dir)) {
- return;
- }
-
- if ($argc < 2) {
- directory_update_all();
- return;
- }
-
- $dir .= "/submit";
-
- $arr = array('url' => $argv[1]);
-
- call_hooks('globaldir_update', $arr);
-
- logger('Updating directory: ' . $arr['url'], LOGGER_DEBUG);
- if (strlen($arr['url'])) {
- fetch_url($dir . '?url=' . bin2hex($arr['url']));
- }
-
- return;
-}
-
-function directory_update_all() {
- $r = q("SELECT `url` FROM `contact`
- INNER JOIN `profile` ON `profile`.`uid` = `contact`.`uid`
- INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
- WHERE `contact`.`self` AND `profile`.`net-publish` AND `profile`.`is-default` AND
- NOT `user`.`account_expired` AND `user`.`verified`");
-
- if (DBM::is_result($r)) {
- foreach ($r AS $user) {
- Worker::add(PRIORITY_LOW, 'directory', $user['url']);
- }
- }
-}
+++ /dev/null
-<?php
-use Friendica\Core\Cache;
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-
-require_once 'include/socgraph.php';
-require_once 'include/datetime.php';
-
-function discover_poco_run(&$argv, &$argc) {
-
- /*
- This function can be called in these ways:
- - dirsearch <search pattern>: Searches for "search pattern" in the directory. "search pattern" is url encoded.
- - checkcontact: Updates gcontact entries
- - suggestions: Discover other servers for their contacts.
- - server <poco url>: Searches for the poco server list. "poco url" is base64 encoded.
- - update_server: Frequently check the first 250 servers for vitality.
- - update_server_directory: Discover the given server id for their contacts
- - poco_load: Load POCO data from a given POCO address
- - check_profile: Update remote profile data
- */
-
- if (($argc > 2) && ($argv[1] == "dirsearch")) {
- $search = urldecode($argv[2]);
- $mode = 1;
- } elseif (($argc == 2) && ($argv[1] == "checkcontact")) {
- $mode = 2;
- } elseif (($argc == 2) && ($argv[1] == "suggestions")) {
- $mode = 3;
- } elseif (($argc == 3) && ($argv[1] == "server")) {
- $mode = 4;
- } elseif (($argc == 2) && ($argv[1] == "update_server")) {
- $mode = 5;
- } elseif (($argc == 3) && ($argv[1] == "update_server_directory")) {
- $mode = 6;
- } elseif (($argc > 5) && ($argv[1] == "poco_load")) {
- $mode = 7;
- } elseif (($argc == 3) && ($argv[1] == "check_profile")) {
- $mode = 8;
- } elseif ($argc == 1) {
- $search = "";
- $mode = 0;
- } else {
- die("Unknown or missing parameter ".$argv[1]."\n");
- }
-
- logger('start '.$search);
-
- if ($mode == 8) {
- if ($argv[2] != "") {
- poco_last_updated($argv[2], true);
- }
- } elseif ($mode == 7) {
- if ($argc == 6) {
- $url = $argv[5];
- } else {
- $url = '';
- }
- poco_load_worker(intval($argv[2]), intval($argv[3]), intval($argv[4]), $url);
- } elseif ($mode == 6) {
- poco_discover_single_server(intval($argv[2]));
- } elseif ($mode == 5) {
- update_server();
- } elseif ($mode == 4) {
- $server_url = $argv[2];
- if ($server_url == "") {
- return;
- }
- $server_url = filter_var($server_url, FILTER_SANITIZE_URL);
- if (substr(normalise_link($server_url), 0, 7) != "http://") {
- return;
- }
- $result = "Checking server ".$server_url." - ";
- $ret = poco_check_server($server_url);
- if ($ret) {
- $result .= "success";
- } else {
- $result .= "failed";
- }
- logger($result, LOGGER_DEBUG);
- } elseif ($mode == 3) {
- update_suggestions();
- } elseif (($mode == 2) && Config::get('system','poco_completion')) {
- discover_users();
- } elseif (($mode == 1) && ($search != "") && Config::get('system','poco_local_search')) {
- discover_directory($search);
- gs_search_user($search);
- } elseif (($mode == 0) && ($search == "") && (Config::get('system','poco_discovery') > 0)) {
- // Query Friendica and Hubzilla servers for their users
- poco_discover();
-
- // Query GNU Social servers for their users ("statistics" addon has to be enabled on the GS server)
- if (!Config::get('system','ostatus_disabled'))
- gs_discover();
- }
-
- logger('end '.$search);
-
- return;
-}
-
-/**
- * @brief Updates the first 250 servers
- *
- */
-function update_server() {
- $r = q("SELECT `url`, `created`, `last_failure`, `last_contact` FROM `gserver` ORDER BY rand()");
-
- if (!DBM::is_result($r)) {
- return;
- }
-
- $updated = 0;
-
- foreach ($r AS $server) {
- if (!poco_do_update($server["created"], "", $server["last_failure"], $server["last_contact"])) {
- continue;
- }
- logger('Update server status for server '.$server["url"], LOGGER_DEBUG);
-
- Worker::add(PRIORITY_LOW, "discover_poco", "server", $server["url"]);
-
- if (++$updated > 250) {
- return;
- }
- }
-}
-
-function discover_users() {
- logger("Discover users", LOGGER_DEBUG);
-
- $starttime = time();
-
- $users = q("SELECT `url`, `created`, `updated`, `last_failure`, `last_contact`, `server_url`, `network` FROM `gcontact`
- WHERE `last_contact` < UTC_TIMESTAMP - INTERVAL 1 MONTH AND
- `last_failure` < UTC_TIMESTAMP - INTERVAL 1 MONTH AND
- `network` IN ('%s', '%s', '%s', '%s', '') ORDER BY rand()",
- dbesc(NETWORK_DFRN), dbesc(NETWORK_DIASPORA),
- dbesc(NETWORK_OSTATUS), dbesc(NETWORK_FEED));
-
- if (!$users) {
- return;
- }
- $checked = 0;
-
- foreach ($users AS $user) {
-
- $urlparts = parse_url($user["url"]);
- if (!isset($urlparts["scheme"])) {
- q("UPDATE `gcontact` SET `network` = '%s' WHERE `nurl` = '%s'",
- dbesc(NETWORK_PHANTOM), dbesc(normalise_link($user["url"])));
- continue;
- }
-
- if (in_array($urlparts["host"], array("www.facebook.com", "facebook.com", "twitter.com",
- "identi.ca", "alpha.app.net"))) {
- $networks = array("www.facebook.com" => NETWORK_FACEBOOK,
- "facebook.com" => NETWORK_FACEBOOK,
- "twitter.com" => NETWORK_TWITTER,
- "identi.ca" => NETWORK_PUMPIO,
- "alpha.app.net" => NETWORK_APPNET);
-
- q("UPDATE `gcontact` SET `network` = '%s' WHERE `nurl` = '%s'",
- dbesc($networks[$urlparts["host"]]), dbesc(normalise_link($user["url"])));
- continue;
- }
-
- $server_url = poco_detect_server($user["url"]);
- $force_update = false;
-
- if ($user["server_url"] != "") {
-
- $force_update = (normalise_link($user["server_url"]) != normalise_link($server_url));
-
- $server_url = $user["server_url"];
- }
-
- if ((($server_url == "") && ($user["network"] == NETWORK_FEED)) || $force_update || poco_check_server($server_url, $user["network"])) {
- logger('Check profile '.$user["url"]);
- Worker::add(PRIORITY_LOW, "discover_poco", "check_profile", $user["url"]);
-
- if (++$checked > 100) {
- return;
- }
- } else {
- q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($user["url"])));
- }
-
- // Quit the loop after 3 minutes
- if (time() > ($starttime + 180)) {
- return;
- }
- }
-}
-
-function discover_directory($search) {
-
- $data = Cache::get("dirsearch:".$search);
- if (!is_null($data)) {
- // Only search for the same item every 24 hours
- if (time() < $data + (60 * 60 * 24)) {
- logger("Already searched for ".$search." in the last 24 hours", LOGGER_DEBUG);
- return;
- }
- }
-
- $x = fetch_url(get_server()."/lsearch?p=1&n=500&search=".urlencode($search));
- $j = json_decode($x);
-
- if (count($j->results)) {
- foreach ($j->results as $jj) {
- // Check if the contact already exists
- $exists = q("SELECT `id`, `last_contact`, `last_failure`, `updated` FROM `gcontact` WHERE `nurl` = '%s'", normalise_link($jj->url));
- if (DBM::is_result($exists)) {
- logger("Profile ".$jj->url." already exists (".$search.")", LOGGER_DEBUG);
-
- if (($exists[0]["last_contact"] < $exists[0]["last_failure"]) &&
- ($exists[0]["updated"] < $exists[0]["last_failure"])) {
- continue;
- }
- // Update the contact
- poco_last_updated($jj->url);
- continue;
- }
-
- $server_url = poco_detect_server($jj->url);
- if ($server_url != '') {
- if (!poco_check_server($server_url)) {
- logger("Friendica server ".$server_url." doesn't answer.", LOGGER_DEBUG);
- continue;
- }
- logger("Friendica server ".$server_url." seems to be okay.", LOGGER_DEBUG);
- }
-
- $data = Probe::uri($jj->url);
- if ($data["network"] == NETWORK_DFRN) {
- logger("Profile ".$jj->url." is reachable (".$search.")", LOGGER_DEBUG);
- logger("Add profile ".$jj->url." to local directory (".$search.")", LOGGER_DEBUG);
-
- if ($jj->tags != "") {
- $data["keywords"] = $jj->tags;
- }
-
- $data["server_url"] = $data["baseurl"];
-
- update_gcontact($data);
- } else {
- logger("Profile ".$jj->url." is not responding or no Friendica contact - but network ".$data["network"], LOGGER_DEBUG);
- }
- }
- }
- Cache::set("dirsearch:".$search, time(), CACHE_DAY);
-}
-
-/**
- * @brief Search for GNU Social user with gstools.org
- *
- * @param str $search User name
- */
-function gs_search_user($search) {
-
- // Currently disabled, since the service isn't available anymore.
- // It is not removed since I hope that there will be a successor.
- return false;
-
- $a = get_app();
-
- $url = "http://gstools.org/api/users_search/".urlencode($search);
-
- $result = z_fetch_url($url);
- if (!$result["success"]) {
- return false;
- }
-
- $contacts = json_decode($result["body"]);
-
- if ($contacts->status == 'ERROR') {
- return false;
- }
-
- /// @TODO AS is considered as a notation for constants (as they usually being written all upper-case)
- /// @TODO find all those and convert to all lower-case which is a keyword then
- foreach ($contacts->data AS $user) {
- $contact = Probe::uri($user->site_address."/".$user->name);
- if ($contact["network"] != NETWORK_PHANTOM) {
- $contact["about"] = $user->description;
- update_gcontact($contact);
- }
- }
-}
<?php
-
+/**
+ * @file include/enotify.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Util\Emailer;
-require_once('include/Emailer.php');
-require_once('include/email.php');
-require_once('include/bbcode.php');
-require_once('include/html2bbcode.php');
+require_once 'include/email.php';
+require_once 'include/bbcode.php';
+require_once 'include/html2bbcode.php';
/**
* @brief Creates a notification entry and possibly sends a mail
// use the Emailer class to send the message
- return Emailer::send(array(
+ return Emailer::send(
+ array(
'uid' => $params['uid'],
'fromName' => $sender_name,
'fromEmail' => $sender_email,
'messageSubject' => $datarray['subject'],
'htmlVersion' => $email_html_body,
'textVersion' => $email_text_body,
- 'additionalMailHeader' => $datarray['headers'],
- ));
+ 'additionalMailHeader' => $datarray['headers'])
+ );
}
- return False;
+ return false;
}
/**
require_once 'include/bbcode.php';
require_once 'include/map.php';
require_once 'include/datetime.php';
+require_once "include/conversation.php";
function format_event_html($ev, $simple = false) {
if (! ((is_array($ev)) && count($ev))) {
return;
}
- q("DELETE FROM `event` WHERE `id` = %d", intval($event_id));
+ dba::delete('event', array('id' => $event_id));
logger("Deleted event ".$event_id, LOGGER_DEBUG);
}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-
-function expire_run(&$argv, &$argc){
- global $a;
-
- require_once('include/datetime.php');
- require_once('include/items.php');
- require_once('include/Contact.php');
-
- load_hooks();
-
- if (($argc == 2) && ($argv[1] == 'delete')) {
- logger('Delete expired items', LOGGER_DEBUG);
- // physically remove anything that has been deleted for more than two months
- $r = dba::p("SELECT `id` FROM `item` WHERE `deleted` AND `changed` < UTC_TIMESTAMP() - INTERVAL 60 DAY");
- while ($row = dba::fetch($r)) {
- dba::delete('item', array('id' => $row['id']));
- }
- dba::close($r);
-
- logger('Delete expired items - done', LOGGER_DEBUG);
-
- // make this optional as it could have a performance impact on large sites
- if (intval(Config::get('system', 'optimize_items'))) {
- q("OPTIMIZE TABLE `item`");
- }
- return;
- } elseif (($argc == 2) && (intval($argv[1]) > 0)) {
- $user = dba::select('user', array('uid', 'username', 'expire'), array('uid' => $argv[1]), array('limit' => 1));
- if (DBM::is_result($user)) {
- logger('Expire items for user '.$user['uid'].' ('.$user['username'].') - interval: '.$user['expire'], LOGGER_DEBUG);
- item_expire($user['uid'], $user['expire']);
- logger('Expire items for user '.$user['uid'].' ('.$user['username'].') - done ', LOGGER_DEBUG);
- }
- return;
- } elseif (($argc == 3) && ($argv[1] == 'hook') && is_array($a->hooks) && array_key_exists("expire", $a->hooks)) {
- foreach ($a->hooks["expire"] as $hook) {
- if ($hook[1] == $argv[2]) {
- logger("Calling expire hook '" . $hook[1] . "'", LOGGER_DEBUG);
- call_single_hook($a, $name, $hook, $data);
- }
- }
- return;
- }
-
- logger('expire: start');
-
- Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
- 'expire', 'delete');
-
- $r = dba::p("SELECT `uid`, `username` FROM `user` WHERE `expire` != 0");
- while ($row = dba::fetch($r)) {
- logger('Calling expiry for user '.$row['uid'].' ('.$row['username'].')', LOGGER_DEBUG);
- Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
- 'expire', (int)$row['uid']);
- }
- dba::close($r);
-
- logger('expire: calling hooks');
-
- if (is_array($a->hooks) && array_key_exists('expire', $a->hooks)) {
- foreach ($a->hooks['expire'] as $hook) {
- logger("Calling expire hook for '" . $hook[1] . "'", LOGGER_DEBUG);
- Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
- 'expire', 'hook', $hook[1]);
- }
- }
-
- logger('expire: end');
-
- return;
-}
* @return boolean
*/
function feature_enabled($uid, $feature) {
- $x = Config::get('feature_lock', $feature);
-
- if (is_null($x)) {
- $x = PConfig::get($uid, 'feature', $feature);
- if (is_null($x)) {
- $x = Config::get('feature', $feature);
- if (is_null($x)) {
- $x = get_feature_default($feature);
- }
- }
+ $x = Config::get('feature_lock', $feature, false);
+
+ if ($x === false) {
+ $x = PConfig::get($uid, 'feature', $feature, false);
+ }
+ if ($x === false) {
+ $x = Config::get('feature', $feature, false);
+ }
+ if ($x === false) {
+ $x = get_feature_default($feature);
}
$arr = array('uid' => $uid, 'feature' => $feature, 'enabled' => $x);
'general' => array(
t('General Features'),
//array('expire', t('Content Expiration'), t('Remove old posts/comments after a period of time')),
- array('multi_profiles', t('Multiple Profiles'), t('Ability to create multiple profiles'), false, Config::get('feature_lock','multi_profiles')),
- array('photo_location', t('Photo Location'), t('Photo metadata is normally stripped. This extracts the location (if present) prior to stripping metadata and links it to a map.'), false, Config::get('feature_lock','photo_location')),
- array('export_calendar', t('Export Public Calendar'), t('Ability for visitors to download the public calendar'), false, Config::get('feature_lock','export_calendar')),
+ array('multi_profiles', t('Multiple Profiles'), t('Ability to create multiple profiles'), false, Config::get('feature_lock','multi_profiles', false)),
+ array('photo_location', t('Photo Location'), t('Photo metadata is normally stripped. This extracts the location (if present) prior to stripping metadata and links it to a map.'), false, Config::get('feature_lock','photo_location', false)),
+ array('export_calendar', t('Export Public Calendar'), t('Ability for visitors to download the public calendar'), false, Config::get('feature_lock','export_calendar', false)),
),
// Post composition
'composition' => array(
t('Post Composition Features'),
- array('preview', t('Post Preview'), t('Allow previewing posts and comments before publishing them'), false, Config::get('feature_lock','preview')),
- array('aclautomention', t('Auto-mention Forums'), t('Add/remove mention when a forum page is selected/deselected in ACL window.'), false, Config::get('feature_lock','aclautomention')),
+ array('preview', t('Post Preview'), t('Allow previewing posts and comments before publishing them'), false, Config::get('feature_lock','preview', false)),
+ array('aclautomention', t('Auto-mention Forums'), t('Add/remove mention when a forum page is selected/deselected in ACL window.'), false, Config::get('feature_lock','aclautomention', false)),
),
// Network sidebar widgets
'widgets' => array(
t('Network Sidebar Widgets'),
- array('archives', t('Search by Date'), t('Ability to select posts by date ranges'), false, Config::get('feature_lock','archives')),
- array('forumlist_widget', t('List Forums'), t('Enable widget to display the forums your are connected with'), true, Config::get('feature_lock','forumlist_widget')),
- array('groups', t('Group Filter'), t('Enable widget to display Network posts only from selected group'), false, Config::get('feature_lock','groups')),
- array('networks', t('Network Filter'), t('Enable widget to display Network posts only from selected network'), false, Config::get('feature_lock','networks')),
- array('savedsearch', t('Saved Searches'), t('Save search terms for re-use'), false, Config::get('feature_lock','savedsearch')),
+ array('archives', t('Search by Date'), t('Ability to select posts by date ranges'), false, Config::get('feature_lock','archives', false)),
+ array('forumlist_widget', t('List Forums'), t('Enable widget to display the forums your are connected with'), true, Config::get('feature_lock','forumlist_widget', false)),
+ array('groups', t('Group Filter'), t('Enable widget to display Network posts only from selected group'), false, Config::get('feature_lock','groups', false)),
+ array('networks', t('Network Filter'), t('Enable widget to display Network posts only from selected network'), false, Config::get('feature_lock','networks', false)),
+ array('savedsearch', t('Saved Searches'), t('Save search terms for re-use'), false, Config::get('feature_lock','savedsearch', false)),
),
// Network tabs
'net_tabs' => array(
t('Network Tabs'),
- array('personal_tab', t('Network Personal Tab'), t('Enable tab to display only Network posts that you\'ve interacted on'), false, Config::get('feature_lock','personal_tab')),
- array('new_tab', t('Network New Tab'), t('Enable tab to display only new Network posts (from the last 12 hours)'), false, Config::get('feature_lock','new_tab')),
- array('link_tab', t('Network Shared Links Tab'), t('Enable tab to display only Network posts with links in them'), false, Config::get('feature_lock','link_tab')),
+ array('personal_tab', t('Network Personal Tab'), t('Enable tab to display only Network posts that you\'ve interacted on'), false, Config::get('feature_lock','personal_tab', false)),
+ array('new_tab', t('Network New Tab'), t('Enable tab to display only new Network posts (from the last 12 hours)'), false, Config::get('feature_lock','new_tab', false)),
+ array('link_tab', t('Network Shared Links Tab'), t('Enable tab to display only Network posts with links in them'), false, Config::get('feature_lock','link_tab', false)),
),
// Item tools
'tools' => array(
t('Post/Comment Tools'),
- array('multi_delete', t('Multiple Deletion'), t('Select and delete multiple posts/comments at once'), false, Config::get('feature_lock','multi_delete')),
- array('edit_posts', t('Edit Sent Posts'), t('Edit and correct posts and comments after sending'), false, Config::get('feature_lock','edit_posts')),
- array('commtag', t('Tagging'), t('Ability to tag existing posts'), false, Config::get('feature_lock','commtag')),
- array('categories', t('Post Categories'), t('Add categories to your posts'), false, Config::get('feature_lock','categories')),
- array('filing', t('Saved Folders'), t('Ability to file posts under folders'), false, Config::get('feature_lock','filing')),
- array('dislike', t('Dislike Posts'), t('Ability to dislike posts/comments'), false, Config::get('feature_lock','dislike')),
- array('star_posts', t('Star Posts'), t('Ability to mark special posts with a star indicator'), false, Config::get('feature_lock','star_posts')),
- array('ignore_posts', t('Mute Post Notifications'), t('Ability to mute notifications for a thread'), false, Config::get('feature_lock','ignore_posts')),
+ array('multi_delete', t('Multiple Deletion'), t('Select and delete multiple posts/comments at once'), false, Config::get('feature_lock','multi_delete', false)),
+ array('edit_posts', t('Edit Sent Posts'), t('Edit and correct posts and comments after sending'), false, Config::get('feature_lock','edit_posts', false)),
+ array('commtag', t('Tagging'), t('Ability to tag existing posts'), false, Config::get('feature_lock','commtag', false)),
+ array('categories', t('Post Categories'), t('Add categories to your posts'), false, Config::get('feature_lock','categories', false)),
+ array('filing', t('Saved Folders'), t('Ability to file posts under folders'), false, Config::get('feature_lock','filing', false)),
+ array('dislike', t('Dislike Posts'), t('Ability to dislike posts/comments'), false, Config::get('feature_lock','dislike', false)),
+ array('star_posts', t('Star Posts'), t('Ability to mark special posts with a star indicator'), false, Config::get('feature_lock','star_posts', false)),
+ array('ignore_posts', t('Mute Post Notifications'), t('Ability to mute notifications for a thread'), false, Config::get('feature_lock','ignore_posts', false)),
),
// Advanced Profile Settings
'advanced_profile' => array(
t('Advanced Profile Settings'),
- array('forumlist_profile', t('List Forums'), t('Show visitors public community forums at the Advanced Profile Page'), false, Config::get('feature_lock','forumlist_profile')),
+ array('forumlist_profile', t('List Forums'), t('Show visitors public community forums at the Advanced Profile Page'), false, Config::get('feature_lock','forumlist_profile', false)),
+ array('tagadelic', t('Tag Cloud'), t('Provide a personal tag cloud on your profile page'), false, Config::get('feature_lock', 'tagadelic', false)),
),
);
if (is_array($arr[$k][$y])) {
if ($arr[$k][$y][4] === false) {
$has_items = true;
- }
- else {
+ } else {
unset($arr[$k][$y]);
}
}
$item["title"] = '';
}
- if ($contact["fetch_further_information"]) {
+ if (!empty($contact["fetch_further_information"]) && ($contact["fetch_further_information"] < 3)) {
$preview = "";
// Handle enclosures and treat them as preview picture
if (!strstr($item["body"], '[url') && ($item['plink'] != '')) {
$item["body"] .= "[hr][url]".$item['plink']."[/url]";
}
+ if ($contact["fetch_further_information"] == 3) {
+ $item["tag"] = add_page_keywords($item["plink"], false, $preview, true, $contact["ffi_keyword_blacklist"]);
+ }
}
if (!$simulate) {
<?php
-
+/**
+ * @file include/follow.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Database\DBM;
use Friendica\Network\Probe;
use Friendica\Protocol\Diaspora;
+use Friendica\Protocol\OStatus;
+use Friendica\Protocol\PortableContact;
-require_once 'include/socgraph.php';
require_once 'include/group.php';
require_once 'include/salmon.php';
-require_once 'include/ostatus.php';
require_once 'include/Photo.php';
function update_contact($id) {
);
// Update the corresponding gcontact entry
- poco_last_updated($ret["url"]);
+ PortableContact::lastUpdated($ret["url"]);
return true;
}
// pull feed and consume it, which should subscribe to the hub.
- Worker::add(PRIORITY_HIGH, "onepoll", $contact_id, "force");
+ Worker::add(PRIORITY_HIGH, "OnePoll", $contact_id, "force");
$r = q("SELECT `contact`.*, `user`.* FROM `contact` INNER JOIN `user` ON `contact`.`uid` = `user`.`uid`
WHERE `user`.`uid` = %d AND `contact`.`self` LIMIT 1",
$item = array();
$item['verb'] = ACTIVITY_FOLLOW;
$item['follow'] = $contact["url"];
- $slap = ostatus::salmon($item, $r[0]);
+ $slap = OStatus::salmon($item, $r[0]);
slapper($r[0], $contact['notify'], $slap);
}
if ($contact['network'] == NETWORK_DIASPORA) {
- $ret = Diaspora::send_share($a->user,$contact);
+ $ret = Diaspora::sendShare($a->user, $contact);
logger('share returns: '.$ret);
}
}
<?php
-require_once "object/TemplateEngine.php";
+use Friendica\Render\ITemplateEngine;
+
require_once("library/Smarty/libs/Smarty.class.php");
require_once "include/plugin.php";
}
// ITemplateEngine interface
- public function replace_macros($s, $r) {
+ public function replaceMacros($s, $r) {
$template = '';
if (gettype($s) === 'string') {
$template = $s;
$s = new FriendicaSmarty();
}
-
+
$r['$APP'] = get_app();
// "middleware": inject variables into templates
return $s->parsed($template);
}
- public function get_template_file($file, $root=''){
+ public function getTemplateFile($file, $root=''){
$a = get_app();
$template_file = get_template_file($a, SMARTY3_TEMPLATE_FOLDER.'/'.$file, $root);
$template = new FriendicaSmarty();
+++ /dev/null
-<?php
-use Friendica\Core\Cache;
-use Friendica\Core\Config;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-
-require_once 'include/socgraph.php';
-require_once 'include/datetime.php';
-
-function gprobe_run(&$argv, &$argc){
- if ($argc != 2) {
- return;
- }
- $url = $argv[1];
-
- $r = q("SELECT `id`, `url`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 1",
- dbesc(normalise_link($url))
- );
-
- logger("gprobe start for ".normalise_link($url), LOGGER_DEBUG);
-
- if (!DBM::is_result($r)) {
-
- // Is it a DDoS attempt?
- $urlparts = parse_url($url);
-
- $result = Cache::get("gprobe:".$urlparts["host"]);
- if (!is_null($result)) {
- if (in_array($result["network"], array(NETWORK_FEED, NETWORK_PHANTOM))) {
- logger("DDoS attempt detected for ".$urlparts["host"]." by ".$_SERVER["REMOTE_ADDR"].". server data: ".print_r($_SERVER, true), LOGGER_DEBUG);
- return;
- }
- }
-
- $arr = Probe::uri($url);
-
- if (is_null($result)) {
- Cache::set("gprobe:".$urlparts["host"], $arr);
- }
-
- if (!in_array($arr["network"], array(NETWORK_FEED, NETWORK_PHANTOM))) {
- update_gcontact($arr);
- }
-
- $r = q("SELECT `id`, `url`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 1",
- dbesc(normalise_link($url))
- );
- }
- if (DBM::is_result($r)) {
- // Check for accessibility and do a poco discovery
- if (poco_last_updated($r[0]['url'], true) && ($r[0]["network"] == NETWORK_DFRN))
- poco_load(0,0,$r[0]['id'], str_replace('/profile/','/poco/',$r[0]['url']));
- }
-
- logger("gprobe end for ".normalise_link($url), LOGGER_DEBUG);
- return;
-}
}
// remove all members
- $r = q("DELETE FROM `group_member` WHERE `uid` = %d AND `gid` = %d ",
- intval($uid),
- intval($group_id)
- );
+ dba::delete('group_member', array('uid' => $uid, 'pid' => $group_id));
// remove group
$r = q("UPDATE `group` SET `deleted` = 1 WHERE `uid` = %d AND `name` = '%s'",
return false;
}
-function group_rmv_member($uid,$name,$member) {
- $gid = group_byname($uid,$name);
- if (! $gid)
- return false;
- if (! ( $uid && $gid && $member))
+function group_rmv_member($uid, $name, $member) {
+ $gid = group_byname($uid, $name);
+
+ if (!$gid) {
return false;
- $r = q("DELETE FROM `group_member` WHERE `uid` = %d AND `gid` = %d AND `contact-id` = %d",
- intval($uid),
- intval($gid),
- intval($member)
- );
- return $r;
+ }
+ if (!($uid && $gid && $member)) {
+ return false;
+ }
+ $r = dba::delete('group_member', array('uid' => $uid, 'gid' => $gid, 'contact-id' => $member));
+ return $r;
}
*/
use Friendica\App;
+use Friendica\Content\ForumManager;
use Friendica\Core\Cache;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once 'include/ForumManager.php';
require_once 'include/bbcode.php';
require_once 'mod/proxy.php';
"SELECT `contact`.`id` AS `contact_id`, `contact`.`photo` AS `contact_photo`,
`contact`.`thumb` AS `contact_thumb`, `contact`.`micro` AS `contact_micro`,
`profile`.`uid` AS `profile_uid`, `profile`.*,
- `contact`.`avatar-date` AS picdate, `contact`.`addr`, `user`.*
+ `contact`.`avatar-date` AS picdate, `contact`.`addr`, `contact`.`url`, `user`.*
FROM `profile`
INNER JOIN `contact` on `contact`.`uid` = `profile`.`uid` AND `contact`.`self`
INNER JOIN `user` ON `profile`.`uid` = `user`.`uid`
"SELECT `contact`.`id` AS `contact_id`, `contact`.`photo` as `contact_photo`,
`contact`.`thumb` AS `contact_thumb`, `contact`.`micro` AS `contact_micro`,
`profile`.`uid` AS `profile_uid`, `profile`.*,
- `contact`.`avatar-date` AS picdate, `contact`.`addr`, `user`.*
+ `contact`.`avatar-date` AS picdate, `contact`.`addr`, `contact`.`url`, `user`.*
FROM `profile`
INNER JOIN `contact` ON `contact`.`uid` = `profile`.`uid` AND `contact`.`self`
INNER JOIN `user` ON `profile`.`uid` = `user`.`uid`
}
// Fetch the account type
- $account_type = account_type($profile);
+ $account_type = Contact::getAccountType($profile);
if ((x($profile, 'address') == 1)
|| (x($profile, 'location') == 1)
$p["photo"] = proxy_url($p["photo"], false, PROXY_SIZE_SMALL);
}
- if ($a->theme['template_engine'] === 'internal') {
- $location = template_escape($location);
- }
-
$tpl = get_markup_template('profile_vcard.tpl');
$o .= replace_macros(
$tpl,
//show subcribed forum if it is enabled in the usersettings
if (feature_enabled($uid, 'forumlist_profile')) {
- $profile['forumlist'] = array( t('Forums:'), ForumManager::profile_advanced($uid));
+ $profile['forumlist'] = array( t('Forums:'), ForumManager::profileAdvanced($uid));
}
if ($a->profile['uid'] == local_user()) {
return;
}
- Worker::add(PRIORITY_LOW, 'gprobe', $tmp_str);
+ Worker::add(PRIORITY_LOW, 'GProbe', $tmp_str);
$arr = array('zrl' => $tmp_str, 'url' => $a->cmd);
call_hooks('zrl_init', $arr);
}
*/
use Friendica\App;
-use Friendica\Core\System;
use Friendica\ParseUrl;
-use Friendica\Util\Lock;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\Worker;
+use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
use Friendica\Protocol\DFRN;
+use Friendica\Protocol\OStatus;
+use Friendica\Util\Lock;
require_once 'include/bbcode.php';
require_once 'include/oembed.php';
require_once 'include/text.php';
require_once 'include/email.php';
require_once 'include/threads.php';
-require_once 'include/socgraph.php';
require_once 'include/plaintext.php';
-require_once 'include/ostatus.php';
require_once 'include/feed.php';
-require_once 'include/Contact.php';
require_once 'mod/share.php';
require_once 'include/enotify.php';
require_once 'include/group.php';
$preview = str_replace(array("[", "]"), array("[", "]"), htmlentities($data["images"][0]["src"], ENT_QUOTES, 'UTF-8', false));
// if the preview picture is larger than 500 pixels then show it in a larger mode
// But only, if the picture isn't higher than large (To prevent huge posts)
- if (($data["images"][0]["width"] >= 500) && ($data["images"][0]["width"] >= $data["images"][0]["height"])) {
+ if (!Config::get('system', 'always_show_preview') && ($data["images"][0]["width"] >= 500)
+ && ($data["images"][0]["width"] >= $data["images"][0]["height"])) {
$text .= " image='".$preview."'";
} else {
$text .= " preview='".$preview."'";
* @return array Item array with removed conversation data
*/
function store_conversation($arr) {
- if (in_array($arr['network'], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
+ if (in_array($arr['network'], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS)) && !empty($arr['uri'])) {
$conversation = array('item-uri' => $arr['uri'], 'received' => DBM::date());
if (isset($arr['parent-uri']) && ($arr['parent-uri'] != $arr['uri'])) {
/// @todo Check if this is really still needed
if ($arr['network'] == NETWORK_OSTATUS) {
if (isset($arr['plink'])) {
- $arr['plink'] = ostatus::convert_href($arr['plink']);
+ $arr['plink'] = OStatus::convertHref($arr['plink']);
} elseif (isset($arr['uri'])) {
- $arr['plink'] = ostatus::convert_href($arr['uri']);
+ $arr['plink'] = OStatus::convertHref($arr['uri']);
}
}
* This is done only for comments (See below explanation at "gcontact-id")
*/
if ($arr['parent-uri'] != $arr['uri']) {
- $arr["contact-id"] = get_contact($arr['author-link'], $uid);
+ $arr["contact-id"] = Contact::getIdForURL($arr['author-link'], $uid);
}
// If not present then maybe the owner was found
if ($arr["contact-id"] == 0) {
- $arr["contact-id"] = get_contact($arr['owner-link'], $uid);
+ $arr["contact-id"] = Contact::getIdForURL($arr['owner-link'], $uid);
}
// Still missing? Then use the "self" contact of the current user
* On comments the author is the better choice.
*/
if ($arr['parent-uri'] === $arr['uri']) {
- $arr["gcontact-id"] = get_gcontact_id(array("url" => $arr['owner-link'], "network" => $arr['network'],
+ $arr["gcontact-id"] = GlobalContact::getId(array("url" => $arr['owner-link'], "network" => $arr['network'],
"photo" => $arr['owner-avatar'], "name" => $arr['owner-name']));
} else {
- $arr["gcontact-id"] = get_gcontact_id(array("url" => $arr['author-link'], "network" => $arr['network'],
+ $arr["gcontact-id"] = GlobalContact::getId(array("url" => $arr['author-link'], "network" => $arr['network'],
"photo" => $arr['author-avatar'], "name" => $arr['author-name']));
}
}
if ($arr["author-id"] == 0) {
- $arr["author-id"] = get_contact($arr["author-link"], 0);
+ $arr["author-id"] = Contact::getIdForURL($arr["author-link"], 0);
}
- if (blockedContact($arr["author-id"])) {
+ if (Contact::isBlocked($arr["author-id"])) {
logger('Contact '.$arr["author-id"].' is blocked, item '.$arr["uri"].' will not be stored');
return 0;
}
if ($arr["owner-id"] == 0) {
- $arr["owner-id"] = get_contact($arr["owner-link"], 0);
+ $arr["owner-id"] = Contact::getIdForURL($arr["owner-link"], 0);
}
- if (blockedContact($arr["owner-id"])) {
+ if (Contact::isBlocked($arr["owner-id"])) {
logger('Contact '.$arr["owner-id"].' is blocked, item '.$arr["uri"].' will not be stored');
return 0;
}
check_item_notification($current_post, $uid);
if ($notify) {
- Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "notifier", $notify_type, $current_post);
+ Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "Notifier", $notify_type, $current_post);
}
return $current_post;
);
update_thread($item_id);
- Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), 'notifier', 'tgroup', $item_id);
+ Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), 'Notifier', 'tgroup', $item_id);
}
//$tempfile = tempnam(get_temppath(), "ostatus2");
//file_put_contents($tempfile, $xml);
logger("Consume OStatus messages ", LOGGER_DEBUG);
- ostatus::import($xml, $importer, $contact, $hub);
+ OStatus::import($xml, $importer, $contact, $hub);
}
return;
}
if (($contact['rel'] == CONTACT_IS_FRIEND) || ($contact['rel'] == CONTACT_IS_SHARING)) {
dba::update('contact', array('rel' => CONTACT_IS_SHARING), array('id' => $contact['id']));
} else {
- contact_remove($contact['id']);
+ Contact::remove($contact['id']);
}
}
if (($contact['rel'] == CONTACT_IS_FRIEND) || ($contact['rel'] == CONTACT_IS_FOLLOWER)) {
dba::update('contact', array('rel' => CONTACT_IS_FOLLOWER), array('id' => $contact['id']));
} else {
- contact_remove($contact['id']);
+ Contact::remove($contact['id']);
}
}
drop_item($item['id'], false);
}
- Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "notifier", "expire", $uid);
+ Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "Notifier", "expire", $uid);
}
/// @TODO type-hint is array
// multiple threads may have been deleted, send an expire notification
if ($uid) {
- Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "notifier", "expire", $uid);
+ Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "Notifier", "expire", $uid);
}
}
}
- if ((local_user() == $item['uid']) || ($contact_id) || (! $interactive)) {
+ if ((local_user() == $item['uid']) || $contact_id || !$interactive) {
// Check if we should do HTML-based delete confirmation
if ($_REQUEST['confirm']) {
* generate a resource-id and therefore aren't intimately linked to the item.
*/
if (strlen($item['resource-id'])) {
- q("DELETE FROM `photo` WHERE `resource-id` = '%s' AND `uid` = %d ",
- dbesc($item['resource-id']),
- intval($item['uid'])
- );
- // ignore the result
+ dba::delete('photo', array('resource-id' => $item['resource-id'], 'uid' => $item['uid']));
}
// If item is a link to an event, nuke the event record.
if (intval($item['event-id'])) {
- q("DELETE FROM `event` WHERE `id` = %d AND `uid` = %d",
- intval($item['event-id']),
- intval($item['uid'])
- );
- // ignore the result
+ dba::delete('event', array('id' => $item['event-id'], 'uid' => $item['uid']));
}
// If item has attachments, drop them
foreach (explode(", ", $item['attach']) as $attach) {
preg_match("|attach/(\d+)|", $attach, $matches);
- q("DELETE FROM `attach` WHERE `id` = %d AND `uid` = %d",
- intval($matches[1]),
- local_user()
- );
- // ignore the result
+ dba::delete('attach', array('id' => $matches[1], 'uid' => $item['uid']));
}
// The new code splits the queries since the mysql optimizer really has bad problems with subqueries
$drop_id = intval($item['id']);
$priority = ($interactive ? PRIORITY_HIGH : PRIORITY_LOW);
- Worker::add(array('priority' => $priority, 'dont_fork' => true), "notifier", "drop", $drop_id);
+ Worker::add(array('priority' => $priority, 'dont_fork' => true), "Notifier", "drop", $drop_id);
if (! $interactive) {
return $owner;
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
use Friendica\Protocol\Diaspora;
/**
$item_contact_id = $owner_self_contact['id'];
$item_contact = $owner_self_contact;
} else {
- $item_contact_id = get_contact($author_contact['url'], $item['uid']);
+ $item_contact_id = Contact::getIdForURL($author_contact['url'], $item['uid']);
$contacts = q("SELECT * FROM `contact` WHERE `id` = %d",
intval($item_contact_id)
// Clean up the Diaspora signatures for this like
// Go ahead and do it even if Diaspora support is disabled. We still want to clean up
// if it had been enabled in the past
- q("DELETE FROM `sign` WHERE `iid` = %d",
- intval($like_item['id'])
- );
+ dba::delete('sign', array('iid' => $like_item['id']));
$like_item_id = $like_item['id'];
- Worker::add(PRIORITY_HIGH, "notifier", "like", $like_item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "like", $like_item_id);
if (!$event_verb_flag || $like_item['verb'] == $activity) {
return true;
}
// Save the author information for the like in case we need to relay to Diaspora
- Diaspora::store_like_signature($item_contact, $new_item_id);
+ Diaspora::storeLikeSignature($item_contact, $new_item_id);
$new_item['id'] = $new_item_id;
call_hooks('post_local_end', $new_item);
- Worker::add(PRIORITY_HIGH, "notifier", "like", $new_item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "like", $new_item_id);
return true;
}
}
if ($post_id) {
- Worker::add(PRIORITY_HIGH, "notifier", "mail", $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "mail", $post_id);
return intval($post_id);
} else {
return -3;
$xmldata = array("result" => $result);
- echo XML::from_array($xmldata, $xml);
+ echo XML::fromArray($xmldata, $xml);
killme();
}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-use Friendica\Protocol\Diaspora;
-
-require_once 'include/queue_fn.php';
-require_once 'include/html2plain.php';
-require_once 'include/ostatus.php';
-require_once 'include/salmon.php';
-
-/*
- * This file was at one time responsible for doing all deliveries, but this caused
- * big problems when the process was killed or stalled during the delivery process.
- * It now invokes separate queues that are delivering via delivery.php and pubsubpublish.php.
- */
-
-/*
- * The notifier is typically called with:
- *
- * Worker::add(PRIORITY_HIGH, "notifier", COMMAND, ITEM_ID);
- *
- * where COMMAND is one of the following:
- *
- * activity (in diaspora.php, dfrn_confirm.php, profiles.php)
- * comment-import (in diaspora.php, items.php)
- * comment-new (in item.php)
- * drop (in diaspora.php, items.php, photos.php)
- * edit_post (in item.php)
- * event (in events.php)
- * expire (in items.php)
- * like (in like.php, poke.php)
- * mail (in message.php)
- * suggest (in fsuggest.php)
- * tag (in photos.php, poke.php, tagger.php)
- * tgroup (in items.php)
- * wall-new (in photos.php, item.php)
- * removeme (in Contact.php)
- * relocate (in uimport.php)
- *
- * and ITEM_ID is the id of the item in the database that needs to be sent to others.
- */
-
-
-function notifier_run(&$argv, &$argc){
- global $a;
-
- require_once 'include/datetime.php';
- require_once 'include/items.php';
- require_once 'include/bbcode.php';
- require_once 'include/email.php';
-
- if ($argc < 3) {
- return;
- }
-
- logger('notifier: invoked: ' . print_r($argv,true), LOGGER_DEBUG);
-
- $cmd = $argv[1];
-
- switch($cmd) {
- case 'mail':
- default:
- $item_id = intval($argv[2]);
- if (! $item_id) {
- return;
- }
- break;
- }
-
- $expire = false;
- $mail = false;
- $fsuggest = false;
- $relocate = false;
- $top_level = false;
- $recipients = array();
- $url_recipients = array();
-
- $normal_mode = true;
-
- if ($cmd === 'mail') {
- $normal_mode = false;
- $mail = true;
- $message = q("SELECT * FROM `mail` WHERE `id` = %d LIMIT 1",
- intval($item_id)
- );
- if (! count($message)) {
- return;
- }
- $uid = $message[0]['uid'];
- $recipients[] = $message[0]['contact-id'];
- $item = $message[0];
-
- } elseif ($cmd === 'expire') {
- $normal_mode = false;
- $expire = true;
- $items = q("SELECT * FROM `item` WHERE `uid` = %d AND `wall` = 1
- AND `deleted` = 1 AND `changed` > UTC_TIMESTAMP() - INTERVAL 10 MINUTE",
- intval($item_id)
- );
- $uid = $item_id;
- $item_id = 0;
- if (! count($items)) {
- return;
- }
- } elseif ($cmd === 'suggest') {
- $normal_mode = false;
- $fsuggest = true;
-
- $suggest = q("SELECT * FROM `fsuggest` WHERE `id` = %d LIMIT 1",
- intval($item_id)
- );
- if (! count($suggest)) {
- return;
- }
- $uid = $suggest[0]['uid'];
- $recipients[] = $suggest[0]['cid'];
- $item = $suggest[0];
- } elseif ($cmd === 'removeme') {
- $r = q("SELECT `contact`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`,
- `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
- `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`, `user`.`guid`
- FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
- WHERE `contact`.`uid` = %d AND `contact`.`self` LIMIT 1",
- intval($item_id));
- if (!$r)
- return;
-
- $user = $r[0];
-
- $r = q("SELECT * FROM `contact` WHERE `uid` = %d AND `self` LIMIT 1", intval($item_id));
- if (!$r)
- return;
-
- $self = $r[0];
-
- $r = q("SELECT * FROM `contact` WHERE NOT `self` AND `uid` = %d", intval($item_id));
- if (!$r) {
- return;
- }
- require_once 'include/Contact.php';
- foreach ($r as $contact) {
- terminate_friendship($user, $self, $contact);
- }
- return;
- } elseif ($cmd === 'relocate') {
- $normal_mode = false;
- $relocate = true;
- $uid = $item_id;
-
- $recipients_relocate = q("SELECT * FROM `contact` WHERE `uid` = %d AND NOT `self` AND `network` IN ('%s', '%s')",
- intval($uid), NETWORK_DFRN, NETWORK_DIASPORA);
- } else {
- // find ancestors
- $r = q("SELECT * FROM `item` WHERE `id` = %d AND visible = 1 AND moderated = 0 LIMIT 1",
- intval($item_id)
- );
-
- if ((! DBM::is_result($r)) || (! intval($r[0]['parent']))) {
- return;
- }
-
- $target_item = $r[0];
- $parent_id = intval($r[0]['parent']);
- $uid = $r[0]['uid'];
- $updated = $r[0]['edited'];
-
- $items = q("SELECT `item`.*, `sign`.`signed_text`,`sign`.`signature`,`sign`.`signer`
- FROM `item` LEFT JOIN `sign` ON `sign`.`iid` = `item`.`id` WHERE `parent` = %d AND visible = 1 AND moderated = 0 ORDER BY `id` ASC",
- intval($parent_id)
- );
-
- if (! count($items)) {
- return;
- }
-
- // avoid race condition with deleting entries
-
- if ($items[0]['deleted']) {
- foreach ($items as $item) {
- $item['deleted'] = 1;
- }
- }
-
- if ((count($items) == 1) && ($items[0]['id'] === $target_item['id']) && ($items[0]['uri'] === $items[0]['parent-uri'])) {
- logger('notifier: top level post');
- $top_level = true;
- }
-
- }
-
- $r = q("SELECT `contact`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`,
- `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
- `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`
- FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
- WHERE `contact`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
- intval($uid)
- );
-
- if (! DBM::is_result($r)) {
- return;
- }
-
- $owner = $r[0];
-
- $walltowall = ((($top_level) && ($owner['id'] != $items[0]['contact-id'])) ? true : false);
-
- // Should the post be transmitted to Diaspora?
- $diaspora_delivery = true;
-
- // If this is a public conversation, notify the feed hub
- $public_message = true;
-
- // Do a PuSH
- $push_notify = false;
-
- // Deliver directly to a forum, don't PuSH
- $direct_forum_delivery = false;
-
- // fill this in with a single salmon slap if applicable
- $slap = '';
-
- if (! ($mail || $fsuggest || $relocate)) {
-
- $slap = ostatus::salmon($target_item,$owner);
-
- require_once 'include/group.php';
-
- $parent = $items[0];
-
- $thr_parent = q("SELECT `network`, `author-link`, `owner-link` FROM `item` WHERE `uri` = '%s' AND `uid` = %d",
- dbesc($target_item["thr-parent"]), intval($target_item["uid"]));
-
- logger('GUID: '.$target_item["guid"].': Parent is '.$parent['network'].'. Thread parent is '.$thr_parent[0]['network'], LOGGER_DEBUG);
-
- // This is IMPORTANT!!!!
-
- // We will only send a "notify owner to relay" or followup message if the referenced post
- // originated on our system by virtue of having our hostname somewhere
- // in the URI, AND it was a comment (not top_level) AND the parent originated elsewhere.
-
- // if $parent['wall'] == 1 we will already have the parent message in our array
- // and we will relay the whole lot.
-
- // expire sends an entire group of expire messages and cannot be forwarded.
- // However the conversation owner will be a part of the conversation and will
- // be notified during this run.
- // Other DFRN conversation members will be alerted during polled updates.
-
-
-
- // Diaspora members currently are not notified of expirations, and other networks have
- // either limited or no ability to process deletions. We should at least fix Diaspora
- // by stringing togther an array of retractions and sending them onward.
-
-
- $localhost = str_replace('www.','',$a->get_hostname());
- if (strpos($localhost,':')) {
- $localhost = substr($localhost,0,strpos($localhost,':'));
- }
- /**
- *
- * Be VERY CAREFUL if you make any changes to the following several lines. Seemingly innocuous changes
- * have been known to cause runaway conditions which affected several servers, along with
- * permissions issues.
- *
- */
-
- $relay_to_owner = false;
-
- if (!$top_level && ($parent['wall'] == 0) && !$expire && (stristr($target_item['uri'],$localhost))) {
- $relay_to_owner = true;
- }
-
-
- if (($cmd === 'uplink') && (intval($parent['forum_mode']) == 1) && !$top_level) {
- $relay_to_owner = true;
- }
-
- // until the 'origin' flag has been in use for several months
- // we will just use it as a fallback test
- // later we will be able to use it as the primary test of whether or not to relay.
-
- if (! $target_item['origin']) {
- $relay_to_owner = false;
- }
- if ($parent['origin']) {
- $relay_to_owner = false;
- }
-
- // Special treatment for forum posts
- if (($target_item['author-link'] != $target_item['owner-link']) &&
- ($owner['id'] != $target_item['contact-id']) &&
- ($target_item['uri'] === $target_item['parent-uri'])) {
-
- $fields = array('forum', 'prv');
- $condition = array('id' => $target_item['contact-id']);
- $contact = dba::select('contact', $fields, $condition, array('limit' => 1));
- if (!DBM::is_result($contact)) {
- // Should never happen
- return false;
- }
-
- // Is the post from a forum?
- if ($contact['forum'] || $contact['prv']) {
- $relay_to_owner = true;
- $direct_forum_delivery = true;
- }
- }
- if ($relay_to_owner) {
- logger('notifier: followup '.$target_item["guid"], LOGGER_DEBUG);
- // local followup to remote post
- $followup = true;
- $public_message = false; // not public
- $conversant_str = dbesc($parent['contact-id']);
- $recipients = array($parent['contact-id']);
- $recipients_followup = array($parent['contact-id']);
-
- //if (!$target_item['private'] && $target_item['wall'] &&
- if (!$target_item['private'] &&
- (strlen($target_item['allow_cid'].$target_item['allow_gid'].
- $target_item['deny_cid'].$target_item['deny_gid']) == 0))
- $push_notify = true;
-
- if (($thr_parent && ($thr_parent[0]['network'] == NETWORK_OSTATUS)) || ($parent['network'] == NETWORK_OSTATUS)) {
-
- $push_notify = true;
-
- if ($parent["network"] == NETWORK_OSTATUS) {
- // Distribute the message to the DFRN contacts as if this wasn't a followup since OStatus can't relay comments
- // Currently it is work at progress
- $r = q("SELECT `id` FROM `contact` WHERE `uid` = %d AND `network` = '%s' AND NOT `blocked` AND NOT `pending` AND NOT `archive`",
- intval($uid),
- dbesc(NETWORK_DFRN)
- );
- if (DBM::is_result($r)) {
- foreach ($r as $rr) {
- $recipients_followup[] = $rr['id'];
- }
- }
- }
- }
-
- if ($direct_forum_delivery) {
- $push_notify = false;
- }
-
- logger("Notify ".$target_item["guid"]." via PuSH: ".($push_notify?"Yes":"No"), LOGGER_DEBUG);
- } else {
- $followup = false;
-
- logger('Distributing directly '.$target_item["guid"], LOGGER_DEBUG);
-
- // don't send deletions onward for other people's stuff
-
- if ($target_item['deleted'] && (! intval($target_item['wall']))) {
- logger('notifier: ignoring delete notification for non-wall item');
- return;
- }
-
- if ((strlen($parent['allow_cid']))
- || (strlen($parent['allow_gid']))
- || (strlen($parent['deny_cid']))
- || (strlen($parent['deny_gid']))) {
- $public_message = false; // private recipients, not public
- }
-
- $allow_people = expand_acl($parent['allow_cid']);
- $allow_groups = expand_groups(expand_acl($parent['allow_gid']),true);
- $deny_people = expand_acl($parent['deny_cid']);
- $deny_groups = expand_groups(expand_acl($parent['deny_gid']));
-
- // if our parent is a public forum (forum_mode == 1), uplink to the origional author causing
- // a delivery fork. private groups (forum_mode == 2) do not uplink
-
- if ((intval($parent['forum_mode']) == 1) && (! $top_level) && ($cmd !== 'uplink')) {
- Worker::add($a->queue['priority'], 'notifier', 'uplink', $item_id);
- }
-
- $conversants = array();
-
- foreach ($items as $item) {
- $recipients[] = $item['contact-id'];
- $conversants[] = $item['contact-id'];
- // pull out additional tagged people to notify (if public message)
- if ($public_message && strlen($item['inform'])) {
- $people = explode(',',$item['inform']);
- foreach ($people as $person) {
- if (substr($person,0,4) === 'cid:') {
- $recipients[] = intval(substr($person,4));
- $conversants[] = intval(substr($person,4));
- } else {
- $url_recipients[] = substr($person,4);
- }
- }
- }
- }
-
- if (count($url_recipients))
- logger('notifier: '.$target_item["guid"].' url_recipients ' . print_r($url_recipients,true));
-
- $conversants = array_unique($conversants);
-
-
- $recipients = array_unique(array_merge($recipients,$allow_people,$allow_groups));
- $deny = array_unique(array_merge($deny_people,$deny_groups));
- $recipients = array_diff($recipients,$deny);
-
- $conversant_str = dbesc(implode(', ',$conversants));
- }
-
- // If the thread parent is OStatus then do some magic to distribute the messages.
- // We have not only to look at the parent, since it could be a Friendica thread.
- if (($thr_parent && ($thr_parent[0]['network'] == NETWORK_OSTATUS)) || ($parent['network'] == NETWORK_OSTATUS)) {
-
- $diaspora_delivery = false;
-
- logger('Some parent is OStatus for '.$target_item["guid"]." - Author: ".$thr_parent[0]['author-link']." - Owner: ".$thr_parent[0]['owner-link'], LOGGER_DEBUG);
-
- // Send a salmon to the parent author
- $r = q("SELECT `url`, `notify` FROM `contact` WHERE `nurl`='%s' AND `uid` IN (0, %d) AND `notify` != ''",
- dbesc(normalise_link($thr_parent[0]['author-link'])),
- intval($uid));
- if (DBM::is_result($r)) {
- $probed_contact = $r[0];
- } else {
- $probed_contact = Probe::uri($thr_parent[0]['author-link']);
- }
-
- if ($probed_contact["notify"] != "") {
- logger('Notify parent author '.$probed_contact["url"].': '.$probed_contact["notify"]);
- $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
- }
-
- // Send a salmon to the parent owner
- $r = q("SELECT `url`, `notify` FROM `contact` WHERE `nurl`='%s' AND `uid` IN (0, %d) AND `notify` != ''",
- dbesc(normalise_link($thr_parent[0]['owner-link'])),
- intval($uid));
- if (DBM::is_result($r)) {
- $probed_contact = $r[0];
- } else {
- $probed_contact = Probe::uri($thr_parent[0]['owner-link']);
- }
-
- if ($probed_contact["notify"] != "") {
- logger('Notify parent owner '.$probed_contact["url"].': '.$probed_contact["notify"]);
- $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
- }
-
- // Send a salmon notification to every person we mentioned in the post
- $arr = explode(',',$target_item['tag']);
- foreach ($arr as $x) {
- //logger('Checking tag '.$x, LOGGER_DEBUG);
- $matches = null;
- if (preg_match('/@\[url=([^\]]*)\]/',$x,$matches)) {
- $probed_contact = Probe::uri($matches[1]);
- if ($probed_contact["notify"] != "") {
- logger('Notify mentioned user '.$probed_contact["url"].': '.$probed_contact["notify"]);
- $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
- }
- }
- }
-
- // It only makes sense to distribute answers to OStatus messages to Friendica and OStatus - but not Diaspora
- $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."')";
- } else {
- $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."', '".NETWORK_DIASPORA."', '".NETWORK_MAIL."', '".NETWORK_MAIL2."')";
- }
- } else {
- $public_message = false;
- }
-
- // If this is a public message and pubmail is set on the parent, include all your email contacts
-
- $mail_disabled = ((function_exists('imap_open') && (!Config::get('system','imap_disabled'))) ? 0 : 1);
-
- if (! $mail_disabled) {
- if ((! strlen($target_item['allow_cid'])) && (! strlen($target_item['allow_gid']))
- && (! strlen($target_item['deny_cid'])) && (! strlen($target_item['deny_gid']))
- && (intval($target_item['pubmail']))) {
- $r = q("SELECT `id` FROM `contact` WHERE `uid` = %d AND `network` = '%s'",
- intval($uid),
- dbesc(NETWORK_MAIL)
- );
- if (DBM::is_result($r)) {
- foreach ($r as $rr) {
- $recipients[] = $rr['id'];
- }
- }
- }
- }
-
- if ($followup) {
- $recip_str = implode(', ', $recipients_followup);
- } else {
- $recip_str = implode(', ', $recipients);
- }
- if ($relocate) {
- $r = $recipients_relocate;
- } else {
- $r = q("SELECT `id`, `url`, `network`, `self` FROM `contact`
- WHERE `id` IN (%s) AND NOT `blocked` AND NOT `pending` AND NOT `archive`".$sql_extra,
- dbesc($recip_str)
- );
- }
-
- // delivery loop
-
- if (DBM::is_result($r)) {
- foreach ($r as $contact) {
- if ($contact['self']) {
- continue;
- }
- logger("Deliver ".$target_item["guid"]." to ".$contact['url']." via network ".$contact['network'], LOGGER_DEBUG);
-
- Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
- 'delivery', $cmd, $item_id, (int)$contact['id']);
- }
- }
-
- // send salmon slaps to mentioned remote tags (@foo@example.com) in OStatus posts
- // They are especially used for notifications to OStatus users that don't follow us.
-
- if ($slap && count($url_recipients) && ($public_message || $push_notify) && $normal_mode) {
- if (!Config::get('system','dfrn_only')) {
- foreach ($url_recipients as $url) {
- if ($url) {
- logger('notifier: urldelivery: ' . $url);
- $deliver_status = slapper($owner,$url,$slap);
- /// @TODO Redeliver/queue these items on failure, though there is no contact record
- }
- }
- }
- }
-
-
- if ($public_message) {
-
- $r0 = array();
- $r1 = array();
-
- if ($diaspora_delivery) {
- if (!$followup) {
- $r0 = Diaspora::relay_list();
- }
-
- $r1 = q("SELECT `batch`, ANY_VALUE(`id`) AS `id`, ANY_VALUE(`name`) AS `name`, ANY_VALUE(`network`) AS `network`
- FROM `contact` WHERE `network` = '%s' AND `batch` != ''
- AND `uid` = %d AND `rel` != %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` GROUP BY `batch`",
- dbesc(NETWORK_DIASPORA),
- intval($owner['uid']),
- intval(CONTACT_IS_SHARING)
- );
- }
-
- $r2 = q("SELECT `id`, `name`,`network` FROM `contact`
- WHERE `network` in ('%s', '%s') AND `uid` = %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` AND `rel` != %d",
- dbesc(NETWORK_DFRN),
- dbesc(NETWORK_MAIL2),
- intval($owner['uid']),
- intval(CONTACT_IS_SHARING)
- );
-
- $r = array_merge($r2,$r1,$r0);
-
- if (DBM::is_result($r)) {
- logger('pubdeliver '.$target_item["guid"].': '.print_r($r,true), LOGGER_DEBUG);
-
- foreach ($r as $rr) {
-
- // except for Diaspora batch jobs
- // Don't deliver to folks who have already been delivered to
-
- if (($rr['network'] !== NETWORK_DIASPORA) && (in_array($rr['id'],$conversants))) {
- logger('notifier: already delivered id=' . $rr['id']);
- continue;
- }
-
- if ((! $mail) && (! $fsuggest) && (! $followup)) {
- logger('notifier: delivery agent: '.$rr['name'].' '.$rr['id'].' '.$rr['network'].' '.$target_item["guid"]);
- Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
- 'delivery', $cmd, $item_id, (int)$rr['id']);
- }
- }
- }
-
- $push_notify = true;
-
- }
-
- // Notify PuSH subscribers (Used for OStatus distribution of regular posts)
- if ($push_notify) {
- // Set push flag for PuSH subscribers to this topic,
- // they will be notified in queue.php
- q("UPDATE `push_subscriber` SET `push` = 1 ".
- "WHERE `nickname` = '%s' AND `push` = 0", dbesc($owner['nickname']));
-
- logger('Activating internal PuSH for item '.$item_id, LOGGER_DEBUG);
-
- // Handling the pubsubhubbub requests
- Worker::add(array('priority' => PRIORITY_HIGH, 'created' => $a->queue['created'], 'dont_fork' => true),
- 'pubsubpublish');
- }
-
- logger('notifier: calling hooks', LOGGER_DEBUG);
-
- if ($normal_mode) {
- call_hooks('notifier_normal',$target_item);
- }
-
- call_hooks('notifier_end',$target_item);
-
- return;
-}
}
- q("DELETE FROM tokens WHERE id='%s'", $token->key);
+ dba::delete('tokens', array('id' => $token->key));
if (!is_null($ret) && $uverifier!==false){
}
}
-/*
-class FKOAuth2 extends OAuth2 {
-
- private function db_secret($client_secret){
- return hash('whirlpool',$client_secret);
- }
-
- public function addClient($client_id, $client_secret, $redirect_uri) {
- $client_secret = $this->db_secret($client_secret);
- $r = q("INSERT INTO clients (client_id, pw, redirect_uri) VALUES ('%s', '%s', '%s')",
- dbesc($client_id),
- dbesc($client_secret),
- dbesc($redirect_uri)
- );
-
- return $r;
- }
-
- protected function checkClientCredentials($client_id, $client_secret = NULL) {
- $client_secret = $this->db_secret($client_secret);
-
- $r = q("SELECT pw FROM clients WHERE client_id = '%s'",
- dbesc($client_id));
-
- if ($client_secret === NULL)
- return $result !== FALSE;
-
- return $result["client_secret"] == $client_secret;
- }
-
- protected function getRedirectUri($client_id) {
- $r = q("SELECT redirect_uri FROM clients WHERE client_id = '%s'",
- dbesc($client_id));
- if ($r === FALSE)
- return FALSE;
-
- return isset($r[0]["redirect_uri"]) && $r[0]["redirect_uri"] ? $r[0]["redirect_uri"] : NULL;
- }
-
- protected function getAccessToken($oauth_token) {
- $r = q("SELECT client_id, expires, scope FROM tokens WHERE id = '%s'",
- dbesc($oauth_token));
-
- if (DBM::is_result($r))
- return $r[0];
- return null;
- }
-
-
-
- protected function setAccessToken($oauth_token, $client_id, $expires, $scope = NULL) {
- $r = q("INSERT INTO tokens (id, client_id, expires, scope) VALUES ('%s', '%s', %d, '%s')",
- dbesc($oauth_token),
- dbesc($client_id),
- intval($expires),
- dbesc($scope));
-
- return $r;
- }
-
- protected function getSupportedGrantTypes() {
- return array(
- OAUTH2_GRANT_TYPE_AUTH_CODE,
- );
- }
-
-
- protected function getAuthCode($code) {
- $r = q("SELECT id, client_id, redirect_uri, expires, scope FROM auth_codes WHERE id = '%s'",
- dbesc($code));
-
- if (DBM::is_result($r))
- return $r[0];
- return null;
- }
-
- protected function setAuthCode($code, $client_id, $redirect_uri, $expires, $scope = NULL) {
- $r = q("INSERT INTO auth_codes
- (id, client_id, redirect_uri, expires, scope) VALUES
- ('%s', '%s', '%s', %d, '%s')",
- dbesc($code),
- dbesc($client_id),
- dbesc($redirect_uri),
- intval($expires),
- dbesc($scope));
- return $r;
- }
-
-}
-*/
* @return bool|object Returns object with embed content or false if no embedable
* content exists
*/
-function oembed_fetch_url($embedurl, $no_rich_type = false){
+function oembed_fetch_url($embedurl, $no_rich_type = false) {
$embedurl = trim($embedurl, "'");
$embedurl = trim($embedurl, '"');
$a = get_app();
- $r = q("SELECT * FROM `oembed` WHERE `url` = '%s'",
- dbesc(normalise_link($embedurl)));
+ $condition = array('url' => normalise_link($embedurl));
+ $r = dba::select('oembed', array('content'), $condition, array('limit' => 1));
if (DBM::is_result($r)) {
- $txt = $r[0]["content"];
+ $txt = $r["content"];
} else {
$txt = Cache::get($a->videowidth . $embedurl);
}
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Core\PConfig;
-use Friendica\Database\DBM;
-
-require_once 'include/follow.php';
-
-function RemoveReply($subject) {
- while (in_array(strtolower(substr($subject, 0, 3)), array("re:", "aw:"))) {
- $subject = trim(substr($subject, 4));
- }
-
- return $subject;
-}
-
-function onepoll_run(&$argv, &$argc) {
- global $a;
-
- require_once 'include/datetime.php';
- require_once 'include/items.php';
- require_once 'include/Contact.php';
- require_once 'include/email.php';
- require_once 'include/socgraph.php';
- require_once 'include/queue_fn.php';
-
- logger('onepoll: start');
-
- $manual_id = 0;
- $generation = 0;
- $hub_update = false;
- $force = false;
- $restart = false;
-
- if (($argc > 1) && (intval($argv[1]))) {
- $contact_id = intval($argv[1]);
- }
-
- if (($argc > 2) && ($argv[2] == "force")) {
- $force = true;
- }
-
- if (!$contact_id) {
- logger('onepoll: no contact');
- return;
- }
-
- $d = datetime_convert();
-
- // Only poll from those with suitable relationships,
- // and which have a polling address and ignore Diaspora since
- // we are unable to match those posts with a Diaspora GUID and prevent duplicates.
-
- $contacts = q("SELECT `contact`.* FROM `contact`
- WHERE (`rel` = %d OR `rel` = %d) AND `poll` != ''
- AND NOT `network` IN ('%s', '%s')
- AND `contact`.`id` = %d
- AND `self` = 0 AND `contact`.`blocked` = 0 AND `contact`.`readonly` = 0
- AND `contact`.`archive` = 0 LIMIT 1",
- intval(CONTACT_IS_SHARING),
- intval(CONTACT_IS_FRIEND),
- dbesc(NETWORK_FACEBOOK),
- dbesc(NETWORK_PUMPIO),
- intval($contact_id)
- );
-
- if (!count($contacts)) {
- logger('Contact not found or cannot be used.');
- return;
- }
-
- $contact = $contacts[0];
-
- $importer_uid = $contact['uid'];
-
- // load current friends if possible.
- if (($contact['poco'] != "") && ($contact['success_update'] > $contact['failure_update'])) {
- $r = q("SELECT count(*) AS total FROM glink
- WHERE `cid` = %d AND updated > UTC_TIMESTAMP() - INTERVAL 1 DAY",
- intval($contact['id'])
- );
- if (DBM::is_result($r)) {
- if (!$r[0]['total']) {
- poco_load($contact['id'], $importer_uid, 0, $contact['poco']);
- }
- }
- }
-
- /// @TODO Check why we don't poll the Diaspora feed at the moment (some guid problem in the items?)
- /// @TODO Check whether this is possible with Redmatrix
- if ($contact["network"] == NETWORK_DIASPORA) {
- if (poco_do_update($contact["created"], $contact["last-item"], $contact["failure_update"], $contact["success_update"])) {
- $last_updated = poco_last_updated($contact["url"]);
- $updated = datetime_convert();
- if ($last_updated) {
- $fields = array('last-item' => $last_updated, 'last-update' => $updated, 'success_update' => $updated);
- dba::update('contact', $fields, array('id' => $contact['id']));
- } else {
- dba::update('contact', array('last-update' => $updated, 'failure_update' => $updated), array('id' => $contact['id']));
- }
- }
- return;
- }
-
- $xml = false;
-
- $t = $contact['last-update'];
-
- if ($contact['subhub']) {
- $poll_interval = Config::get('system', 'pushpoll_frequency');
- $contact['priority'] = (($poll_interval !== false) ? intval($poll_interval) : 3);
- $hub_update = false;
-
- if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day")) {
- $hub_update = true;
- }
- } else {
- $hub_update = false;
- }
-
- $last_update = (($contact['last-update'] <= NULL_DATE)
- ? datetime_convert('UTC', 'UTC', 'now - 7 days', ATOM_TIME)
- : datetime_convert('UTC', 'UTC', $contact['last-update'], ATOM_TIME)
- );
-
- // Update the contact entry
- if (($contact['network'] === NETWORK_OSTATUS) || ($contact['network'] === NETWORK_DIASPORA) || ($contact['network'] === NETWORK_DFRN)) {
- if (!poco_reachable($contact['url'])) {
- logger("Skipping probably dead contact ".$contact['url']);
- return;
- }
-
- if (!update_contact($contact["id"])) {
- mark_for_death($contact);
- logger('Contact is marked dead');
- return;
- } else {
- unmark_for_death($contact);
- }
- }
-
- if ($importer_uid == 0) {
- logger('Ignore public contacts');
- return;
- }
-
- $r = q("SELECT `contact`.*, `user`.`page-flags` FROM `contact` INNER JOIN `user` on `contact`.`uid` = `user`.`uid` WHERE `user`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
- intval($importer_uid)
- );
-
- if (!DBM::is_result($r)) {
- logger('No self contact for user '.$importer_uid);
- return;
- }
-
- $importer = $r[0];
-
- logger("onepoll: poll: ({$contact['id']}) IMPORTER: {$importer['name']}, CONTACT: {$contact['name']}");
-
- if ($contact['network'] === NETWORK_DFRN) {
- $idtosend = $orig_id = (($contact['dfrn-id']) ? $contact['dfrn-id'] : $contact['issued-id']);
- if (intval($contact['duplex']) && $contact['dfrn-id']) {
- $idtosend = '0:' . $orig_id;
- }
- if (intval($contact['duplex']) && $contact['issued-id']) {
- $idtosend = '1:' . $orig_id;
- }
-
- // they have permission to write to us. We already filtered this in the contact query.
- $perm = 'rw';
-
- // But this may be our first communication, so set the writable flag if it isn't set already.
-
- if (!intval($contact['writable'])) {
- $fields = array('writable' => true);
- dba::update('contact', $fields, array('id' => $contact['id']));
- }
-
- $url = $contact['poll'] . '?dfrn_id=' . $idtosend
- . '&dfrn_version=' . DFRN_PROTOCOL_VERSION
- . '&type=data&last_update=' . $last_update
- . '&perm=' . $perm ;
-
- $ret = z_fetch_url($url);
-
- if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
- return;
- }
-
- $handshake_xml = $ret['body'];
-
- $html_code = $a->get_curl_code();
-
- logger('onepoll: handshake with url ' . $url . ' returns xml: ' . $handshake_xml, LOGGER_DATA);
-
-
- if (!strlen($handshake_xml) || ($html_code >= 400) || !$html_code) {
- logger("poller: $url appears to be dead - marking for death ");
-
- // dead connection - might be a transient event, or this might
- // mean the software was uninstalled or the domain expired.
- // Will keep trying for one month.
-
- mark_for_death($contact);
-
- // set the last-update so we don't keep polling
- $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
- dba::update('contact', $fields, array('id' => $contact['id']));
-
- return;
- }
-
- if (! strstr($handshake_xml, '<')) {
- logger('poller: response from ' . $url . ' did not contain XML.');
-
- mark_for_death($contact);
-
- $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
- dba::update('contact', $fields, array('id' => $contact['id']));
-
- return;
- }
-
-
- $res = parse_xml_string($handshake_xml);
-
- if (intval($res->status) == 1) {
- logger("poller: $url replied status 1 - marking for death ");
-
- // we may not be friends anymore. Will keep trying for one month.
- // set the last-update so we don't keep polling
- $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
- dba::update('contact', $fields, array('id' => $contact['id']));
-
- mark_for_death($contact);
- } elseif ($contact['term-date'] > NULL_DATE) {
- logger("poller: $url back from the dead - removing mark for death");
- unmark_for_death($contact);
- }
-
- if ((intval($res->status) != 0) || !strlen($res->challenge) || !strlen($res->dfrn_id)) {
- return;
- }
-
- if (((float)$res->dfrn_version > 2.21) && ($contact['poco'] == '')) {
- $fields = array('poco' => str_replace('/profile/', '/poco/', $contact['url']));
- dba::update('contact', $fields, array('id' => $contact['id']));
- }
-
- $postvars = array();
-
- $sent_dfrn_id = hex2bin((string) $res->dfrn_id);
- $challenge = hex2bin((string) $res->challenge);
-
- $final_dfrn_id = '';
-
- if ($contact['duplex'] && strlen($contact['prvkey'])) {
- openssl_private_decrypt($sent_dfrn_id, $final_dfrn_id, $contact['prvkey']);
- openssl_private_decrypt($challenge, $postvars['challenge'], $contact['prvkey']);
- } else {
- openssl_public_decrypt($sent_dfrn_id, $final_dfrn_id, $contact['pubkey']);
- openssl_public_decrypt($challenge, $postvars['challenge'], $contact['pubkey']);
- }
-
- $final_dfrn_id = substr($final_dfrn_id, 0, strpos($final_dfrn_id, '.'));
-
- if (strpos($final_dfrn_id, ':') == 1) {
- $final_dfrn_id = substr($final_dfrn_id, 2);
- }
-
- if ($final_dfrn_id != $orig_id) {
- logger('poller: ID did not decode: ' . $contact['id'] . ' orig: ' . $orig_id . ' final: ' . $final_dfrn_id);
- // did not decode properly - cannot trust this site
- return;
- }
-
- $postvars['dfrn_id'] = $idtosend;
- $postvars['dfrn_version'] = DFRN_PROTOCOL_VERSION;
- $postvars['perm'] = 'rw';
-
- $xml = post_url($contact['poll'], $postvars);
-
- } elseif (($contact['network'] === NETWORK_OSTATUS)
- || ($contact['network'] === NETWORK_DIASPORA)
- || ($contact['network'] === NETWORK_FEED)) {
-
- // Upgrading DB fields from an older Friendica version
- // Will only do this once per notify-enabled OStatus contact
- // or if relationship changes
-
- $stat_writeable = ((($contact['notify']) && ($contact['rel'] == CONTACT_IS_FOLLOWER || $contact['rel'] == CONTACT_IS_FRIEND)) ? 1 : 0);
-
- // Contacts from OStatus are always writable
- if ($contact['network'] === NETWORK_OSTATUS) {
- $stat_writeable = 1;
- }
-
- if ($stat_writeable != $contact['writable']) {
- $fields = array('writable' => $stat_writeable);
- dba::update('contact', $fields, array('id' => $contact['id']));
- }
-
- // Are we allowed to import from this person?
-
- if ($contact['rel'] == CONTACT_IS_FOLLOWER || $contact['blocked'] || $contact['readonly']) {
- return;
- }
-
- $cookiejar = tempnam(get_temppath(), 'cookiejar-onepoll-');
- $ret = z_fetch_url($contact['poll'], false, $redirects, array('cookiejar' => $cookiejar));
-
- if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
- return;
- }
-
- $xml = $ret['body'];
-
- unlink($cookiejar);
- } elseif ($contact['network'] === NETWORK_MAIL || $contact['network'] === NETWORK_MAIL2) {
-
- logger("Mail: Fetching for ".$contact['addr'], LOGGER_DEBUG);
-
- $mail_disabled = ((function_exists('imap_open') && (! Config::get('system', 'imap_disabled'))) ? 0 : 1);
- if ($mail_disabled) {
- return;
- }
-
- logger("Mail: Enabled", LOGGER_DEBUG);
-
- $mbox = null;
- $x = dba::select('user', array('prvkey'), array('uid' => $importer_uid), array('limit' => 1));
-
- $condition = array("`server` != '' AND `uid` = ?", $importer_uid);
- $mailconf = dba::select('mailacct', array(), $condition, array('limit' => 1));
- if (DBM::is_result($x) && DBM::is_result($mailconf)) {
- $mailbox = construct_mailbox_name($mailconf);
- $password = '';
- openssl_private_decrypt(hex2bin($mailconf['pass']), $password, $x['prvkey']);
- $mbox = email_connect($mailbox, $mailconf['user'], $password);
- unset($password);
- logger("Mail: Connect to " . $mailconf['user']);
- if ($mbox) {
- $fields = array('last_check' => datetime_convert());
- dba::update('mailacct', $fields, array('id' => $mailconf['id']));
- logger("Mail: Connected to " . $mailconf['user']);
- } else {
- logger("Mail: Connection error ".$mailconf['user']." ".print_r(imap_errors(), true));
- }
- }
-
- if ($mbox) {
- $msgs = email_poll($mbox, $contact['addr']);
-
- if (count($msgs)) {
- logger("Mail: Parsing ".count($msgs)." mails from ".$contact['addr']." for ".$mailconf['user'], LOGGER_DEBUG);
-
- $metas = email_msg_meta($mbox,implode(',', $msgs));
- if (count($metas) != count($msgs)) {
- logger("onepoll: for " . $mailconf['user'] . " there are ". count($msgs) . " messages but received " . count($metas) . " metas", LOGGER_DEBUG);
- } else {
- $msgs = array_combine($msgs, $metas);
-
- foreach ($msgs as $msg_uid => $meta) {
- logger("Mail: Parsing mail ".$msg_uid, LOGGER_DATA);
-
- $datarray = array();
- $datarray['verb'] = ACTIVITY_POST;
- $datarray['object-type'] = ACTIVITY_OBJ_NOTE;
- // $meta = email_msg_meta($mbox, $msg_uid);
- // $headers = email_msg_headers($mbox, $msg_uid);
-
- $datarray['uri'] = msgid2iri(trim($meta->message_id, '<>'));
-
- // Have we seen it before?
- $fields = array('deleted', 'id');
- $condition = array('uid' => $importer_uid, 'uri' => $datarray['uri']);
- $r = dba::select('item', $fields, $condition, array('limit' => 1));
-
- if (DBM::is_result($r)) {
- logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user']." UID: ".$importer_uid." URI: ".$datarray['uri'],LOGGER_DEBUG);
-
- // Only delete when mails aren't automatically moved or deleted
- if (($mailconf['action'] != 1) && ($mailconf['action'] != 3))
- if ($meta->deleted && ! $r['deleted']) {
- $fields = array('deleted' => true, 'changed' => datetime_convert());
- dba::update('item', $fields, array('id' => $r['id']));
- }
-
- switch ($mailconf['action']) {
- case 0:
- logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user'].". Doing nothing.", LOGGER_DEBUG);
- break;
- case 1:
- logger("Mail: Deleting ".$msg_uid." for ".$mailconf['user']);
- imap_delete($mbox, $msg_uid, FT_UID);
- break;
- case 2:
- logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf['user']);
- imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
- break;
- case 3:
- logger("Mail: Moving ".$msg_uid." to ".$mailconf['movetofolder']." for ".$mailconf['user']);
- imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
- if ($mailconf['movetofolder'] != "") {
- imap_mail_move($mbox, $msg_uid, $mailconf['movetofolder'], FT_UID);
- }
- break;
- }
- continue;
- }
-
-
- // look for a 'references' or an 'in-reply-to' header and try to match with a parent item we have locally.
- $raw_refs = ((property_exists($meta, 'references')) ? str_replace("\t", '', $meta->references) : '');
- if (! trim($raw_refs)) {
- $raw_refs = ((property_exists($meta, 'in_reply_to')) ? str_replace("\t", '', $meta->in_reply_to) : '');
- }
- $raw_refs = trim($raw_refs); // Don't allow a blank reference in $refs_arr
-
- if ($raw_refs) {
- $refs_arr = explode(' ', $raw_refs);
- if (count($refs_arr)) {
- for ($x = 0; $x < count($refs_arr); $x ++) {
- $refs_arr[$x] = "'" . msgid2iri(str_replace(array('<', '>', ' '),array('', '', ''),dbesc($refs_arr[$x]))) . "'";
- }
- }
- $qstr = implode(',', $refs_arr);
- $r = q("SELECT `parent-uri` FROM `item` USE INDEX (`uid_uri`) WHERE `uri` IN ($qstr) AND `uid` = %d LIMIT 1",
- intval($importer_uid)
- );
- if (DBM::is_result($r)) {
- $datarray['parent-uri'] = $r[0]['parent-uri']; // Set the parent as the top-level item
- }
- }
-
- // Decoding the header
- $subject = imap_mime_header_decode($meta->subject);
- $datarray['title'] = "";
- foreach ($subject as $subpart) {
- if ($subpart->charset != "default") {
- $datarray['title'] .= iconv($subpart->charset, 'UTF-8//IGNORE', $subpart->text);
- } else {
- $datarray['title'] .= $subpart->text;
- }
- }
- $datarray['title'] = notags(trim($datarray['title']));
-
- //$datarray['title'] = notags(trim($meta->subject));
- $datarray['created'] = datetime_convert('UTC', 'UTC', $meta->date);
-
- // Is it a reply?
- $reply = ((substr(strtolower($datarray['title']), 0, 3) == "re:") ||
- (substr(strtolower($datarray['title']), 0, 3) == "re-") ||
- ($raw_refs != ""));
-
- // Remove Reply-signs in the subject
- $datarray['title'] = RemoveReply($datarray['title']);
-
- // If it seems to be a reply but a header couldn't be found take the last message with matching subject
- if (empty($datarray['parent-uri']) && $reply) {
- $r = q("SELECT `parent-uri` FROM `item` WHERE `title` = \"%s\" AND `uid` = %d AND `network` = '%s' ORDER BY `created` DESC LIMIT 1",
- dbesc(protect_sprintf($datarray['title'])),
- intval($importer_uid),
- dbesc(NETWORK_MAIL));
- if (DBM::is_result($r)) {
- $datarray['parent-uri'] = $r[0]['parent-uri'];
- }
- }
-
- if (empty($datarray['parent-uri'])) {
- $datarray['parent-uri'] = $datarray['uri'];
- }
-
- $r = email_get_msg($mbox, $msg_uid, $reply);
- if (!$r) {
- logger("Mail: can't fetch msg ".$msg_uid." for ".$mailconf['user']);
- continue;
- }
- $datarray['body'] = escape_tags($r['body']);
- $datarray['body'] = limit_body_size($datarray['body']);
-
- logger("Mail: Importing ".$msg_uid." for ".$mailconf['user']);
-
- /// @TODO Adding a gravatar for the original author would be cool
-
- $from = imap_mime_header_decode($meta->from);
- $fromdecoded = "";
- foreach ($from as $frompart) {
- if ($frompart->charset != "default") {
- $fromdecoded .= iconv($frompart->charset, 'UTF-8//IGNORE', $frompart->text);
- } else {
- $fromdecoded .= $frompart->text;
- }
- }
-
- $fromarr = imap_rfc822_parse_adrlist($fromdecoded, $a->get_hostname());
-
- $frommail = $fromarr[0]->mailbox."@".$fromarr[0]->host;
-
- if (isset($fromarr[0]->personal)) {
- $fromname = $fromarr[0]->personal;
- } else {
- $fromname = $frommail;
- }
-
- $datarray['author-name'] = $fromname;
- $datarray['author-link'] = "mailto:".$frommail;
- $datarray['author-avatar'] = $contact['photo'];
-
- $datarray['owner-name'] = $contact['name'];
- $datarray['owner-link'] = "mailto:".$contact['addr'];
- $datarray['owner-avatar'] = $contact['photo'];
-
- $datarray['uid'] = $importer_uid;
- $datarray['contact-id'] = $contact['id'];
- if ($datarray['parent-uri'] === $datarray['uri']) {
- $datarray['private'] = 1;
- }
- if (($contact['network'] === NETWORK_MAIL) && (!PConfig::get($importer_uid, 'system', 'allow_public_email_replies'))) {
- $datarray['private'] = 1;
- $datarray['allow_cid'] = '<' . $contact['id'] . '>';
- }
-
- $stored_item = item_store($datarray);
-
- $condition = array('parent-uri' => $datarray['parent-uri'], 'uid' => $importer_uid);
- dba::update('item', array('last-child' => false), $condition);
-
- dba::update('item', array('last-child' => true), array('id' => $stored_item));
-
- switch ($mailconf['action']) {
- case 0:
- logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user'].". Doing nothing.", LOGGER_DEBUG);
- break;
- case 1:
- logger("Mail: Deleting ".$msg_uid." for ".$mailconf['user']);
- imap_delete($mbox, $msg_uid, FT_UID);
- break;
- case 2:
- logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf['user']);
- imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
- break;
- case 3:
- logger("Mail: Moving ".$msg_uid." to ".$mailconf['movetofolder']." for ".$mailconf['user']);
- imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
- if ($mailconf['movetofolder'] != "") {
- imap_mail_move($mbox, $msg_uid, $mailconf['movetofolder'], FT_UID);
- }
- break;
- }
- }
- }
- } else {
- logger("Mail: no mails for ".$mailconf['user']);
- }
-
- logger("Mail: closing connection for ".$mailconf['user']);
- imap_close($mbox);
- }
- }
-
- if ($xml) {
- logger('poller: received xml : ' . $xml, LOGGER_DATA);
- if (!strstr($xml, '<')) {
- logger('poller: post_handshake: response from ' . $url . ' did not contain XML.');
-
- $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
- dba::update('contact', $fields, array('id' => $contact['id']));
-
- return;
- }
-
-
- logger("Consume feed of contact ".$contact['id']);
-
- consume_feed($xml, $importer, $contact, $hub, 1, 1);
-
- // do it twice. Ensures that children of parents which may be later in the stream aren't tossed
-
- consume_feed($xml, $importer, $contact, $hub, 1, 2);
-
- $hubmode = 'subscribe';
- if ($contact['network'] === NETWORK_DFRN || $contact['blocked'] || $contact['readonly']) {
- $hubmode = 'unsubscribe';
- }
-
- if (($contact['network'] === NETWORK_OSTATUS || $contact['network'] == NETWORK_FEED) && (! $contact['hub-verify'])) {
- $hub_update = true;
- }
-
- if ($force) {
- $hub_update = true;
- }
-
- logger("Contact ".$contact['id']." returned hub: ".$hub." Network: ".$contact['network']." Relation: ".$contact['rel']." Update: ".$hub_update);
-
- if (strlen($hub) && $hub_update && (($contact['rel'] != CONTACT_IS_FOLLOWER) || $contact['network'] == NETWORK_FEED)) {
- logger('poller: hub ' . $hubmode . ' : ' . $hub . ' contact name : ' . $contact['name'] . ' local user : ' . $importer['name']);
- $hubs = explode(',', $hub);
- if (count($hubs)) {
- foreach ($hubs as $h) {
- $h = trim($h);
- if (!strlen($h)) {
- continue;
- }
- subscribe_to_hub($h, $importer, $contact, $hubmode);
- }
- }
- }
-
- $updated = datetime_convert();
-
- dba::update('contact', array('last-update' => $updated, 'success_update' => $updated), array('id' => $contact['id']));
- dba::update('gcontact', array('last_contact' => $updated), array('nurl' => $contact['nurl']));
- } elseif (in_array($contact["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, NETWORK_FEED))) {
- $updated = datetime_convert();
-
- dba::update('contact', array('last-update' => $updated, 'failure_update' => $updated), array('id' => $contact['id']));
- dba::update('gcontact', array('last_failure' => $updated), array('nurl' => $contact['nurl']));
- } else {
- dba::update('contact', array('last-update' => $updated), array('id' => $contact['id']));
- }
-
- return;
-}
+++ /dev/null
-<?php
-/**
- * @file include/ostatus.php
- */
-
-use Friendica\App;
-use Friendica\Core\Cache;
-use Friendica\Core\System;
-use Friendica\Core\Config;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-use Friendica\Util\Lock;
-use Friendica\Util\XML;
-
-require_once 'include/Contact.php';
-require_once 'include/threads.php';
-require_once 'include/html2bbcode.php';
-require_once 'include/bbcode.php';
-require_once 'include/items.php';
-require_once 'mod/share.php';
-require_once 'include/enotify.php';
-require_once 'include/socgraph.php';
-require_once 'include/Photo.php';
-require_once 'include/follow.php';
-require_once 'include/api.php';
-require_once 'mod/proxy.php';
-
-/**
- * @brief This class contain functions for the OStatus protocol
- */
-class ostatus
-{
- private static $itemlist;
- private static $conv_list = array();
-
- /**
- * @brief Fetches author data
- *
- * @param object $xpath The xpath object
- * @param object $context The xml context of the author details
- * @param array $importer user record of the importing user
- * @param array $contact Called by reference, will contain the fetched contact
- * @param bool $onlyfetch Only fetch the header without updating the contact entries
- *
- * @return array Array of author related entries for the item
- */
- private static function fetchauthor($xpath, $context, $importer, &$contact, $onlyfetch)
- {
- $author = array();
- $author["author-link"] = $xpath->evaluate('atom:author/atom:uri/text()', $context)->item(0)->nodeValue;
- $author["author-name"] = $xpath->evaluate('atom:author/atom:name/text()', $context)->item(0)->nodeValue;
- $addr = $xpath->evaluate('atom:author/atom:email/text()', $context)->item(0)->nodeValue;
-
- $aliaslink = $author["author-link"];
-
- $alternate = $xpath->query("atom:author/atom:link[@rel='alternate']", $context)->item(0)->attributes;
- if (is_object($alternate)) {
- foreach ($alternate as $attributes) {
- if (($attributes->name == "href") && ($attributes->textContent != "")) {
- $author["author-link"] = $attributes->textContent;
- }
- }
- }
- $author["contact-id"] = $contact["id"];
-
- $found = false;
-
- if ($aliaslink != '') {
- $condition = array("`uid` = ? AND `alias` = ? AND `network` != ?",
- $importer["uid"], $aliaslink, NETWORK_STATUSNET);
- $r = dba::select('contact', array(), $condition, array('limit' => 1));
-
- if (DBM::is_result($r)) {
- $found = true;
- if ($r['blocked']) {
- $r['id'] = -1;
- }
- $contact = $r;
- $author["contact-id"] = $r["id"];
- }
- }
-
- if (!$found && ($author["author-link"] != "")) {
- if ($aliaslink == "") {
- $aliaslink = $author["author-link"];
- }
-
- $condition = array("`uid` = ? AND `nurl` IN (?, ?) AND `network` != ?", $importer["uid"],
- normalise_link($author["author-link"]), normalise_link($aliaslink), NETWORK_STATUSNET);
- $r = dba::select('contact', array(), $condition, array('limit' => 1));
-
- if (DBM::is_result($r)) {
- $found = true;
- if ($r['blocked']) {
- $r['id'] = -1;
- }
- $contact = $r;
- $author["contact-id"] = $r["id"];
- }
- }
-
- if (!$found && ($addr != "")) {
- $condition = array("`uid` = ? AND `addr` = ? AND `network` != ?",
- $importer["uid"], $addr, NETWORK_STATUSNET);
- $r = dba::select('contact', array(), $condition, array('limit' => 1));
-
- if (DBM::is_result($r)) {
- $found = true;
- if ($r['blocked']) {
- $r['id'] = -1;
- }
- $contact = $r;
- $author["contact-id"] = $r["id"];
- }
- }
-
- $avatarlist = array();
- $avatars = $xpath->query("atom:author/atom:link[@rel='avatar']", $context);
- foreach ($avatars as $avatar) {
- $href = "";
- $width = 0;
- foreach ($avatar->attributes as $attributes) {
- if ($attributes->name == "href") {
- $href = $attributes->textContent;
- }
- if ($attributes->name == "width") {
- $width = $attributes->textContent;
- }
- }
- if ($href != "") {
- $avatarlist[$width] = $href;
- }
- }
- if (count($avatarlist) > 0) {
- krsort($avatarlist);
- $author["author-avatar"] = Probe::fixAvatar(current($avatarlist), $author["author-link"]);
- }
-
- $displayname = $xpath->evaluate('atom:author/poco:displayName/text()', $context)->item(0)->nodeValue;
- if ($displayname != "") {
- $author["author-name"] = $displayname;
- }
-
- $author["owner-name"] = $author["author-name"];
- $author["owner-link"] = $author["author-link"];
- $author["owner-avatar"] = $author["author-avatar"];
-
- // Only update the contacts if it is an OStatus contact
- if ($r && ($r['id'] > 0) && !$onlyfetch && ($contact["network"] == NETWORK_OSTATUS)) {
- // This contact is vital, so we awake it from the dead
- unmark_for_death($contact);
-
- // Update contact data
-
- $current = $contact;
- unset($current['name-date']);
-
- // This query doesn't seem to work
- // $value = $xpath->query("atom:link[@rel='salmon']", $context)->item(0)->nodeValue;
- // if ($value != "")
- // $contact["notify"] = $value;
-
- // This query doesn't seem to work as well - I hate these queries
- // $value = $xpath->query("atom:link[@rel='self' and @type='application/atom+xml']", $context)->item(0)->nodeValue;
- // if ($value != "")
- // $contact["poll"] = $value;
-
- $contact['url'] = $author["author-link"];
- $contact['nurl'] = normalise_link($contact['url']);
-
- $value = $xpath->evaluate('atom:author/atom:uri/text()', $context)->item(0)->nodeValue;
- if ($value != "") {
- $contact["alias"] = $value;
- }
-
- $value = $xpath->evaluate('atom:author/poco:displayName/text()', $context)->item(0)->nodeValue;
- if ($value != "") {
- $contact["name"] = $value;
- }
-
- $value = $xpath->evaluate('atom:author/poco:preferredUsername/text()', $context)->item(0)->nodeValue;
- if ($value != "") {
- $contact["nick"] = $value;
- }
-
- $value = $xpath->evaluate('atom:author/poco:note/text()', $context)->item(0)->nodeValue;
- if ($value != "") {
- $contact["about"] = html2bbcode($value);
- }
-
- $value = $xpath->evaluate('atom:author/poco:address/poco:formatted/text()', $context)->item(0)->nodeValue;
- if ($value != "") {
- $contact["location"] = $value;
- }
-
- $contact['name-date'] = datetime_convert();
-
- dba::update('contact', $contact, array('id' => $contact["id"]), $current);
-
- if (!empty($author["author-avatar"]) && ($author["author-avatar"] != $current['avatar'])) {
- logger("Update profile picture for contact ".$contact["id"], LOGGER_DEBUG);
- update_contact_avatar($author["author-avatar"], $importer["uid"], $contact["id"]);
- }
-
- // Ensure that we are having this contact (with uid=0)
- $cid = get_contact($aliaslink, 0);
-
- if ($cid) {
- $fields = array('url', 'nurl', 'name', 'nick', 'alias', 'about', 'location');
- $old_contact = dba::select('contact', $fields, array('id' => $cid), array('limit' => 1));
-
- // Update it with the current values
- $fields = array('url' => $author["author-link"], 'name' => $contact["name"],
- 'nurl' => normalise_link($author["author-link"]),
- 'nick' => $contact["nick"], 'alias' => $contact["alias"],
- 'about' => $contact["about"], 'location' => $contact["location"],
- 'success_update' => datetime_convert(), 'last-update' => datetime_convert());
-
- dba::update('contact', $fields, array('id' => $cid), $old_contact);
-
- // Update the avatar
- update_contact_avatar($author["author-avatar"], 0, $cid);
- }
-
- $contact["generation"] = 2;
- $contact["hide"] = false; // OStatus contacts are never hidden
- $contact["photo"] = $author["author-avatar"];
- $gcid = update_gcontact($contact);
-
- link_gcontact($gcid, $contact["uid"], $contact["id"]);
- }
-
- return $author;
- }
-
- /**
- * @brief Fetches author data from a given XML string
- *
- * @param string $xml The XML
- * @param array $importer user record of the importing user
- *
- * @return array Array of author related entries for the item
- */
- public static function salmon_author($xml, $importer)
- {
- if ($xml == "") {
- return;
- }
-
- $doc = new DOMDocument();
- @$doc->loadXML($xml);
-
- $xpath = new DomXPath($doc);
- $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
- $xpath->registerNamespace('thr', NAMESPACE_THREAD);
- $xpath->registerNamespace('georss', NAMESPACE_GEORSS);
- $xpath->registerNamespace('activity', NAMESPACE_ACTIVITY);
- $xpath->registerNamespace('media', NAMESPACE_MEDIA);
- $xpath->registerNamespace('poco', NAMESPACE_POCO);
- $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
- $xpath->registerNamespace('statusnet', NAMESPACE_STATUSNET);
-
- $entries = $xpath->query('/atom:entry');
-
- foreach ($entries as $entry) {
- // fetch the author
- $author = self::fetchauthor($xpath, $entry, $importer, $contact, true);
- return $author;
- }
- }
-
- /**
- * @brief Read attributes from element
- *
- * @param object $element Element object
- *
- * @return array attributes
- */
- private static function read_attributes($element)
- {
- $attribute = array();
-
- foreach ($element->attributes as $attributes) {
- $attribute[$attributes->name] = $attributes->textContent;
- }
-
- return $attribute;
- }
-
- /**
- * @brief Imports an XML string containing OStatus elements
- *
- * @param string $xml The XML
- * @param array $importer user record of the importing user
- * @param array $contact contact
- * @param string $hub Called by reference, returns the fetched hub data
- */
- public static function import($xml, $importer, &$contact, &$hub)
- {
- self::process($xml, $importer, $contact, $hub);
- }
-
- /**
- * @brief Internal feed processing
- *
- * @param string $xml The XML
- * @param array $importer user record of the importing user
- * @param array $contact
- * @param string $hub Called by reference, returns the fetched hub data
- * @param boolean $stored Is the post fresh imported or from the database?
- * @param boolean $initialize Is it the leading post so that data has to be initialized?
- *
- * @return boolean Could the XML be processed?
- */
- private static function process($xml, $importer, &$contact, &$hub, $stored = false, $initialize = true)
- {
- if ($initialize) {
- self::$itemlist = array();
- self::$conv_list = array();
- }
-
- logger("Import OStatus message", LOGGER_DEBUG);
-
- if ($xml == "") {
- return false;
- }
- $doc = new DOMDocument();
- @$doc->loadXML($xml);
-
- $xpath = new DomXPath($doc);
- $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
- $xpath->registerNamespace('thr', NAMESPACE_THREAD);
- $xpath->registerNamespace('georss', NAMESPACE_GEORSS);
- $xpath->registerNamespace('activity', NAMESPACE_ACTIVITY);
- $xpath->registerNamespace('media', NAMESPACE_MEDIA);
- $xpath->registerNamespace('poco', NAMESPACE_POCO);
- $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
- $xpath->registerNamespace('statusnet', NAMESPACE_STATUSNET);
-
- $hub = "";
- $hub_attributes = $xpath->query("/atom:feed/atom:link[@rel='hub']")->item(0)->attributes;
- if (is_object($hub_attributes)) {
- foreach ($hub_attributes as $hub_attribute) {
- if ($hub_attribute->name == "href") {
- $hub = $hub_attribute->textContent;
- logger("Found hub ".$hub, LOGGER_DEBUG);
- }
- }
- }
-
- $header = array();
- $header["uid"] = $importer["uid"];
- $header["network"] = NETWORK_OSTATUS;
- $header["type"] = "remote";
- $header["wall"] = 0;
- $header["origin"] = 0;
- $header["gravity"] = GRAVITY_PARENT;
-
- $first_child = $doc->firstChild->tagName;
-
- if ($first_child == "feed") {
- $entries = $xpath->query('/atom:feed/atom:entry');
- } else {
- $entries = $xpath->query('/atom:entry');
- }
-
- if ($entries->length == 1) {
- // We reformat the XML to make it better readable
- $doc2 = new DOMDocument();
- $doc2->loadXML($xml);
- $doc2->preserveWhiteSpace = false;
- $doc2->formatOutput = true;
- $xml2 = $doc2->saveXML();
-
- $header["protocol"] = PROTOCOL_OSTATUS_SALMON;
- $header["source"] = $xml2;
- } elseif (!$initialize) {
- return false;
- }
-
- // Fetch the first author
- $authordata = $xpath->query('//author')->item(0);
- $author = self::fetchauthor($xpath, $authordata, $importer, $contact, $stored);
-
- $entry = $xpath->query('/atom:entry');
-
- // Reverse the order of the entries
- $entrylist = array();
-
- foreach ($entries as $entry) {
- $entrylist[] = $entry;
- }
-
- foreach (array_reverse($entrylist) as $entry) {
- // fetch the author
- $authorelement = $xpath->query('/atom:entry/atom:author', $entry);
-
- if ($authorelement->length == 0) {
- $authorelement = $xpath->query('atom:author', $entry);
- }
-
- if ($authorelement->length > 0) {
- $author = self::fetchauthor($xpath, $entry, $importer, $contact, $stored);
- }
-
- $value = $xpath->evaluate('atom:author/poco:preferredUsername/text()', $entry)->item(0)->nodeValue;
- if ($value != "") {
- $nickname = $value;
- } else {
- $nickname = $author["author-name"];
- }
-
- $item = array_merge($header, $author);
-
- $item["uri"] = $xpath->query('atom:id/text()', $entry)->item(0)->nodeValue;
-
- $item["verb"] = $xpath->query('activity:verb/text()', $entry)->item(0)->nodeValue;
-
- // Delete a message
- if (in_array($item["verb"], array('qvitter-delete-notice', ACTIVITY_DELETE, 'delete'))) {
- self::deleteNotice($item);
- continue;
- }
-
- if (in_array($item["verb"], array(NAMESPACE_OSTATUS."/unfavorite", ACTIVITY_UNFAVORITE))) {
- // Ignore "Unfavorite" message
- logger("Ignore unfavorite message ".print_r($item, true), LOGGER_DEBUG);
- continue;
- }
-
- // Deletions come with the same uri, so we check for duplicates after processing deletions
- if (dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item["uri"]))) {
- logger('Post with URI '.$item["uri"].' already existed for user '.$importer["uid"].'.', LOGGER_DEBUG);
- continue;
- } else {
- logger('Processing post with URI '.$item["uri"].' for user '.$importer["uid"].'.', LOGGER_DEBUG);
- }
-
- if ($item["verb"] == ACTIVITY_JOIN) {
- // ignore "Join" messages
- logger("Ignore join message ".print_r($item, true), LOGGER_DEBUG);
- continue;
- }
-
- if ($item["verb"] == "http://mastodon.social/schema/1.0/block") {
- // ignore mastodon "block" messages
- logger("Ignore block message ".print_r($item, true), LOGGER_DEBUG);
- continue;
- }
-
- if ($item["verb"] == ACTIVITY_FOLLOW) {
- new_follower($importer, $contact, $item, $nickname);
- continue;
- }
-
- if ($item["verb"] == NAMESPACE_OSTATUS."/unfollow") {
- lose_follower($importer, $contact, $item, $dummy);
- continue;
- }
-
- if ($item["verb"] == ACTIVITY_FAVORITE) {
- $orig_uri = $xpath->query("activity:object/atom:id", $entry)->item(0)->nodeValue;
- logger("Favorite ".$orig_uri." ".print_r($item, true));
-
- $item["verb"] = ACTIVITY_LIKE;
- $item["parent-uri"] = $orig_uri;
- $item["gravity"] = GRAVITY_LIKE;
- }
-
- // http://activitystrea.ms/schema/1.0/rsvp-yes
- if (!in_array($item["verb"], array(ACTIVITY_POST, ACTIVITY_LIKE, ACTIVITY_SHARE))) {
- logger("Unhandled verb ".$item["verb"]." ".print_r($item, true), LOGGER_DEBUG);
- }
-
- self::processPost($xpath, $entry, $item, $importer);
-
- if ($initialize && (count(self::$itemlist) > 0)) {
- if (self::$itemlist[0]['uri'] == self::$itemlist[0]['parent-uri']) {
- // We will import it everytime, when it is started by our contacts
- $valid = !empty(self::$itemlist[0]['contact-id']);
- if (!$valid) {
- // If not, then it depends on this setting
- $valid = !Config::get('system', 'ostatus_full_threads');
- }
- if ($valid) {
- // Never post a thread when the only interaction by our contact was a like
- $valid = false;
- $verbs = array(ACTIVITY_POST, ACTIVITY_SHARE);
- foreach (self::$itemlist as $item) {
- if (!empty($item['contact-id']) && in_array($item['verb'], $verbs)) {
- $valid = true;
- }
- }
- }
- } else {
- // But we will only import complete threads
- $valid = dba::exists('item', array('uid' => $importer["uid"], 'uri' => self::$itemlist[0]['parent-uri']));
- }
-
- if ($valid) {
- $default_contact = 0;
- $key = count(self::$itemlist);
- for ($key = count(self::$itemlist) - 1; $key >= 0; $key--) {
- if (empty(self::$itemlist[$key]['contact-id'])) {
- self::$itemlist[$key]['contact-id'] = $default_contact;
- } else {
- $default_contact = $item['contact-id'];
- }
- }
- foreach (self::$itemlist as $item) {
- $found = dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item["uri"]));
- if ($found) {
- logger("Item with uri ".$item["uri"]." for user ".$importer["uid"]." already exists.", LOGGER_DEBUG);
- } elseif ($item['contact-id'] < 0) {
- logger("Item with uri ".$item["uri"]." is from a blocked contact.", LOGGER_DEBUG);
- } else {
- // We are having duplicated entries. Hopefully this solves it.
- if (Lock::set('ostatus_process_item_store')) {
- $ret = item_store($item);
- Lock::remove('ostatus_process_item_store');
- logger("Item with uri ".$item["uri"]." for user ".$importer["uid"].' stored. Return value: '.$ret);
- } else {
- $ret = item_store($item);
- logger("We couldn't lock - but tried to store the item anyway. Return value is ".$ret);
- }
- }
- }
- }
- self::$itemlist = array();
- }
- logger('Processing done for post with URI '.$item["uri"].' for user '.$importer["uid"].'.', LOGGER_DEBUG);
- }
- return true;
- }
-
- private static function deleteNotice($item)
- {
- $condition = array('uid' => $item['uid'], 'author-link' => $item['author-link'], 'uri' => $item['uri']);
- $deleted = dba::select('item', array('id', 'parent-uri'), $condition, array('limit' => 1));
- if (!DBM::is_result($deleted)) {
- logger('Item from '.$item['author-link'].' with uri '.$item['uri'].' for user '.$item['uid']." wasn't found. We don't delete it. ");
- return;
- }
-
- // Currently we don't have a central deletion function that we could use in this case. The function "item_drop" doesn't work for that case
- dba::update(
- 'item',
- array('deleted' => true, 'title' => '', 'body' => '',
- 'edited' => datetime_convert(), 'changed' => datetime_convert()),
- array('id' => $deleted["id"])
- );
-
- delete_thread($deleted["id"], $deleted["parent-uri"]);
-
- logger('Deleted item with uri '.$item['uri'].' for user '.$item['uid']);
- }
-
- /**
- * @brief Processes the XML for a post
- *
- * @param object $xpath The xpath object
- * @param object $entry The xml entry that is processed
- * @param array $item The item array
- * @param array $importer user record of the importing user
- */
- private static function processPost($xpath, $entry, &$item, $importer)
- {
- $item["body"] = html2bbcode($xpath->query('atom:content/text()', $entry)->item(0)->nodeValue);
- $item["object-type"] = $xpath->query('activity:object-type/text()', $entry)->item(0)->nodeValue;
- if (($item["object-type"] == ACTIVITY_OBJ_BOOKMARK) || ($item["object-type"] == ACTIVITY_OBJ_EVENT)) {
- $item["title"] = $xpath->query('atom:title/text()', $entry)->item(0)->nodeValue;
- $item["body"] = $xpath->query('atom:summary/text()', $entry)->item(0)->nodeValue;
- } elseif ($item["object-type"] == ACTIVITY_OBJ_QUESTION) {
- $item["title"] = $xpath->query('atom:title/text()', $entry)->item(0)->nodeValue;
- }
-
- $item["created"] = $xpath->query('atom:published/text()', $entry)->item(0)->nodeValue;
- $item["edited"] = $xpath->query('atom:updated/text()', $entry)->item(0)->nodeValue;
- $conversation = $xpath->query('ostatus:conversation/text()', $entry)->item(0)->nodeValue;
- $item['conversation-uri'] = $conversation;
-
- $conv = $xpath->query('ostatus:conversation', $entry);
- if (is_object($conv->item(0))) {
- foreach ($conv->item(0)->attributes as $attributes) {
- if ($attributes->name == "ref") {
- $item['conversation-uri'] = $attributes->textContent;
- }
- if ($attributes->name == "href") {
- $item['conversation-href'] = $attributes->textContent;
- }
- }
- }
-
- $related = "";
-
- $inreplyto = $xpath->query('thr:in-reply-to', $entry);
- if (is_object($inreplyto->item(0))) {
- foreach ($inreplyto->item(0)->attributes as $attributes) {
- if ($attributes->name == "ref") {
- $item["parent-uri"] = $attributes->textContent;
- }
- if ($attributes->name == "href") {
- $related = $attributes->textContent;
- }
- }
- }
-
- $georsspoint = $xpath->query('georss:point', $entry);
- if (!empty($georsspoint) && ($georsspoint->length > 0)) {
- $item["coord"] = $georsspoint->item(0)->nodeValue;
- }
-
- $categories = $xpath->query('atom:category', $entry);
- if ($categories) {
- foreach ($categories as $category) {
- foreach ($category->attributes as $attributes) {
- if ($attributes->name == "term") {
- $term = $attributes->textContent;
- if (strlen($item["tag"])) {
- $item["tag"] .= ',';
- }
- $item["tag"] .= "#[url=".System::baseUrl()."/search?tag=".$term."]".$term."[/url]";
- }
- }
- }
- }
-
- $self = '';
- $add_body = '';
-
- $links = $xpath->query('atom:link', $entry);
- if ($links) {
- $link_data = self::processLinks($links, $item);
- $self = $link_data['self'];
- $add_body = $link_data['add_body'];
- }
-
- $repeat_of = "";
-
- $notice_info = $xpath->query('statusnet:notice_info', $entry);
- if ($notice_info && ($notice_info->length > 0)) {
- foreach ($notice_info->item(0)->attributes as $attributes) {
- if ($attributes->name == "source") {
- $item["app"] = strip_tags($attributes->textContent);
- }
- if ($attributes->name == "repeat_of") {
- $repeat_of = $attributes->textContent;
- }
- }
- }
- // Is it a repeated post?
- if (($repeat_of != "") || ($item["verb"] == ACTIVITY_SHARE)) {
- $link_data = self::processRepeatedItem($xpath, $entry, $item, $importer);
- if (!empty($link_data['add_body'])) {
- $add_body .= $link_data['add_body'];
- }
- }
-
- $item["body"] .= $add_body;
-
- // Only add additional data when there is no picture in the post
- if (!strstr($item["body"], '[/img]')) {
- $item["body"] = add_page_info_to_body($item["body"]);
- }
-
- // Mastodon Content Warning
- if (($item["verb"] == ACTIVITY_POST) && $xpath->evaluate('boolean(atom:summary)', $entry)) {
- $clear_text = $xpath->query('atom:summary/text()', $entry)->item(0)->nodeValue;
-
- $item["body"] = html2bbcode($clear_text) . '[spoiler]' . $item["body"] . '[/spoiler]';
- }
-
- if (($self != '') && empty($item['protocol'])) {
- self::fetchSelf($self, $item);
- }
-
- if (!empty($item["conversation-href"])) {
- self::fetchConversation($item['conversation-href'], $item['conversation-uri']);
- }
-
- if (isset($item["parent-uri"]) && ($related != '')) {
- if (!dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item['parent-uri']))) {
- self::fetchRelated($related, $item["parent-uri"], $importer);
- } else {
- logger('Reply with URI '.$item["uri"].' already existed for user '.$importer["uid"].'.', LOGGER_DEBUG);
- }
-
- $item["type"] = 'remote-comment';
- $item["gravity"] = GRAVITY_COMMENT;
- } else {
- $item["parent-uri"] = $item["uri"];
- }
-
- if (($item['author-link'] != '') && !empty($item['protocol'])) {
- $item = store_conversation($item);
- }
-
- self::$itemlist[] = $item;
- }
-
- /**
- * @brief Fetch the conversation for posts
- *
- * @param string $conversation The link to the conversation
- * @param string $conversation_uri The conversation in "uri" format
- */
- private static function fetchConversation($conversation, $conversation_uri)
- {
- // Ensure that we only store a conversation once in a process
- if (isset(self::$conv_list[$conversation])) {
- return;
- }
-
- self::$conv_list[$conversation] = true;
-
- $conversation_data = z_fetch_url($conversation, false, $redirects, array('accept_content' => 'application/atom+xml, text/html'));
-
- if (!$conversation_data['success']) {
- return;
- }
-
- $xml = '';
-
- if (stristr($conversation_data['header'], 'Content-Type: application/atom+xml')) {
- $xml = $conversation_data['body'];
- }
-
- if ($xml == '') {
- $doc = new DOMDocument();
- if (!@$doc->loadHTML($conversation_data['body'])) {
- return;
- }
- $xpath = new DomXPath($doc);
-
- $links = $xpath->query('//link');
- if ($links) {
- foreach ($links as $link) {
- $attribute = ostatus::read_attributes($link);
- if (($attribute['rel'] == 'alternate') && ($attribute['type'] == 'application/atom+xml')) {
- $file = $attribute['href'];
- }
- }
- if ($file != '') {
- $conversation_atom = z_fetch_url($attribute['href']);
-
- if ($conversation_atom['success']) {
- $xml = $conversation_atom['body'];
- }
- }
- }
- }
-
- if ($xml == '') {
- return;
- }
-
- self::storeConversation($xml, $conversation, $conversation_uri);
- }
-
- /**
- * @brief Store a feed in several conversation entries
- *
- * @param string $xml The feed
- * @param string $conversation conversation
- * @param string $conversation_uri conversation uri
- */
- private static function storeConversation($xml, $conversation = '', $conversation_uri = '')
- {
- $doc = new DOMDocument();
- @$doc->loadXML($xml);
-
- $xpath = new DomXPath($doc);
- $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
- $xpath->registerNamespace('thr', NAMESPACE_THREAD);
- $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
-
- $entries = $xpath->query('/atom:feed/atom:entry');
-
- // Now store the entries
- foreach ($entries as $entry) {
- $doc2 = new DOMDocument();
- $doc2->preserveWhiteSpace = false;
- $doc2->formatOutput = true;
-
- $conv_data = array();
-
- $conv_data['protocol'] = PROTOCOL_SPLITTED_CONV;
- $conv_data['network'] = NETWORK_OSTATUS;
- $conv_data['uri'] = $xpath->query('atom:id/text()', $entry)->item(0)->nodeValue;
-
- $inreplyto = $xpath->query('thr:in-reply-to', $entry);
- if (is_object($inreplyto->item(0))) {
- foreach ($inreplyto->item(0)->attributes as $attributes) {
- if ($attributes->name == "ref") {
- $conv_data['reply-to-uri'] = $attributes->textContent;
- }
- }
- }
-
- $conv = $xpath->query('ostatus:conversation/text()', $entry)->item(0)->nodeValue;
- $conv_data['conversation-uri'] = $conv;
-
- $conv = $xpath->query('ostatus:conversation', $entry);
- if (is_object($conv->item(0))) {
- foreach ($conv->item(0)->attributes as $attributes) {
- if ($attributes->name == "ref") {
- $conv_data['conversation-uri'] = $attributes->textContent;
- }
- if ($attributes->name == "href") {
- $conv_data['conversation-href'] = $attributes->textContent;
- }
- }
- }
-
- if ($conversation != '') {
- $conv_data['conversation-uri'] = $conversation;
- }
-
- if ($conversation_uri != '') {
- $conv_data['conversation-uri'] = $conversation_uri;
- }
-
- $entry = $doc2->importNode($entry, true);
-
- $doc2->appendChild($entry);
-
- $conv_data['source'] = $doc2->saveXML();
-
- $condition = array('item-uri' => $conv_data['uri'],'protocol' => PROTOCOL_OSTATUS_FEED);
- if (dba::exists('conversation', $condition)) {
- logger('Delete deprecated entry for URI '.$conv_data['uri'], LOGGER_DEBUG);
- dba::delete('conversation', array('item-uri' => $conv_data['uri']));
- }
-
- logger('Store conversation data for uri '.$conv_data['uri'], LOGGER_DEBUG);
- store_conversation($conv_data);
- }
- }
-
- /**
- * @brief Fetch the own post so that it can be stored later
- * @param array $item The item array
- *
- * We want to store the original data for later processing.
- * This function is meant for cases where we process a feed with multiple entries.
- * In that case we need to fetch the single posts here.
- *
- * @param string $self The link to the self item
- */
- private static function fetchSelf($self, &$item)
- {
- $condition = array('`item-uri` = ? AND `protocol` IN (?, ?)', $self, PROTOCOL_DFRN, PROTOCOL_OSTATUS_SALMON);
- if (dba::exists('conversation', $condition)) {
- logger('Conversation '.$item['uri'].' is already stored.', LOGGER_DEBUG);
- return;
- }
-
- $self_data = z_fetch_url($self);
-
- if (!$self_data['success']) {
- return;
- }
-
- // We reformat the XML to make it better readable
- $doc = new DOMDocument();
- $doc->loadXML($self_data['body']);
- $doc->preserveWhiteSpace = false;
- $doc->formatOutput = true;
- $xml = $doc->saveXML();
-
- $item["protocol"] = PROTOCOL_OSTATUS_SALMON;
- $item["source"] = $xml;
-
- logger('Conversation '.$item['uri'].' is now fetched.', LOGGER_DEBUG);
- }
-
- /**
- * @brief Fetch related posts and processes them
- *
- * @param string $related The link to the related item
- * @param string $related_uri The related item in "uri" format
- * @param array $importer user record of the importing user
- */
- private static function fetchRelated($related, $related_uri, $importer)
- {
- $condition = array('`item-uri` = ? AND `protocol` IN (?, ?)', $related_uri, PROTOCOL_DFRN, PROTOCOL_OSTATUS_SALMON);
- $conversation = dba::select('conversation', array('source', 'protocol'), $condition, array('limit' => 1));
- if (DBM::is_result($conversation)) {
- $stored = true;
- $xml = $conversation['source'];
- if (self::process($xml, $importer, $contact, $hub, $stored, false)) {
- logger('Got valid cached XML for URI '.$related_uri, LOGGER_DEBUG);
- return;
- }
- if ($conversation['protocol'] == PROTOCOL_OSTATUS_SALMON) {
- logger('Delete invalid cached XML for URI '.$related_uri, LOGGER_DEBUG);
- dba::delete('conversation', array('item-uri' => $related_uri));
- }
- }
-
- $stored = false;
- $related_data = z_fetch_url($related, false, $redirects, array('accept_content' => 'application/atom+xml, text/html'));
-
- if (!$related_data['success']) {
- return;
- }
-
- $xml = '';
-
- if (stristr($related_data['header'], 'Content-Type: application/atom+xml')) {
- logger('Directly fetched XML for URI '.$related_uri, LOGGER_DEBUG);
- $xml = $related_data['body'];
- }
-
- if ($xml == '') {
- $doc = new DOMDocument();
- if (!@$doc->loadHTML($related_data['body'])) {
- return;
- }
- $xpath = new DomXPath($doc);
-
- $atom_file = '';
-
- $links = $xpath->query('//link');
- if ($links) {
- foreach ($links as $link) {
- $attribute = self::read_attributes($link);
- if (($attribute['rel'] == 'alternate') && ($attribute['type'] == 'application/atom+xml')) {
- $atom_file = $attribute['href'];
- }
- }
- if ($atom_file != '') {
- $related_atom = z_fetch_url($atom_file);
-
- if ($related_atom['success']) {
- logger('Fetched XML for URI '.$related_uri, LOGGER_DEBUG);
- $xml = $related_atom['body'];
- }
- }
- }
- }
-
- // Workaround for older GNU Social servers
- if (($xml == '') && strstr($related, '/notice/')) {
- $related_atom = z_fetch_url(str_replace('/notice/', '/api/statuses/show/', $related).'.atom');
-
- if ($related_atom['success']) {
- logger('GNU Social workaround to fetch XML for URI '.$related_uri, LOGGER_DEBUG);
- $xml = $related_atom['body'];
- }
- }
-
- // Even more worse workaround for GNU Social ;-)
- if ($xml == '') {
- $related_guess = ostatus::convert_href($related_uri);
- $related_atom = z_fetch_url(str_replace('/notice/', '/api/statuses/show/', $related_guess).'.atom');
-
- if ($related_atom['success']) {
- logger('GNU Social workaround 2 to fetch XML for URI '.$related_uri, LOGGER_DEBUG);
- $xml = $related_atom['body'];
- }
- }
-
- // Finally we take the data that we fetched from "ostatus:conversation"
- if ($xml == '') {
- $condition = array('item-uri' => $related_uri, 'protocol' => PROTOCOL_SPLITTED_CONV);
- $conversation = dba::select('conversation', array('source'), $condition, array('limit' => 1));
- if (DBM::is_result($conversation)) {
- $stored = true;
- logger('Got cached XML from conversation for URI '.$related_uri, LOGGER_DEBUG);
- $xml = $conversation['source'];
- }
- }
-
- if ($xml != '') {
- self::process($xml, $importer, $contact, $hub, $stored, false);
- } else {
- logger("XML couldn't be fetched for URI: ".$related_uri." - href: ".$related, LOGGER_DEBUG);
- }
- return;
- }
-
- /**
- * @brief Processes the XML for a repeated post
- *
- * @param object $xpath The xpath object
- * @param object $entry The xml entry that is processed
- * @param array $item The item array
- * @param array $importer user record of the importing user
- *
- * @return array with data from links
- */
- private static function processRepeatedItem($xpath, $entry, &$item, $importer)
- {
- $activityobjects = $xpath->query('activity:object', $entry)->item(0);
-
- if (!is_object($activityobjects)) {
- return array();
- }
-
- $link_data = array();
-
- $orig_uri = $xpath->query('atom:id/text()', $activityobjects)->item(0)->nodeValue;
-
- $links = $xpath->query("atom:link", $activityobjects);
- if ($links) {
- $link_data = self::processLinks($links, $item);
- }
-
- $orig_body = $xpath->query('atom:content/text()', $activityobjects)->item(0)->nodeValue;
- $orig_created = $xpath->query('atom:published/text()', $activityobjects)->item(0)->nodeValue;
- $orig_edited = $xpath->query('atom:updated/text()', $activityobjects)->item(0)->nodeValue;
-
- $orig_contact = $contact;
- $orig_author = self::fetchauthor($xpath, $activityobjects, $importer, $orig_contact, false);
-
- $item["author-name"] = $orig_author["author-name"];
- $item["author-link"] = $orig_author["author-link"];
- $item["author-avatar"] = $orig_author["author-avatar"];
-
- $item["body"] = html2bbcode($orig_body);
- $item["created"] = $orig_created;
- $item["edited"] = $orig_edited;
-
- $item["uri"] = $orig_uri;
-
- $item["verb"] = $xpath->query('activity:verb/text()', $activityobjects)->item(0)->nodeValue;
-
- $item["object-type"] = $xpath->query('activity:object-type/text()', $activityobjects)->item(0)->nodeValue;
-
- $inreplyto = $xpath->query('thr:in-reply-to', $activityobjects);
- if (is_object($inreplyto->item(0))) {
- foreach ($inreplyto->item(0)->attributes as $attributes) {
- if ($attributes->name == "ref") {
- $item["parent-uri"] = $attributes->textContent;
- }
- }
- }
-
- return $link_data;
- }
-
- /**
- * @brief Processes links in the XML
- *
- * @param object $links The xml data that contain links
- * @param array $item The item array
- *
- * @return array with data from the links
- */
- private static function processLinks($links, &$item)
- {
- $link_data = array('add_body' => '', 'self' => '');
-
- foreach ($links as $link) {
- $attribute = self::read_attributes($link);
-
- if (($attribute['rel'] != "") && ($attribute['href'] != "")) {
- switch ($attribute['rel']) {
- case "alternate":
- $item["plink"] = $attribute['href'];
- if (($item["object-type"] == ACTIVITY_OBJ_QUESTION)
- || ($item["object-type"] == ACTIVITY_OBJ_EVENT)
- ) {
- $item["body"] .= add_page_info($attribute['href']);
- }
- break;
- case "ostatus:conversation":
- $link_data['conversation'] = $attribute['href'];
- $item['conversation-href'] = $link_data['conversation'];
- if (!isset($item['conversation-uri'])) {
- $item['conversation-uri'] = $item['conversation-href'];
- }
- break;
- case "enclosure":
- $filetype = strtolower(substr($attribute['type'], 0, strpos($attribute['type'], '/')));
- if ($filetype == 'image') {
- $link_data['add_body'] .= "\n[img]".$attribute['href'].'[/img]';
- } else {
- if (strlen($item["attach"])) {
- $item["attach"] .= ',';
- }
- if (!isset($attribute['length'])) {
- $attribute['length'] = "0";
- }
- $item["attach"] .= '[attach]href="'.$attribute['href'].'" length="'.$attribute['length'].'" type="'.$attribute['type'].'" title="'.$attribute['title'].'"[/attach]';
- }
- break;
- case "related":
- if ($item["object-type"] != ACTIVITY_OBJ_BOOKMARK) {
- if (!isset($item["parent-uri"])) {
- $item["parent-uri"] = $attribute['href'];
- }
- $link_data['related'] = $attribute['href'];
- } else {
- $item["body"] .= add_page_info($attribute['href']);
- }
- break;
- case "self":
- if ($item["plink"] == '') {
- $item["plink"] = $attribute['href'];
- }
- $link_data['self'] = $attribute['href'];
- break;
- }
- }
- }
- return $link_data;
- }
-
- /**
- * @brief Create an url out of an uri
- *
- * @param string $href URI in the format "parameter1:parameter1:..."
- *
- * @return string URL in the format http(s)://....
- */
- public static function convert_href($href)
- {
- $elements = explode(":", $href);
-
- if ((count($elements) <= 2) || ($elements[0] != "tag")) {
- return $href;
- }
-
- $server = explode(",", $elements[1]);
- $conversation = explode("=", $elements[2]);
-
- if ((count($elements) == 4) && ($elements[2] == "post")) {
- return "http://".$server[0]."/notice/".$elements[3];
- }
-
- if ((count($conversation) != 2) || ($conversation[1] =="")) {
- return $href;
- }
- if ($elements[3] == "objectType=thread") {
- return "http://".$server[0]."/conversation/".$conversation[1];
- } else {
- return "http://".$server[0]."/notice/".$conversation[1];
- }
- return $href;
- }
-
- /**
- * @brief Checks if the current post is a reshare
- *
- * @param array $item The item array of thw post
- *
- * @return string The guid if the post is a reshare
- */
- private static function get_reshared_guid($item)
- {
- $body = trim($item["body"]);
-
- // Skip if it isn't a pure repeated messages
- // Does it start with a share?
- if (strpos($body, "[share") > 0) {
- return "";
- }
-
- // Does it end with a share?
- if (strlen($body) > (strrpos($body, "[/share]") + 8)) {
- return "";
- }
-
- $attributes = preg_replace("/\[share(.*?)\]\s?(.*?)\s?\[\/share\]\s?/ism", "$1", $body);
- // Skip if there is no shared message in there
- if ($body == $attributes) {
- return false;
- }
-
- $guid = "";
- preg_match("/guid='(.*?)'/ism", $attributes, $matches);
- if ($matches[1] != "") {
- $guid = $matches[1];
- }
-
- preg_match('/guid="(.*?)"/ism', $attributes, $matches);
- if ($matches[1] != "") {
- $guid = $matches[1];
- }
-
- return $guid;
- }
-
- /**
- * @brief Cleans the body of a post if it contains picture links
- *
- * @param string $body The body
- *
- * @return string The cleaned body
- */
- private static function format_picture_post($body)
- {
- $siteinfo = get_attached_data($body);
-
- if (($siteinfo["type"] == "photo")) {
- if (isset($siteinfo["preview"])) {
- $preview = $siteinfo["preview"];
- } else {
- $preview = $siteinfo["image"];
- }
-
- // Is it a remote picture? Then make a smaller preview here
- $preview = proxy_url($preview, false, PROXY_SIZE_SMALL);
-
- // Is it a local picture? Then make it smaller here
- $preview = str_replace(array("-0.jpg", "-0.png"), array("-2.jpg", "-2.png"), $preview);
- $preview = str_replace(array("-1.jpg", "-1.png"), array("-2.jpg", "-2.png"), $preview);
-
- if (isset($siteinfo["url"])) {
- $url = $siteinfo["url"];
- } else {
- $url = $siteinfo["image"];
- }
-
- $body = trim($siteinfo["text"])." [url]".$url."[/url]\n[img]".$preview."[/img]";
- }
-
- return $body;
- }
-
- /**
- * @brief Adds the header elements to the XML document
- *
- * @param object $doc XML document
- * @param array $owner Contact data of the poster
- *
- * @return object header root element
- */
- private static function add_header($doc, $owner)
- {
- $a = get_app();
-
- $root = $doc->createElementNS(NAMESPACE_ATOM1, 'feed');
- $doc->appendChild($root);
-
- $root->setAttribute("xmlns:thr", NAMESPACE_THREAD);
- $root->setAttribute("xmlns:georss", NAMESPACE_GEORSS);
- $root->setAttribute("xmlns:activity", NAMESPACE_ACTIVITY);
- $root->setAttribute("xmlns:media", NAMESPACE_MEDIA);
- $root->setAttribute("xmlns:poco", NAMESPACE_POCO);
- $root->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
- $root->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
- $root->setAttribute("xmlns:mastodon", NAMESPACE_MASTODON);
-
- $attributes = array("uri" => "https://friendi.ca", "version" => FRIENDICA_VERSION."-".DB_UPDATE_VERSION);
- XML::add_element($doc, $root, "generator", FRIENDICA_PLATFORM, $attributes);
- XML::add_element($doc, $root, "id", System::baseUrl()."/profile/".$owner["nick"]);
- XML::add_element($doc, $root, "title", sprintf("%s timeline", $owner["name"]));
- XML::add_element($doc, $root, "subtitle", sprintf("Updates from %s on %s", $owner["name"], $a->config["sitename"]));
- XML::add_element($doc, $root, "logo", $owner["photo"]);
- XML::add_element($doc, $root, "updated", datetime_convert("UTC", "UTC", "now", ATOM_TIME));
-
- $author = self::add_author($doc, $owner);
- $root->appendChild($author);
-
- $attributes = array("href" => $owner["url"], "rel" => "alternate", "type" => "text/html");
- XML::add_element($doc, $root, "link", "", $attributes);
-
- /// @TODO We have to find out what this is
- /// $attributes = array("href" => System::baseUrl()."/sup",
- /// "rel" => "http://api.friendfeed.com/2008/03#sup",
- /// "type" => "application/json");
- /// XML::add_element($doc, $root, "link", "", $attributes);
-
- self::hublinks($doc, $root, $owner["nick"]);
-
- $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "salmon");
- XML::add_element($doc, $root, "link", "", $attributes);
-
- $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "http://salmon-protocol.org/ns/salmon-replies");
- XML::add_element($doc, $root, "link", "", $attributes);
-
- $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "http://salmon-protocol.org/ns/salmon-mention");
- XML::add_element($doc, $root, "link", "", $attributes);
-
- $attributes = array("href" => System::baseUrl()."/api/statuses/user_timeline/".$owner["nick"].".atom",
- "rel" => "self", "type" => "application/atom+xml");
- XML::add_element($doc, $root, "link", "", $attributes);
-
- return $root;
- }
-
- /**
- * @brief Add the link to the push hubs to the XML document
- *
- * @param object $doc XML document
- * @param object $root XML root element where the hub links are added
- * @param object $nick nick
- */
- public static function hublinks($doc, $root, $nick)
- {
- $h = System::baseUrl() . '/pubsubhubbub/'.$nick;
- XML::add_element($doc, $root, "link", "", array("href" => $h, "rel" => "hub"));
- }
-
- /**
- * @brief Adds attachement data to the XML document
- *
- * @param object $doc XML document
- * @param object $root XML root element where the hub links are added
- * @param array $item Data of the item that is to be posted
- */
- private static function get_attachment($doc, $root, $item)
- {
- $o = "";
- $siteinfo = get_attached_data($item["body"]);
-
- switch ($siteinfo["type"]) {
- case 'photo':
- $imgdata = get_photo_info($siteinfo["image"]);
- $attributes = array("rel" => "enclosure",
- "href" => $siteinfo["image"],
- "type" => $imgdata["mime"],
- "length" => intval($imgdata["size"]));
- XML::add_element($doc, $root, "link", "", $attributes);
- break;
- case 'video':
- $attributes = array("rel" => "enclosure",
- "href" => $siteinfo["url"],
- "type" => "text/html; charset=UTF-8",
- "length" => "",
- "title" => $siteinfo["title"]);
- XML::add_element($doc, $root, "link", "", $attributes);
- break;
- default:
- break;
- }
-
- if (!Config::get('system', 'ostatus_not_attach_preview') && ($siteinfo["type"] != "photo") && isset($siteinfo["image"])) {
- $imgdata = get_photo_info($siteinfo["image"]);
- $attributes = array("rel" => "enclosure",
- "href" => $siteinfo["image"],
- "type" => $imgdata["mime"],
- "length" => intval($imgdata["size"]));
-
- XML::add_element($doc, $root, "link", "", $attributes);
- }
-
- $arr = explode('[/attach],', $item['attach']);
- if (count($arr)) {
- foreach ($arr as $r) {
- $matches = false;
- $cnt = preg_match('|\[attach\]href=\"(.*?)\" length=\"(.*?)\" type=\"(.*?)\" title=\"(.*?)\"|', $r, $matches);
- if ($cnt) {
- $attributes = array("rel" => "enclosure",
- "href" => $matches[1],
- "type" => $matches[3]);
-
- if (intval($matches[2])) {
- $attributes["length"] = intval($matches[2]);
- }
- if (trim($matches[4]) != "") {
- $attributes["title"] = trim($matches[4]);
- }
- XML::add_element($doc, $root, "link", "", $attributes);
- }
- }
- }
- }
-
- /**
- * @brief Adds the author element to the XML document
- *
- * @param object $doc XML document
- * @param array $owner Contact data of the poster
- *
- * @return object author element
- */
- private static function add_author($doc, $owner)
- {
- $r = q("SELECT `homepage`, `publish` FROM `profile` WHERE `uid` = %d AND `is-default` LIMIT 1", intval($owner["uid"]));
- if (DBM::is_result($r)) {
- $profile = $r[0];
- }
- $author = $doc->createElement("author");
- XML::add_element($doc, $author, "id", $owner["url"]);
- XML::add_element($doc, $author, "activity:object-type", ACTIVITY_OBJ_PERSON);
- XML::add_element($doc, $author, "uri", $owner["url"]);
- XML::add_element($doc, $author, "name", $owner["nick"]);
- XML::add_element($doc, $author, "email", $owner["addr"]);
- XML::add_element($doc, $author, "summary", bbcode($owner["about"], false, false, 7));
-
- $attributes = array("rel" => "alternate", "type" => "text/html", "href" => $owner["url"]);
- XML::add_element($doc, $author, "link", "", $attributes);
-
- $attributes = array(
- "rel" => "avatar",
- "type" => "image/jpeg", // To-Do?
- "media:width" => 175,
- "media:height" => 175,
- "href" => $owner["photo"]);
- XML::add_element($doc, $author, "link", "", $attributes);
-
- if (isset($owner["thumb"])) {
- $attributes = array(
- "rel" => "avatar",
- "type" => "image/jpeg", // To-Do?
- "media:width" => 80,
- "media:height" => 80,
- "href" => $owner["thumb"]);
- XML::add_element($doc, $author, "link", "", $attributes);
- }
-
- XML::add_element($doc, $author, "poco:preferredUsername", $owner["nick"]);
- XML::add_element($doc, $author, "poco:displayName", $owner["name"]);
- XML::add_element($doc, $author, "poco:note", bbcode($owner["about"], false, false, 7));
-
- if (trim($owner["location"]) != "") {
- $element = $doc->createElement("poco:address");
- XML::add_element($doc, $element, "poco:formatted", $owner["location"]);
- $author->appendChild($element);
- }
-
- if (trim($profile["homepage"]) != "") {
- $urls = $doc->createElement("poco:urls");
- XML::add_element($doc, $urls, "poco:type", "homepage");
- XML::add_element($doc, $urls, "poco:value", $profile["homepage"]);
- XML::add_element($doc, $urls, "poco:primary", "true");
- $author->appendChild($urls);
- }
-
- if (count($profile)) {
- XML::add_element($doc, $author, "followers", "", array("url" => System::baseUrl()."/viewcontacts/".$owner["nick"]));
- XML::add_element($doc, $author, "statusnet:profile_info", "", array("local_id" => $owner["uid"]));
- }
-
- if ($profile["publish"]) {
- XML::add_element($doc, $author, "mastodon:scope", "public");
- }
- return $author;
- }
-
- /**
- * @TODO Picture attachments should look like this:
- * <a href="https://status.pirati.ca/attachment/572819" title="https://status.pirati.ca/file/heluecht-20151202T222602-rd3u49p.gif"
- * class="attachment thumbnail" id="attachment-572819" rel="nofollow external">https://status.pirati.ca/attachment/572819</a>
- */
-
- /**
- * @brief Returns the given activity if present - otherwise returns the "post" activity
- *
- * @param array $item Data of the item that is to be posted
- *
- * @return string activity
- */
- private static function construct_verb($item)
- {
- if ($item['verb']) {
- return $item['verb'];
- }
-
- return ACTIVITY_POST;
- }
-
- /**
- * @brief Returns the given object type if present - otherwise returns the "note" object type
- *
- * @param array $item Data of the item that is to be posted
- *
- * @return string Object type
- */
- private static function construct_objecttype($item)
- {
- if (in_array($item['object-type'], array(ACTIVITY_OBJ_NOTE, ACTIVITY_OBJ_COMMENT)))
- return $item['object-type'];
- return ACTIVITY_OBJ_NOTE;
- }
-
- /**
- * @brief Adds an entry element to the XML document
- *
- * @param object $doc XML document
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param bool $toplevel optional default false
- *
- * @return object Entry element
- */
- private static function entry($doc, $item, $owner, $toplevel = false)
- {
- $repeated_guid = self::get_reshared_guid($item);
- if ($repeated_guid != "") {
- $xml = self::reshare_entry($doc, $item, $owner, $repeated_guid, $toplevel);
- }
-
- if ($xml) {
- return $xml;
- }
-
- if ($item["verb"] == ACTIVITY_LIKE) {
- return self::like_entry($doc, $item, $owner, $toplevel);
- } elseif (in_array($item["verb"], array(ACTIVITY_FOLLOW, NAMESPACE_OSTATUS."/unfollow"))) {
- return self::follow_entry($doc, $item, $owner, $toplevel);
- } else {
- return self::note_entry($doc, $item, $owner, $toplevel);
- }
- }
-
- /**
- * @brief Adds a source entry to the XML document
- *
- * @param object $doc XML document
- * @param array $contact Array of the contact that is added
- *
- * @return object Source element
- */
- private static function source_entry($doc, $contact)
- {
- $source = $doc->createElement("source");
- XML::add_element($doc, $source, "id", $contact["poll"]);
- XML::add_element($doc, $source, "title", $contact["name"]);
- XML::add_element($doc, $source, "link", "", array("rel" => "alternate", "type" => "text/html", "href" => $contact["alias"]));
- XML::add_element($doc, $source, "link", "", array("rel" => "self", "type" => "application/atom+xml", "href" => $contact["poll"]));
- XML::add_element($doc, $source, "icon", $contact["photo"]);
- XML::add_element($doc, $source, "updated", datetime_convert("UTC", "UTC", $contact["success_update"]."+00:00", ATOM_TIME));
-
- return $source;
- }
-
- /**
- * @brief Fetches contact data from the contact or the gcontact table
- *
- * @param string $url URL of the contact
- * @param array $owner Contact data of the poster
- *
- * @return array Contact array
- */
- private static function contact_entry($url, $owner)
- {
- $r = q(
- "SELECT * FROM `contact` WHERE `nurl` = '%s' AND `uid` IN (0, %d) ORDER BY `uid` DESC LIMIT 1",
- dbesc(normalise_link($url)),
- intval($owner["uid"])
- );
- if (DBM::is_result($r)) {
- $contact = $r[0];
- $contact["uid"] = -1;
- }
-
- if (!DBM::is_result($r)) {
- $r = q(
- "SELECT * FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
- dbesc(normalise_link($url))
- );
- if (DBM::is_result($r)) {
- $contact = $r[0];
- $contact["uid"] = -1;
- $contact["success_update"] = $contact["updated"];
- }
- }
-
- if (!DBM::is_result($r)) {
- $contact = owner;
- }
-
- if (!isset($contact["poll"])) {
- $data = Probe::uri($url);
- $contact["poll"] = $data["poll"];
-
- if (!$contact["alias"]) {
- $contact["alias"] = $data["alias"];
- }
- }
-
- if (!isset($contact["alias"])) {
- $contact["alias"] = $contact["url"];
- }
-
- return $contact;
- }
-
- /**
- * @brief Adds an entry element with reshared content
- *
- * @param object $doc XML document
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param $repeated_guid
- * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
- *
- * @return object Entry element
- */
- private static function reshare_entry($doc, $item, $owner, $repeated_guid, $toplevel)
- {
- if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
- logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
- }
-
- $title = self::entry_header($doc, $entry, $owner, $toplevel);
-
- $r = q(
- "SELECT * FROM `item` WHERE `uid` = %d AND `guid` = '%s' AND NOT `private` AND `network` IN ('%s', '%s', '%s') LIMIT 1",
- intval($owner["uid"]),
- dbesc($repeated_guid),
- dbesc(NETWORK_DFRN),
- dbesc(NETWORK_DIASPORA),
- dbesc(NETWORK_OSTATUS)
- );
- if (DBM::is_result($r)) {
- $repeated_item = $r[0];
- } else {
- return false;
- }
- $contact = self::contact_entry($repeated_item['author-link'], $owner);
-
- $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
-
- $title = $owner["nick"]." repeated a notice by ".$contact["nick"];
-
- self::entry_content($doc, $entry, $item, $owner, $title, ACTIVITY_SHARE, false);
-
- $as_object = $doc->createElement("activity:object");
-
- XML::add_element($doc, $as_object, "activity:object-type", NAMESPACE_ACTIVITY_SCHEMA."activity");
-
- self::entry_content($doc, $as_object, $repeated_item, $owner, "", "", false);
-
- $author = self::add_author($doc, $contact);
- $as_object->appendChild($author);
-
- $as_object2 = $doc->createElement("activity:object");
-
- XML::add_element($doc, $as_object2, "activity:object-type", self::construct_objecttype($repeated_item));
-
- $title = sprintf("New comment by %s", $contact["nick"]);
-
- self::entry_content($doc, $as_object2, $repeated_item, $owner, $title);
-
- $as_object->appendChild($as_object2);
-
- self::entry_footer($doc, $as_object, $item, $owner, false);
-
- $source = self::source_entry($doc, $contact);
-
- $as_object->appendChild($source);
-
- $entry->appendChild($as_object);
-
- self::entry_footer($doc, $entry, $item, $owner);
-
- return $entry;
- }
-
- /**
- * @brief Adds an entry element with a "like"
- *
- * @param object $doc XML document
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
- *
- * @return object Entry element with "like"
- */
- private static function like_entry($doc, $item, $owner, $toplevel)
- {
- if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
- logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
- }
-
- $title = self::entry_header($doc, $entry, $owner, $toplevel);
-
- $verb = NAMESPACE_ACTIVITY_SCHEMA."favorite";
- self::entry_content($doc, $entry, $item, $owner, "Favorite", $verb, false);
-
- $as_object = $doc->createElement("activity:object");
-
- $parent = q(
- "SELECT * FROM `item` WHERE `uri` = '%s' AND `uid` = %d",
- dbesc($item["thr-parent"]),
- intval($item["uid"])
- );
- $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
-
- XML::add_element($doc, $as_object, "activity:object-type", self::construct_objecttype($parent[0]));
-
- self::entry_content($doc, $as_object, $parent[0], $owner, "New entry");
-
- $entry->appendChild($as_object);
-
- self::entry_footer($doc, $entry, $item, $owner);
-
- return $entry;
- }
-
- /**
- * @brief Adds the person object element to the XML document
- *
- * @param object $doc XML document
- * @param array $owner Contact data of the poster
- * @param array $contact Contact data of the target
- *
- * @return object author element
- */
- private static function add_person_object($doc, $owner, $contact)
- {
- $object = $doc->createElement("activity:object");
- XML::add_element($doc, $object, "activity:object-type", ACTIVITY_OBJ_PERSON);
-
- if ($contact['network'] == NETWORK_PHANTOM) {
- XML::add_element($doc, $object, "id", $contact['url']);
- return $object;
- }
-
- XML::add_element($doc, $object, "id", $contact["alias"]);
- XML::add_element($doc, $object, "title", $contact["nick"]);
-
- $attributes = array("rel" => "alternate", "type" => "text/html", "href" => $contact["url"]);
- XML::add_element($doc, $object, "link", "", $attributes);
-
- $attributes = array(
- "rel" => "avatar",
- "type" => "image/jpeg", // To-Do?
- "media:width" => 175,
- "media:height" => 175,
- "href" => $contact["photo"]);
- XML::add_element($doc, $object, "link", "", $attributes);
-
- XML::add_element($doc, $object, "poco:preferredUsername", $contact["nick"]);
- XML::add_element($doc, $object, "poco:displayName", $contact["name"]);
-
- if (trim($contact["location"]) != "") {
- $element = $doc->createElement("poco:address");
- XML::add_element($doc, $element, "poco:formatted", $contact["location"]);
- $object->appendChild($element);
- }
-
- return $object;
- }
-
- /**
- * @brief Adds a follow/unfollow entry element
- *
- * @param object $doc XML document
- * @param array $item Data of the follow/unfollow message
- * @param array $owner Contact data of the poster
- * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
- *
- * @return object Entry element
- */
- private static function follow_entry($doc, $item, $owner, $toplevel)
- {
- $item["id"] = $item["parent"] = 0;
- $item["created"] = $item["edited"] = date("c");
- $item["private"] = true;
-
- $contact = Probe::uri($item['follow']);
-
- if ($contact['alias'] == '') {
- $contact['alias'] = $contact["url"];
- } else {
- $item['follow'] = $contact['alias'];
- }
-
- $r = q(
- "SELECT `id` FROM `contact` WHERE `uid` = %d AND `nurl` = '%s'",
- intval($owner['uid']),
- dbesc(normalise_link($contact["url"]))
- );
-
- if (DBM::is_result($r)) {
- $connect_id = $r[0]['id'];
- } else {
- $connect_id = 0;
- }
-
- if ($item['verb'] == ACTIVITY_FOLLOW) {
- $message = t('%s is now following %s.');
- $title = t('following');
- $action = "subscription";
- } else {
- $message = t('%s stopped following %s.');
- $title = t('stopped following');
- $action = "unfollow";
- }
-
- $item["uri"] = $item['parent-uri'] = $item['thr-parent']
- = 'tag:'.get_app()->get_hostname().
- ','.date('Y-m-d').':'.$action.':'.$owner['uid'].
- ':person:'.$connect_id.':'.$item['created'];
-
- $item["body"] = sprintf($message, $owner["nick"], $contact["nick"]);
-
- self::entry_header($doc, $entry, $owner, $toplevel);
-
- self::entry_content($doc, $entry, $item, $owner, $title);
-
- $object = self::add_person_object($doc, $owner, $contact);
- $entry->appendChild($object);
-
- self::entry_footer($doc, $entry, $item, $owner);
-
- return $entry;
- }
-
- /**
- * @brief Adds a regular entry element
- *
- * @param object $doc XML document
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
- *
- * @return object Entry element
- */
- private static function note_entry($doc, $item, $owner, $toplevel)
- {
- if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
- logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
- }
-
- $title = self::entry_header($doc, $entry, $owner, $toplevel);
-
- XML::add_element($doc, $entry, "activity:object-type", ACTIVITY_OBJ_NOTE);
-
- self::entry_content($doc, $entry, $item, $owner, $title);
-
- self::entry_footer($doc, $entry, $item, $owner);
-
- return $entry;
- }
-
- /**
- * @brief Adds a header element to the XML document
- *
- * @param object $doc XML document
- * @param object $entry The entry element where the elements are added
- * @param array $owner Contact data of the poster
- * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
- *
- * @return string The title for the element
- */
- private static function entry_header($doc, &$entry, $owner, $toplevel)
- {
- /// @todo Check if this title stuff is really needed (I guess not)
- if (!$toplevel) {
- $entry = $doc->createElement("entry");
- $title = sprintf("New note by %s", $owner["nick"]);
- } else {
- $entry = $doc->createElementNS(NAMESPACE_ATOM1, "entry");
-
- $entry->setAttribute("xmlns:thr", NAMESPACE_THREAD);
- $entry->setAttribute("xmlns:georss", NAMESPACE_GEORSS);
- $entry->setAttribute("xmlns:activity", NAMESPACE_ACTIVITY);
- $entry->setAttribute("xmlns:media", NAMESPACE_MEDIA);
- $entry->setAttribute("xmlns:poco", NAMESPACE_POCO);
- $entry->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
- $entry->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
- $entry->setAttribute("xmlns:mastodon", NAMESPACE_MASTODON);
-
- $author = self::add_author($doc, $owner);
- $entry->appendChild($author);
-
- $title = sprintf("New comment by %s", $owner["nick"]);
- }
- return $title;
- }
-
- /**
- * @brief Adds elements to the XML document
- *
- * @param object $doc XML document
- * @param object $entry Entry element where the content is added
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param string $title Title for the post
- * @param string $verb The activity verb
- * @param bool $complete Add the "status_net" element?
- */
- private static function entry_content($doc, $entry, $item, $owner, $title, $verb = "", $complete = true)
- {
- if ($verb == "") {
- $verb = self::construct_verb($item);
- }
-
- XML::add_element($doc, $entry, "id", $item["uri"]);
- XML::add_element($doc, $entry, "title", $title);
-
- $body = self::format_picture_post($item['body']);
-
- if ($item['title'] != "") {
- $body = "[b]".$item['title']."[/b]\n\n".$body;
- }
-
- $body = bbcode($body, false, false, 7);
-
- XML::add_element($doc, $entry, "content", $body, array("type" => "html"));
-
- XML::add_element($doc, $entry, "link", "", array("rel" => "alternate", "type" => "text/html",
- "href" => System::baseUrl()."/display/".$item["guid"])
- );
-
- if ($complete && ($item["id"] > 0)) {
- XML::add_element($doc, $entry, "status_net", "", array("notice_id" => $item["id"]));
- }
-
- XML::add_element($doc, $entry, "activity:verb", $verb);
-
- XML::add_element($doc, $entry, "published", datetime_convert("UTC", "UTC", $item["created"]."+00:00", ATOM_TIME));
- XML::add_element($doc, $entry, "updated", datetime_convert("UTC", "UTC", $item["edited"]."+00:00", ATOM_TIME));
- }
-
- /**
- * @brief Adds the elements at the foot of an entry to the XML document
- *
- * @param object $doc XML document
- * @param object $entry The entry element where the elements are added
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- * @param bool $complete default true
- */
- private static function entry_footer($doc, $entry, $item, $owner, $complete = true)
- {
- $mentioned = array();
-
- if (($item['parent'] != $item['id']) || ($item['parent-uri'] !== $item['uri']) || (($item['thr-parent'] !== '') && ($item['thr-parent'] !== $item['uri']))) {
- $parent = q("SELECT `guid`, `author-link`, `owner-link` FROM `item` WHERE `id` = %d", intval($item["parent"]));
- $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
-
- $thrparent = q(
- "SELECT `guid`, `author-link`, `owner-link`, `plink` FROM `item` WHERE `uid` = %d AND `uri` = '%s'",
- intval($owner["uid"]),
- dbesc($parent_item)
- );
- if ($thrparent) {
- $mentioned[$thrparent[0]["author-link"]] = $thrparent[0]["author-link"];
- $mentioned[$thrparent[0]["owner-link"]] = $thrparent[0]["owner-link"];
- $parent_plink = $thrparent[0]["plink"];
- } else {
- $mentioned[$parent[0]["author-link"]] = $parent[0]["author-link"];
- $mentioned[$parent[0]["owner-link"]] = $parent[0]["owner-link"];
- $parent_plink = System::baseUrl()."/display/".$parent[0]["guid"];
- }
-
- $attributes = array(
- "ref" => $parent_item,
- "href" => $parent_plink);
- XML::add_element($doc, $entry, "thr:in-reply-to", "", $attributes);
-
- $attributes = array(
- "rel" => "related",
- "href" => $parent_plink);
- XML::add_element($doc, $entry, "link", "", $attributes);
- }
-
- if (intval($item["parent"]) > 0) {
- $conversation_href = System::baseUrl()."/display/".$owner["nick"]."/".$item["parent"];
- $conversation_uri = $conversation_href;
-
- if (isset($parent_item)) {
- $r = dba::fetch_first("SELECT `conversation-uri`, `conversation-href` FROM `conversation` WHERE `item-uri` = ?", $parent_item);
- if (DBM::is_result($r)) {
- if ($r['conversation-uri'] != '') {
- $conversation_uri = $r['conversation-uri'];
- }
- if ($r['conversation-href'] != '') {
- $conversation_href = $r['conversation-href'];
- }
- }
- }
-
- XML::add_element($doc, $entry, "link", "", array("rel" => "ostatus:conversation", "href" => $conversation_href));
-
- $attributes = array(
- "href" => $conversation_href,
- "local_id" => $item["parent"],
- "ref" => $conversation_uri);
-
- XML::add_element($doc, $entry, "ostatus:conversation", $conversation_uri, $attributes);
- }
-
- $tags = item_getfeedtags($item);
-
- if (count($tags)) {
- foreach ($tags as $t) {
- if ($t[0] == "@") {
- $mentioned[$t[1]] = $t[1];
- }
- }
- }
-
- // Make sure that mentions are accepted (GNU Social has problems with mixing HTTP and HTTPS)
- $newmentions = array();
- foreach ($mentioned as $mention) {
- $newmentions[str_replace("http://", "https://", $mention)] = str_replace("http://", "https://", $mention);
- $newmentions[str_replace("https://", "http://", $mention)] = str_replace("https://", "http://", $mention);
- }
- $mentioned = $newmentions;
-
- foreach ($mentioned as $mention) {
- $r = q(
- "SELECT `forum`, `prv` FROM `contact` WHERE `uid` = %d AND `nurl` = '%s'",
- intval($owner["uid"]),
- dbesc(normalise_link($mention))
- );
- if ($r[0]["forum"] || $r[0]["prv"]) {
- XML::add_element($doc, $entry, "link", "",
- array(
- "rel" => "mentioned",
- "ostatus:object-type" => ACTIVITY_OBJ_GROUP,
- "href" => $mention)
- );
- } else {
- XML::add_element($doc, $entry, "link", "",
- array(
- "rel" => "mentioned",
- "ostatus:object-type" => ACTIVITY_OBJ_PERSON,
- "href" => $mention)
- );
- }
- }
-
- if (!$item["private"]) {
- XML::add_element($doc, $entry, "link", "", array("rel" => "ostatus:attention",
- "href" => "http://activityschema.org/collection/public"));
- XML::add_element($doc, $entry, "link", "", array("rel" => "mentioned",
- "ostatus:object-type" => "http://activitystrea.ms/schema/1.0/collection",
- "href" => "http://activityschema.org/collection/public"));
- XML::add_element($doc, $entry, "mastodon:scope", "public");
- }
-
- if (count($tags)) {
- foreach ($tags as $t) {
- if ($t[0] != "@") {
- XML::add_element($doc, $entry, "category", "", array("term" => $t[2]));
- }
- }
- }
-
- self::get_attachment($doc, $entry, $item);
-
- if ($complete && ($item["id"] > 0)) {
- $app = $item["app"];
- if ($app == "") {
- $app = "web";
- }
-
- $attributes = array("local_id" => $item["id"], "source" => $app);
-
- if (isset($parent["id"])) {
- $attributes["repeat_of"] = $parent["id"];
- }
-
- if ($item["coord"] != "") {
- XML::add_element($doc, $entry, "georss:point", $item["coord"]);
- }
-
- XML::add_element($doc, $entry, "statusnet:notice_info", "", $attributes);
- }
- }
-
- /**
- * @brief Creates the XML feed for a given nickname
- *
- * @param object $a The application class
- * @param string $owner_nick Nickname of the feed owner
- * @param string $last_update Date of the last update
- * @param integer $max_items Number of maximum items to fetch
- *
- * @return string XML feed
- */
- public static function feed(App $a, $owner_nick, &$last_update, $max_items = 300)
- {
- $stamp = microtime(true);
-
- $cachekey = "ostatus:feed:".$owner_nick.":".$last_update;
-
- $previous_created = $last_update;
-
- $result = Cache::get($cachekey);
- if (!is_null($result)) {
- logger('Feed duration: '.number_format(microtime(true) - $stamp, 3).' - '.$owner_nick.' - '.$previous_created.' (cached)', LOGGER_DEBUG);
- $last_update = $result['last_update'];
- return $result['feed'];
- }
-
- $r = q(
- "SELECT `contact`.*, `user`.`nickname`, `user`.`timezone`, `user`.`page-flags`
- FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
- WHERE `contact`.`self` AND `user`.`nickname` = '%s' LIMIT 1",
- dbesc($owner_nick)
- );
- if (!DBM::is_result($r)) {
- return;
- }
-
- $owner = $r[0];
-
- if (!strlen($last_update)) {
- $last_update = 'now -30 days';
- }
-
- $check_date = datetime_convert('UTC', 'UTC', $last_update, 'Y-m-d H:i:s');
- $authorid = get_contact($owner["url"], 0);
-
- $items = q(
- "SELECT `item`.*, `item`.`id` AS `item_id` FROM `item` USE INDEX (`uid_contactid_created`)
- STRAIGHT_JOIN `thread` ON `thread`.`iid` = `item`.`parent`
- WHERE `item`.`uid` = %d AND `item`.`contact-id` = %d AND
- `item`.`author-id` = %d AND `item`.`created` > '%s' AND
- NOT `item`.`deleted` AND NOT `item`.`private` AND
- `thread`.`network` IN ('%s', '%s')
- ORDER BY `item`.`created` DESC LIMIT %d",
- intval($owner["uid"]), intval($owner["id"]),
- intval($authorid), dbesc($check_date),
- dbesc(NETWORK_OSTATUS), dbesc(NETWORK_DFRN), intval($max_items)
- );
-
- $doc = new DOMDocument('1.0', 'utf-8');
- $doc->formatOutput = true;
-
- $root = self::add_header($doc, $owner);
-
- foreach ($items as $item) {
- if (Config::get('system', 'ostatus_debug')) {
- $item['body'] .= '🍼';
- }
- $entry = self::entry($doc, $item, $owner);
- $root->appendChild($entry);
-
- if ($last_update < $item['created']) {
- $last_update = $item['created'];
- }
- }
-
- $feeddata = trim($doc->saveXML());
-
- $msg = array('feed' => $feeddata, 'last_update' => $last_update);
- Cache::set($cachekey, $msg, CACHE_QUARTER_HOUR);
-
- logger('Feed duration: '.number_format(microtime(true) - $stamp, 3).' - '.$owner_nick.' - '.$previous_created, LOGGER_DEBUG);
-
- return $feeddata;
- }
-
- /**
- * @brief Creates the XML for a salmon message
- *
- * @param array $item Data of the item that is to be posted
- * @param array $owner Contact data of the poster
- *
- * @return string XML for the salmon
- */
- public static function salmon($item, $owner)
- {
- $doc = new DOMDocument('1.0', 'utf-8');
- $doc->formatOutput = true;
-
- if (Config::get('system', 'ostatus_debug')) {
- $item['body'] .= '🐟';
- }
-
- $entry = self::entry($doc, $item, $owner, true);
-
- $doc->appendChild($entry);
-
- return trim($doc->saveXML());
- }
-}
* @param string $plugin name of the addon
* @return boolean
*/
-if (! function_exists('uninstall_plugin')){
-function uninstall_plugin($plugin){
+function uninstall_plugin($plugin) {
logger("Addons: uninstalling " . $plugin);
- q("DELETE FROM `addon` WHERE `name` = '%s' ",
- dbesc($plugin)
- );
+ dba::delete('addon', array('name' => $plugin));
@include_once('addon/' . $plugin . '/' . $plugin . '.php');
if (function_exists($plugin . '_uninstall')) {
$func = $plugin . '_uninstall';
$func();
}
-}}
+}
/**
* @brief installs an addon.
* @param string $plugin name of the addon
* @return bool
*/
-if (! function_exists('install_plugin')){
function install_plugin($plugin) {
// silently fail if plugin was removed
- if (! file_exists('addon/' . $plugin . '/' . $plugin . '.php'))
+ if (!file_exists('addon/' . $plugin . '/' . $plugin . '.php')) {
return false;
+ }
logger("Addons: installing " . $plugin);
$t = @filemtime('addon/' . $plugin . '/' . $plugin . '.php');
@include_once('addon/' . $plugin . '/' . $plugin . '.php');
dba::update('addon', array('hidden' => true), array('name' => $plugin));
}
return true;
- }
- else {
+ } else {
logger("Addons: FAILED installing " . $plugin);
return false;
}
-
-}}
+}
// reload all updated plugins
-if (! function_exists('reload_plugins')) {
function reload_plugins() {
- $plugins = Config::get('system','addon');
+ $plugins = Config::get('system', 'addon');
if (strlen($plugins)) {
$r = q("SELECT * FROM `addon` WHERE `installed` = 1");
- if (DBM::is_result($r))
+ if (DBM::is_result($r)) {
$installed = $r;
- else
+ } else {
$installed = array();
+ }
$parr = explode(',',$plugins);
}
}
-}}
+}
/**
* @brief check if addon is enabled
* @param int $priority A priority (defaults to 0)
* @return mixed|bool
*/
-if (! function_exists('register_hook')) {
-function register_hook($hook,$file,$function,$priority=0) {
-
- $r = q("SELECT * FROM `hook` WHERE `hook` = '%s' AND `file` = '%s' AND `function` = '%s' LIMIT 1",
- dbesc($hook),
- dbesc($file),
- dbesc($function)
- );
- if (DBM::is_result($r))
+function register_hook($hook, $file, $function, $priority=0) {
+ $condition = array('hook' => $hook, 'file' => $file, 'function' => $function);
+ $exists = dba::exists('hook', $condition);
+ if ($exists) {
return true;
+ }
$r = dba::insert('hook', array('hook' => $hook, 'file' => $file, 'function' => $function, 'priority' => $priority));
return $r;
-}}
+}
/**
* @brief unregisters a hook.
* @param string $function the name of the function that the hook called
* @return array
*/
-if (! function_exists('unregister_hook')) {
-function unregister_hook($hook,$file,$function) {
-
- $r = q("DELETE FROM `hook` WHERE `hook` = '%s' AND `file` = '%s' AND `function` = '%s'",
- dbesc($hook),
- dbesc($file),
- dbesc($function)
- );
+function unregister_hook($hook, $file, $function) {
+ $condition = array('hook' => $hook, 'file' => $file, 'function' => $function);
+ $r = dba::delete('hook', $condition);
return $r;
-}}
+}
function load_hooks() {
$func($a, $data);
} else {
// remove orphan hooks
- q("DELETE FROM `hook` WHERE `hook` = '%s' AND `file` = '%s' AND `function` = '%s'",
- dbesc($name),
- dbesc($hook[0]),
- dbesc($hook[1])
- );
+ $condition = array('hook' => $name, 'file' => $hook[0], 'function' => $hook[1]);
+ dba::delete('hook', $condition);
}
}
//check if an app_menu hook exist for plugin $name.
//Return true if the plugin is an app
-if (! function_exists('plugin_is_app')) {
function plugin_is_app($name) {
$a = get_app();
}
return false;
-}}
+}
/**
* @brief Parse plugin comment in search of plugin infos.
* @return array with the plugin information
*/
-if (! function_exists('get_plugin_info')){
-function get_plugin_info($plugin){
+function get_plugin_info($plugin) {
$a = get_app();
$r = preg_match("|/\*.*\*/|msU", $f, $m);
- if ($r){
+ if ($r) {
$ll = explode("\n", $m[0]);
foreach ( $ll as $l ) {
$l = trim($l,"\t\n\r */");
- if ($l!=""){
+ if ($l != "") {
list($k,$v) = array_map("trim", explode(":",$l,2));
$k= strtolower($k);
- if ($k=="author"){
+ if ($k == "author") {
$r=preg_match("|([^<]+)<([^>]+)>|", $v, $m);
if ($r) {
$info['author'][] = array('name'=>$m[1], 'link'=>$m[2]);
$info['author'][] = array('name'=>$v);
}
} else {
- if (array_key_exists($k,$info)){
+ if (array_key_exists($k,$info)) {
$info[$k]=$v;
}
}
}
return $info;
-}}
+}
/**
* @return array
*/
-if (! function_exists('get_theme_info')){
-function get_theme_info($theme){
+function get_theme_info($theme) {
$info=Array(
'name' => $theme,
'description' => "",
$r = preg_match("|/\*.*\*/|msU", $f, $m);
- if ($r){
+ if ($r) {
$ll = explode("\n", $m[0]);
foreach ( $ll as $l ) {
$l = trim($l,"\t\n\r */");
- if ($l!=""){
+ if ($l != "") {
list($k,$v) = array_map("trim", explode(":",$l,2));
$k= strtolower($k);
- if ($k=="author"){
+ if ($k == "author") {
$r=preg_match("|([^<]+)<([^>]+)>|", $v, $m);
if ($r) {
} else {
$info['author'][] = array('name'=>$v);
}
- }
- elseif ($k=="maintainer"){
+ } elseif ($k == "maintainer") {
$r=preg_match("|([^<]+)<([^>]+)>|", $v, $m);
if ($r) {
$info['maintainer'][] = array('name'=>$m[1], 'link'=>$m[2]);
$info['maintainer'][] = array('name'=>$v);
}
} else {
- if (array_key_exists($k,$info)){
+ if (array_key_exists($k,$info)) {
$info[$k]=$v;
}
}
}
return $info;
-}}
+}
/**
* @brief Returns the theme's screenshot.
}
// install and uninstall theme
-if (! function_exists('uninstall_theme')){
-function uninstall_theme($theme){
+function uninstall_theme($theme) {
logger("Addons: uninstalling theme " . $theme);
include_once("view/theme/$theme/theme.php");
$func = "{$theme}_uninstall";
$func();
}
-}}
+}
-if (! function_exists('install_theme')){
function install_theme($theme) {
// silently fail if theme was removed
return false;
}
-}}
+}
/**
* @brief Get the full path to relevant theme files by filename
+++ /dev/null
-<?php
-use Friendica\App;
-use Friendica\Core\Worker;
-use Friendica\Core\Config;
-
-if (!file_exists("boot.php") && (sizeof($_SERVER["argv"]) != 0)) {
- $directory = dirname($_SERVER["argv"][0]);
-
- if (substr($directory, 0, 1) != "/") {
- $directory = $_SERVER["PWD"]."/".$directory;
- }
- $directory = realpath($directory."/..");
-
- chdir($directory);
-}
-
-require_once("boot.php");
-
-function poller_run($argv, $argc) {
- global $a;
-
- if (empty($a)) {
- $a = new App(dirname(__DIR__));
- }
-
- require_once ".htconfig.php";
- require_once "include/dba.php";
- dba::connect($db_host, $db_user, $db_pass, $db_data);
- unset($db_host, $db_user, $db_pass, $db_data);
-
- Config::load();
-
- // Check the database structure and possibly fixes it
- check_db(true);
-
- // Quit when in maintenance
- if (Config::get('system', 'maintenance', true)) {
- return;
- }
-
- $a->set_baseurl(Config::get('system', 'url'));
-
- load_hooks();
-
- $run_cron = (($argc <= 1) || ($argv[1] != "no_cron"));
- Worker::processQueue($run_cron);
- return;
-}
-
-if (array_search(__file__, get_included_files()) === 0) {
- poller_run($_SERVER["argv"], $_SERVER["argc"]);
-
- Worker::unclaimProcess();
-
- get_app()->end_process();
-
- killme();
-}
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
/**
* @brief Calls the post update functions
// Set the "gcontact-id" in the item table and add a new gcontact entry if needed
foreach ($item_arr AS $item) {
- $gcontact_id = get_gcontact_id(array("url" => $item['author-link'], "network" => $item['network'],
+ $gcontact_id = GlobalContact::getId(array("url" => $item['author-link'], "network" => $item['network'],
"photo" => $item['author-avatar'], "name" => $item['author-name']));
q("UPDATE `item` SET `gcontact-id` = %d WHERE `uid` = %d AND `author-link` = '%s' AND `gcontact-id` = 0",
intval($gcontact_id), intval($item["uid"]), dbesc($item["author-link"]));
// Set the "gcontact-id" in the item table and add a new gcontact entry if needed
foreach ($item_arr AS $item) {
- $author_id = get_contact($item["author-link"], 0);
- $owner_id = get_contact($item["owner-link"], 0);
+ $author_id = Contact::getIdForURL($item["author-link"], 0);
+ $owner_id = Contact::getIdForURL($item["owner-link"], 0);
if ($author_id == 0)
$author_id = -1;
+++ /dev/null
-<?php
-use Friendica\Protocol\Diaspora;
-
-function profile_update_run(&$argv, &$argc) {
- if ($argc != 2) {
- return;
- }
-
- $uid = intval($argv[1]);
-
- Diaspora::send_profile($uid);
-}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\System;
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-
-require_once('include/items.php');
-require_once('include/ostatus.php');
-
-function pubsubpublish_run(&$argv, &$argc){
- global $a;
-
- if ($argc > 1) {
- $pubsubpublish_id = intval($argv[1]);
- } else {
- // We'll push to each subscriber that has push > 0,
- // i.e. there has been an update (set in notifier.php).
- $r = q("SELECT `id`, `callback_url` FROM `push_subscriber` WHERE `push` > 0 ORDER BY `last_update` DESC");
-
- foreach ($r as $rr) {
- logger("Publish feed to ".$rr["callback_url"], LOGGER_DEBUG);
- Worker::add(array('priority' => PRIORITY_HIGH, 'created' => $a->queue['created'], 'dont_fork' => true),
- 'pubsubpublish', (int)$rr["id"]);
- }
- }
-
- handle_pubsubhubbub($pubsubpublish_id);
-
- return;
-}
-
-function handle_pubsubhubbub($id) {
- global $a;
-
- $r = q("SELECT * FROM `push_subscriber` WHERE `id` = %d", intval($id));
- if (!DBM::is_result($r)) {
- return;
- }
-
- $rr = $r[0];
-
- /// @todo Check server status with poco_check_server()
- // Before this can be done we need a way to safely detect the server url.
-
- logger("Generate feed of user ".$rr['nickname']." to ".$rr['callback_url']." - last updated ".$rr['last_update'], LOGGER_DEBUG);
-
- $last_update = $rr['last_update'];
- $params = ostatus::feed($a, $rr['nickname'], $last_update);
-
- if (!$params) {
- return;
- }
-
- $hmac_sig = hash_hmac("sha1", $params, $rr['secret']);
-
- $headers = array("Content-type: application/atom+xml",
- sprintf("Link: <%s>;rel=hub,<%s>;rel=self",
- System::baseUrl().'/pubsubhubbub/'.$rr['nickname'],
- $rr['topic']),
- "X-Hub-Signature: sha1=".$hmac_sig);
-
- logger('POST '.print_r($headers, true)."\n".$params, LOGGER_DEBUG);
-
- post_url($rr['callback_url'], $params, $headers);
- $ret = $a->get_curl_code();
-
- if ($ret >= 200 && $ret <= 299) {
- logger('successfully pushed to '.$rr['callback_url']);
-
- // set last_update to the "created" date of the last item, and reset push=0
- q("UPDATE `push_subscriber` SET `push` = 0, last_update = '%s' WHERE id = %d",
- dbesc($last_update),
- intval($rr['id']));
-
- } else {
- logger('error when pushing to '.$rr['callback_url'].' HTTP: '.$ret);
-
- // we use the push variable also as a counter, if we failed we
- // increment this until some upper limit where we give up
- $new_push = intval($rr['push']) + 1;
-
- if ($new_push > 30) // OK, let's give up
- $new_push = 0;
-
- q("UPDATE `push_subscriber` SET `push` = %d WHERE id = %d",
- $new_push,
- intval($rr['id']));
- }
-}
+++ /dev/null
-<?php
-/**
- * @file include/queue.php
- */
-use Friendica\Core\Cache;
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-use Friendica\Protocol\Diaspora;
-use Friendica\Protocol\DFRN;
-
-require_once 'include/queue_fn.php';
-require_once 'include/datetime.php';
-require_once 'include/items.php';
-require_once 'include/bbcode.php';
-require_once 'include/socgraph.php';
-
-function queue_run(&$argv, &$argc)
-{
- global $a;
-
- if ($argc > 1) {
- $queue_id = intval($argv[1]);
- } else {
- $queue_id = 0;
- }
-
- $cachekey_deadguy = 'queue_run:deadguy:';
- $cachekey_server = 'queue_run:server:';
-
- if (!$queue_id) {
- logger('queue: start');
-
- // Handling the pubsubhubbub requests
- Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), 'pubsubpublish');
-
- $r = q(
- "SELECT `queue`.*, `contact`.`name`, `contact`.`uid` FROM `queue`
- INNER JOIN `contact` ON `queue`.`cid` = `contact`.`id`
- WHERE `queue`.`created` < UTC_TIMESTAMP() - INTERVAL 3 DAY"
- );
-
- if (DBM::is_result($r)) {
- foreach ($r as $rr) {
- logger('Removing expired queue item for ' . $rr['name'] . ', uid=' . $rr['uid']);
- logger('Expired queue data: ' . $rr['content'], LOGGER_DATA);
- }
- q("DELETE FROM `queue` WHERE `created` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
- }
-
- /*
- * For the first 12 hours we'll try to deliver every 15 minutes
- * After that, we'll only attempt delivery once per hour.
- */
- $r = q("SELECT `id` FROM `queue` WHERE ((`created` > UTC_TIMESTAMP() - INTERVAL 12 HOUR AND `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE) OR (`last` < UTC_TIMESTAMP() - INTERVAL 1 HOUR)) ORDER BY `cid`, `created`");
-
- call_hooks('queue_predeliver', $a, $r);
-
- if (DBM::is_result($r)) {
- foreach ($r as $q_item) {
- logger('Call queue for id '.$q_item['id']);
- Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "queue", (int)$q_item['id']);
- }
- }
- return;
- }
-
-
- // delivering
-
- require_once 'include/salmon.php';
-
- $r = q(
- "SELECT * FROM `queue` WHERE `id` = %d LIMIT 1",
- intval($queue_id)
- );
-
- if (!DBM::is_result($r)) {
- return;
- }
-
- $q_item = $r[0];
-
- $c = q(
- "SELECT * FROM `contact` WHERE `id` = %d LIMIT 1",
- intval($q_item['cid'])
- );
-
- if (!DBM::is_result($c)) {
- remove_queue_item($q_item['id']);
- return;
- }
-
- $dead = Cache::get($cachekey_deadguy.$c[0]['notify']);
-
- if (!is_null($dead) && $dead) {
- logger('queue: skipping known dead url: '.$c[0]['notify']);
- update_queue_time($q_item['id']);
- return;
- }
-
- $server = poco_detect_server($c[0]['url']);
-
- if ($server != "") {
- $vital = Cache::get($cachekey_server.$server);
-
- if (is_null($vital)) {
- logger("Check server ".$server." (".$c[0]["network"].")");
-
- $vital = poco_check_server($server, $c[0]["network"], true);
- Cache::set($cachekey_server.$server, $vital, CACHE_QUARTER_HOUR);
- }
-
- if (!is_null($vital) && !$vital) {
- logger('queue: skipping dead server: '.$server);
- update_queue_time($q_item['id']);
- return;
- }
- }
-
- $u = q(
- "SELECT `user`.*, `user`.`pubkey` AS `upubkey`, `user`.`prvkey` AS `uprvkey`
- FROM `user` WHERE `uid` = %d LIMIT 1",
- intval($c[0]['uid'])
- );
- if (!DBM::is_result($u)) {
- remove_queue_item($q_item['id']);
- return;
- }
-
- $data = $q_item['content'];
- $public = $q_item['batch'];
- $contact = $c[0];
- $owner = $u[0];
-
- $deliver_status = 0;
-
- switch ($contact['network']) {
- case NETWORK_DFRN:
- logger('queue: dfrndelivery: item '.$q_item['id'].' for '.$contact['name'].' <'.$contact['url'].'>');
- $deliver_status = DFRN::deliver($owner, $contact, $data);
-
- if ($deliver_status == (-1)) {
- update_queue_time($q_item['id']);
- Cache::set($cachekey_deadguy.$contact['notify'], true, CACHE_QUARTER_HOUR);
- } else {
- remove_queue_item($q_item['id']);
- }
- break;
- case NETWORK_OSTATUS:
- if ($contact['notify']) {
- logger('queue: slapdelivery: item '.$q_item['id'].' for '.$contact['name'].' <'.$contact['url'].'>');
- $deliver_status = slapper($owner, $contact['notify'], $data);
-
- if ($deliver_status == (-1)) {
- update_queue_time($q_item['id']);
- Cache::set($cachekey_deadguy.$contact['notify'], true, CACHE_QUARTER_HOUR);
- } else {
- remove_queue_item($q_item['id']);
- }
- }
- break;
- case NETWORK_DIASPORA:
- if ($contact['notify']) {
- logger('queue: diaspora_delivery: item '.$q_item['id'].' for '.$contact['name'].' <'.$contact['url'].'>');
- $deliver_status = Diaspora::transmit($owner, $contact, $data, $public, true);
-
- if ($deliver_status == (-1)) {
- update_queue_time($q_item['id']);
- Cache::set($cachekey_deadguy.$contact['notify'], true, CACHE_QUARTER_HOUR);
- } else {
- remove_queue_item($q_item['id']);
- }
- }
- break;
-
- default:
- $params = array('owner' => $owner, 'contact' => $contact, 'queue' => $q_item, 'result' => false);
- call_hooks('queue_deliver', $a, $params);
-
- if ($params['result']) {
- remove_queue_item($q_item['id']);
- } else {
- update_queue_time($q_item['id']);
- }
- break;
- }
- logger('Deliver status '.(int)$deliver_status.' for item '.$q_item['id'].' to '.$contact['name'].' <'.$contact['url'].'>');
-
- return;
-}
function remove_queue_item($id) {
logger('queue: remove queue item ' . $id);
- q("DELETE FROM `queue` WHERE `id` = %d",
- intval($id)
- );
+ dba::delete('queue', array('id' => $id));
}
/**
+++ /dev/null
-<?php
-/**
- * @file include/remove_contact.php
- * @brief Removes orphaned data from deleted contacts
- */
-
-use Friendica\Core\Config;
-
-function remove_contact_run($argv, $argc) {
- if ($argc != 2) {
- return;
- }
-
- $id = intval($argv[1]);
-
- // Only delete if the contact doesn't exist (anymore)
- $r = dba::exists('contact', array('id' => $id));
- if ($r) {
- return;
- }
-
- // Now we delete all the depending table entries
- dba::delete('contact', array('id' => $id));
-}
$namespaces = array("me" => "http://salmon-protocol.org/ns/magic-env");
- $salmon = XML::from_array($xmldata, $xml, false, $namespaces);
+ $salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
// slap them
post_url($url, $salmon, array(
$namespaces = array("me" => "http://salmon-protocol.org/ns/magic-env");
- $salmon = XML::from_array($xmldata, $xml, false, $namespaces);
+ $salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
// slap them
post_url($url, $salmon, array(
$namespaces = array("me" => "http://salmon-protocol.org/ns/magic-env");
- $salmon = XML::from_array($xmldata, $xml, false, $namespaces);
+ $salmon = XML::fromArray($xmldata, $xml, false, $namespaces);
// slap them
post_url($url, $salmon, array(
*/
function cookie_hash($user) {
return(hash("sha256", Config::get("system", "site_prvkey").
- $user["uprvkey"].
+ $user["prvkey"].
$user["password"]));
}
+++ /dev/null
-<?php
-
-use Friendica\App;
-use Friendica\Core\Config;
-
-require_once("boot.php");
-require_once("include/threads.php");
-
-function shadowupdate_run(&$argv, &$argc){
- global $a;
-
- if (empty($a)) {
- $a = new App(dirname(__DIR__));
- }
-
- @include(".htconfig.php");
- require_once("include/dba.php");
- dba::connect($db_host, $db_user, $db_pass, $db_data);
- unset($db_host, $db_user, $db_pass, $db_data);
-
- Config::load();
-
- update_shadow_copy();
-}
-
-if (array_search(__file__,get_included_files())===0){
- shadowupdate_run($_SERVER["argv"],$_SERVER["argc"]);
- killme();
-}
+++ /dev/null
-<?php
-/**
- * @file include/socgraph.php
- *
- * @todo Move GNU Social URL schemata (http://server.tld/user/number) to http://server.tld/username
- * @todo Fetch profile data from profile page for Redmatrix users
- * @todo Detect if it is a forum
- */
-
-use Friendica\App;
-use Friendica\Core\System;
-use Friendica\Core\Cache;
-use Friendica\Core\Config;
-use Friendica\Core\Worker;
-use Friendica\Database\DBM;
-use Friendica\Network\Probe;
-
-require_once 'include/datetime.php';
-require_once 'include/network.php';
-require_once 'include/html2bbcode.php';
-require_once 'include/Contact.php';
-require_once 'include/Photo.php';
-
-/**
- * @brief Fetch POCO data
- *
- * @param integer $cid Contact ID
- * @param integer $uid User ID
- * @param integer $zcid Global Contact ID
- * @param integer $url POCO address that should be polled
- *
- * Given a contact-id (minimum), load the PortableContacts friend list for that contact,
- * and add the entries to the gcontact (Global Contact) table, or update existing entries
- * if anything (name or photo) has changed.
- * We use normalised urls for comparison which ignore http vs https and www.domain vs domain
- *
- * Once the global contact is stored add (if necessary) the contact linkage which associates
- * the given uid, cid to the global contact entry. There can be many uid/cid combinations
- * pointing to the same global contact id.
- *
- */
-function poco_load($cid, $uid = 0, $zcid = 0, $url = null) {
- // Call the function "poco_load_worker" via the worker
- Worker::add(PRIORITY_LOW, "discover_poco", "poco_load", (int)$cid, (int)$uid, (int)$zcid, $url);
-}
-
-/**
- * @brief Fetch POCO data from the worker
- *
- * @param integer $cid Contact ID
- * @param integer $uid User ID
- * @param integer $zcid Global Contact ID
- * @param integer $url POCO address that should be polled
- *
- */
-function poco_load_worker($cid, $uid, $zcid, $url) {
- $a = get_app();
-
- if ($cid) {
- if ((! $url) || (! $uid)) {
- $r = q("select `poco`, `uid` from `contact` where `id` = %d limit 1",
- intval($cid)
- );
- if (DBM::is_result($r)) {
- $url = $r[0]['poco'];
- $uid = $r[0]['uid'];
- }
- }
- if (! $uid) {
- return;
- }
- }
-
- if (! $url) {
- return;
- }
-
- $url = $url . (($uid) ? '/@me/@all?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation' : '?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation') ;
-
- logger('poco_load: ' . $url, LOGGER_DEBUG);
-
- $s = fetch_url($url);
-
- logger('poco_load: returns ' . $s, LOGGER_DATA);
-
- logger('poco_load: return code: ' . $a->get_curl_code(), LOGGER_DEBUG);
-
- if (($a->get_curl_code() > 299) || (! $s)) {
- return;
- }
-
- $j = json_decode($s);
-
- logger('poco_load: json: ' . print_r($j,true),LOGGER_DATA);
-
- if (! isset($j->entry)) {
- return;
- }
-
- $total = 0;
- foreach ($j->entry as $entry) {
-
- $total ++;
- $profile_url = '';
- $profile_photo = '';
- $connect_url = '';
- $name = '';
- $network = '';
- $updated = NULL_DATE;
- $location = '';
- $about = '';
- $keywords = '';
- $gender = '';
- $contact_type = -1;
- $generation = 0;
-
- $name = $entry->displayName;
-
- if (isset($entry->urls)) {
- foreach ($entry->urls as $url) {
- if ($url->type == 'profile') {
- $profile_url = $url->value;
- continue;
- }
- if ($url->type == 'webfinger') {
- $connect_url = str_replace('acct:' , '', $url->value);
- continue;
- }
- }
- }
- if (isset($entry->photos)) {
- foreach ($entry->photos as $photo) {
- if ($photo->type == 'profile') {
- $profile_photo = $photo->value;
- continue;
- }
- }
- }
-
- if (isset($entry->updated)) {
- $updated = date("Y-m-d H:i:s", strtotime($entry->updated));
- }
-
- if (isset($entry->network)) {
- $network = $entry->network;
- }
-
- if (isset($entry->currentLocation)) {
- $location = $entry->currentLocation;
- }
-
- if (isset($entry->aboutMe)) {
- $about = html2bbcode($entry->aboutMe);
- }
-
- if (isset($entry->gender)) {
- $gender = $entry->gender;
- }
-
- if (isset($entry->generation) && ($entry->generation > 0)) {
- $generation = ++$entry->generation;
- }
-
- if (isset($entry->tags)) {
- foreach ($entry->tags as $tag) {
- $keywords = implode(", ", $tag);
- }
- }
-
- if (isset($entry->contactType) && ($entry->contactType >= 0)) {
- $contact_type = $entry->contactType;
- }
-
- $gcontact = array("url" => $profile_url,
- "name" => $name,
- "network" => $network,
- "photo" => $profile_photo,
- "about" => $about,
- "location" => $location,
- "gender" => $gender,
- "keywords" => $keywords,
- "connect" => $connect_url,
- "updated" => $updated,
- "contact-type" => $contact_type,
- "generation" => $generation);
-
- try {
- $gcontact = sanitize_gcontact($gcontact);
- $gcid = update_gcontact($gcontact);
-
- link_gcontact($gcid, $uid, $cid, $zcid);
- } catch (Exception $e) {
- logger($e->getMessage(), LOGGER_DEBUG);
- }
- }
- logger("poco_load: loaded $total entries",LOGGER_DEBUG);
-
- q("DELETE FROM `glink` WHERE `cid` = %d AND `uid` = %d AND `zcid` = %d AND `updated` < UTC_TIMESTAMP - INTERVAL 2 DAY",
- intval($cid),
- intval($uid),
- intval($zcid)
- );
-
-}
-/**
- * @brief Sanitize the given gcontact data
- *
- * @param array $gcontact array with gcontact data
- * @throw Exception
- *
- * Generation:
- * 0: No definition
- * 1: Profiles on this server
- * 2: Contacts of profiles on this server
- * 3: Contacts of contacts of profiles on this server
- * 4: ...
- *
- */
-function sanitize_gcontact($gcontact) {
-
- if ($gcontact['url'] == "") {
- throw new Exception('URL is empty');
- }
-
- $urlparts = parse_url($gcontact['url']);
- if (!isset($urlparts["scheme"])) {
- throw new Exception("This (".$gcontact['url'].") doesn't seem to be an url.");
- }
-
- if (in_array($urlparts["host"], array("www.facebook.com", "facebook.com", "twitter.com",
- "identi.ca", "alpha.app.net"))) {
- throw new Exception('Contact from a non federated network ignored. ('.$gcontact['url'].')');
- }
-
- // Don't store the statusnet connector as network
- // We can't simply set this to NETWORK_OSTATUS since the connector could have fetched posts from friendica as well
- if ($gcontact['network'] == NETWORK_STATUSNET) {
- $gcontact['network'] = "";
- }
-
- // Assure that there are no parameter fragments in the profile url
- if (in_array($gcontact['network'], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
- $gcontact['url'] = clean_contact_url($gcontact['url']);
- }
-
- $alternate = poco_alternate_ostatus_url($gcontact['url']);
-
- // The global contacts should contain the original picture, not the cached one
- if (($gcontact['generation'] != 1) && stristr(normalise_link($gcontact['photo']), normalise_link(System::baseUrl()."/photo/"))) {
- $gcontact['photo'] = "";
- }
-
- if (!isset($gcontact['network'])) {
- $r = q("SELECT `network` FROM `contact` WHERE `uid` = 0 AND `nurl` = '%s' AND `network` != '' AND `network` != '%s' LIMIT 1",
- dbesc(normalise_link($gcontact['url'])), dbesc(NETWORK_STATUSNET)
- );
- if (DBM::is_result($r)) {
- $gcontact['network'] = $r[0]["network"];
- }
-
- if (($gcontact['network'] == "") || ($gcontact['network'] == NETWORK_OSTATUS)) {
- $r = q("SELECT `network`, `url` FROM `contact` WHERE `uid` = 0 AND `alias` IN ('%s', '%s') AND `network` != '' AND `network` != '%s' LIMIT 1",
- dbesc($gcontact['url']), dbesc(normalise_link($gcontact['url'])), dbesc(NETWORK_STATUSNET)
- );
- if (DBM::is_result($r)) {
- $gcontact['network'] = $r[0]["network"];
- }
- }
- }
-
- $gcontact['server_url'] = '';
- $gcontact['network'] = '';
-
- $x = q("SELECT * FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
- dbesc(normalise_link($gcontact['url']))
- );
-
- if (DBM::is_result($x)) {
- if (!isset($gcontact['network']) && ($x[0]["network"] != NETWORK_STATUSNET)) {
- $gcontact['network'] = $x[0]["network"];
- }
- if ($gcontact['updated'] <= NULL_DATE) {
- $gcontact['updated'] = $x[0]["updated"];
- }
- if (!isset($gcontact['server_url']) && (normalise_link($x[0]["server_url"]) != normalise_link($x[0]["url"]))) {
- $gcontact['server_url'] = $x[0]["server_url"];
- }
- if (!isset($gcontact['addr'])) {
- $gcontact['addr'] = $x[0]["addr"];
- }
- }
-
- if ((!isset($gcontact['network']) || !isset($gcontact['name']) || !isset($gcontact['addr']) || !isset($gcontact['photo']) || !isset($gcontact['server_url']) || $alternate)
- && poco_reachable($gcontact['url'], $gcontact['server_url'], $gcontact['network'], false)) {
- $data = Probe::uri($gcontact['url']);
-
- if ($data["network"] == NETWORK_PHANTOM) {
- throw new Exception('Probing for URL '.$gcontact['url'].' failed');
- }
-
- $orig_profile = $gcontact['url'];
-
- $gcontact["server_url"] = $data["baseurl"];
-
- $gcontact = array_merge($gcontact, $data);
-
- if ($alternate && ($gcontact['network'] == NETWORK_OSTATUS)) {
- // Delete the old entry - if it exists
- $r = q("SELECT `id` FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($orig_profile)));
- if (DBM::is_result($r)) {
- q("DELETE FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($orig_profile)));
- q("DELETE FROM `glink` WHERE `gcid` = %d", intval($r[0]["id"]));
- }
- }
- }
-
- if (!isset($gcontact['name']) || !isset($gcontact['photo'])) {
- throw new Exception('No name and photo for URL '.$gcontact['url']);
- }
-
- if (!in_array($gcontact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_DIASPORA))) {
- throw new Exception('No federated network ('.$gcontact['network'].') detected for URL '.$gcontact['url']);
- }
-
- if (!isset($gcontact['server_url'])) {
- // We check the server url to be sure that it is a real one
- $server_url = poco_detect_server($gcontact['url']);
-
- // We are now sure that it is a correct URL. So we use it in the future
- if ($server_url != "") {
- $gcontact['server_url'] = $server_url;
- }
- }
-
- // The server URL doesn't seem to be valid, so we don't store it.
- if (!poco_check_server($gcontact['server_url'], $gcontact['network'])) {
- $gcontact['server_url'] = "";
- }
-
- return $gcontact;
-}
-
-/**
- * @brief Link the gcontact entry with user, contact and global contact
- *
- * @param integer $gcid Global contact ID
- * @param integer $cid Contact ID
- * @param integer $uid User ID
- * @param integer $zcid Global Contact ID
- * *
- */
-function link_gcontact($gcid, $uid = 0, $cid = 0, $zcid = 0) {
-
- if ($gcid <= 0) {
- return;
- }
-
- $r = q("SELECT * FROM `glink` WHERE `cid` = %d AND `uid` = %d AND `gcid` = %d AND `zcid` = %d LIMIT 1",
- intval($cid),
- intval($uid),
- intval($gcid),
- intval($zcid)
- );
-
- if (!DBM::is_result($r)) {
- q("INSERT INTO `glink` (`cid`, `uid`, `gcid`, `zcid`, `updated`) VALUES (%d, %d, %d, %d, '%s') ",
- intval($cid),
- intval($uid),
- intval($gcid),
- intval($zcid),
- dbesc(datetime_convert())
- );
- } else {
- q("UPDATE `glink` SET `updated` = '%s' WHERE `cid` = %d AND `uid` = %d AND `gcid` = %d AND `zcid` = %d",
- dbesc(datetime_convert()),
- intval($cid),
- intval($uid),
- intval($gcid),
- intval($zcid)
- );
- }
-}
-
-function poco_reachable($profile, $server = "", $network = "", $force = false) {
-
- if ($server == "") {
- $server = poco_detect_server($profile);
- }
-
- if ($server == "") {
- return true;
- }
-
- return poco_check_server($server, $network, $force);
-}
-
-function poco_detect_server($profile) {
-
- // Try to detect the server path based upon some known standard paths
- $server_url = "";
-
- if ($server_url == "") {
- $friendica = preg_replace("=(https?://)(.*)/profile/(.*)=ism", "$1$2", $profile);
- if ($friendica != $profile) {
- $server_url = $friendica;
- $network = NETWORK_DFRN;
- }
- }
-
- if ($server_url == "") {
- $diaspora = preg_replace("=(https?://)(.*)/u/(.*)=ism", "$1$2", $profile);
- if ($diaspora != $profile) {
- $server_url = $diaspora;
- $network = NETWORK_DIASPORA;
- }
- }
-
- if ($server_url == "") {
- $red = preg_replace("=(https?://)(.*)/channel/(.*)=ism", "$1$2", $profile);
- if ($red != $profile) {
- $server_url = $red;
- $network = NETWORK_DIASPORA;
- }
- }
-
- // Mastodon
- if ($server_url == "") {
- $mastodon = preg_replace("=(https?://)(.*)/users/(.*)=ism", "$1$2", $profile);
- if ($mastodon != $profile) {
- $server_url = $mastodon;
- $network = NETWORK_OSTATUS;
- }
- }
-
- // Numeric OStatus variant
- if ($server_url == "") {
- $ostatus = preg_replace("=(https?://)(.*)/user/(.*)=ism", "$1$2", $profile);
- if ($ostatus != $profile) {
- $server_url = $ostatus;
- $network = NETWORK_OSTATUS;
- }
- }
-
- // Wild guess
- if ($server_url == "") {
- $base = preg_replace("=(https?://)(.*?)/(.*)=ism", "$1$2", $profile);
- if ($base != $profile) {
- $server_url = $base;
- $network = NETWORK_PHANTOM;
- }
- }
-
- if ($server_url == "") {
- return "";
- }
-
- $r = q("SELECT `id` FROM `gserver` WHERE `nurl` = '%s' AND `last_contact` > `last_failure`",
- dbesc(normalise_link($server_url)));
- if (DBM::is_result($r)) {
- return $server_url;
- }
-
- // Fetch the host-meta to check if this really is a server
- $serverret = z_fetch_url($server_url."/.well-known/host-meta");
- if (!$serverret["success"]) {
- return "";
- }
-
- return $server_url;
-}
-
-function poco_alternate_ostatus_url($url) {
- return(preg_match("=https?://.+/user/\d+=ism", $url, $matches));
-}
-
-function poco_last_updated($profile, $force = false) {
-
- $gcontacts = q("SELECT * FROM `gcontact` WHERE `nurl` = '%s'",
- dbesc(normalise_link($profile)));
-
- if (!DBM::is_result($gcontacts)) {
- return false;
- }
-
- $contact = array("url" => $profile);
-
- if ($gcontacts[0]["created"] <= NULL_DATE) {
- $contact['created'] = datetime_convert();
- }
-
- if ($force) {
- $server_url = normalise_link(poco_detect_server($profile));
- }
-
- if (($server_url == '') && ($gcontacts[0]["server_url"] != "")) {
- $server_url = $gcontacts[0]["server_url"];
- }
-
- if (!$force && (($server_url == '') || ($gcontacts[0]["server_url"] == $gcontacts[0]["nurl"]))) {
- $server_url = normalise_link(poco_detect_server($profile));
- }
-
- if (!in_array($gcontacts[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_FEED, NETWORK_OSTATUS, ""))) {
- logger("Profile ".$profile.": Network type ".$gcontacts[0]["network"]." can't be checked", LOGGER_DEBUG);
- return false;
- }
-
- if ($server_url != "") {
- if (!poco_check_server($server_url, $gcontacts[0]["network"], $force)) {
- if ($force) {
- q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($profile)));
- }
-
- logger("Profile ".$profile.": Server ".$server_url." wasn't reachable.", LOGGER_DEBUG);
- return false;
- }
- $contact['server_url'] = $server_url;
- }
-
- if (in_array($gcontacts[0]["network"], array("", NETWORK_FEED))) {
- $server = q("SELECT `network` FROM `gserver` WHERE `nurl` = '%s' AND `network` != ''",
- dbesc(normalise_link($server_url)));
-
- if ($server) {
- $contact['network'] = $server[0]["network"];
- } else {
- return false;
- }
- }
-
- // noscrape is really fast so we don't cache the call.
- if (($server_url != "") && ($gcontacts[0]["nick"] != "")) {
-
- // Use noscrape if possible
- $server = q("SELECT `noscrape`, `network` FROM `gserver` WHERE `nurl` = '%s' AND `noscrape` != ''", dbesc(normalise_link($server_url)));
-
- if ($server) {
- $noscraperet = z_fetch_url($server[0]["noscrape"]."/".$gcontacts[0]["nick"]);
-
- if ($noscraperet["success"] && ($noscraperet["body"] != "")) {
-
- $noscrape = json_decode($noscraperet["body"], true);
-
- if (is_array($noscrape)) {
- $contact["network"] = $server[0]["network"];
-
- if (isset($noscrape["fn"])) {
- $contact["name"] = $noscrape["fn"];
- }
- if (isset($noscrape["comm"])) {
- $contact["community"] = $noscrape["comm"];
- }
- if (isset($noscrape["tags"])) {
- $keywords = implode(" ", $noscrape["tags"]);
- if ($keywords != "") {
- $contact["keywords"] = $keywords;
- }
- }
-
- $location = formatted_location($noscrape);
- if ($location) {
- $contact["location"] = $location;
- }
- if (isset($noscrape["dfrn-notify"])) {
- $contact["notify"] = $noscrape["dfrn-notify"];
- }
- // Remove all fields that are not present in the gcontact table
- unset($noscrape["fn"]);
- unset($noscrape["key"]);
- unset($noscrape["homepage"]);
- unset($noscrape["comm"]);
- unset($noscrape["tags"]);
- unset($noscrape["locality"]);
- unset($noscrape["region"]);
- unset($noscrape["country-name"]);
- unset($noscrape["contacts"]);
- unset($noscrape["dfrn-request"]);
- unset($noscrape["dfrn-confirm"]);
- unset($noscrape["dfrn-notify"]);
- unset($noscrape["dfrn-poll"]);
-
- // Set the date of the last contact
- /// @todo By now the function "update_gcontact" doesn't work with this field
- //$contact["last_contact"] = datetime_convert();
-
- $contact = array_merge($contact, $noscrape);
-
- update_gcontact($contact);
-
- if (trim($noscrape["updated"]) != "") {
- q("UPDATE `gcontact` SET `last_contact` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($profile)));
-
- logger("Profile ".$profile." was last updated at ".$noscrape["updated"]." (noscrape)", LOGGER_DEBUG);
-
- return $noscrape["updated"];
- }
- }
- }
- }
- }
-
- // If we only can poll the feed, then we only do this once a while
- if (!$force && !poco_do_update($gcontacts[0]["created"], $gcontacts[0]["updated"], $gcontacts[0]["last_failure"], $gcontacts[0]["last_contact"])) {
- logger("Profile ".$profile." was last updated at ".$gcontacts[0]["updated"]." (cached)", LOGGER_DEBUG);
-
- update_gcontact($contact);
- return $gcontacts[0]["updated"];
- }
-
- $data = Probe::uri($profile);
-
- // Is the profile link the alternate OStatus link notation? (http://domain.tld/user/4711)
- // Then check the other link and delete this one
- if (($data["network"] == NETWORK_OSTATUS) && poco_alternate_ostatus_url($profile) &&
- (normalise_link($profile) == normalise_link($data["alias"])) &&
- (normalise_link($profile) != normalise_link($data["url"]))) {
-
- // Delete the old entry
- q("DELETE FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($profile)));
- q("DELETE FROM `glink` WHERE `gcid` = %d", intval($gcontacts[0]["id"]));
-
- $gcontact = array_merge($gcontacts[0], $data);
-
- $gcontact["server_url"] = $data["baseurl"];
-
- try {
- $gcontact = sanitize_gcontact($gcontact);
- update_gcontact($gcontact);
-
- poco_last_updated($data["url"], $force);
- } catch (Exception $e) {
- logger($e->getMessage(), LOGGER_DEBUG);
- }
-
- logger("Profile ".$profile." was deleted", LOGGER_DEBUG);
- return false;
- }
-
- if (($data["poll"] == "") || (in_array($data["network"], array(NETWORK_FEED, NETWORK_PHANTOM)))) {
- q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($profile)));
-
- logger("Profile ".$profile." wasn't reachable (profile)", LOGGER_DEBUG);
- return false;
- }
-
- $contact = array_merge($contact, $data);
-
- $contact["server_url"] = $data["baseurl"];
-
- update_gcontact($contact);
-
- $feedret = z_fetch_url($data["poll"]);
-
- if (!$feedret["success"]) {
- q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($profile)));
-
- logger("Profile ".$profile." wasn't reachable (no feed)", LOGGER_DEBUG);
- return false;
- }
-
- $doc = new DOMDocument();
- @$doc->loadXML($feedret["body"]);
-
- $xpath = new DomXPath($doc);
- $xpath->registerNamespace('atom', "http://www.w3.org/2005/Atom");
-
- $entries = $xpath->query('/atom:feed/atom:entry');
-
- $last_updated = "";
-
- foreach ($entries as $entry) {
- $published = $xpath->query('atom:published/text()', $entry)->item(0)->nodeValue;
- $updated = $xpath->query('atom:updated/text()', $entry)->item(0)->nodeValue;
-
- if ($last_updated < $published)
- $last_updated = $published;
-
- if ($last_updated < $updated)
- $last_updated = $updated;
- }
-
- // Maybe there aren't any entries. Then check if it is a valid feed
- if ($last_updated == "") {
- if ($xpath->query('/atom:feed')->length > 0) {
- $last_updated = NULL_DATE;
- }
- }
- q("UPDATE `gcontact` SET `updated` = '%s', `last_contact` = '%s' WHERE `nurl` = '%s'",
- dbesc(DBM::date($last_updated)), dbesc(DBM::date()), dbesc(normalise_link($profile)));
-
- if (($gcontacts[0]["generation"] == 0)) {
- q("UPDATE `gcontact` SET `generation` = 9 WHERE `nurl` = '%s'",
- dbesc(normalise_link($profile)));
- }
-
- logger("Profile ".$profile." was last updated at ".$last_updated, LOGGER_DEBUG);
-
- return($last_updated);
-}
-
-function poco_do_update($created, $updated, $last_failure, $last_contact) {
- $now = strtotime(datetime_convert());
-
- if ($updated > $last_contact) {
- $contact_time = strtotime($updated);
- } else {
- $contact_time = strtotime($last_contact);
- }
-
- $failure_time = strtotime($last_failure);
- $created_time = strtotime($created);
-
- // If there is no "created" time then use the current time
- if ($created_time <= 0) {
- $created_time = $now;
- }
-
- // If the last contact was less than 24 hours then don't update
- if (($now - $contact_time) < (60 * 60 * 24)) {
- return false;
- }
-
- // If the last failure was less than 24 hours then don't update
- if (($now - $failure_time) < (60 * 60 * 24)) {
- return false;
- }
-
- // If the last contact was less than a week ago and the last failure is older than a week then don't update
- //if ((($now - $contact_time) < (60 * 60 * 24 * 7)) && ($contact_time > $failure_time))
- // return false;
-
- // If the last contact time was more than a week ago and the contact was created more than a week ago, then only try once a week
- if ((($now - $contact_time) > (60 * 60 * 24 * 7)) && (($now - $created_time) > (60 * 60 * 24 * 7)) && (($now - $failure_time) < (60 * 60 * 24 * 7))) {
- return false;
- }
-
- // If the last contact time was more than a month ago and the contact was created more than a month ago, then only try once a month
- if ((($now - $contact_time) > (60 * 60 * 24 * 30)) && (($now - $created_time) > (60 * 60 * 24 * 30)) && (($now - $failure_time) < (60 * 60 * 24 * 30))) {
- return false;
- }
-
- return true;
-}
-
-function poco_to_boolean($val) {
- if (($val == "true") || ($val == 1)) {
- return true;
- } elseif (($val == "false") || ($val == 0)) {
- return false;
- }
-
- return $val;
-}
-
-/**
- * @brief Detect server type (Hubzilla or Friendica) via the poco data
- *
- * @param object $data POCO data
- * @return array Server data
- */
-function poco_detect_poco_data($data) {
- $server = false;
-
- if (!isset($data->entry)) {
- return false;
- }
-
- if (count($data->entry) == 0) {
- return false;
- }
-
- if (!isset($data->entry[0]->urls)) {
- return false;
- }
-
- if (count($data->entry[0]->urls) == 0) {
- return false;
- }
-
- foreach ($data->entry[0]->urls as $url) {
- if ($url->type == 'zot') {
- $server = array();
- $server["platform"] = 'Hubzilla';
- $server["network"] = NETWORK_DIASPORA;
- return $server;
- }
- }
- return false;
-}
-
-/**
- * @brief Detect server type by using the nodeinfo data
- *
- * @param string $server_url address of the server
- * @return array Server data
- */
-function poco_fetch_nodeinfo($server_url) {
- $serverret = z_fetch_url($server_url."/.well-known/nodeinfo");
- if (!$serverret["success"]) {
- return false;
- }
-
- $nodeinfo = json_decode($serverret['body']);
-
- if (!is_object($nodeinfo)) {
- return false;
- }
-
- if (!is_array($nodeinfo->links)) {
- return false;
- }
-
- $nodeinfo_url = '';
-
- foreach ($nodeinfo->links as $link) {
- if ($link->rel == 'http://nodeinfo.diaspora.software/ns/schema/1.0') {
- $nodeinfo_url = $link->href;
- }
- }
-
- if ($nodeinfo_url == '') {
- return false;
- }
-
- $serverret = z_fetch_url($nodeinfo_url);
- if (!$serverret["success"]) {
- return false;
- }
-
- $nodeinfo = json_decode($serverret['body']);
-
- if (!is_object($nodeinfo)) {
- return false;
- }
-
- $server = array();
-
- $server['register_policy'] = REGISTER_CLOSED;
-
- if (is_bool($nodeinfo->openRegistrations) && $nodeinfo->openRegistrations) {
- $server['register_policy'] = REGISTER_OPEN;
- }
-
- if (is_object($nodeinfo->software)) {
- if (isset($nodeinfo->software->name)) {
- $server['platform'] = $nodeinfo->software->name;
- }
-
- if (isset($nodeinfo->software->version)) {
- $server['version'] = $nodeinfo->software->version;
- // Version numbers on Nodeinfo are presented with additional info, e.g.:
- // 0.6.3.0-p1702cc1c, 0.6.99.0-p1b9ab160 or 3.4.3-2-1191.
- $server['version'] = preg_replace("=(.+)-(.{4,})=ism", "$1", $server['version']);
- }
- }
-
- if (is_object($nodeinfo->metadata)) {
- if (isset($nodeinfo->metadata->nodeName)) {
- $server['site_name'] = $nodeinfo->metadata->nodeName;
- }
- }
-
- $diaspora = false;
- $friendica = false;
- $gnusocial = false;
-
- if (is_array($nodeinfo->protocols->inbound)) {
- foreach ($nodeinfo->protocols->inbound as $inbound) {
- if ($inbound == 'diaspora') {
- $diaspora = true;
- }
- if ($inbound == 'friendica') {
- $friendica = true;
- }
- if ($inbound == 'gnusocial') {
- $gnusocial = true;
- }
- }
- }
-
- if ($gnusocial) {
- $server['network'] = NETWORK_OSTATUS;
- }
- if ($diaspora) {
- $server['network'] = NETWORK_DIASPORA;
- }
- if ($friendica) {
- $server['network'] = NETWORK_DFRN;
- }
-
- if (!$server) {
- return false;
- }
-
- return $server;
-}
-
-/**
- * @brief Detect server type (Hubzilla or Friendica) via the front page body
- *
- * @param string $body Front page of the server
- * @return array Server data
- */
-function poco_detect_server_type($body) {
- $server = false;
-
- $doc = new DOMDocument();
- @$doc->loadHTML($body);
- $xpath = new DomXPath($doc);
-
- $list = $xpath->query("//meta[@name]");
-
- foreach ($list as $node) {
- $attr = array();
- if ($node->attributes->length) {
- foreach ($node->attributes as $attribute) {
- $attr[$attribute->name] = $attribute->value;
- }
- }
- if ($attr['name'] == 'generator') {
- $version_part = explode(" ", $attr['content']);
- if (count($version_part) == 2) {
- if (in_array($version_part[0], array("Friendika", "Friendica"))) {
- $server = array();
- $server["platform"] = $version_part[0];
- $server["version"] = $version_part[1];
- $server["network"] = NETWORK_DFRN;
- }
- }
- }
- }
-
- if (!$server) {
- $list = $xpath->query("//meta[@property]");
-
- foreach ($list as $node) {
- $attr = array();
- if ($node->attributes->length) {
- foreach ($node->attributes as $attribute) {
- $attr[$attribute->name] = $attribute->value;
- }
- }
- if ($attr['property'] == 'generator' && in_array($attr['content'], array("hubzilla", "BlaBlaNet"))) {
- $server = array();
- $server["platform"] = $attr['content'];
- $server["version"] = "";
- $server["network"] = NETWORK_DIASPORA;
- }
- }
- }
-
- if (!$server) {
- return false;
- }
-
- $server["site_name"] = $xpath->evaluate($element."//head/title/text()", $context)->item(0)->nodeValue;
- return $server;
-}
-
-function poco_check_server($server_url, $network = "", $force = false) {
-
- // Unify the server address
- $server_url = trim($server_url, "/");
- $server_url = str_replace("/index.php", "", $server_url);
-
- if ($server_url == "") {
- return false;
- }
-
- $servers = q("SELECT * FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
- if (DBM::is_result($servers)) {
-
- if ($servers[0]["created"] <= NULL_DATE) {
- q("UPDATE `gserver` SET `created` = '%s' WHERE `nurl` = '%s'",
- dbesc(datetime_convert()), dbesc(normalise_link($server_url)));
- }
- $poco = $servers[0]["poco"];
- $noscrape = $servers[0]["noscrape"];
-
- if ($network == "") {
- $network = $servers[0]["network"];
- }
-
- $last_contact = $servers[0]["last_contact"];
- $last_failure = $servers[0]["last_failure"];
- $version = $servers[0]["version"];
- $platform = $servers[0]["platform"];
- $site_name = $servers[0]["site_name"];
- $info = $servers[0]["info"];
- $register_policy = $servers[0]["register_policy"];
-
- if (!$force && !poco_do_update($servers[0]["created"], "", $last_failure, $last_contact)) {
- logger("Use cached data for server ".$server_url, LOGGER_DEBUG);
- return ($last_contact >= $last_failure);
- }
- } else {
- $poco = "";
- $noscrape = "";
- $version = "";
- $platform = "";
- $site_name = "";
- $info = "";
- $register_policy = -1;
-
- $last_contact = NULL_DATE;
- $last_failure = NULL_DATE;
- }
- logger("Server ".$server_url." is outdated or unknown. Start discovery. Force: ".$force." Created: ".$servers[0]["created"]." Failure: ".$last_failure." Contact: ".$last_contact, LOGGER_DEBUG);
-
- $failure = false;
- $possible_failure = false;
- $orig_last_failure = $last_failure;
- $orig_last_contact = $last_contact;
-
- // Check if the page is accessible via SSL.
- $orig_server_url = $server_url;
- $server_url = str_replace("http://", "https://", $server_url);
-
- // We set the timeout to 20 seconds since this operation should be done in no time if the server was vital
- $serverret = z_fetch_url($server_url."/.well-known/host-meta", false, $redirects, array('timeout' => 20));
-
- // Quit if there is a timeout.
- // But we want to make sure to only quit if we are mostly sure that this server url fits.
- if (DBM::is_result($servers) && ($orig_server_url == $server_url) &&
- ($serverret['errno'] == CURLE_OPERATION_TIMEDOUT)) {
- logger("Connection to server ".$server_url." timed out.", LOGGER_DEBUG);
- dba::update('gserver', array('last_failure' => datetime_convert()), array('nurl' => normalise_link($server_url)));
- return false;
- }
-
- // Maybe the page is unencrypted only?
- $xmlobj = @simplexml_load_string($serverret["body"],'SimpleXMLElement',0, "http://docs.oasis-open.org/ns/xri/xrd-1.0");
- if (!$serverret["success"] || ($serverret["body"] == "") || (@sizeof($xmlobj) == 0) || !is_object($xmlobj)) {
- $server_url = str_replace("https://", "http://", $server_url);
-
- // We set the timeout to 20 seconds since this operation should be done in no time if the server was vital
- $serverret = z_fetch_url($server_url."/.well-known/host-meta", false, $redirects, array('timeout' => 20));
-
- // Quit if there is a timeout
- if ($serverret['errno'] == CURLE_OPERATION_TIMEDOUT) {
- logger("Connection to server ".$server_url." timed out.", LOGGER_DEBUG);
- dba::update('gserver', array('last_failure' => datetime_convert()), array('nurl' => normalise_link($server_url)));
- return false;
- }
-
- $xmlobj = @simplexml_load_string($serverret["body"],'SimpleXMLElement',0, "http://docs.oasis-open.org/ns/xri/xrd-1.0");
- }
-
- if (!$serverret["success"] || ($serverret["body"] == "") || (sizeof($xmlobj) == 0) || !is_object($xmlobj)) {
- // Workaround for bad configured servers (known nginx problem)
- if (!in_array($serverret["debug"]["http_code"], array("403", "404"))) {
- $failure = true;
- }
- $possible_failure = true;
- }
-
- // If the server has no possible failure we reset the cached data
- if (!$possible_failure) {
- $version = "";
- $platform = "";
- $site_name = "";
- $info = "";
- $register_policy = -1;
- }
-
- // Look for poco
- if (!$failure) {
- $serverret = z_fetch_url($server_url."/poco");
- if ($serverret["success"]) {
- $data = json_decode($serverret["body"]);
- if (isset($data->totalResults)) {
- $poco = $server_url."/poco";
- $server = poco_detect_poco_data($data);
- if ($server) {
- $platform = $server['platform'];
- $network = $server['network'];
- $version = '';
- $site_name = '';
- }
- }
- }
- }
-
- if (!$failure) {
- // Test for Diaspora, Hubzilla, Mastodon or older Friendica servers
- $serverret = z_fetch_url($server_url);
-
- if (!$serverret["success"] || ($serverret["body"] == "")) {
- $failure = true;
- } else {
- $server = poco_detect_server_type($serverret["body"]);
- if ($server) {
- $platform = $server['platform'];
- $network = $server['network'];
- $version = $server['version'];
- $site_name = $server['site_name'];
- }
-
- $lines = explode("\n",$serverret["header"]);
- if (count($lines)) {
- foreach($lines as $line) {
- $line = trim($line);
- if (stristr($line,'X-Diaspora-Version:')) {
- $platform = "Diaspora";
- $version = trim(str_replace("X-Diaspora-Version:", "", $line));
- $version = trim(str_replace("x-diaspora-version:", "", $version));
- $network = NETWORK_DIASPORA;
- $versionparts = explode("-", $version);
- $version = $versionparts[0];
- }
-
- if (stristr($line,'Server: Mastodon')) {
- $platform = "Mastodon";
- $network = NETWORK_OSTATUS;
- }
- }
- }
- }
- }
-
- if (!$failure && ($poco == "")) {
- // Test for Statusnet
- // Will also return data for Friendica and GNU Social - but it will be overwritten later
- // The "not implemented" is a special treatment for really, really old Friendica versions
- $serverret = z_fetch_url($server_url."/api/statusnet/version.json");
- if ($serverret["success"] && ($serverret["body"] != '{"error":"not implemented"}') &&
- ($serverret["body"] != '') && (strlen($serverret["body"]) < 30)) {
- $platform = "StatusNet";
- // Remove junk that some GNU Social servers return
- $version = str_replace(chr(239).chr(187).chr(191), "", $serverret["body"]);
- $version = trim($version, '"');
- $network = NETWORK_OSTATUS;
- }
-
- // Test for GNU Social
- $serverret = z_fetch_url($server_url."/api/gnusocial/version.json");
- if ($serverret["success"] && ($serverret["body"] != '{"error":"not implemented"}') &&
- ($serverret["body"] != '') && (strlen($serverret["body"]) < 30)) {
- $platform = "GNU Social";
- // Remove junk that some GNU Social servers return
- $version = str_replace(chr(239).chr(187).chr(191), "", $serverret["body"]);
- $version = trim($version, '"');
- $network = NETWORK_OSTATUS;
- }
-
- // Test for Mastodon
- $orig_version = $version;
- $serverret = z_fetch_url($server_url."/api/v1/instance");
- if ($serverret["success"] && ($serverret["body"] != '')) {
- $data = json_decode($serverret["body"]);
- if (isset($data->version)) {
- $platform = "Mastodon";
- $version = $data->version;
- $site_name = $data->title;
- $info = $data->description;
- $network = NETWORK_OSTATUS;
- }
- }
- if (strstr($orig_version.$version, 'Pleroma')) {
- $platform = 'Pleroma';
- $version = trim(str_replace('Pleroma', '', $version));
- }
- }
-
- if (!$failure) {
- // Test for Hubzilla and Red
- $serverret = z_fetch_url($server_url."/siteinfo.json");
- if ($serverret["success"]) {
- $data = json_decode($serverret["body"]);
- if (isset($data->url)) {
- $platform = $data->platform;
- $version = $data->version;
- $network = NETWORK_DIASPORA;
- }
- if (!empty($data->site_name)) {
- $site_name = $data->site_name;
- }
- switch ($data->register_policy) {
- case "REGISTER_OPEN":
- $register_policy = REGISTER_OPEN;
- break;
- case "REGISTER_APPROVE":
- $register_policy = REGISTER_APPROVE;
- break;
- case "REGISTER_CLOSED":
- default:
- $register_policy = REGISTER_CLOSED;
- break;
- }
- } else {
- // Test for Hubzilla, Redmatrix or Friendica
- $serverret = z_fetch_url($server_url."/api/statusnet/config.json");
- if ($serverret["success"]) {
- $data = json_decode($serverret["body"]);
- if (isset($data->site->server)) {
- if (isset($data->site->platform)) {
- $platform = $data->site->platform->PLATFORM_NAME;
- $version = $data->site->platform->STD_VERSION;
- $network = NETWORK_DIASPORA;
- }
- if (isset($data->site->BlaBlaNet)) {
- $platform = $data->site->BlaBlaNet->PLATFORM_NAME;
- $version = $data->site->BlaBlaNet->STD_VERSION;
- $network = NETWORK_DIASPORA;
- }
- if (isset($data->site->hubzilla)) {
- $platform = $data->site->hubzilla->PLATFORM_NAME;
- $version = $data->site->hubzilla->RED_VERSION;
- $network = NETWORK_DIASPORA;
- }
- if (isset($data->site->redmatrix)) {
- if (isset($data->site->redmatrix->PLATFORM_NAME)) {
- $platform = $data->site->redmatrix->PLATFORM_NAME;
- } elseif (isset($data->site->redmatrix->RED_PLATFORM)) {
- $platform = $data->site->redmatrix->RED_PLATFORM;
- }
-
- $version = $data->site->redmatrix->RED_VERSION;
- $network = NETWORK_DIASPORA;
- }
- if (isset($data->site->friendica)) {
- $platform = $data->site->friendica->FRIENDICA_PLATFORM;
- $version = $data->site->friendica->FRIENDICA_VERSION;
- $network = NETWORK_DFRN;
- }
-
- $site_name = $data->site->name;
-
- $data->site->closed = poco_to_boolean($data->site->closed);
- $data->site->private = poco_to_boolean($data->site->private);
- $data->site->inviteonly = poco_to_boolean($data->site->inviteonly);
-
- if (!$data->site->closed && !$data->site->private and $data->site->inviteonly) {
- $register_policy = REGISTER_APPROVE;
- } elseif (!$data->site->closed && !$data->site->private) {
- $register_policy = REGISTER_OPEN;
- } else {
- $register_policy = REGISTER_CLOSED;
- }
- }
- }
- }
- }
-
- // Query statistics.json. Optional package for Diaspora, Friendica and Redmatrix
- if (!$failure) {
- $serverret = z_fetch_url($server_url."/statistics.json");
- if ($serverret["success"]) {
- $data = json_decode($serverret["body"]);
- if (isset($data->version)) {
- $version = $data->version;
- // Version numbers on statistics.json are presented with additional info, e.g.:
- // 0.6.3.0-p1702cc1c, 0.6.99.0-p1b9ab160 or 3.4.3-2-1191.
- $version = preg_replace("=(.+)-(.{4,})=ism", "$1", $version);
- }
-
- if (!empty($data->name)) {
- $site_name = $data->name;
- }
-
- if (!empty($data->network)) {
- $platform = $data->network;
- }
-
- if ($platform == "Diaspora") {
- $network = NETWORK_DIASPORA;
- }
-
- if ($data->registrations_open) {
- $register_policy = REGISTER_OPEN;
- } else {
- $register_policy = REGISTER_CLOSED;
- }
- }
- }
-
- // Query nodeinfo. Working for (at least) Diaspora and Friendica.
- if (!$failure) {
- $server = poco_fetch_nodeinfo($server_url);
- if ($server) {
- $register_policy = $server['register_policy'];
-
- if (isset($server['platform'])) {
- $platform = $server['platform'];
- }
-
- if (isset($server['network'])) {
- $network = $server['network'];
- }
-
- if (isset($server['version'])) {
- $version = $server['version'];
- }
-
- if (isset($server['site_name'])) {
- $site_name = $server['site_name'];
- }
- }
- }
-
- // Check for noscrape
- // Friendica servers could be detected as OStatus servers
- if (!$failure && in_array($network, array(NETWORK_DFRN, NETWORK_OSTATUS))) {
- $serverret = z_fetch_url($server_url."/friendica/json");
-
- if (!$serverret["success"]) {
- $serverret = z_fetch_url($server_url."/friendika/json");
- }
-
- if ($serverret["success"]) {
- $data = json_decode($serverret["body"]);
-
- if (isset($data->version)) {
- $network = NETWORK_DFRN;
-
- $noscrape = $data->no_scrape_url;
- $version = $data->version;
- $site_name = $data->site_name;
- $info = $data->info;
- $register_policy_str = $data->register_policy;
- $platform = $data->platform;
-
- switch ($register_policy_str) {
- case "REGISTER_CLOSED":
- $register_policy = REGISTER_CLOSED;
- break;
- case "REGISTER_APPROVE":
- $register_policy = REGISTER_APPROVE;
- break;
- case "REGISTER_OPEN":
- $register_policy = REGISTER_OPEN;
- break;
- }
- }
- }
- }
-
- if ($possible_failure && !$failure) {
- $failure = true;
- }
-
- if ($failure) {
- $last_contact = $orig_last_contact;
- $last_failure = datetime_convert();
- } else {
- $last_contact = datetime_convert();
- $last_failure = $orig_last_failure;
- }
-
- if (($last_contact <= $last_failure) && !$failure) {
- logger("Server ".$server_url." seems to be alive, but last contact wasn't set - could be a bug", LOGGER_DEBUG);
- } elseif (($last_contact >= $last_failure) && $failure) {
- logger("Server ".$server_url." seems to be dead, but last failure wasn't set - could be a bug", LOGGER_DEBUG);
- }
-
- // Check again if the server exists
- $servers = q("SELECT `nurl` FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
-
- $version = strip_tags($version);
- $site_name = strip_tags($site_name);
- $info = strip_tags($info);
- $platform = strip_tags($platform);
-
- if ($servers) {
- q("UPDATE `gserver` SET `url` = '%s', `version` = '%s', `site_name` = '%s', `info` = '%s', `register_policy` = %d, `poco` = '%s', `noscrape` = '%s',
- `network` = '%s', `platform` = '%s', `last_contact` = '%s', `last_failure` = '%s' WHERE `nurl` = '%s'",
- dbesc($server_url),
- dbesc($version),
- dbesc($site_name),
- dbesc($info),
- intval($register_policy),
- dbesc($poco),
- dbesc($noscrape),
- dbesc($network),
- dbesc($platform),
- dbesc($last_contact),
- dbesc($last_failure),
- dbesc(normalise_link($server_url))
- );
- } elseif (!$failure) {
- q("INSERT INTO `gserver` (`url`, `nurl`, `version`, `site_name`, `info`, `register_policy`, `poco`, `noscrape`, `network`, `platform`, `created`, `last_contact`, `last_failure`)
- VALUES ('%s', '%s', '%s', '%s', '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s')",
- dbesc($server_url),
- dbesc(normalise_link($server_url)),
- dbesc($version),
- dbesc($site_name),
- dbesc($info),
- intval($register_policy),
- dbesc($poco),
- dbesc($noscrape),
- dbesc($network),
- dbesc($platform),
- dbesc(datetime_convert()),
- dbesc($last_contact),
- dbesc($last_failure),
- dbesc(datetime_convert())
- );
- }
- logger("End discovery for server " . $server_url, LOGGER_DEBUG);
-
- return !$failure;
-}
-
-function count_common_friends($uid, $cid) {
-
- $r = q("SELECT count(*) as `total`
- FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
- WHERE `glink`.`cid` = %d AND `glink`.`uid` = %d AND
- ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))
- AND `gcontact`.`nurl` IN (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 and id != %d ) ",
- intval($cid),
- intval($uid),
- intval($uid),
- intval($cid)
- );
-
- // logger("count_common_friends: $uid $cid {$r[0]['total']}");
- if (DBM::is_result($r)) {
- return $r[0]['total'];
- }
- return 0;
-
-}
-
-
-function common_friends($uid, $cid, $start = 0, $limit = 9999, $shuffle = false) {
-
- if ($shuffle) {
- $sql_extra = " order by rand() ";
- } else {
- $sql_extra = " order by `gcontact`.`name` asc ";
- }
-
- $r = q("SELECT `gcontact`.*, `contact`.`id` AS `cid`
- FROM `glink`
- INNER JOIN `gcontact` ON `glink`.`gcid` = `gcontact`.`id`
- INNER JOIN `contact` ON `gcontact`.`nurl` = `contact`.`nurl`
- WHERE `glink`.`cid` = %d and `glink`.`uid` = %d
- AND `contact`.`uid` = %d AND `contact`.`self` = 0 AND `contact`.`blocked` = 0
- AND `contact`.`hidden` = 0 AND `contact`.`id` != %d
- AND ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))
- $sql_extra LIMIT %d, %d",
- intval($cid),
- intval($uid),
- intval($uid),
- intval($cid),
- intval($start),
- intval($limit)
- );
-
- /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
- return $r;
-
-}
-
-
-function count_common_friends_zcid($uid, $zcid) {
-
- $r = q("SELECT count(*) as `total`
- FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
- where `glink`.`zcid` = %d
- and `gcontact`.`nurl` in (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 ) ",
- intval($zcid),
- intval($uid)
- );
-
- if (DBM::is_result($r)) {
- return $r[0]['total'];
- }
- return 0;
-
-}
-
-function common_friends_zcid($uid, $zcid, $start = 0, $limit = 9999, $shuffle = false) {
-
- if ($shuffle) {
- $sql_extra = " order by rand() ";
- } else {
- $sql_extra = " order by `gcontact`.`name` asc ";
- }
-
- $r = q("SELECT `gcontact`.*
- FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
- where `glink`.`zcid` = %d
- and `gcontact`.`nurl` in (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 )
- $sql_extra limit %d, %d",
- intval($zcid),
- intval($uid),
- intval($start),
- intval($limit)
- );
-
- /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
- return $r;
-
-}
-
-
-function count_all_friends($uid, $cid) {
-
- $r = q("SELECT count(*) as `total`
- FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
- where `glink`.`cid` = %d and `glink`.`uid` = %d AND
- ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))",
- intval($cid),
- intval($uid)
- );
-
- if (DBM::is_result($r)) {
- return $r[0]['total'];
- }
- return 0;
-
-}
-
-
-function all_friends($uid, $cid, $start = 0, $limit = 80) {
-
- $r = q("SELECT `gcontact`.*, `contact`.`id` AS `cid`
- FROM `glink`
- INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
- LEFT JOIN `contact` ON `contact`.`nurl` = `gcontact`.`nurl` AND `contact`.`uid` = %d
- WHERE `glink`.`cid` = %d AND `glink`.`uid` = %d AND
- ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))
- ORDER BY `gcontact`.`name` ASC LIMIT %d, %d ",
- intval($uid),
- intval($cid),
- intval($uid),
- intval($start),
- intval($limit)
- );
-
- /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
- return $r;
-}
-
-
-
-function suggestion_query($uid, $start = 0, $limit = 80) {
-
- if (!$uid) {
- return array();
- }
-
- /*
- * Uncommented because the result of the queries are to big to store it in the cache.
- * We need to decide if we want to change the db column type or if we want to delete it.
- */
- //$list = Cache::get("suggestion_query:".$uid.":".$start.":".$limit);
- //if (!is_null($list)) {
- // return $list;
- //}
-
- $network = array(NETWORK_DFRN);
-
- if (Config::get('system','diaspora_enabled')) {
- $network[] = NETWORK_DIASPORA;
- }
-
- if (!Config::get('system','ostatus_disabled')) {
- $network[] = NETWORK_OSTATUS;
- }
-
- $sql_network = implode("', '", $network);
- $sql_network = "'".$sql_network."'";
-
- /// @todo This query is really slow
- // By now we cache the data for five minutes
- $r = q("SELECT count(glink.gcid) as `total`, gcontact.* from gcontact
- INNER JOIN `glink` ON `glink`.`gcid` = `gcontact`.`id`
- where uid = %d and not gcontact.nurl in ( select nurl from contact where uid = %d )
- AND NOT `gcontact`.`name` IN (SELECT `name` FROM `contact` WHERE `uid` = %d)
- AND NOT `gcontact`.`id` IN (SELECT `gcid` FROM `gcign` WHERE `uid` = %d)
- AND `gcontact`.`updated` >= '%s'
- AND `gcontact`.`last_contact` >= `gcontact`.`last_failure`
- AND `gcontact`.`network` IN (%s)
- GROUP BY `glink`.`gcid` ORDER BY `gcontact`.`updated` DESC,`total` DESC LIMIT %d, %d",
- intval($uid),
- intval($uid),
- intval($uid),
- intval($uid),
- dbesc(NULL_DATE),
- $sql_network,
- intval($start),
- intval($limit)
- );
-
- if (DBM::is_result($r) && count($r) >= ($limit -1)) {
- /*
- * Uncommented because the result of the queries are to big to store it in the cache.
- * We need to decide if we want to change the db column type or if we want to delete it.
- */
- //Cache::set("suggestion_query:".$uid.":".$start.":".$limit, $r, CACHE_FIVE_MINUTES);
-
- return $r;
- }
-
- $r2 = q("SELECT gcontact.* FROM gcontact
- INNER JOIN `glink` ON `glink`.`gcid` = `gcontact`.`id`
- WHERE `glink`.`uid` = 0 AND `glink`.`cid` = 0 AND `glink`.`zcid` = 0 AND NOT `gcontact`.`nurl` IN (SELECT `nurl` FROM `contact` WHERE `uid` = %d)
- AND NOT `gcontact`.`name` IN (SELECT `name` FROM `contact` WHERE `uid` = %d)
- AND NOT `gcontact`.`id` IN (SELECT `gcid` FROM `gcign` WHERE `uid` = %d)
- AND `gcontact`.`updated` >= '%s'
- AND `gcontact`.`last_contact` >= `gcontact`.`last_failure`
- AND `gcontact`.`network` IN (%s)
- ORDER BY rand() LIMIT %d, %d",
- intval($uid),
- intval($uid),
- intval($uid),
- dbesc(NULL_DATE),
- $sql_network,
- intval($start),
- intval($limit)
- );
-
- $list = array();
- foreach ($r2 as $suggestion) {
- $list[$suggestion["nurl"]] = $suggestion;
- }
-
- foreach ($r as $suggestion) {
- $list[$suggestion["nurl"]] = $suggestion;
- }
-
- while (sizeof($list) > ($limit)) {
- array_pop($list);
- }
-
- /*
- * Uncommented because the result of the queries are to big to store it in the cache.
- * We need to decide if we want to change the db column type or if we want to delete it.
- */
- //Cache::set("suggestion_query:".$uid.":".$start.":".$limit, $list, CACHE_FIVE_MINUTES);
- return $list;
-}
-
-function update_suggestions() {
-
- $a = get_app();
-
- $done = array();
-
- /// @TODO Check if it is really neccessary to poll the own server
- poco_load(0, 0, 0, System::baseUrl() . '/poco');
-
- $done[] = System::baseUrl() . '/poco';
-
- if (strlen(Config::get('system','directory'))) {
- $x = fetch_url(get_server()."/pubsites");
- if ($x) {
- $j = json_decode($x);
- if ($j->entries) {
- foreach ($j->entries as $entry) {
-
- poco_check_server($entry->url);
-
- $url = $entry->url . '/poco';
- if (! in_array($url,$done)) {
- poco_load(0,0,0,$entry->url . '/poco');
- }
- }
- }
- }
- }
-
- // Query your contacts from Friendica and Redmatrix/Hubzilla for their contacts
- $r = q("SELECT DISTINCT(`poco`) AS `poco` FROM `contact` WHERE `network` IN ('%s', '%s')",
- dbesc(NETWORK_DFRN), dbesc(NETWORK_DIASPORA)
- );
-
- if (DBM::is_result($r)) {
- foreach ($r as $rr) {
- $base = substr($rr['poco'],0,strrpos($rr['poco'],'/'));
- if (! in_array($base,$done)) {
- poco_load(0,0,0,$base);
- }
- }
- }
-}
-
-/**
- * @brief Fetch server list from remote servers and adds them when they are new.
- *
- * @param string $poco URL to the POCO endpoint
- */
-function poco_fetch_serverlist($poco) {
- $serverret = z_fetch_url($poco."/@server");
- if (!$serverret["success"]) {
- return;
- }
- $serverlist = json_decode($serverret['body']);
-
- if (!is_array($serverlist)) {
- return;
- }
-
- foreach ($serverlist as $server) {
- $server_url = str_replace("/index.php", "", $server->url);
-
- $r = q("SELECT `nurl` FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
- if (!DBM::is_result($r)) {
- logger("Call server check for server ".$server_url, LOGGER_DEBUG);
- Worker::add(PRIORITY_LOW, "discover_poco", "server", $server_url);
- }
- }
-}
-
-function poco_discover_federation() {
- $last = Config::get('poco','last_federation_discovery');
-
- if ($last) {
- $next = $last + (24 * 60 * 60);
- if ($next > time()) {
- return;
- }
- }
-
- // Discover Friendica, Hubzilla and Diaspora servers
- $serverdata = fetch_url("http://the-federation.info/pods.json");
-
- if ($serverdata) {
- $servers = json_decode($serverdata);
-
- foreach ($servers->pods as $server) {
- Worker::add(PRIORITY_LOW, "discover_poco", "server", "https://".$server->host);
- }
- }
-
- // Disvover Mastodon servers
- if (!Config::get('system','ostatus_disabled')) {
- $serverdata = fetch_url("https://instances.mastodon.xyz/instances.json");
-
- if ($serverdata) {
- $servers = json_decode($serverdata);
-
- foreach ($servers as $server) {
- $url = (is_null($server->https_score) ? 'http' : 'https').'://'.$server->name;
- Worker::add(PRIORITY_LOW, "discover_poco", "server", $url);
- }
- }
- }
-
- // Currently disabled, since the service isn't available anymore.
- // It is not removed since I hope that there will be a successor.
- // Discover GNU Social Servers.
- //if (!Config::get('system','ostatus_disabled')) {
- // $serverdata = "http://gstools.org/api/get_open_instances/";
-
- // $result = z_fetch_url($serverdata);
- // if ($result["success"]) {
- // $servers = json_decode($result["body"]);
-
- // foreach($servers->data as $server)
- // poco_check_server($server->instance_address);
- // }
- //}
-
- Config::set('poco','last_federation_discovery', time());
-}
-
-function poco_discover_single_server($id) {
- $r = q("SELECT `poco`, `nurl`, `url`, `network` FROM `gserver` WHERE `id` = %d", intval($id));
- if (!DBM::is_result($r)) {
- return false;
- }
-
- $server = $r[0];
-
- // Discover new servers out there (Works from Friendica version 3.5.2)
- poco_fetch_serverlist($server["poco"]);
-
- // Fetch all users from the other server
- $url = $server["poco"]."/?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
-
- logger("Fetch all users from the server ".$server["url"], LOGGER_DEBUG);
-
- $retdata = z_fetch_url($url);
- if ($retdata["success"]) {
- $data = json_decode($retdata["body"]);
-
- poco_discover_server($data, 2);
-
- if (Config::get('system','poco_discovery') > 1) {
-
- $timeframe = Config::get('system','poco_discovery_since');
- if ($timeframe == 0) {
- $timeframe = 30;
- }
-
- $updatedSince = date("Y-m-d H:i:s", time() - $timeframe * 86400);
-
- // Fetch all global contacts from the other server (Not working with Redmatrix and Friendica versions before 3.3)
- $url = $server["poco"]."/@global?updatedSince=".$updatedSince."&fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
-
- $success = false;
-
- $retdata = z_fetch_url($url);
- if ($retdata["success"]) {
- logger("Fetch all global contacts from the server ".$server["nurl"], LOGGER_DEBUG);
- $success = poco_discover_server(json_decode($retdata["body"]));
- }
-
- if (!$success && (Config::get('system','poco_discovery') > 2)) {
- logger("Fetch contacts from users of the server ".$server["nurl"], LOGGER_DEBUG);
- poco_discover_server_users($data, $server);
- }
- }
-
- q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
-
- return true;
- } else {
- // If the server hadn't replied correctly, then force a sanity check
- poco_check_server($server["url"], $server["network"], true);
-
- // If we couldn't reach the server, we will try it some time later
- q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
-
- return false;
- }
-}
-
-function poco_discover($complete = false) {
-
- // Update the server list
- poco_discover_federation();
-
- $no_of_queries = 5;
-
- $requery_days = intval(Config::get("system", "poco_requery_days"));
-
- if ($requery_days == 0) {
- $requery_days = 7;
- }
- $last_update = date("c", time() - (60 * 60 * 24 * $requery_days));
-
- $r = q("SELECT `id`, `url`, `network` FROM `gserver` WHERE `last_contact` >= `last_failure` AND `poco` != '' AND `last_poco_query` < '%s' ORDER BY RAND()", dbesc($last_update));
- if (DBM::is_result($r)) {
- foreach ($r as $server) {
-
- if (!poco_check_server($server["url"], $server["network"])) {
- // The server is not reachable? Okay, then we will try it later
- q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
- continue;
- }
-
- logger('Update directory from server '.$server['url'].' with ID '.$server['id'], LOGGER_DEBUG);
- Worker::add(PRIORITY_LOW, "discover_poco", "update_server_directory", (int)$server['id']);
-
- if (!$complete && (--$no_of_queries == 0)) {
- break;
- }
- }
- }
-}
-
-function poco_discover_server_users($data, $server) {
-
- if (!isset($data->entry)) {
- return;
- }
-
- foreach ($data->entry as $entry) {
- $username = "";
- if (isset($entry->urls)) {
- foreach ($entry->urls as $url) {
- if ($url->type == 'profile') {
- $profile_url = $url->value;
- $urlparts = parse_url($profile_url);
- $username = end(explode("/", $urlparts["path"]));
- }
- }
- }
- if ($username != "") {
- logger("Fetch contacts for the user ".$username." from the server ".$server["nurl"], LOGGER_DEBUG);
-
- // Fetch all contacts from a given user from the other server
- $url = $server["poco"]."/".$username."/?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
-
- $retdata = z_fetch_url($url);
- if ($retdata["success"]) {
- poco_discover_server(json_decode($retdata["body"]), 3);
- }
- }
- }
-}
-
-function poco_discover_server($data, $default_generation = 0) {
-
- if (!isset($data->entry) || !count($data->entry)) {
- return false;
- }
-
- $success = false;
-
- foreach ($data->entry as $entry) {
- $profile_url = '';
- $profile_photo = '';
- $connect_url = '';
- $name = '';
- $network = '';
- $updated = NULL_DATE;
- $location = '';
- $about = '';
- $keywords = '';
- $gender = '';
- $contact_type = -1;
- $generation = $default_generation;
-
- $name = $entry->displayName;
-
- if (isset($entry->urls)) {
- foreach ($entry->urls as $url) {
- if ($url->type == 'profile') {
- $profile_url = $url->value;
- continue;
- }
- if ($url->type == 'webfinger') {
- $connect_url = str_replace('acct:' , '', $url->value);
- continue;
- }
- }
- }
-
- if (isset($entry->photos)) {
- foreach ($entry->photos as $photo) {
- if ($photo->type == 'profile') {
- $profile_photo = $photo->value;
- continue;
- }
- }
- }
-
- if (isset($entry->updated)) {
- $updated = date("Y-m-d H:i:s", strtotime($entry->updated));
- }
-
- if (isset($entry->network)) {
- $network = $entry->network;
- }
-
- if (isset($entry->currentLocation)) {
- $location = $entry->currentLocation;
- }
-
- if (isset($entry->aboutMe)) {
- $about = html2bbcode($entry->aboutMe);
- }
-
- if (isset($entry->gender)) {
- $gender = $entry->gender;
- }
-
- if(isset($entry->generation) && ($entry->generation > 0)) {
- $generation = ++$entry->generation;
- }
-
- if(isset($entry->contactType) && ($entry->contactType >= 0)) {
- $contact_type = $entry->contactType;
- }
-
- if (isset($entry->tags)) {
- foreach ($entry->tags as $tag) {
- $keywords = implode(", ", $tag);
- }
- }
-
- if ($generation > 0) {
- $success = true;
-
- logger("Store profile ".$profile_url, LOGGER_DEBUG);
-
- $gcontact = array("url" => $profile_url,
- "name" => $name,
- "network" => $network,
- "photo" => $profile_photo,
- "about" => $about,
- "location" => $location,
- "gender" => $gender,
- "keywords" => $keywords,
- "connect" => $connect_url,
- "updated" => $updated,
- "contact-type" => $contact_type,
- "generation" => $generation);
-
- try {
- $gcontact = sanitize_gcontact($gcontact);
- update_gcontact($gcontact);
- } catch (Exception $e) {
- logger($e->getMessage(), LOGGER_DEBUG);
- }
-
- logger("Done for profile ".$profile_url, LOGGER_DEBUG);
- }
- }
- return $success;
-}
-
-/**
- * @brief Removes unwanted parts from a contact url
- *
- * @param string $url Contact url
- * @return string Contact url with the wanted parts
- */
-function clean_contact_url($url) {
- $parts = parse_url($url);
-
- if (!isset($parts["scheme"]) || !isset($parts["host"])) {
- return $url;
- }
-
- $new_url = $parts["scheme"]."://".$parts["host"];
-
- if (isset($parts["port"])) {
- $new_url .= ":".$parts["port"];
- }
-
- if (isset($parts["path"])) {
- $new_url .= $parts["path"];
- }
-
- if ($new_url != $url) {
- logger("Cleaned contact url ".$url." to ".$new_url." - Called by: ".System::callstack(), LOGGER_DEBUG);
- }
-
- return $new_url;
-}
-
-/**
- * @brief Replace alternate OStatus user format with the primary one
- *
- * @param arr $contact contact array (called by reference)
- */
-function fix_alternate_contact_address(&$contact) {
- if (($contact["network"] == NETWORK_OSTATUS) && poco_alternate_ostatus_url($contact["url"])) {
- $data = Probe::uri($contact["url"]);
- if ($contact["network"] == NETWORK_OSTATUS) {
- logger("Fix primary url from ".$contact["url"]." to ".$data["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
- $contact["url"] = $data["url"];
- $contact["addr"] = $data["addr"];
- $contact["alias"] = $data["alias"];
- $contact["server_url"] = $data["baseurl"];
- }
- }
-}
-
-/**
- * @brief Fetch the gcontact id, add an entry if not existed
- *
- * @param arr $contact contact array
- * @return bool|int Returns false if not found, integer if contact was found
- */
-function get_gcontact_id($contact) {
-
- $gcontact_id = 0;
- $doprobing = false;
-
- if (in_array($contact["network"], array(NETWORK_PHANTOM))) {
- logger("Invalid network for contact url ".$contact["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
- return false;
- }
-
- if ($contact["network"] == NETWORK_STATUSNET) {
- $contact["network"] = NETWORK_OSTATUS;
- }
-
- // All new contacts are hidden by default
- if (!isset($contact["hide"])) {
- $contact["hide"] = true;
- }
-
- // Replace alternate OStatus user format with the primary one
- fix_alternate_contact_address($contact);
-
- // Remove unwanted parts from the contact url (e.g. "?zrl=...")
- if (in_array($contact["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
- $contact["url"] = clean_contact_url($contact["url"]);
- }
-
- dba::lock('gcontact');
- $r = q("SELECT `id`, `last_contact`, `last_failure`, `network` FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
- dbesc(normalise_link($contact["url"])));
-
- if (DBM::is_result($r)) {
- $gcontact_id = $r[0]["id"];
-
- // Update every 90 days
- if (in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
- $last_failure_str = $r[0]["last_failure"];
- $last_failure = strtotime($r[0]["last_failure"]);
- $last_contact_str = $r[0]["last_contact"];
- $last_contact = strtotime($r[0]["last_contact"]);
- $doprobing = (((time() - $last_contact) > (90 * 86400)) && ((time() - $last_failure) > (90 * 86400)));
- }
- } else {
- q("INSERT INTO `gcontact` (`name`, `nick`, `addr` , `network`, `url`, `nurl`, `photo`, `created`, `updated`, `location`, `about`, `hide`, `generation`)
- VALUES ('%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d, %d)",
- dbesc($contact["name"]),
- dbesc($contact["nick"]),
- dbesc($contact["addr"]),
- dbesc($contact["network"]),
- dbesc($contact["url"]),
- dbesc(normalise_link($contact["url"])),
- dbesc($contact["photo"]),
- dbesc(datetime_convert()),
- dbesc(datetime_convert()),
- dbesc($contact["location"]),
- dbesc($contact["about"]),
- intval($contact["hide"]),
- intval($contact["generation"])
- );
-
- $r = q("SELECT `id`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 2",
- dbesc(normalise_link($contact["url"])));
-
- if (DBM::is_result($r)) {
- $gcontact_id = $r[0]["id"];
-
- $doprobing = in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""));
- }
- }
- dba::unlock();
-
- if ($doprobing) {
- logger("Last Contact: ". $last_contact_str." - Last Failure: ".$last_failure_str." - Checking: ".$contact["url"], LOGGER_DEBUG);
- Worker::add(PRIORITY_LOW, 'gprobe', $contact["url"]);
- }
-
- return $gcontact_id;
-}
-
-/**
- * @brief Updates the gcontact table from a given array
- *
- * @param arr $contact contact array
- * @return bool|int Returns false if not found, integer if contact was found
- */
-function update_gcontact($contact) {
-
- // Check for invalid "contact-type" value
- if (isset($contact['contact-type']) && (intval($contact['contact-type']) < 0)) {
- $contact['contact-type'] = 0;
- }
-
- /// @todo update contact table as well
-
- $gcontact_id = get_gcontact_id($contact);
-
- if (!$gcontact_id) {
- return false;
- }
-
- $r = q("SELECT `name`, `nick`, `photo`, `location`, `about`, `addr`, `generation`, `birthday`, `gender`, `keywords`,
- `contact-type`, `hide`, `nsfw`, `network`, `alias`, `notify`, `server_url`, `connect`, `updated`, `url`
- FROM `gcontact` WHERE `id` = %d LIMIT 1",
- intval($gcontact_id));
-
- // Get all field names
- $fields = array();
- foreach ($r[0] as $field => $data) {
- $fields[$field] = $data;
- }
-
- unset($fields["url"]);
- unset($fields["updated"]);
- unset($fields["hide"]);
-
- // Bugfix: We had an error in the storing of keywords which lead to the "0"
- // This value is still transmitted via poco.
- if ($contact["keywords"] == "0") {
- unset($contact["keywords"]);
- }
-
- if ($r[0]["keywords"] == "0") {
- $r[0]["keywords"] = "";
- }
-
- // assign all unassigned fields from the database entry
- foreach ($fields as $field => $data) {
- if (!isset($contact[$field]) || ($contact[$field] == "")) {
- $contact[$field] = $r[0][$field];
- }
- }
-
- if (!isset($contact["hide"])) {
- $contact["hide"] = $r[0]["hide"];
- }
-
- $fields["hide"] = $r[0]["hide"];
-
- if ($contact["network"] == NETWORK_STATUSNET) {
- $contact["network"] = NETWORK_OSTATUS;
- }
-
- // Replace alternate OStatus user format with the primary one
- fix_alternate_contact_address($contact);
-
- if (!isset($contact["updated"])) {
- $contact["updated"] = DBM::date();
- }
-
- if ($contact["network"] == NETWORK_TWITTER) {
- $contact["server_url"] = 'http://twitter.com';
- }
-
- if ($contact["server_url"] == "") {
- $data = Probe::uri($contact["url"]);
- if ($data["network"] != NETWORK_PHANTOM) {
- $contact["server_url"] = $data['baseurl'];
- }
- } else {
- $contact["server_url"] = normalise_link($contact["server_url"]);
- }
-
- if (($contact["addr"] == "") && ($contact["server_url"] != "") && ($contact["nick"] != "")) {
- $hostname = str_replace("http://", "", $contact["server_url"]);
- $contact["addr"] = $contact["nick"]."@".$hostname;
- }
-
- // Check if any field changed
- $update = false;
- unset($fields["generation"]);
-
- if ((($contact["generation"] > 0) && ($contact["generation"] <= $r[0]["generation"])) || ($r[0]["generation"] == 0)) {
- foreach ($fields as $field => $data) {
- if ($contact[$field] != $r[0][$field]) {
- logger("Difference for contact ".$contact["url"]." in field '".$field."'. New value: '".$contact[$field]."', old value '".$r[0][$field]."'", LOGGER_DEBUG);
- $update = true;
- }
- }
-
- if ($contact["generation"] < $r[0]["generation"]) {
- logger("Difference for contact ".$contact["url"]." in field 'generation'. new value: '".$contact["generation"]."', old value '".$r[0]["generation"]."'", LOGGER_DEBUG);
- $update = true;
- }
- }
-
- if ($update) {
- logger("Update gcontact for ".$contact["url"], LOGGER_DEBUG);
- $condition = array('`nurl` = ? AND (`generation` = 0 OR `generation` >= ?)',
- normalise_link($contact["url"]), $contact["generation"]);
- $contact["updated"] = DBM::date($contact["updated"]);
-
- $updated = array('photo' => $contact['photo'], 'name' => $contact['name'],
- 'nick' => $contact['nick'], 'addr' => $contact['addr'],
- 'network' => $contact['network'], 'birthday' => $contact['birthday'],
- 'gender' => $contact['gender'], 'keywords' => $contact['keywords'],
- 'hide' => $contact['hide'], 'nsfw' => $contact['nsfw'],
- 'contact-type' => $contact['contact-type'], 'alias' => $contact['alias'],
- 'notify' => $contact['notify'], 'url' => $contact['url'],
- 'location' => $contact['location'], 'about' => $contact['about'],
- 'generation' => $contact['generation'], 'updated' => $contact['updated'],
- 'server_url' => $contact['server_url'], 'connect' => $contact['connect']);
-
- dba::update('gcontact', $updated, $condition, $fields);
-
- // Now update the contact entry with the user id "0" as well.
- // This is used for the shadow copies of public items.
- $r = q("SELECT `id` FROM `contact` WHERE `nurl` = '%s' AND `uid` = 0 ORDER BY `id` LIMIT 1",
- dbesc(normalise_link($contact["url"])));
-
- if (DBM::is_result($r)) {
- logger("Update public contact ".$r[0]["id"], LOGGER_DEBUG);
-
- update_contact_avatar($contact["photo"], 0, $r[0]["id"]);
-
- $fields = array('name', 'nick', 'addr',
- 'network', 'bd', 'gender',
- 'keywords', 'alias', 'contact-type',
- 'url', 'location', 'about');
- $old_contact = dba::select('contact', $fields, array('id' => $r[0]["id"]), array('limit' => 1));
-
- // Update it with the current values
- $fields = array('name' => $contact['name'], 'nick' => $contact['nick'],
- 'addr' => $contact['addr'], 'network' => $contact['network'],
- 'bd' => $contact['birthday'], 'gender' => $contact['gender'],
- 'keywords' => $contact['keywords'], 'alias' => $contact['alias'],
- 'contact-type' => $contact['contact-type'], 'url' => $contact['url'],
- 'location' => $contact['location'], 'about' => $contact['about']);
-
- dba::update('contact', $fields, array('id' => $r[0]["id"]), $old_contact);
- }
- }
-
- return $gcontact_id;
-}
-
-/**
- * @brief Updates the gcontact entry from probe
- *
- * @param str $url profile link
- */
-function update_gcontact_from_probe($url) {
- $data = Probe::uri($url);
-
- if (in_array($data["network"], array(NETWORK_PHANTOM))) {
- logger("Invalid network for contact url ".$data["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
- return;
- }
-
- $data["server_url"] = $data["baseurl"];
-
- update_gcontact($data);
-}
-
-/**
- * @brief Update the gcontact entry for a given user id
- *
- * @param int $uid User ID
- */
-function update_gcontact_for_user($uid) {
- $r = q("SELECT `profile`.`locality`, `profile`.`region`, `profile`.`country-name`,
- `profile`.`name`, `profile`.`about`, `profile`.`gender`,
- `profile`.`pub_keywords`, `profile`.`dob`, `profile`.`photo`,
- `profile`.`net-publish`, `user`.`nickname`, `user`.`hidewall`,
- `contact`.`notify`, `contact`.`url`, `contact`.`addr`
- FROM `profile`
- INNER JOIN `user` ON `user`.`uid` = `profile`.`uid`
- INNER JOIN `contact` ON `contact`.`uid` = `profile`.`uid`
- WHERE `profile`.`uid` = %d AND `profile`.`is-default` AND `contact`.`self`",
- intval($uid));
-
- $location = formatted_location(array("locality" => $r[0]["locality"], "region" => $r[0]["region"],
- "country-name" => $r[0]["country-name"]));
-
- // The "addr" field was added in 3.4.3 so it can be empty for older users
- if ($r[0]["addr"] != "") {
- $addr = $r[0]["nickname"].'@'.str_replace(array("http://", "https://"), "", System::baseUrl());
- } else {
- $addr = $r[0]["addr"];
- }
-
- $gcontact = array("name" => $r[0]["name"], "location" => $location, "about" => $r[0]["about"],
- "gender" => $r[0]["gender"], "keywords" => $r[0]["pub_keywords"],
- "birthday" => $r[0]["dob"], "photo" => $r[0]["photo"],
- "notify" => $r[0]["notify"], "url" => $r[0]["url"],
- "hide" => ($r[0]["hidewall"] || !$r[0]["net-publish"]),
- "nick" => $r[0]["nickname"], "addr" => $addr,
- "connect" => $addr, "server_url" => System::baseUrl(),
- "generation" => 1, "network" => NETWORK_DFRN);
-
- update_gcontact($gcontact);
-}
-
-/**
- * @brief Fetches users of given GNU Social server
- *
- * If the "Statistics" plugin is enabled (See http://gstools.org/ for details) we query user data with this.
- *
- * @param str $server Server address
- */
-function gs_fetch_users($server) {
-
- logger("Fetching users from GNU Social server ".$server, LOGGER_DEBUG);
-
- $url = $server."/main/statistics";
-
- $result = z_fetch_url($url);
- if (!$result["success"]) {
- return false;
- }
-
- $statistics = json_decode($result["body"]);
-
- if (is_object($statistics->config)) {
- if ($statistics->config->instance_with_ssl) {
- $server = "https://";
- } else {
- $server = "http://";
- }
-
- $server .= $statistics->config->instance_address;
-
- $hostname = $statistics->config->instance_address;
- } else {
- /// @TODO is_object() above means here no object, still $statistics is being used as object
- if ($statistics->instance_with_ssl) {
- $server = "https://";
- } else {
- $server = "http://";
- }
-
- $server .= $statistics->instance_address;
-
- $hostname = $statistics->instance_address;
- }
-
- if (is_object($statistics->users)) {
- foreach ($statistics->users as $nick => $user) {
- $profile_url = $server."/".$user->nickname;
-
- $contact = array("url" => $profile_url,
- "name" => $user->fullname,
- "addr" => $user->nickname."@".$hostname,
- "nick" => $user->nickname,
- "about" => $user->bio,
- "network" => NETWORK_OSTATUS,
- "photo" => System::baseUrl()."/images/person-175.jpg");
- get_gcontact_id($contact);
- }
- }
-}
-
-/**
- * @brief Asking GNU Social server on a regular base for their user data
- *
- */
-function gs_discover() {
-
- $requery_days = intval(Config::get("system", "poco_requery_days"));
-
- $last_update = date("c", time() - (60 * 60 * 24 * $requery_days));
-
- $r = q("SELECT `nurl`, `url` FROM `gserver` WHERE `last_contact` >= `last_failure` AND `network` = '%s' AND `last_poco_query` < '%s' ORDER BY RAND() LIMIT 5",
- dbesc(NETWORK_OSTATUS), dbesc($last_update));
-
- if (!DBM::is_result($r)) {
- return;
- }
-
- foreach ($r as $server) {
- gs_fetch_users($server["url"]);
- q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
- }
-}
-
-/**
- * @brief Returns a list of all known servers
- * @return array List of server urls
- */
-function poco_serverlist() {
- $r = q("SELECT `url`, `site_name` AS `displayName`, `network`, `platform`, `version` FROM `gserver`
- WHERE `network` IN ('%s', '%s', '%s') AND `last_contact` > `last_failure`
- ORDER BY `last_contact`
- LIMIT 1000",
- dbesc(NETWORK_DFRN), dbesc(NETWORK_DIASPORA), dbesc(NETWORK_OSTATUS));
- if (!DBM::is_result($r)) {
- return false;
- }
-
- return $r;
-}
+++ /dev/null
-<?php
-/**
- * @file include/spool_post.php
- * @brief Posts items that wer spooled because they couldn't be posted.
- */
-
-use Friendica\Core\Config;
-
-require_once("include/items.php");
-
-function spool_post_run($argv, $argc) {
- global $a;
-
- $path = get_spoolpath();
-
- if (($path != '') && is_writable($path)){
- if ($dh = opendir($path)) {
- while (($file = readdir($dh)) !== false) {
-
- // It is not named like a spool file, so we don't care.
- if (substr($file, 0, 5) != "item-") {
- continue;
- }
-
- $fullfile = $path."/".$file;
-
- // We don't care about directories either
- if (filetype($fullfile) != "file") {
- continue;
- }
-
- // We can't read or write the file? So we don't care about it.
- if (!is_writable($fullfile) || !is_readable($fullfile)) {
- continue;
- }
-
- $arr = json_decode(file_get_contents($fullfile), true);
-
- // If it isn't an array then it is no spool file
- if (!is_array($arr)) {
- continue;
- }
-
- // Skip if it doesn't seem to be an item array
- if (!isset($arr['uid']) && !isset($arr['uri']) && !isset($arr['network'])) {
- continue;
- }
-
- $result = item_store($arr);
-
- logger("Spool file ".$file." stored: ".$result, LOGGER_DEBUG);
- unlink($fullfile);
- }
- closedir($dh);
- }
- }
-}
use Friendica\App;
use Friendica\Core\System;
+use Friendica\Database\DBM;
+use Friendica\Object\Contact;
function create_tags_from_item($itemid) {
$profile_base = System::baseUrl();
dba::close($messages);
}
+
+/**
+ * @brief Get alphabetical sorted array of used tags/terms of an user including
+ * a weighting by frequency of use.
+ *
+ * @param int $uid The user ID.
+ * @param int $count Max number of displayed tags/terms.
+ * @param int $owner_id The contact id of the owner of the tagged items.
+ * @param string $flags Special item flags.
+ * @param int $type The tag/term type.
+ *
+ * @return arr Alphabetical sorted array of used tags of an user.
+ */
+function tagadelic($uid, $count = 0, $owner_id = 0, $flags = '', $type = TERM_HASHTAG) {
+ require_once('include/security.php');
+
+ $item_condition = item_condition();
+ $sql_options = item_permissions_sql($uid);
+ $limit = $count ? sprintf("LIMIT %d", intval($count)) : "";
+
+ if ($flags) {
+ if ($flags === 'wall') {
+ $sql_options .= " AND `item`.`wall` ";
+ }
+ }
+
+ if ($owner_id) {
+ $sql_options .= " AND `item`.`owner-id` = ".intval($owner_id)." ";
+ }
+
+ // Fetch tags
+ $r = dba::p("SELECT `term`, COUNT(`term`) AS `total` FROM `term`
+ LEFT JOIN `item` ON `term`.`oid` = `item`.`id`
+ WHERE `term`.`uid` = ? AND `term`.`type` = ?
+ AND `term`.`otype` = ?
+ AND $item_condition $sql_options
+ GROUP BY `term` ORDER BY `total` DESC $limit",
+ $uid,
+ $type,
+ TERM_OBJ_POST
+ );
+ if(!DBM::is_result($r)) {
+ return array();
+ }
+
+ return tag_calc($r);
+}
+
+/**
+ * @brief Construct a tag/term cloud block for an user.
+ *
+ * @param int $uid The user ID.
+ * @param int $count Max number of displayed tags/terms.
+ * @param int $owner_id The contact ID of the owner of the tagged items.
+ * @param string $flags Special item flags.
+ * @param int $type The tag/term type.
+ *
+ * @return string HTML formatted output.
+ */
+function wtagblock($uid, $count = 0,$owner_id = 0, $flags = '', $type = TERM_HASHTAG) {
+ $o = '';
+ $r = tagadelic($uid, $count, $owner_id, $flags, $type);
+ if (count($r)) {
+ $contact = dba::select(
+ "contact",
+ array("url"),
+ array("id" => $uid),
+ array("limit" => 1)
+ );
+ $url = System::removedBaseUrl($contact['url']);
+
+ foreach ($r as $rr) {
+ $tag['level'] = $rr[2];
+ $tag['url'] = $url."?tag=".urlencode($rr[0]);
+ $tag['name'] = $rr[0];
+
+ $tags[] = $tag;
+ }
+
+ $tpl = get_markup_template("tagblock_widget.tpl");
+ $o = replace_macros($tpl, array(
+ '$title' => t('Tags'),
+ '$tags' => $tags
+ ));
+
+ }
+ return $o;
+}
+
+/**
+ * @brief Calculate weighting of tags according to the frequency of use.
+ *
+ * @param array $arr Array of tags/terms with tag/term name and total count of use.
+ * @return array Alphabetical sorted array of used tags/terms of an user.
+ */
+function tag_calc($arr) {
+ $tags = array();
+ $min = 1e9;
+ $max = -1e9;
+ $x = 0;
+
+ if (!$arr) {
+ return array();
+ }
+
+ foreach ($arr as $rr) {
+ $tags[$x][0] = $rr['term'];
+ $tags[$x][1] = log($rr['total']);
+ $tags[$x][2] = 0;
+ $min = min($min, $tags[$x][1]);
+ $max = max($max, $tags[$x][1]);
+ $x ++;
+ }
+
+ usort($tags, 'tags_sort');
+ $range = max(.01, $max - $min) * 1.0001;
+
+ for ($x = 0; $x < count($tags); $x ++) {
+ $tags[$x][2] = 1 + floor(9 * ($tags[$x][1] - $min) / $range);
+ }
+
+ return $tags;
+}
+
+/**
+ * @brief Compare function to sort tags/terms alphabetically.
+ *
+ * @param type $a
+ * @param type $b
+ *
+ * @return int
+ */
+function tags_sort($a, $b) {
+ if (strtolower($a[0]) == strtolower($b[0])) {
+ return 0;
+ }
+ return ((strtolower($a[0]) < strtolower($b[0])) ? -1 : 1);
+}
+
+/**
+ * @brief Insert a tag cloud widget for the present profile.
+ *
+ * @param int $limit Max number of displayed tags.
+ * @return string HTML formattat output.
+ */
+function tagcloud_wall_widget($limit = 50) {
+ $a = get_app();
+
+ if(!$a->profile['profile_uid'] || !$a->profile['url']) {
+ return "";
+ }
+
+ if(feature_enabled($a->profile['profile_uid'], 'tagadelic')) {
+ $owner_id = Contact::getIdForURL($a->profile['url']);
+
+ if(!$owner_id) {
+ return "";
+ }
+ return wtagblock($a->profile['profile_uid'], $limit, $owner_id, 'wall');
+ }
+
+ return "";
+}
+++ /dev/null
-<?php
-require_once("include/tags.php");
-
-function tagupdate_run(&$argv, &$argc){
- update_items();
-}
+++ /dev/null
-<?php
-/*
- * This is the old template engine, now deprecated.
- * Friendica's default template engine is Smarty3 (see include/friendica_smarty.php)
- *
- */
-require_once 'object/TemplateEngine.php';
-
-define("KEY_NOT_EXISTS", '^R_key_not_Exists^');
-
-class Template implements ITemplateEngine {
- static $name ="internal";
-
- var $r;
- var $search;
- var $replace;
- var $stack = array();
- var $nodes = array();
- var $done = false;
- var $d = false;
- var $lang = null;
- var $debug = false;
-
- private function _preg_error() {
-
- switch (preg_last_error()) {
- case PREG_INTERNAL_ERROR: echo('PREG_INTERNAL_ERROR');
- break;
- case PREG_BACKTRACK_LIMIT_ERROR: echo('PREG_BACKTRACK_LIMIT_ERROR');
- break;
- case PREG_RECURSION_LIMIT_ERROR: echo('PREG_RECURSION_LIMIT_ERROR');
- break;
- case PREG_BAD_UTF8_ERROR: echo('PREG_BAD_UTF8_ERROR');
- break;
-// This is only valid for php > 5.3, not certain how to code around it for unit tests
-// case PREG_BAD_UTF8_OFFSET_ERROR: echo('PREG_BAD_UTF8_OFFSET_ERROR'); break;
- default:
- //die("Unknown preg error.");
- return;
- }
- echo "<hr><pre>";
- debug_print_backtrace();
- die();
- }
-
- private function _push_stack() {
- $this->stack[] = array($this->r, $this->nodes);
- }
-
- private function _pop_stack() {
- list($this->r, $this->nodes) = array_pop($this->stack);
- }
-
- private function _get_var($name, $retNoKey = false) {
- $keys = array_map('trim', explode(".", $name));
- if ($retNoKey && !array_key_exists($keys[0], $this->r))
- return KEY_NOT_EXISTS;
- $val = $this->r;
- foreach ($keys as $k) {
- $val = (isset($val[$k]) ? $val[$k] : null);
- }
- return $val;
- }
-
- /**
- * IF node
- *
- * {{ if <$var> }}...[{{ else }} ...] {{ endif }}
- * {{ if <$var>==<val|$var> }}...[{{ else }} ...]{{ endif }}
- * {{ if <$var>!=<val|$var> }}...[{{ else }} ...]{{ endif }}
- */
- private function _replcb_if ($args) {
- if (strpos($args[2], "==") > 0) {
- list($a, $b) = array_map("trim", explode("==", $args[2]));
- $a = $this->_get_var($a);
- if ($b[0] == "$")
- $b = $this->_get_var($b);
- $val = ($a == $b);
- } else if (strpos($args[2], "!=") > 0) {
- list($a, $b) = array_map("trim", explode("!=", $args[2]));
- $a = $this->_get_var($a);
- if ($b[0] == "$")
- $b = $this->_get_var($b);
- $val = ($a != $b);
- } else {
- $val = $this->_get_var($args[2]);
- }
- $x = preg_split("|{{ *else *}}|", $args[3]);
- return ( $val ? $x[0] : (isset($x[1]) ? $x[1] : ""));
- }
-
- /**
- * FOR node
- *
- * {{ for <$var> as $name }}...{{ endfor }}
- * {{ for <$var> as $key=>$name }}...{{ endfor }}
- */
- private function _replcb_for ($args) {
- $m = array_map('trim', explode(" as ", $args[2]));
- $x = explode("=>", $m[1]);
- if (count($x) == 1) {
- $varname = $x[0];
- $keyname = "";
- } else {
- list($keyname, $varname) = $x;
- }
- if ($m[0] == "" || $varname == "" || is_null($varname))
- die("template error: 'for " . $m[0] . " as " . $varname . "'");
- //$vals = $this->r[$m[0]];
- $vals = $this->_get_var($m[0]);
- $ret = "";
- if (!is_array($vals)) {
- return $ret;
- }
- foreach ($vals as $k => $v) {
- $this->_push_stack();
- $r = $this->r;
- $r[$varname] = $v;
- if ($keyname != '') {
- $r[$keyname] = (($k === 0) ? '0' : $k);
- }
- $ret .= $this->replace($args[3], $r);
- $this->_pop_stack();
- }
- return $ret;
- }
-
- /**
- * INC node
- *
- * {{ inc <templatefile> [with $var1=$var2] }}{{ endinc }}
- */
- private function _replcb_inc($args) {
- if (strpos($args[2], "with")) {
- list($tplfile, $newctx) = array_map('trim', explode("with", $args[2]));
- } else {
- $tplfile = trim($args[2]);
- $newctx = null;
- }
-
- if ($tplfile[0] == "$")
- $tplfile = $this->_get_var($tplfile);
-
- $this->_push_stack();
- $r = $this->r;
- if (!is_null($newctx)) {
- list($a, $b) = array_map('trim', explode("=", $newctx));
- $r[$a] = $this->_get_var($b);
- }
- $this->nodes = Array();
- $tpl = get_markup_template($tplfile);
- $ret = $this->replace($tpl, $r);
- $this->_pop_stack();
- return $ret;
- }
-
- /**
- * DEBUG node
- *
- * {{ debug $var [$var [$var [...]]] }}{{ enddebug }}
- *
- * replace node with <pre>var_dump($var, $var, ...);</pre>
- */
- private function _replcb_debug($args) {
- $vars = array_map('trim', explode(" ", $args[2]));
- $vars[] = $args[1];
-
- $ret = "<pre>";
- foreach ($vars as $var) {
- $ret .= htmlspecialchars(var_export($this->_get_var($var), true));
- $ret .= "\n";
- }
- $ret .= "</pre>";
- return $ret;
- }
-
- private function _replcb_node($m) {
- $node = $this->nodes[$m[1]];
- if (method_exists($this, "_replcb_" . $node[1])) {
- $s = call_user_func(array($this, "_replcb_" . $node[1]), $node);
- } else {
- $s = "";
- }
- $s = preg_replace_callback('/\|\|([0-9]+)\|\|/', array($this, "_replcb_node"), $s);
- return $s;
- }
-
- private function _replcb($m) {
- //var_dump(array_map('htmlspecialchars', $m));
- $this->done = false;
- $this->nodes[] = (array) $m;
- return "||" . (count($this->nodes) - 1) . "||";
- }
-
- private function _build_nodes($s) {
- $this->done = false;
- while (!$this->done) {
- $this->done = true;
- $s = preg_replace_callback('|{{ *([a-z]*) *([^}]*)}}([^{]*({{ *else *}}[^{]*)?){{ *end\1 *}}|', array($this, "_replcb"), $s);
- if ($s == Null)
- $this->_preg_error();
- }
- //({{ *else *}}[^{]*)?
- krsort($this->nodes);
- return $s;
- }
-
- private function var_replace($s) {
- $m = array();
- /** regexp:
- * \$ literal $
- * (\[)? optional open square bracket
- * ([a-zA-Z0-9-_]+\.?)+ var name, followed by optional
- * dot, repeated at least 1 time
- * (|[a-zA-Z0-9-_:]+)* pipe followed by filter name and args, zero or many
- * (?(1)\]) if there was opened square bracket
- * (subgrup 1), match close bracket
- */
- if (preg_match_all('/\$(\[)?([a-zA-Z0-9-_]+\.?)+(\|[a-zA-Z0-9-_:]+)*(?(1)\])/', $s, $m)) {
- foreach ($m[0] as $var) {
-
- $exp = str_replace(array("[", "]"), array("", ""), $var);
- $exptks = explode("|", $exp);
-
- $varn = $exptks[0];
- unset($exptks[0]);
- $val = $this->_get_var($varn, true);
- if ($val != KEY_NOT_EXISTS) {
- /* run filters */
- /*
- * Filter are in form of:
- * filtername:arg:arg:arg
- *
- * "filtername" is function name
- * "arg"s are optional, var value is appended to the end
- * if one "arg"==='x' , is replaced with var value
- *
- * examples:
- * $item.body|htmlspecialchars // escape html chars
- * $item.body|htmlspecialchars|strtoupper // escape html and uppercase result
- * $item.created|date:%Y %M %j // format date (created is a timestamp)
- * $item.body|str_replace:cat:dog // replace all "cat" with "dog"
- * $item.body|str_replace:cat:dog:x:1 // replace one "cat" with "dog"
-
- */
- foreach ($exptks as $filterstr) {
- $filter = explode(":", $filterstr);
- $filtername = $filter[0];
- unset($filter[0]);
- $valkey = array_search("x", $filter);
- if ($valkey === false) {
- $filter[] = $val;
- } else {
- $filter[$valkey] = $val;
- }
- if (function_exists($filtername)) {
- $val = call_user_func_array($filtername, $filter);
- }
- }
- $s = str_replace($var, $val, $s);
- }
- }
- }
-
- return $s;
- }
-
- // TemplateEngine interface
- public function replace_macros($s, $r) {
- $this->r = $r;
-
- // remove comments block
- $s = preg_replace('/{#(.*?\s*?)*?#}/', "", $s);
-
- $s = $this->_build_nodes($s);
-
- $s = preg_replace_callback('/\|\|([0-9]+)\|\|/', array($this, "_replcb_node"), $s);
- if ($s == Null)
- $this->_preg_error();
-
- // replace strings recursively (limit to 10 loops)
- $os = "";
- $count = 0;
- while ($os != $s && $count < 10) {
- $os = $s;
- $count++;
- $s = $this->var_replace($s);
- }
- return template_unescape($s);
- }
-
- public function get_template_file($file, $root='') {
- $a = get_app();
- $template_file = get_template_file($a, $file, $root);
- $content = file_get_contents($template_file);
- return $content;
- }
-
-}
-
-
-function template_escape($s) {
-
- return str_replace(array('$', '{{'), array('!_Doll^Ars1Az_!', '!_DoubLe^BraceS4Rw_!'), $s);
-}
-
-function template_unescape($s) {
-
- return str_replace(array('!_Doll^Ars1Az_!', '!_DoubLe^BraceS4Rw_!'), array('$', '{{'), $s);
-}
-
<?php
use Friendica\App;
+use Friendica\Content\Smilies;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
-require_once "include/template_processor.php";
require_once "include/friendica_smarty.php";
-require_once "include/Smilies.php";
require_once "include/map.php";
require_once "mod/proxy.php";
+require_once "include/conversation.php";
/**
* This is our template processor
$t = $a->template_engine();
try {
- $output = $t->replace_macros($s, $r);
+ $output = $t->replaceMacros($s, $r);
} catch (Exception $e) {
echo "<pre><b>" . __FUNCTION__ . "</b>: " . $e->getMessage() . "</pre>";
killme();
return $output;
}
+/**
+ * @brief Generates a pseudo-random string of hexadecimal characters
+ *
+ * @param int $size
+ * @return string
+ */
+function random_string($size = 64)
+{
+ $byte_size = ceil($size / 2);
-// random string, there are 86 characters max in text mode, 128 for hex
-// output is urlsafe
+ $bytes = random_bytes($byte_size);
-define('RANDOM_STRING_HEX', 0x00);
-define('RANDOM_STRING_TEXT', 0x01);
+ $return = substr(bin2hex($bytes), 0, $size);
-function random_string($size = 64, $type = RANDOM_STRING_HEX) {
- // generate a bit of entropy and run it through the whirlpool
- $s = hash('whirlpool', (string) rand() . uniqid(rand(),true) . (string) rand(), (($type == RANDOM_STRING_TEXT) ? true : false));
- $s = (($type == RANDOM_STRING_TEXT) ? str_replace("\n", "", base64url_encode($s,true)) : $s);
- return substr($s,0,$size);
+ return $return;
}
/**
$a = get_app();
$t = $a->template_engine();
try {
- $template = $t->get_template_file($s, $root);
+ $template = $t->getTemplateFile($s, $root);
} catch (Exception $e) {
echo "<pre><b>" . __FUNCTION__ . "</b>: " . $e->getMessage() . "</pre>";
killme();
/**
* @brief Translate days and months names.
- *
+ *
* @param string $s String with day or month name.
* @return string Translated string.
*/
/**
* @brief Translate short days and months names.
- *
+ *
* @param string $s String with short day or month name.
* @return string Translated string.
*/
use Friendica\App;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
function add_thread($itemid, $onlyshadow = false) {
$items = q("SELECT `uid`, `created`, `edited`, `commented`, `received`, `changed`, `wall`, `private`, `pubmail`,
}
// Is the public contact configured as hidden?
- if (hiddenContact($item["owner-id"]) || hiddenContact($item["author-id"])) {
+ if (Contact::isHidden($item["owner-id"]) || Contact::isHidden($item["author-id"])) {
return;
}
if (!DBM::is_result($r)) {
// Preparing public shadow (removing user specific data)
require_once("include/items.php");
- require_once("include/Contact.php");
unset($item[0]['id']);
$item[0]['uid'] = 0;
$item[0]['origin'] = 0;
$item[0]['wall'] = 0;
- $item[0]['contact-id'] = get_contact($item[0]['author-link'], 0);
+ $item[0]['contact-id'] = Contact::getIdForURL($item[0]['author-link'], 0);
if (in_array($item[0]['type'], array("net-comment", "wall-comment"))) {
$item[0]['type'] = 'remote-comment';
// Preparing public shadow (removing user specific data)
require_once("include/items.php");
- require_once("include/Contact.php");
unset($item['id']);
$item['uid'] = 0;
$item['origin'] = 0;
$item['wall'] = 0;
- $item['contact-id'] = get_contact($item['author-link'], 0);
+ $item['contact-id'] = Contact::getIdForURL($item['author-link'], 0);
if (in_array($item['type'], array("net-comment", "wall-comment"))) {
$item['type'] = 'remote-comment';
}
// Using dba::delete at this time could delete the associated item entries
- $result = q("DELETE FROM `thread` WHERE `iid` = %d", intval($itemid));
+ $result = dba::e("DELETE FROM `thread` WHERE `iid` = ?", $itemid);
logger("delete_thread: Deleted thread for item ".$itemid." - ".print_r($result, true), LOGGER_DEBUG);
+++ /dev/null
-<?php
-require_once("include/threads.php");
-
-function threadupdate_run(&$argv, &$argc){
- update_threads();
- update_threads_mention();
-}
// import user
$r = db_import_assoc('user', $account['user']);
if ($r === false) {
- //echo "<pre>"; var_dump($r, $query, mysql_error()); killme();
logger("uimport:insert user : ERROR : " . dba::errorMessage(), LOGGER_NORMAL);
notice(t("User creation error"));
return;
}
}
if ($contact['uid'] == $olduid && $contact['self'] == '0') {
- // set contacts 'avatar-date' to NULL_DATE to let poller to update urls
+ // set contacts 'avatar-date' to NULL_DATE to let worker to update urls
$contact["avatar-date"] = NULL_DATE;
switch ($contact['network']) {
}
// send relocate messages
- Worker::add(PRIORITY_HIGH, 'notifier', 'relocate', $newuid);
+ Worker::add(PRIORITY_HIGH, 'Notifier', 'relocate', $newuid);
info(t("Done. You can now login with your username and password"));
goaway(System::baseUrl() . "/login");
+++ /dev/null
-<?php
-
-use Friendica\Core\Config;
-use Friendica\Network\Probe;
-use Friendica\Database\DBM;
-
-function update_gcontact_run(&$argv, &$argc) {
- global $a;
-
- require_once 'include/socgraph.php';
-
- logger('update_gcontact: start');
-
- if (($argc > 1) && (intval($argv[1]))) {
- $contact_id = intval($argv[1]);
- }
-
- if (!$contact_id) {
- logger('update_gcontact: no contact');
- return;
- }
-
- $r = q("SELECT * FROM `gcontact` WHERE `id` = %d", intval($contact_id));
-
- if (!DBM::is_result($r)) {
- return;
- }
-
- if (!in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
- return;
- }
-
- $data = Probe::uri($r[0]["url"]);
-
- if (!in_array($data["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
- if ($r[0]["server_url"] != "")
- poco_check_server($r[0]["server_url"], $r[0]["network"]);
-
- q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `id` = %d",
- dbesc(datetime_convert()), intval($contact_id));
- return;
- }
-
- if (($data["name"] == "") && ($r[0]['name'] != ""))
- $data["name"] = $r[0]['name'];
-
- if (($data["nick"] == "") && ($r[0]['nick'] != ""))
- $data["nick"] = $r[0]['nick'];
-
- if (($data["addr"] == "") && ($r[0]['addr'] != ""))
- $data["addr"] = $r[0]['addr'];
-
- if (($data["photo"] == "") && ($r[0]['photo'] != ""))
- $data["photo"] = $r[0]['photo'];
-
-
- q("UPDATE `gcontact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `photo` = '%s'
- WHERE `id` = %d",
- dbesc($data["name"]),
- dbesc($data["nick"]),
- dbesc($data["addr"]),
- dbesc($data["photo"]),
- intval($contact_id)
- );
-
- q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `photo` = '%s'
- WHERE `uid` = 0 AND `addr` = '' AND `nurl` = '%s'",
- dbesc($data["name"]),
- dbesc($data["nick"]),
- dbesc($data["addr"]),
- dbesc($data["photo"]),
- dbesc(normalise_link($data["url"]))
- );
-
- q("UPDATE `contact` SET `addr` = '%s'
- WHERE `uid` != 0 AND `addr` = '' AND `nurl` = '%s'",
- dbesc($data["addr"]),
- dbesc(normalise_link($data["url"]))
- );
-}
use Friendica\Core\System;
use Friendica\Database\DBM;
-require_once('include/network.php');
-require_once('include/plugin.php');
-require_once('include/text.php');
-require_once('include/pgettext.php');
-require_once('include/datetime.php');
-require_once('include/enotify.php');
-
+require_once 'include/network.php';
+require_once 'include/plugin.php';
+require_once 'include/text.php';
+require_once 'include/pgettext.php';
+require_once 'include/datetime.php';
+require_once 'include/enotify.php';
function create_user($arr) {
* @param string $email
* @param string $sitename
* @param string $username
- * @return NULL|boolean from notification() and email() inherited
+ * @return NULL|boolean from notification() and email() inherited
*/
function send_register_pending_eml($email, $sitename, $username) {
$body = deindent(t('
<?php
-
-
/**
- *
+ * @file index.php
* Friendica
- *
*/
/**
- *
- * bootstrap the application
- *
+ * Bootstrap the application
*/
use Friendica\App;
+use Friendica\BaseObject;
use Friendica\Core\System;
use Friendica\Core\Config;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
require_once 'boot.php';
-require_once 'object/BaseObject.php';
if (empty($a)) {
$a = new App(__DIR__);
}
-BaseObject::set_app($a);
+BaseObject::setApp($a);
// We assume that the index.php is called by a frontend process
// The value is set to "true" by default in boot.php
$a->backend = false;
/**
- *
* Load the configuration file which contains our DB credentials.
* Ignore errors. If the file doesn't exist or is empty, we are running in
* installation mode.
- *
*/
$install = ((file_exists('.htconfig.php') && filesize('.htconfig.php')) ? false : true);
}
/**
- *
* Try to open the database;
- *
*/
require_once "include/dba.php";
die("System is currently unavailable. Please try again later");
}
- if (Config::get('system', 'force_ssl') && ($a->get_scheme() == "http") &&
- (intval(Config::get('system', 'ssl_policy')) == SSL_POLICY_FULL) &&
- (substr(System::baseUrl(), 0, 8) == "https://")) {
+ if (Config::get('system', 'force_ssl') && ($a->get_scheme() == "http")
+ && (intval(Config::get('system', 'ssl_policy')) == SSL_POLICY_FULL)
+ && (substr(System::baseUrl(), 0, 8) == "https://")
+ ) {
header("HTTP/1.1 302 Moved Temporarily");
header("Location: " . System::baseUrl() . "/" . $a->query_string);
exit();
load_translation_table($lang);
/**
- *
* Important stuff we always need to do.
*
* The order of these may be important so use caution if you think they're all
* intertwingled with no logical order and decide to sort it out. Some of the
* dependencies have changed, but at least at one time in the recent past - the
* order was critical to everything working properly
- *
*/
// Exclude the backend processes from the session management
* Language was set earlier, but we can over-ride it in the session.
* We have to do it here because the session was just now opened.
*/
-if (x($_SESSION,'authenticated') && !x($_SESSION,'language')) {
+if (x($_SESSION, 'authenticated') && !x($_SESSION, 'language')) {
// we didn't loaded user data yet, but we need user language
$r = dba::select('user', array('language'), array('uid' => $_SESSION['uid']), array('limit' => 1));
$_SESSION['language'] = $lang;
}
}
-if ((x($_SESSION,'language')) && ($_SESSION['language'] !== $lang)) {
+if ((x($_SESSION, 'language')) && ($_SESSION['language'] !== $lang)) {
$lang = $_SESSION['language'];
load_translation_table($lang);
}
-if ((x($_GET,'zrl')) && (!$install && !$maintenance)) {
+if ((x($_GET, 'zrl')) && (!$install && !$maintenance)) {
// Only continue when the given profile link seems valid
// Valid profile links contain a path with "/profile/" and no query parameters
- if ((parse_url($_GET['zrl'], PHP_URL_QUERY) == "") &&
- strstr(parse_url($_GET['zrl'], PHP_URL_PATH), "/profile/")) {
+ if ((parse_url($_GET['zrl'], PHP_URL_QUERY) == "")
+ && strstr(parse_url($_GET['zrl'], PHP_URL_PATH), "/profile/")
+ ) {
$_SESSION['my_url'] = $_GET['zrl'];
- $a->query_string = preg_replace('/[\?&]zrl=(.*?)([\?&]|$)/is','',$a->query_string);
+ $a->query_string = preg_replace('/[\?&]zrl=(.*?)([\?&]|$)/is', '', $a->query_string);
zrl_init($a);
} else {
// Someone came with an invalid parameter, maybe as a DDoS attempt
}
/**
- *
* For Mozilla auth manager - still needs sorting, and this might conflict with LRDD header.
* Apache/PHP lumps the Link: headers into one - and other services might not be able to parse it
* this way. There's a PHP flag to link the headers because by default this will over-write any other
* link header.
*
* What we really need to do is output the raw headers ourselves so we can keep them separate.
- *
*/
// header('Link: <' . System::baseUrl() . '/amcd>; rel="acct-mgmt";');
-if (x($_COOKIE["Friendica"]) || (x($_SESSION,'authenticated')) || (x($_POST,'auth-params')) || ($a->module === 'login')) {
- require("include/auth.php");
+if (x($_COOKIE["Friendica"]) || (x($_SESSION, 'authenticated')) || (x($_POST, 'auth-params')) || ($a->module === 'login')) {
+ require "include/auth.php";
}
-if (! x($_SESSION,'authenticated')) {
+if (! x($_SESSION, 'authenticated')) {
header('X-Account-Management-Status: none');
}
$a->page['end'] = '';
-if (! x($_SESSION,'sysmsg')) {
+if (! x($_SESSION, 'sysmsg')) {
$_SESSION['sysmsg'] = array();
}
-if (! x($_SESSION,'sysmsg_info')) {
+if (! x($_SESSION, 'sysmsg_info')) {
$_SESSION['sysmsg_info'] = array();
}
// Array for informations about last received items
-if (! x($_SESSION,'last_updated')) {
+if (! x($_SESSION, 'last_updated')) {
$_SESSION['last_updated'] = array();
}
/*
nav_set_selected('nothing');
//Don't populate apps_menu if apps are private
-$privateapps = Config::get('config','private_addons');
+$privateapps = Config::get('config', 'private_addons');
if ((local_user()) || (! $privateapps === "1")) {
$arr = array('app_menu' => $a->apps);
}
/**
- *
* We have already parsed the server path into $a->argc and $a->argv
*
* $a->argv[0] is our module name. We will load the file mod/{$a->argv[0]}.php
if (strlen($a->module)) {
/**
- *
* We will always have a module name.
* First see if we have a plugin which is masquerading as a module.
- *
*/
// Compatibility with the Android Diaspora client
$a->module = "login";
}
- $privateapps = Config::get('config','private_addons');
+ $privateapps = Config::get('config', 'private_addons');
- if (is_array($a->plugins) && in_array($a->module,$a->plugins) && file_exists("addon/{$a->module}/{$a->module}.php")) {
+ if (is_array($a->plugins) && in_array($a->module, $a->plugins) && file_exists("addon/{$a->module}/{$a->module}.php")) {
//Check if module is an app and if public access to apps is allowed or not
if ((!local_user()) && plugin_is_app($a->module) && $privateapps === "1") {
- info( t("You must be logged in to use addons. "));
+ info(t("You must be logged in to use addons. "));
} else {
- include_once("addon/{$a->module}/{$a->module}.php");
+ include_once "addon/{$a->module}/{$a->module}.php";
if (function_exists($a->module . '_module')) {
$a->module_loaded = true;
}
*/
if ((! $a->module_loaded) && (file_exists("mod/{$a->module}.php"))) {
- include_once("mod/{$a->module}.php");
+ include_once "mod/{$a->module}.php";
$a->module_loaded = true;
}
/**
- *
* The URL provided does not resolve to a valid module.
*
* On Dreamhost sites, quite often things go wrong for no apparent reason and they send us to '/internal_error.html'.
* this will often succeed and eventually do the right thing.
*
* Otherwise we are going to emit a 404 not found.
- *
*/
if (! $a->module_loaded) {
-
// Stupid browser tried to pre-fetch our Javascript img template. Don't log the event or return anything - just quietly exit.
- if ((x($_SERVER,'QUERY_STRING')) && preg_match('/{[0-9]}/',$_SERVER['QUERY_STRING']) !== 0) {
+ if ((x($_SERVER, 'QUERY_STRING')) && preg_match('/{[0-9]}/', $_SERVER['QUERY_STRING']) !== 0) {
killme();
}
- if ((x($_SERVER,'QUERY_STRING')) && ($_SERVER['QUERY_STRING'] === 'q=internal_error.html') && isset($dreamhost_error_hack)) {
+ if ((x($_SERVER, 'QUERY_STRING')) && ($_SERVER['QUERY_STRING'] === 'q=internal_error.html') && isset($dreamhost_error_hack)) {
logger('index.php: dreamhost_error_hack invoked. Original URI =' . $_SERVER['REQUEST_URI']);
goaway(System::baseUrl() . $_SERVER['REQUEST_URI']);
}
logger('index.php: page not found: ' . $_SERVER['REQUEST_URI'] . ' ADDRESS: ' . $_SERVER['REMOTE_ADDR'] . ' QUERY: ' . $_SERVER['QUERY_STRING'], LOGGER_DEBUG);
header($_SERVER["SERVER_PROTOCOL"] . ' 404 ' . t('Not Found'));
$tpl = get_markup_template("404.tpl");
- $a->page['content'] = replace_macros($tpl, array(
- '$message' => t('Page not found.' )
- ));
+ $a->page['content'] = replace_macros(
+ $tpl,
+ array(
+ '$message' => t('Page not found.'))
+ );
}
}
/**
- * load current theme info
+ * Load current theme info
*/
$theme_info_file = "view/theme/".current_theme()."/theme.php";
-if (file_exists($theme_info_file)){
- require_once($theme_info_file);
+if (file_exists($theme_info_file)) {
+ require_once $theme_info_file;
}
/* initialise content region */
-if (! x($a->page,'content')) {
+if (! x($a->page, 'content')) {
$a->page['content'] = '';
}
if (!$install && !$maintenance) {
- call_hooks('page_content_top',$a->page['content']);
+ call_hooks('page_content_top', $a->page['content']);
}
/**
$func($a);
}
- if (function_exists(str_replace('-','_',current_theme()) . '_init')) {
- $func = str_replace('-','_',current_theme()) . '_init';
+ if (function_exists(str_replace('-', '_', current_theme()) . '_init')) {
+ $func = str_replace('-', '_', current_theme()) . '_init';
$func($a);
}
if (($_SERVER['REQUEST_METHOD'] === 'POST') && (! $a->error)
&& (function_exists($a->module . '_post'))
- && (! x($_POST,'auth-params'))) {
+ && (! x($_POST, 'auth-params'))
+ ) {
call_hooks($a->module . '_mod_post', $_POST);
$func = $a->module . '_post';
$func($a);
}
if ((! $a->error) && (function_exists($a->module . '_afterpost'))) {
- call_hooks($a->module . '_mod_afterpost',$placeholder);
+ call_hooks($a->module . '_mod_afterpost', $placeholder);
$func = $a->module . '_afterpost';
$func($a);
}
$a->page['content'] .= $arr['content'];
}
- if (function_exists(str_replace('-','_',current_theme()) . '_content_loaded')) {
- $func = str_replace('-','_',current_theme()) . '_content_loaded';
+ if (function_exists(str_replace('-', '_', current_theme()) . '_content_loaded')) {
+ $func = str_replace('-', '_', current_theme()) . '_content_loaded';
$func($a);
}
}
} else {
$link = 'toggle_mobile?off=1&address=' . curPageURL();
}
- $a->page['footer'] = replace_macros(get_markup_template("toggle_mobile_footer.tpl"), array(
- '$toggle_link' => $link,
- '$toggle_text' => t('toggle mobile')
- ));
+ $a->page['footer'] = replace_macros(
+ get_markup_template("toggle_mobile_footer.tpl"),
+ array(
+ '$toggle_link' => $link,
+ '$toggle_text' => t('toggle mobile'))
+ );
}
/**
$stylesheet = $a->theme['stylesheet'];
}
-$a->page['htmlhead'] = str_replace('{{$stylesheet}}',$stylesheet,$a->page['htmlhead']);
+$a->page['htmlhead'] = str_replace('{{$stylesheet}}', $stylesheet, $a->page['htmlhead']);
//$a->page['htmlhead'] = replace_macros($a->page['htmlhead'], array('$stylesheet' => $stylesheet));
if (isset($_GET["mode"]) && (($_GET["mode"] == "raw") || ($_GET["mode"] == "minimal"))) {
}
if (isset($_GET["mode"]) && ($_GET["mode"] == "raw")) {
-
header("Content-type: text/html; charset=utf-8");
echo substr($target->saveHTML(), 6, -8);
this.kp_timer = null;
- if (preset==undefined) preset = [];
+ if (preset == undefined) {
+ preset = [];
+ }
this.allow_cid = (preset[0] || []);
this.allow_gid = (preset[1] || []);
this.deny_cid = (preset[2] || []);
this.deny_gid = (preset[3] || []);
this.group_uids = [];
+ this.forumCache = null;
if (this.is_mobile) {
this.nw = 1;
this.item_tpl = unescape($(".acl-list-item[rel=acl-template]").html());
this.showall = $("#acl-showall");
- if (preset.length==0) this.showall.addClass("selected");
+ if (preset.length==0) {
+ this.showall.addClass("selected");
+ }
/*events*/
this.showall.click(this.on_showall.bind(this));
}
var end = start + searchText.length;
this.element.setSelection(start, end).replaceSelectedText('').collapseSelection(false);
-}
+};
ACL.prototype.add_mention = function(id) {
if (!this.automention) {
$(this.deny_cid).each(function(i,v){
aclfields.append("<input type='hidden' name='contact_deny[]' value='"+v+"'>");
});
-}
+};
ACL.prototype.search = function(){
var srcstr = $("#acl-search").val();
this.list_content.html("");
this.get(0,100, srcstr);
-}
+};
ACL.prototype.on_search = function(event){
if (this.kp_timer) clearTimeout(this.kp_timer);
this.kp_timer = setTimeout( this.search.bind(this), 1000);
-}
+};
ACL.prototype.on_showall = function(event){
event.preventDefault()
this.update_view();
return false;
-}
+};
ACL.prototype.on_button_show = function(event){
event.preventDefault()
this.set_allow($(event.target).parent().attr('id'));
return false;
-}
+};
+
ACL.prototype.on_button_hide = function(event){
event.preventDefault()
event.stopImmediatePropagation()
this.set_deny($(event.target).parent().attr('id'));
return false;
-}
+};
-ACL.prototype.set_allow = function(itemid){
+ACL.prototype.set_allow = function(itemid) {
type = itemid[0];
- id = parseInt(itemid.substr(1));
+ id = parseInt(itemid.substr(1));
- switch(type){
+ switch (type){
case "g":
- if (this.allow_gid.indexOf(id)<0){
- this.allow_gid.push(id)
+ if (this.allow_gid.indexOf(id) < 0) {
+ this.allow_gid.push(id);
}else {
this.allow_gid.remove(id);
}
- if (this.deny_gid.indexOf(id)>=0) this.deny_gid.remove(id);
+ if (this.deny_gid.indexOf(id) >= 0) {
+ this.deny_gid.remove(id);
+ }
break;
case "c":
- if (this.allow_cid.indexOf(id)<0){
- this.allow_cid.push(id)
- if (this.data[id].forum=="1") this.add_mention(id);
+ if (this.allow_cid.indexOf(id) < 0){
+ this.allow_cid.push(id);
+ if (this.data[id].forum == "1") {
+ // If we have select already a forum,
+ // we need to remove the old one (because friendica does
+ // allow only one forum as receiver).
+ if (this.forumCache !== null && this.forumCache !== id) {
+ this.deselectCid(this.forumCache);
+ }
+ // Update the forum cache.
+ this.forumCache = id;
+ this.add_mention(id);
+ }
} else {
this.allow_cid.remove(id);
- if (this.data[id].forum=="1") this.remove_mention(id);
+ if (this.data[id].forum == "1") {
+ this.remove_mention(id);
+ }
+ }
+ if (this.deny_cid.indexOf(id) >=0 ) {
+ this.deny_cid.remove(id);
}
- if (this.deny_cid.indexOf(id)>=0) this.deny_cid.remove(id);
break;
}
this.update_view();
-}
+};
ACL.prototype.set_deny = function(itemid){
type = itemid[0];
break;
}
this.update_view();
-}
+};
ACL.prototype.is_show_all = function() {
return (this.allow_gid.length==0 && this.allow_cid.length==0 &&
this.deny_gid.length==0 && this.deny_cid.length==0);
-}
+};
ACL.prototype.update_view = function(){
if (this.is_show_all()){
}
-
ACL.prototype.get = function(start,count, search){
var postdata = {
start:start,
dataType: 'json',
success:this.populate.bind(this)
});
-}
+};
ACL.prototype.populate = function(data){
var height = Math.ceil(data.tot / this.nw) * 42;
});
this.update_view();
-}
-
+};
+
+/**
+ * @brief Deselect previous selected contact.
+ *
+ * @param {int} id The contact ID.
+ * @returns {void}
+ */
+ACL.prototype.deselectCid = function(id) {
+ if (this.allow_cid.indexOf(id) >= 0) {
+ this.allow_cid.remove(id);
+ }
+ if (this.deny_cid.indexOf(id) >=0 ) {
+ this.deny_cid.remove(id);
+ }
+ this.remove_mention(id);
+};
use Friendica\Core\Config;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\User;
-require_once("include/enotify.php");
-require_once("include/text.php");
-require_once('include/items.php');
+require_once 'include/enotify.php';
+require_once 'include/text.php';
+require_once 'include/items.php';
/**
* @brief Process send data from the admin panels subpages
check_form_security_token_redirectOnErr('/admin/site', 'admin_site');
if (!empty($_POST['republish_directory'])) {
- Worker::add(PRIORITY_LOW, 'directory');
+ Worker::add(PRIORITY_LOW, 'Directory');
return;
}
$users = q("SELECT `uid` FROM `user` WHERE `account_removed` = 0 AND `account_expired` = 0");
foreach ($users as $user) {
- Worker::add(PRIORITY_HIGH, 'notifier', 'relocate', $user['uid']);
+ Worker::add(PRIORITY_HIGH, 'Notifier', 'relocate', $user['uid']);
}
info("Relocation started. Could take a while to complete.");
$block_public = ((x($_POST,'block_public')) ? True : False);
$force_publish = ((x($_POST,'publish_all')) ? True : False);
$global_directory = ((x($_POST,'directory')) ? notags(trim($_POST['directory'])) : '');
- $thread_allow = ((x($_POST,'thread_allow')) ? True : False);
$newuser_private = ((x($_POST,'newuser_private')) ? True : False);
$enotify_no_content = ((x($_POST,'enotify_no_content')) ? True : False);
$private_addons = ((x($_POST,'private_addons')) ? True : False);
// Has the directory url changed? If yes, then resubmit the existing profiles there
if ($global_directory != Config::get('system', 'directory') && ($global_directory != '')) {
Config::set('system', 'directory', $global_directory);
- Worker::add(PRIORITY_LOW, 'directory');
+ Worker::add(PRIORITY_LOW, 'Directory');
}
if ($a->get_path() != "") {
$diaspora_enabled = false;
}
- if (!$thread_allow) {
- $ostatus_disabled = true;
- }
if ($ssl_policy != intval(Config::get('system','ssl_policy'))) {
if ($ssl_policy == SSL_POLICY_FULL) {
q("UPDATE `contact` SET
Config::set('system', 'allowed_email', $allowed_email);
Config::set('system', 'block_public', $block_public);
Config::set('system', 'publish_all', $force_publish);
- Config::set('system', 'thread_allow', $thread_allow);
Config::set('system', 'newuser_private', $newuser_private);
Config::set('system', 'enotify_no_content', $enotify_no_content);
Config::set('system', 'disable_embedded', $disable_embedded);
'$block_public' => array('block_public', t("Block public"), Config::get('system','block_public'), t("Check to block public access to all otherwise public personal pages on this site unless you are currently logged in.")),
'$force_publish' => array('publish_all', t("Force publish"), Config::get('system','publish_all'), t("Check to force all profiles on this site to be listed in the site directory.")),
'$global_directory' => array('directory', t("Global directory URL"), Config::get('system','directory'), t("URL to the global directory. If this is not set, the global directory is completely unavailable to the application.")),
- '$thread_allow' => array('thread_allow', t("Allow threaded items"), Config::get('system','thread_allow'), t("Allow infinite level threading for items on this site.")),
'$newuser_private' => array('newuser_private', t("Private posts by default for new users"), Config::get('system','newuser_private'), t("Set default post permissions for all new members to the default privacy group rather than public.")),
'$enotify_no_content' => array('enotify_no_content', t("Don't include post content in email notifications"), Config::get('system','enotify_no_content'), t("Don't include the content of a post/comment/private message/etc. in the email notifications that are sent out from this site, as a privacy measure.")),
'$private_addons' => array('private_addons', t("Disallow public access to addons listed in the apps menu."), Config::get('config','private_addons'), t("Checking this box will restrict addons listed in the apps menu to members only.")),
'$timeout' => array('timeout', t("Network timeout"), (x(Config::get('system','curl_timeout'))?Config::get('system','curl_timeout'):60), t("Value is in seconds. Set to 0 for unlimited (not recommended).")),
'$maxloadavg' => array('maxloadavg', t("Maximum Load Average"), ((intval(Config::get('system','maxloadavg')) > 0)?Config::get('system','maxloadavg'):50), t("Maximum system load before delivery and poll processes are deferred - default 50.")),
'$maxloadavg_frontend' => array('maxloadavg_frontend', t("Maximum Load Average (Frontend)"), ((intval(Config::get('system','maxloadavg_frontend')) > 0)?Config::get('system','maxloadavg_frontend'):50), t("Maximum system load before the frontend quits service - default 50.")),
- '$min_memory' => array('min_memory', t("Minimal Memory"), ((intval(Config::get('system','min_memory')) > 0)?Config::get('system','min_memory'):0), t("Minimal free memory in MB for the poller. Needs access to /proc/meminfo - default 0 (deactivated).")),
+ '$min_memory' => array('min_memory', t("Minimal Memory"), ((intval(Config::get('system','min_memory')) > 0)?Config::get('system','min_memory'):0), t("Minimal free memory in MB for the worker. Needs access to /proc/meminfo - default 0 (deactivated).")),
'$optimize_max_tablesize'=> array('optimize_max_tablesize', t("Maximum table size for optimization"), $optimize_max_tablesize, t("Maximum table size (in MB) for the automatic optimization - default 100 MB. Enter -1 to disable it.")),
'$optimize_fragmentation'=> array('optimize_fragmentation', t("Minimum level of fragmentation"), ((intval(Config::get('system','optimize_fragmentation')) > 0)?Config::get('system','optimize_fragmentation'):30), t("Minimum fragmenation level to start the automatic optimization - default value is 30%.")),
'$rino' => array('rino', t("RINO Encryption"), intval(Config::get('system','rino_encrypt')), t("Encryption layer between nodes."), array("Disabled", "RINO1 (deprecated)", "RINO2")),
'$worker_queues' => array('worker_queues', t("Maximum number of parallel workers"), Config::get('system','worker_queues'), t("On shared hosters set this to 2. On larger systems, values of 10 are great. Default value is 4.")),
- '$worker_dont_fork' => array('worker_dont_fork', t("Don't use 'proc_open' with the worker"), Config::get('system','worker_dont_fork'), t("Enable this if your system doesn't allow the use of 'proc_open'. This can happen on shared hosters. If this is enabled you should increase the frequency of poller calls in your crontab.")),
+ '$worker_dont_fork' => array('worker_dont_fork', t("Don't use 'proc_open' with the worker"), Config::get('system','worker_dont_fork'), t("Enable this if your system doesn't allow the use of 'proc_open'. This can happen on shared hosters. If this is enabled you should increase the frequency of worker calls in your crontab.")),
'$worker_fastlane' => array('worker_fastlane', t("Enable fastlane"), Config::get('system','worker_fastlane'), t("When enabed, the fastlane mechanism starts an additional worker if processes with higher priority are blocked by processes of lower priority.")),
'$worker_frontend' => array('worker_frontend', t('Enable frontend worker'), Config::get('system','frontend_worker'), sprintf(t('When enabled the Worker process is triggered when backend access is performed (e.g. messages being delivered). On smaller sites you might want to call %s/worker on a regular basis via an external cron job. You should only enable this option if you cannot utilize cron/scheduled jobs on your server.'), System::baseUrl())),
notice(sprintf(tt("%s user blocked/unblocked", "%s users blocked/unblocked", count($users)), count($users)));
}
if (x($_POST,'page_users_delete')) {
- require_once("include/Contact.php");
foreach ($users as $uid) {
- user_remove($uid);
+ User::remove($uid);
}
notice(sprintf(tt("%s user deleted", "%s users deleted", count($users)), count($users)));
}
case "delete":
check_form_security_token_redirectOnErr('/admin/users', 'admin_users', 't');
// delete user
- require_once("include/Contact.php");
- user_remove($uid);
+ User::remove($uid);
notice(sprintf(t("User '%s' deleted"), $user[0]['username']).EOL);
break;
<?php
-
+/**
+ * @file mod/allfriends.php
+ */
use Friendica\App;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
-require_once('include/socgraph.php');
-require_once('include/Contact.php');
-require_once('include/contact_selectors.php');
-require_once('mod/contacts.php');
+require_once 'include/contact_selectors.php';
+require_once 'mod/contacts.php';
function allfriends_content(App $a) {
}
$a->page['aside'] = "";
- profile_load($a, "", 0, get_contact_details_by_url($c[0]["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($c[0]["url"]));
- $total = count_all_friends(local_user(), $cid);
+ $total = GlobalContact::countAllFriends(local_user(), $cid);
if(count($total))
$a->set_pager_total($total);
- $r = all_friends(local_user(), $cid, $a->pager['start'], $a->pager['itemspage']);
+ $r = GlobalContact::allFriends(local_user(), $cid, $a->pager['start'], $a->pager['itemspage']);
if (! DBM::is_result($r)) {
$o .= t('No friends to display.');
foreach ($r as $rr) {
//get further details of the contact
- $contact_details = get_contact_details_by_url($rr['url'], $uid, $rr);
+ $contact_details = Contact::getDetailsByURL($rr['url'], $uid, $rr);
$photo_menu = '';
// If the contact is not common to the user, Connect/Follow' will be added to the photo menu
if ($rr[cid]) {
$rr[id] = $rr[cid];
- $photo_menu = contact_photo_menu ($rr);
+ $photo_menu = Contact::photoMenu ($rr);
}
else {
$connlnk = System::baseUrl() . '/follow/?url=' . $rr['url'];
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'network' => network_to_name($contact_details['network'], $contact_details['url']),
'photo_menu' => $photo_menu,
'conntxt' => t('Connect'),
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once('include/event.php');
-require_once('include/redir.php');
+require_once 'include/event.php';
+require_once 'include/redir.php';
function cal_init(App $a) {
if($a->argc > 1)
$profile = get_profiledata_by_nick($nick, $a->profile_uid);
- $account_type = account_type($profile);
+ $account_type = Contact::getAccountType($profile);
$tpl = get_markup_template("vcard-widget.tpl");
<?php
-
+/**
+ * @file include/common.php
+ */
use Friendica\App;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
-require_once('include/socgraph.php');
-require_once('include/Contact.php');
-require_once('include/contact_selectors.php');
-require_once('mod/contacts.php');
+require_once 'include/contact_selectors.php';
+require_once 'mod/contacts.php';
function common_content(App $a) {
);
/// @TODO Handle $c with DBM::is_result()
$a->page['aside'] = "";
- profile_load($a, "", 0, get_contact_details_by_url($c[0]["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($c[0]["url"]));
} else {
$c = q("SELECT `name`, `url`, `photo` FROM `contact` WHERE `self` = 1 AND `uid` = %d LIMIT 1",
intval($uid)
}
if ($cid) {
- $t = count_common_friends($uid, $cid);
+ $t = GlobalContact::countCommonFriends($uid, $cid);
} else {
- $t = count_common_friends_zcid($uid, $zcid);
+ $t = GlobalContact::countCommonFriendsZcid($uid, $zcid);
}
if (count($t)) {
$a->set_pager_total($t);
} else {
- notice( t('No contacts in common.') . EOL);
+ notice(t('No contacts in common.') . EOL);
return $o;
}
if ($cid) {
- $r = common_friends($uid, $cid, $a->pager['start'], $a->pager['itemspage']);
+ $r = GlobalContact::commonFriends($uid, $cid, $a->pager['start'], $a->pager['itemspage']);
} else {
- $r = common_friends_zcid($uid, $zcid, $a->pager['start'], $a->pager['itemspage']);
+ $r = GlobalContact::commonFriendsZcid($uid, $zcid, $a->pager['start'], $a->pager['itemspage']);
}
foreach ($r as $rr) {
//get further details of the contact
- $contact_details = get_contact_details_by_url($rr['url'], $uid);
+ $contact_details = Contact::getDetailsByURL($rr['url'], $uid);
// $rr['id'] is needed to use contact_photo_menu()
/// @TODO Adding '/" here avoids E_NOTICE on missing constants
$rr['id'] = $rr['cid'];
$photo_menu = '';
- $photo_menu = contact_photo_menu($rr);
+ $photo_menu = Contact::photoMenu($rr);
$entry = array(
'url' => $rr['url'],
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'network' => network_to_name($contact_details['network'], $contact_details['url']),
'photo_menu' => $photo_menu,
'id' => ++$id,
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
-require_once 'include/Contact.php';
-require_once 'include/socgraph.php';
require_once 'include/contact_selectors.php';
require_once 'mod/proxy.php';
require_once 'include/Photo.php';
'$addr' => (($a->data['contact']['addr'] != "") ? ($a->data['contact']['addr']) : ""),
'$network_name' => $networkname,
'$network' => t('Network:'),
- '$account_type' => account_type($a->data['contact'])
+ '$account_type' => Contact::getAccountType($a->data['contact'])
));
$finpeople_widget = '';
if ($r) $count_actions++;
}
if (x($_POST, 'contacts_batch_drop')) {
- _contact_drop($contact_id, $orig_record);
+ _contact_drop($orig_record);
$count_actions++;
}
}
intval($contact_id));
} else
// pull feed and consume it, which should subscribe to the hub.
- Worker::add(PRIORITY_HIGH, "onepoll", $contact_id, "force");
+ Worker::add(PRIORITY_HIGH, "OnePoll", $contact_id, "force");
}
function _contact_update_profile($contact_id) {
update_contact_avatar($data['photo'], local_user(), $contact_id, true);
// Update the entry in the gcontact table
- update_gcontact_from_probe($data["url"]);
+ GlobalContact::updateFromProbe($data["url"]);
}
function _contact_block($contact_id, $orig_record) {
}
return $r;
}
-function _contact_drop($contact_id, $orig_record) {
+
+function _contact_drop($orig_record)
+{
$a = get_app();
$r = q("SELECT `contact`.*, `user`.* FROM `contact` INNER JOIN `user` ON `contact`.`uid` = `user`.`uid`
return;
}
- $self = ""; // Unused parameter
- terminate_friendship($r[0], $self, $orig_record);
- contact_remove($orig_record['id']);
+ Contact::terminateFriendship($r[0], $orig_record);
+ Contact::remove($orig_record['id']);
}
}
}
- _contact_drop($contact_id, $orig_record[0]);
+ _contact_drop($orig_record[0]);
info( t('Contact has been removed.') . EOL );
if (x($_SESSION,'return_url')) {
goaway('' . $_SESSION['return_url']);
$nettype = sprintf( t('Network type: %s'),network_to_name($contact['network'], $contact["url"]));
- //$common = count_common_friends(local_user(),$contact['id']);
+ //$common = GlobalContact::countCommonFriends(local_user(),$contact['id']);
//$common_text = (($common) ? sprintf( tt('%d contact in common','%d contacts in common', $common),$common) : '');
$polling = (($contact['network'] === NETWORK_MAIL | $contact['network'] === NETWORK_FEED) ? 'polling' : '');
- //$x = count_all_friends(local_user(), $contact['id']);
+ //$x = GlobalContact::countAllFriends(local_user(), $contact['id']);
//$all_friends = (($x) ? t('View all contacts') : '');
// tabs
$lost_contact = (($contact['archive'] && $contact['term-date'] > NULL_DATE && $contact['term-date'] < datetime_convert('','','now')) ? t('Communications lost with this contact!') : '');
if ($contact['network'] == NETWORK_FEED) {
- $fetch_further_information = array('fetch_further_information', t('Fetch further information for feeds'), $contact['fetch_further_information'], t('Fetch further information for feeds'),
- array('0'=>t('Disabled'), '1'=>t('Fetch information'), '2'=>t('Fetch information and keywords')));
+ $fetch_further_information = array('fetch_further_information',
+ t('Fetch further information for feeds'),
+ $contact['fetch_further_information'],
+ t("Fetch information like preview pictures, title and teaser from the feed item. You can activate this if the feed doesn't contain much text. Keywords are taken from the meta header in the feed item and are posted as hash tags."),
+ array('0' => t('Disabled'),
+ '1' => t('Fetch information'),
+ '3' => t('Fetch keywords'),
+ '2' => t('Fetch information and keywords')));
}
if (in_array($contact['network'], array(NETWORK_FEED, NETWORK_MAIL, NETWORK_MAIL2)))
$poll_interval = contact_poll_interval($contact['priority'],(! $poll_enabled));
'$blocked' => (($contact['blocked']) ? t('Currently blocked') : ''),
'$ignored' => (($contact['readonly']) ? t('Currently ignored') : ''),
'$archived' => (($contact['archive']) ? t('Currently archived') : ''),
+ '$pending' => (($contact['pending']) ? t('Awaiting connection acknowledge') : ''),
'$hidden' => array('hidden', t('Hide this contact from others'), ($contact['hidden'] == 1), t('Replies/likes to your public posts <strong>may</strong> still be visible')),
'$notify' => array('notify', t('Notification for new posts'), ($contact['notify_new_posts'] == 1), t('Send a notification of every new post of this contact')),
'$fetch_further_information' => $fetch_further_information,
'$url' => $url,
'$profileurllabel' => t('Profile URL'),
'$profileurl' => $contact['url'],
- '$account_type' => account_type($contact),
+ '$account_type' => Contact::getAccountType($contact),
'$location' => bbcode($contact["location"]),
'$location_label' => t("Location:"),
'$xmpp' => bbcode($contact["xmpp"]),
);
// Show this tab only if there is visible friend list
- $x = count_all_friends(local_user(), $contact_id);
+ $x = GlobalContact::countAllFriends(local_user(), $contact_id);
if ($x)
$tabs[] = array('label'=>t('Contacts'),
'url' => "allfriends/".$contact_id,
'accesskey' => 't');
// Show this tab only if there is visible common friend list
- $common = count_common_friends(local_user(),$contact_id);
+ $common = GlobalContact::countCommonFriends(local_user(), $contact_id);
if ($common)
$tabs[] = array('label'=>t('Common Friends'),
'url' => "common/loc/".local_user()."/".$contact_id,
if ($r) {
$contact = $r[0];
$a->page['aside'] = "";
- profile_load($a, "", 0, get_contact_details_by_url($contact["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($contact["url"]));
} else
$profile = "";
$o .= $tab_str;
- $o .= posts_from_contact_url($a, $contact["url"]);
+ $o .= Contact::getPostsFromUrl($contact["url"]);
return $o;
}
return array(
'img_hover' => sprintf( t('Visit %s\'s profile [%s]'),$rr['name'],$rr['url']),
'edit_hover' => t('Edit contact'),
- 'photo_menu' => contact_photo_menu($rr),
+ 'photo_menu' => Contact::photoMenu($rr),
'id' => $rr['id'],
'alt_text' => $alt_text,
'dir_icon' => $dir_icon,
'thumb' => proxy_url($rr['thumb'], false, PROXY_SIZE_THUMB),
'name' => htmlentities($rr['name']),
'username' => htmlentities($rr['name']),
- 'account_type' => account_type($rr),
+ 'account_type' => Contact::getAccountType($rr),
'sparkle' => $sparkle,
'itemurl' => (($rr['addr'] != "") ? $rr['addr'] : $rr['url']),
'url' => $url,
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once("include/contact_selectors.php");
-require_once("mod/contacts.php");
+require_once 'include/contact_selectors.php';
+require_once 'mod/contacts.php';
function crepair_init(App $a) {
if (! local_user()) {
if($contact_id) {
$a->data['contact'] = $r[0];
$contact = $r[0];
- profile_load($a, "", 0, get_contact_details_by_url($contact["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($contact["url"]));
}
}
if ((isset($new_relation) && $new_relation == CONTACT_IS_FRIEND)) {
if (($contact) && ($contact['network'] === NETWORK_DIASPORA)) {
- $ret = Diaspora::send_share($user[0],$r[0]);
+ $ret = Diaspora::sendShare($user[0],$r[0]);
logger('share returns: ' . $ret);
}
$i = item_store($arr);
if($i)
- Worker::add(PRIORITY_HIGH, "notifier", "activity", $i);
+ Worker::add(PRIORITY_HIGH, "Notifier", "activity", $i);
}
}
}
$i = item_store($arr);
if($i)
- Worker::add(PRIORITY_HIGH, "notifier", "activity", $i);
+ Worker::add(PRIORITY_HIGH, "Notifier", "activity", $i);
}
}
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
use Friendica\Protocol\DFRN;
require_once 'include/items.php';
logger('dfrn_notify: data: ' . $data, LOGGER_DATA);
if ($dissolve == 1) {
-
- /*
- * Relationship is dissolved permanently
- */
-
- require_once('include/Contact.php');
- contact_remove($importer['id']);
+ // Relationship is dissolved permanently
+ Contact::remove($importer['id']);
logger('relationship dissolved : ' . $importer['name'] . ' dissolved ' . $importer['username']);
xml_status(0, 'relationship dissolved');
}
*we got a key. old code send only the key, without RINO version.
* we assume RINO 1 if key and no RINO version
*/
- $data = DFRN::aes_decrypt(hex2bin($data), $final_key);
+ $data = DFRN::aesDecrypt(hex2bin($data), $final_key);
break;
case 2:
try {
<?php
-
+/**
+ * @file mod/dfrn_poll.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Database\DBM;
use Friendica\Protocol\DFRN;
+use Friendica\Protocol\OStatus;
-require_once('include/items.php');
-require_once('include/auth.php');
-require_once('include/ostatus.php');
+require_once 'include/items.php';
+require_once 'include/auth.php';
function dfrn_poll_init(App $a) {
$dfrn_id = ((x($_GET,'dfrn_id')) ? $_GET['dfrn_id'] : '');
if (($a->argc > 1) && ($dfrn_id == '') && !strstr($_SERVER["HTTP_USER_AGENT"], 'Friendica')) {
$nickname = $a->argv[1];
header("Content-type: application/atom+xml");
- echo ostatus::feed($a, $nickname, $last_update, 10);
+ echo OStatus::feed($a, $nickname, $last_update, 10);
killme();
}
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
function directory_init(App $a) {
$a->set_pager_itemspage(60);
$about = ((x($profile,'about') == 1) ? t('About:') : False);
- if($a->theme['template_engine'] === 'internal') {
- $location_e = template_escape($location);
- }
- else {
- $location_e = $location;
- }
+ $location_e = $location;
$photo_menu = array(
'profile' => array(t("View Profile"), zrl($profile_link))
'img_hover' => $rr['name'],
'name' => $rr['name'],
'details' => $details,
- 'account_type' => account_type($rr),
+ 'account_type' => Contact::getAccountType($rr),
'profile' => $profile,
'location' => $location_e,
'tags' => $rr['pub_keywords'],
<?php
-
+/**
+ * @file mod/dirfind.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Core\Worker;
+use Friendica\Model\GlobalContact;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
+use Friendica\Protocol\PortableContact;
require_once 'include/contact_widgets.php';
-require_once 'include/socgraph.php';
-require_once 'include/Contact.php';
require_once 'include/contact_selectors.php';
require_once 'mod/contacts.php';
$objresult->tags = "";
$objresult->network = $user_data["network"];
- $contact = get_contact_details_by_url($user_data["url"], local_user());
+ $contact = Contact::getDetailsByURL($user_data["url"], local_user());
$objresult->cid = $contact["cid"];
$j->results[] = $objresult;
// Add the contact to the global contacts if it isn't already in our system
if (($contact["cid"] == 0) && ($contact["zid"] == 0) && ($contact["gid"] == 0)) {
- update_gcontact($user_data);
+ GlobalContact::update($user_data);
}
} elseif ($local) {
$j->items_page = $perpage;
$j->page = $a->pager['page'];
foreach ($results AS $result) {
- if (poco_alternate_ostatus_url($result["url"])) {
+ if (PortableContact::alternateOStatusUrl($result["url"])) {
continue;
}
- $result = get_contact_details_by_url($result["url"], local_user(), $result);
+ $result = Contact::getDetailsByURL($result["url"], local_user(), $result);
if ($result["name"] == "") {
$urlparts = parse_url($result["url"]);
}
// Add found profiles from the global directory to the local directory
- Worker::add(PRIORITY_LOW, 'discover_poco', "dirsearch", urlencode($search));
+ Worker::add(PRIORITY_LOW, 'DiscoverPoCo', "dirsearch", urlencode($search));
} else {
$p = (($a->pager['page'] != 1) ? '&p=' . $a->pager['page'] : '');
$alt_text = "";
- $contact_details = get_contact_details_by_url($jj->url, local_user());
+ $contact_details = Contact::getDetailsByURL($jj->url, local_user());
$itemurl = (($contact_details["addr"] != "") ? $contact_details["addr"] : $jj->url);
$contact = q("SELECT * FROM `contact` WHERE `id` = %d",
intval($jj->cid));
if ($contact) {
- $photo_menu = contact_photo_menu($contact[0]);
+ $photo_menu = Contact::photoMenu($contact[0]);
$details = _contact_detail_for_template($contact[0]);
$alt_text = $details['alt_text'];
} else {
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'network' => network_to_name($jj->network, $jj->url),
'id' => ++$id,
);
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
use Friendica\Protocol\DFRN;
function display_init(App $a) {
function display_fetchauthor($a, $item) {
- require_once("include/Contact.php");
-
$profiledata = array();
$profiledata["uid"] = -1;
$profiledata["nickname"] = $item["author-name"];
$profiledata["about"] = "";
}
- $profiledata = get_contact_details_by_url($profiledata["url"], local_user(), $profiledata);
+ $profiledata = Contact::getDetailsByURL($profiledata["url"], local_user(), $profiledata);
$profiledata["photo"] = System::removedBaseUrl($profiledata["photo"]);
$item_id = event_store($datarray);
if (! $cid) {
- Worker::add(PRIORITY_HIGH, "notifier", "event", $item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "event", $item_id);
}
goaway($_SESSION['return_url']);
$a = get_app();
$types = Photo::supportedTypes();
$ext = $types[$rr['type']];
-
- if($a->theme['template_engine'] === 'internal') {
- $filename_e = template_escape($rr['filename']);
- }
- else {
- $filename_e = $rr['filename'];
- }
+ $filename_e = $rr['filename'];
// Take the largest picture that is smaller or equal 640 pixels
$p = q("SELECT `scale` FROM `photo` WHERE `resource-id` = '%s' AND `height` <= 640 AND `width` <= 640 ORDER BY `resource-id`, `scale` LIMIT 1",
$a = get_app();
list($m1,$m2) = explode("/",$rr['filetype']);
$filetype = ( (file_exists("images/icons/$m1.png"))?$m1:"zip");
+ $filename_e = $rr['filename'];
- if ($a->theme['template_engine'] === 'internal') {
- $filename_e = template_escape($rr['filename']);
- } else {
- $filename_e = $rr['filename'];
- }
-
- return array( System::baseUrl() . '/attach/' . $rr['id'], $filename_e, System::baseUrl() . '/images/icons/16/' . $filetype . '.png');
+ return array(System::baseUrl() . '/attach/' . $rr['id'], $filename_e, System::baseUrl() . '/images/icons/16/' . $filetype . '.png');
}
$files = array_map("_map_files2", $files);
}
$user = $r[0];
- $status = Diaspora::build_status($item[0], $user);
- $xml = Diaspora::build_post_xml($status["type"], $status["message"]);
+ $status = Diaspora::buildStatus($item[0], $user);
+ $xml = Diaspora::buildPostXml($status["type"], $status["message"]);
// Send the envelope
header("Content-Type: application/magic-envelope+xml; charset=utf-8");
- echo Diaspora::build_magic_envelope($xml, $user);
+ echo Diaspora::buildMagicEnvelope($xml, $user);
killme();
}
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
require_once 'include/follow.php';
-require_once 'include/Contact.php';
require_once 'include/contact_selectors.php';
function follow_post(App $a) {
));
$a->page['aside'] = "";
- profile_load($a, "", 0, get_contact_details_by_url($ret["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($ret["url"]));
if ($gcontact_id <> 0) {
$o .= replace_macros(get_markup_template('section_title.tpl'),
));
// Show last public posts
- $o .= posts_from_contact_url($a, $ret["url"]);
+ $o .= Contact::getPostsFromUrl($ret["url"]);
}
return $o;
intval($fsuggest_id),
intval(local_user())
);
- Worker::add(PRIORITY_HIGH, 'notifier', 'suggest', $fsuggest_id);
+ Worker::add(PRIORITY_HIGH, 'Notifier', 'suggest', $fsuggest_id);
}
info( t('Friend suggestion sent.') . EOL);
-function fsuggest_content(App $a) {
-
- require_once('include/acl_selectors.php');
+function fsuggest_content(App $a)
+{
+ require_once 'include/acl_selectors.php';
if (! local_user()) {
- notice( t('Permission denied.') . EOL);
+ notice(t('Permission denied.') . EOL);
return;
}
- if($a->argc != 2)
+ if ($a->argc != 2) {
return;
+ }
$contact_id = intval($a->argv[1]);
- $r = q("SELECT * FROM `contact` WHERE `id` = %d AND `uid` = %d LIMIT 1",
+ $r = q(
+ "SELECT * FROM `contact` WHERE `id` = %d AND `uid` = %d LIMIT 1",
intval($contact_id),
intval(local_user())
);
if (! DBM::is_result($r)) {
- notice( t('Contact not found.') . EOL);
+ notice(t('Contact not found.') . EOL);
return;
}
$contact = $r[0];
$o = '<h3>' . t('Suggest Friends') . '</h3>';
- $o .= '<div id="fsuggest-desc" >' . sprintf( t('Suggest a friend for %s'), $contact['name']) . '</div>';
+ $o .= '<div id="fsuggest-desc" >' . sprintf(t('Suggest a friend for %s'), $contact['name']) . '</div>';
$o .= '<form id="fsuggest-form" action="fsuggest/' . $contact_id . '" method="post" >';
- $o .= contact_selector('suggest','suggest-select', false,
- array('size' => 4, 'exclude' => $contact_id, 'networks' => 'DFRN_ONLY', 'single' => true));
+ $o .= contact_selector(
+ 'suggest',
+ 'suggest-select',
+ array('size' => 4, 'exclude' => $contact_id, 'networks' => 'DFRN_ONLY', 'single' => true),
+ false
+ );
$o .= '<div id="fsuggest-submit-wrapper"><input id="fsuggest-submit" type="submit" name="submit" value="' . t('Submit') . '" /></div>';
use Friendica\App;
use Friendica\Core\Config;
-
-require_once("include/socgraph.php");
-require_once("include/Contact.php");
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
function hovercard_init(App $a) {
// Just for testing purposes
}
// if it's the url containing https it should be converted to http
- $nurl = normalise_link(clean_contact_url($profileurl));
+ $nurl = normalise_link(GlobalContact::cleanContactUrl($profileurl));
if($nurl) {
// Search for contact data
- $contact = get_contact_details_by_url($nurl);
+ $contact = Contact::getDetailsByURL($nurl);
}
if(!is_array($contact))
return;
// Get the photo_menu - the menu if possible contact actions
if(local_user())
- $actions = contact_photo_menu($contact);
+ $actions = Contact::photoMenu($contact);
// Move the contact data to the profile array so we can deliver it to
// 'server_url' => $contact["server_url"],
'bd' => (($contact["birthday"] <= '0001-01-01') ? "" : $contact["birthday"]),
// 'generation' => $contact["generation"],
- 'account_type' => account_type($contact),
+ 'account_type' => Contact::getAccountType($contact),
'actions' => $actions,
);
if($datatype == "html") {
$help = "";
if (!$passed) {
$help .= t('Could not find a command line version of PHP in the web server PATH.'). EOL;
- $help .= t("If you don't have a command line version of PHP installed on server, you will not be able to run the background processing. See <a href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-poller'>'Setup the poller'</a>") . EOL;
+ $help .= t("If you don't have a command line version of PHP installed on server, you will not be able to run the background processing. See <a href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-worker'>'Setup the worker'</a>") . EOL;
$help .= EOL . EOL;
$tpl = get_markup_template('field_input.tpl');
$help .= replace_macros($tpl, array(
$baseurl = System::baseUrl();
return
t('<h1>What next</h1>')
- ."<p>".t('IMPORTANT: You will need to [manually] setup a scheduled task for the poller.')
+ ."<p>".t('IMPORTANT: You will need to [manually] setup a scheduled task for the worker.')
.t('Please see the file "INSTALL.txt".')
."</p><p>"
.t("Go to your new Friendica node <a href='$baseurl/register'>registration page</a> and register as new user. Remember to use the same email you have entered as administrator email. This will allow you to enter the site admin panel.")
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
use Friendica\Protocol\Diaspora;
+use Friendica\Util\Emailer;
require_once 'include/crypto.php';
require_once 'include/enotify.php';
require_once 'include/threads.php';
require_once 'include/text.php';
require_once 'include/items.php';
-require_once 'include/Contact.php';
function item_post(App $a) {
$thrparent = q("SELECT `author-link`, `network` FROM `item` WHERE `uri` = '%s' LIMIT 1", dbesc($thr_parent));
if (DBM::is_result($thrparent) && ($thrparent[0]["network"] === NETWORK_OSTATUS)
&& (normalise_link($parent_contact["url"]) != normalise_link($thrparent[0]["author-link"]))) {
- $parent_contact = get_contact_details_by_url($thrparent[0]["author-link"]);
+ $parent_contact = Contact::getDetailsByURL($thrparent[0]["author-link"]);
if (!isset($parent_contact["nick"])) {
$probed_contact = Probe::uri($thrparent[0]["author-link"]);
}
}
+ // Look for any tags and linkify them
+ $str_tags = '';
+ $inform = '';
+
+ $tags = get_tags($body);
+
+ /*
+ * add a statusnet style reply tag if the original post was from there
+ * and we are replying, and there isn't one already
+ */
+ if ($parent && ($parent_contact['network'] == NETWORK_OSTATUS)) {
+ $contact = '@[url=' . $parent_contact['url'] . ']' . $parent_contact['nick'] . '[/url]';
+
+ if (!in_array($contact, $tags)) {
+ $body = $contact . ' ' . $body;
+ $tags[] = $contact;
+ }
+
+ $toplevel_contact = "";
+ $toplevel_parent = q("SELECT `contact`.* FROM `contact`
+ INNER JOIN `item` ON `item`.`contact-id` = `contact`.`id` AND `contact`.`url` = `item`.`author-link`
+ WHERE `item`.`id` = `item`.`parent` AND `item`.`parent` = %d", intval($parent));
+ if (DBM::is_result($toplevel_parent)) {
+ if (!empty($toplevel_parent[0]['addr'])) {
+ $toplevel_contact = '@' . $toplevel_parent[0]['addr'];
+ } else {
+ $toplevel_contact = '@' . $toplevel_parent[0]['nick'] . '+' . $toplevel_parent[0]['id'];
+ }
+ } else {
+ $toplevel_parent = q("SELECT `author-link`, `author-name` FROM `item` WHERE `id` = `parent` AND `parent` = %d", intval($parent));
+ $toplevel_contact = '@[url=' . $toplevel_parent[0]['author-link'] . ']' . $toplevel_parent[0]['author-name'] . '[/url]';
+ }
+
+ if (!in_array($toplevel_contact, $tags)) {
+ $tags[] = $toplevel_contact;
+ }
+ }
+
+ $tagged = array();
+
+ $private_forum = false;
+ $only_to_forum = false;
+ $forum_contact = array();
+
+ if (count($tags)) {
+ foreach ($tags as $tag) {
+
+ $tag_type = substr($tag, 0, 1);
+
+ if ($tag_type == '#') {
+ continue;
+ }
+
+ /*
+ * If we already tagged 'Robert Johnson', don't try and tag 'Robert'.
+ * Robert Johnson should be first in the $tags array
+ */
+ $fullnametagged = false;
+ /// @TODO $tagged is initialized above if() block and is not filled, maybe old-lost code?
+ foreach ($tagged as $nextTag) {
+ if (stristr($nextTag, $tag . ' ')) {
+ $fullnametagged = true;
+ break;
+ }
+ }
+ if ($fullnametagged) {
+ continue;
+ }
+
+ $success = handle_tag($a, $body, $inform, $str_tags, (local_user()) ? local_user() : $profile_uid , $tag, $network);
+ if ($success['replaced']) {
+ $tagged[] = $tag;
+ }
+ // When the forum is private or the forum is addressed with a "!" make the post private
+ if (is_array($success['contact']) && ($success['contact']['prv'] || ($tag_type == '!'))) {
+ $private_forum = $success['contact']['prv'];
+ $only_to_forum = ($tag_type == '!');
+ $private_id = $success['contact']['id'];
+ $forum_contact = $success['contact'];
+ } elseif (is_array($success['contact']) && $success['contact']['forum'] &&
+ ($str_contact_allow == '<' . $success['contact']['id'] . '>')) {
+ $private_forum = false;
+ $only_to_forum = true;
+ $private_id = $success['contact']['id'];
+ $forum_contact = $success['contact'];
+ }
+ }
+ }
+
+ $original_contact_id = $contact_id;
+
+ if (!$parent && count($forum_contact) && ($private_forum || $only_to_forum)) {
+ // we tagged a forum in a top level post. Now we change the post
+ $private = $private_forum;
+
+ $str_group_allow = '';
+ $str_contact_deny = '';
+ $str_group_deny = '';
+ if ($private_forum) {
+ $str_contact_allow = '<' . $private_id . '>';
+ } else {
+ $str_contact_allow = '';
+ }
+ $contact_id = $private_id;
+ $contact_record = $forum_contact;
+ $_REQUEST['origin'] = false;
+ }
+
/*
* When a photo was uploaded into the message using the (profile wall) ajax
* uploader, The permissions are initially set to disallow anybody but the
$match = null;
- if ((! $preview) && preg_match_all("/\[img([\=0-9x]*?)\](.*?)\[\/img\]/",$body,$match)) {
+ if (!$preview && preg_match_all("/\[img([\=0-9x]*?)\](.*?)\[\/img\]/",$body,$match)) {
$images = $match[2];
if (count($images)) {
$objecttype = ACTIVITY_OBJ_IMAGE;
foreach ($images as $image) {
- if (! stristr($image,System::baseUrl() . '/photo/')) {
+ if (!stristr($image, System::baseUrl() . '/photo/')) {
continue;
}
$image_uri = substr($image,strrpos($image,'/') + 1);
$image_uri = substr($image_uri,0, strpos($image_uri,'-'));
- if (! strlen($image_uri)) {
+ if (!strlen($image_uri)) {
continue;
}
- $srch = '<' . intval($contact_id) . '>';
+ $srch = '<' . intval($original_contact_id) . '>';
$r = q("SELECT `id` FROM `photo` WHERE `allow_cid` = '%s' AND `allow_gid` = '' AND `deny_cid` = '' AND `deny_gid` = ''
AND `resource-id` = '%s' AND `uid` = %d LIMIT 1",
dbesc($str_group_deny),
dbesc($image_uri),
intval($profile_uid),
- dbesc( t('Wall Photos'))
+ dbesc(t('Wall Photos'))
);
}
}
require_once 'include/plaintext.php';
$objectdata = get_attached_data($body);
- if ($post["type"] == "link") {
+ if ($objectdata["type"] == "link") {
$objecttype = ACTIVITY_OBJ_BOOKMARK;
- } elseif ($post["type"] == "video") {
+ } elseif ($objectdata["type"] == "video") {
$objecttype = ACTIVITY_OBJ_VIDEO;
- } elseif ($post["type"] == "photo") {
+ } elseif ($objectdata["type"] == "photo") {
$objecttype = ACTIVITY_OBJ_IMAGE;
}
}
- // Look for any tags and linkify them
- $str_tags = '';
- $inform = '';
-
- $tags = get_tags($body);
-
- /*
- * add a statusnet style reply tag if the original post was from there
- * and we are replying, and there isn't one already
- */
- if ($parent && ($parent_contact['network'] == NETWORK_OSTATUS)) {
- $contact = '@[url=' . $parent_contact['url'] . ']' . $parent_contact['nick'] . '[/url]';
-
- if (!in_array($contact, $tags)) {
- $body = $contact . ' ' . $body;
- $tags[] = $contact;
- }
-
- $toplevel_contact = "";
- $toplevel_parent = q("SELECT `contact`.* FROM `contact`
- INNER JOIN `item` ON `item`.`contact-id` = `contact`.`id` AND `contact`.`url` = `item`.`author-link`
- WHERE `item`.`id` = `item`.`parent` AND `item`.`parent` = %d", intval($parent));
- if (DBM::is_result($toplevel_parent)) {
- if (!empty($toplevel_parent[0]['addr'])) {
- $toplevel_contact = '@' . $toplevel_parent[0]['addr'];
- } else {
- $toplevel_contact = '@' . $toplevel_parent[0]['nick'] . '+' . $toplevel_parent[0]['id'];
- }
- } else {
- $toplevel_parent = q("SELECT `author-link`, `author-name` FROM `item` WHERE `id` = `parent` AND `parent` = %d", intval($parent));
- $toplevel_contact = '@[url=' . $toplevel_parent[0]['author-link'] . ']' . $toplevel_parent[0]['author-name'] . '[/url]';
- }
-
- if (!in_array($toplevel_contact, $tags)) {
- $tags[] = $toplevel_contact;
- }
- }
-
- $tagged = array();
-
- $private_forum = false;
- $only_to_forum = false;
- $forum_contact = array();
-
- if (count($tags)) {
- foreach ($tags as $tag) {
-
- $tag_type = substr($tag, 0, 1);
-
- if ($tag_type == '#') {
- continue;
- }
-
- /*
- * If we already tagged 'Robert Johnson', don't try and tag 'Robert'.
- * Robert Johnson should be first in the $tags array
- */
- $fullnametagged = false;
- /// @TODO $tagged is initialized above if() block and is not filled, maybe old-lost code?
- foreach ($tagged as $nextTag) {
- if (stristr($nextTag, $tag . ' ')) {
- $fullnametagged = true;
- break;
- }
- }
- if ($fullnametagged) {
- continue;
- }
-
- $success = handle_tag($a, $body, $inform, $str_tags, (local_user()) ? local_user() : $profile_uid , $tag, $network);
- if ($success['replaced']) {
- $tagged[] = $tag;
- }
- // When the forum is private or the forum is addressed with a "!" make the post private
- if (is_array($success['contact']) && ($success['contact']['prv'] || ($tag_type == '!'))) {
- $private_forum = $success['contact']['prv'];
- $only_to_forum = ($tag_type == '!');
- $private_id = $success['contact']['id'];
- $forum_contact = $success['contact'];
- } elseif (is_array($success['contact']) && $success['contact']['forum'] &&
- ($str_contact_allow == '<' . $success['contact']['id'] . '>')) {
- $private_forum = false;
- $only_to_forum = true;
- $private_id = $success['contact']['id'];
- $forum_contact = $success['contact'];
- }
- }
- }
-
- if (!$parent && count($forum_contact) && ($private_forum || $only_to_forum)) {
- // we tagged a forum in a top level post. Now we change the post
- $private = $private_forum;
-
- $str_group_allow = '';
- $str_contact_deny = '';
- $str_group_deny = '';
- if ($private_forum) {
- $str_contact_allow = '<' . $private_id . '>';
- } else {
- $str_contact_allow = '';
- }
- $contact_id = $private_id;
- $contact_record = $forum_contact;
- $_REQUEST['origin'] = false;
- }
-
$attachments = '';
$match = false;
$datarray['owner-name'] = $contact_record['name'];
$datarray['owner-link'] = $contact_record['url'];
$datarray['owner-avatar'] = $contact_record['thumb'];
- $datarray['owner-id'] = get_contact($datarray['owner-link'], 0);
+ $datarray['owner-id'] = Contact::getIdForURL($datarray['owner-link'], 0);
$datarray['author-name'] = $author['name'];
$datarray['author-link'] = $author['url'];
$datarray['author-avatar'] = $author['thumb'];
- $datarray['author-id'] = get_contact($datarray['author-link'], 0);
+ $datarray['author-id'] = Contact::getIdForURL($datarray['author-link'], 0);
$datarray['created'] = datetime_convert();
$datarray['edited'] = datetime_convert();
$datarray['commented'] = datetime_convert();
$datarray['postopts'] = $postopts;
$datarray['origin'] = $origin;
$datarray['moderated'] = $allow_moderated;
- $datarray['gcontact-id'] = get_gcontact_id(array("url" => $datarray['author-link'], "network" => $datarray['network'],
+ $datarray['gcontact-id'] = GlobalContact::getId(array("url" => $datarray['author-link'], "network" => $datarray['network'],
"photo" => $datarray['author-avatar'], "name" => $datarray['author-name']));
$datarray['object'] = $object;
// update filetags in pconfig
file_tag_update_pconfig($uid,$categories_old,$categories_new,'category');
- Worker::add(PRIORITY_HIGH, "notifier", 'edit_post', $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", 'edit_post', $post_id);
if ((x($_REQUEST, 'return')) && strlen($return_path)) {
logger('return: ' . $return_path);
goaway($return_path);
// Store the comment signature information in case we need to relay to Diaspora
- Diaspora::store_comment_signature($datarray, $author, ($self ? $user['prvkey'] : false), $post_id);
+ Diaspora::storeCommentSignature($datarray, $author, ($self ? $user['prvkey'] : false), $post_id);
} else {
$parent = $post_id;
$message = '<html><body>' . $link . $html . $disclaimer . '</body></html>';
include_once 'include/html2plain.php';
$params = array (
- 'fromName' => $a->user['username'],
- 'fromEmail' => $a->user['email'],
- 'toEmail' => $addr,
- 'replyTo' => $a->user['email'],
- 'messageSubject' => $subject,
- 'htmlVersion' => $message,
- 'textVersion' => html2plain($html.$disclaimer),
+ 'fromName' => $a->user['username'],
+ 'fromEmail' => $a->user['email'],
+ 'toEmail' => $addr,
+ 'replyTo' => $a->user['email'],
+ 'messageSubject' => $subject,
+ 'htmlVersion' => $message,
+ 'textVersion' => html2plain($html.$disclaimer)
);
Emailer::send($params);
}
// We now do it in the background to save some time.
// This is important in interactive environments like the frontend or the API.
// We don't fork a new process since this is done anyway with the following command
- Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "create_shadowentry", $post_id);
+ Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "CreateShadowEntry", $post_id);
// Call the background process that is delivering the item to the receivers
- Worker::add(PRIORITY_HIGH, "notifier", $notify_type, $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", $notify_type, $post_id);
logger('post_complete');
*
* @return boolean true if replaced, false if not replaced
*/
-function handle_tag(App $a, &$body, &$inform, &$str_tags, $profile_uid, $tag, $network = "") {
- require_once 'include/socgraph.php';
-
+function handle_tag(App $a, &$body, &$inform, &$str_tags, $profile_uid, $tag, $network = "")
+{
$replaced = false;
$r = null;
$tag_type = '@';
if (!DBM::is_result($r)) {
$probed = Probe::uri($name);
if ($result['network'] != NETWORK_PHANTOM) {
- update_gcontact($probed);
+ GlobalContact::update($probed);
$r = q("SELECT `url`, `name`, `nick`, `network`, `alias`, `notify` FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
dbesc(normalise_link($probed["url"])));
}
<?php
-
+/**
+ * @file mod/match.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once('include/text.php');
-require_once('include/socgraph.php');
-require_once('include/contact_widgets.php');
-require_once('mod/proxy.php');
+require_once 'include/text.php';
+require_once 'include/contact_widgets.php';
+require_once 'mod/proxy.php';
/**
* @brief Controller for /match.
* It takes keywords from your profile and queries the directory server for
* matching keywords from other profiles.
*
- * @param App $a
+ * @param App $a App
+ *
* @return void|string
*/
-function match_content(App $a) {
-
+function match_content(App $a)
+{
$o = '';
if (! local_user()) {
return;
$_SESSION['return_url'] = System::baseUrl() . '/' . $a->cmd;
- $r = q("SELECT `pub_keywords`, `prv_keywords` FROM `profile` WHERE `is-default` = 1 AND `uid` = %d LIMIT 1",
+ $r = q(
+ "SELECT `pub_keywords`, `prv_keywords` FROM `profile` WHERE `is-default` = 1 AND `uid` = %d LIMIT 1",
intval(local_user())
);
if (! DBM::is_result($r)) {
return;
}
- if(! $r[0]['pub_keywords'] && (! $r[0]['prv_keywords'])) {
- notice( t('No keywords to match. Please add keywords to your default profile.') . EOL);
+ if (! $r[0]['pub_keywords'] && (! $r[0]['prv_keywords'])) {
+ notice(t('No keywords to match. Please add keywords to your default profile.') . EOL);
return;
}
$params = array();
$tags = trim($r[0]['pub_keywords'] . ' ' . $r[0]['prv_keywords']);
- if($tags) {
+ if ($tags) {
$params['s'] = $tags;
- if($a->pager['page'] != 1)
+ if ($a->pager['page'] != 1) {
$params['p'] = $a->pager['page'];
+ }
- if(strlen(Config::get('system','directory')))
+ if (strlen(Config::get('system', 'directory'))) {
$x = post_url(get_server().'/msearch', $params);
- else
+ } else {
$x = post_url(System::baseUrl() . '/msearch', $params);
+ }
$j = json_decode($x);
- if($j->total) {
+ if ($j->total) {
$a->set_pager_total($j->total);
$a->set_pager_itemspage($j->items_page);
}
- if(count($j->results)) {
-
+ if (count($j->results)) {
$id = 0;
- foreach($j->results as $jj) {
+ foreach ($j->results as $jj) {
$match_nurl = normalise_link($jj->url);
- $match = q("SELECT `nurl` FROM `contact` WHERE `uid` = '%d' AND nurl='%s' LIMIT 1",
+ $match = q(
+ "SELECT `nurl` FROM `contact` WHERE `uid` = '%d' AND nurl='%s' LIMIT 1",
intval(local_user()),
- dbesc($match_nurl));
+ dbesc($match_nurl)
+ );
if (!count($match)) {
$jj->photo = str_replace("http:///photo/", get_server()."/photo/", $jj->photo);
'follow' => array(t("Connect/Follow"), $connlnk)
);
- $contact_details = get_contact_details_by_url($jj->url, local_user());
+ $contact_details = Contact::getDetailsByURL($jj->url, local_user());
$entry = array(
'url' => zrl($jj->url),
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'thumb' => proxy_url($jj->photo, false, PROXY_SIZE_THUMB),
'inttxt' => ' ' . t('is interested in:'),
'conntxt' => t('Connect'),
}
}
- $tpl = get_markup_template('viewcontact_template.tpl');
-
- $o .= replace_macros($tpl,array(
- '$title' => t('Profile Match'),
- '$contacts' => $entries,
- '$paginate' => paginate($a),
- ));
-
- }
- else {
- info( t('No matches') . EOL);
+ $tpl = get_markup_template('viewcontact_template.tpl');
+
+ $o .= replace_macros(
+ $tpl,
+ array(
+ '$title' => t('Profile Match'),
+ '$contacts' => $entries,
+ '$paginate' => paginate($a))
+ );
+ } else {
+ info(t('No matches') . EOL);
}
-
}
return $o;
<?php
use Friendica\App;
+use Friendica\Content\Smilies;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once('include/acl_selectors.php');
-require_once('include/message.php');
-require_once('include/Smilies.php');
+require_once 'include/acl_selectors.php';
+require_once 'include/message.php';
function message_init(App $a) {
if ($extracted['images'])
$message['body'] = item_redir_and_replace_images($extracted['body'], $extracted['images'], $message['contact-id']);
- if ($a->theme['template_engine'] === 'internal') {
- $from_name_e = template_escape($message['from-name']);
- $subject_e = template_escape($message['title']);
- $body_e = template_escape(Smilies::replace(bbcode($message['body'])));
- $to_name_e = template_escape($message['name']);
- } else {
- $from_name_e = $message['from-name'];
- $subject_e = $message['title'];
- $body_e = Smilies::replace(bbcode($message['body']));
- $to_name_e = $message['name'];
- }
+ $from_name_e = $message['from-name'];
+ $subject_e = $message['title'];
+ $body_e = Smilies::replace(bbcode($message['body']));
+ $to_name_e = $message['name'];
- $contact = get_contact_details_by_url($message['from-url']);
+ $contact = Contact::getDetailsByURL($message['from-url']);
if (isset($contact["thumb"]))
$from_photo = $contact["thumb"];
else
$tpl = get_markup_template('mail_display.tpl');
- if ($a->theme['template_engine'] === 'internal') {
- $subjtxt_e = template_escape($message['title']);
- } else {
- $subjtxt_e = $message['title'];
- }
+ $subjtxt_e = $message['title'];
$o = replace_macros($tpl, array(
'$thread_id' => $a->argv[1],
else
$participants = sprintf(t("%s and You"), $rr['from-name']);
- if ($a->theme['template_engine'] === 'internal') {
- $subject_e = template_escape((($rr['mailseen']) ? $rr['title'] : '<strong>' . $rr['title'] . '</strong>'));
- $body_e = template_escape($rr['body']);
- $to_name_e = template_escape($rr['name']);
- } else {
- $subject_e = (($rr['mailseen']) ? $rr['title'] : '<strong>' . $rr['title'] . '</strong>');
- $body_e = $rr['body'];
- $to_name_e = $rr['name'];
- }
+ $subject_e = (($rr['mailseen']) ? $rr['title'] : '<strong>' . $rr['title'] . '</strong>');
+ $body_e = $rr['body'];
+ $to_name_e = $rr['name'];
- $contact = get_contact_details_by_url($rr['url']);
+ $contact = Contact::getDetailsByURL($rr['url']);
if (isset($contact["thumb"]))
$from_photo = $contact["thumb"];
else
intval($uid),
intval($item_id)
);
- Worker::add(PRIORITY_HIGH, "notifier", "tag", $item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id);
}
call_hooks('post_local_end', $arr);
- Worker::add(PRIORITY_HIGH, "notifier", "like", $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "like", $post_id);
return;
}
<?php
-
+/**
+ * @file mod/network.php
+ */
use Friendica\App;
+use Friendica\Content\ForumManager;
use Friendica\Core\System;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
require_once 'include/conversation.php';
require_once 'include/group.php';
require_once 'include/contact_widgets.php';
require_once 'include/items.php';
-require_once 'include/ForumManager.php';
require_once 'include/acl_selectors.php';
function network_init(App $a) {
}
$is_a_date_query = false;
+
+ $group_id = (($a->argc > 1 && is_numeric($a->argv[1])) ? intval($a->argv[1]) : 0);
+
if (x($_GET, 'cid') && intval($_GET['cid']) != 0) {
$cid = $_GET['cid'];
$_GET['nets'] = 'all';
-
+ $group_id = 0;
}
+ PConfig::set(local_user(), 'network.view', 'group.selected', $group_id);
+
if ($a->argc > 1) {
for ($x = 1; $x < $a->argc; $x ++) {
if (is_a_date_arg($a->argv[$x])) {
unset($_GET['nets']);
}
- $group_id = (($a->argc > 1 && is_numeric($a->argv[1])) ? intval($a->argv[1]) : 0);
-
- PConfig::set(local_user(), 'network.view', 'group.selected', $group_id);
if (!x($a->page, 'aside')) {
$a->page['aside'] = '';
}
$a->page['aside'] .= (feature_enabled(local_user(),'groups') ? group_side('network/0','network','standard',$group_id) : '');
- $a->page['aside'] .= (feature_enabled(local_user(),'forumlist_widget') ? ForumManager::widget(local_user(),$cid) : '');
+ $a->page['aside'] .= (feature_enabled(local_user(), 'forumlist_widget') ? ForumManager::widget(local_user(), $cid) : '');
$a->page['aside'] .= posted_date_widget('network',local_user(),false);
$a->page['aside'] .= networks_widget('network',(x($_GET, 'nets') ? $_GET['nets'] : ''));
$a->page['aside'] .= saved_searches($search);
'details' => $r['location'],
);
- $entries[0]["account_type"] = account_type($r);
+ $entries[0]["account_type"] = Contact::getAccountType($r);
$o = replace_macros(get_markup_template("viewcontact_template.tpl"),array(
'contacts' => $entries,
<?php
-
+/**
+ * @file mod/nogroup.php
+ */
use Friendica\App;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once('include/Contact.php');
-require_once('include/socgraph.php');
-require_once('include/contact_selectors.php');
-
-function nogroup_init(App $a) {
+require_once 'include/contact_selectors.php';
+function nogroup_init(App $a)
+{
if (! local_user()) {
return;
}
- require_once('include/group.php');
- require_once('include/contact_widgets.php');
+ require_once 'include/group.php';
+ require_once 'include/contact_widgets.php';
- if (! x($a->page,'aside')) {
+ if (! x($a->page, 'aside')) {
$a->page['aside'] = '';
}
- $a->page['aside'] .= group_side('contacts','group','extended',0,$contact_id);
+ $a->page['aside'] .= group_side('contacts', 'group', 'extended', 0, $contact_id);
}
-
-function nogroup_content(App $a) {
-
+function nogroup_content(App $a)
+{
if (! local_user()) {
- notice( t('Permission denied.') . EOL);
+ notice(t('Permission denied.') . EOL);
return '';
}
- require_once('include/Contact.php');
- $r = contacts_not_grouped(local_user());
+ $r = Contact::getUngroupedList(local_user());
if (DBM::is_result($r)) {
$a->set_pager_total($r[0]['total']);
}
- $r = contacts_not_grouped(local_user(),$a->pager['start'],$a->pager['itemspage']);
+ $r = Contact::getUngroupedList(local_user(), $a->pager['start'], $a->pager['itemspage']);
if (DBM::is_result($r)) {
foreach ($r as $rr) {
-
- $contact_details = get_contact_details_by_url($rr['url'], local_user(), $rr);
+ $contact_details = Contact::getDetailsByURL($rr['url'], local_user(), $rr);
$contacts[] = array(
'img_hover' => sprintf(t('Visit %s\'s profile [%s]'), $contact_details['name'], $rr['url']),
'edit_hover' => t('Edit contact'),
- 'photo_menu' => contact_photo_menu($rr),
+ 'photo_menu' => Contact::photoMenu($rr),
'id' => $rr['id'],
'alt_text' => $alt_text,
'dir_icon' => $dir_icon,
'about' => $contact_details['about'],
'sparkle' => $sparkle,
'itemurl' => (($contact_details['addr'] != "") ? $contact_details['addr'] : $rr['url']),
- 'url' => $url,
+ 'url' => $rr['url'],
'network' => network_to_name($rr['network'], $url),
);
}
}
$tpl = get_markup_template("nogroup-template.tpl");
- $o .= replace_macros($tpl, array(
+ $o .= replace_macros(
+ $tpl,
+ array(
'$header' => t('Contacts who are not members of a group'),
'$contacts' => $contacts,
- '$paginate' => paginate($a),
- ));
+ '$paginate' => paginate($a))
+ );
return $o;
-
}
// mod/settings.php in 8367cad so it might have left mixed
// records in the user table
//
- $r = q("SELECT *, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey` FROM `user`
+ $r = q("SELECT *
+ FROM `user`
WHERE ( `openid` = '%s' OR `openid` = '%s' )
AND `blocked` = 0 AND `account_expired` = 0
AND `account_removed` = 0 AND `verified` = 1
}
$user = $r[0];
- $status = Diaspora::build_status($item[0], $user);
- $xml = Diaspora::build_post_xml($status["type"], $status["message"]);
+ $status = Diaspora::buildStatus($item[0], $user);
+ $xml = Diaspora::buildPostXml($status["type"], $status["message"]);
header("Content-Type: application/xml; charset=utf-8");
echo $xml;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
require_once 'include/Photo.php';
require_once 'include/photos.php';
$profile = get_profiledata_by_nick($nick, $a->profile_uid);
- $account_type = account_type($profile);
+ $account_type = Contact::getAccountType($profile);
$tpl = get_markup_template("vcard-widget.tpl");
// send the notification upstream/downstream as the case may be
if ($rr['visible']) {
- Worker::add(PRIORITY_HIGH, "notifier", "drop", $drop_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "drop", $drop_id);
}
}
}
photo_albums($page_owner_uid, true);
if ($i[0]['visible']) {
- Worker::add(PRIORITY_HIGH, "notifier", "drop", $drop_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "drop", $drop_id);
}
}
}
$item_id = item_store($arr);
if ($item_id) {
- Worker::add(PRIORITY_HIGH, "notifier", "tag", $item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id);
}
}
}
photo_albums($page_owner_uid, true);
if ($visible) {
- Worker::add(PRIORITY_HIGH, "notifier", 'wall-new', $item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", 'wall-new', $item_id);
}
call_hooks('photo_post_end',intval($item_id));
$tpl = get_markup_template('photos_upload.tpl');
- if ($a->theme['template_engine'] === 'internal') {
- $albumselect_e = template_escape($albumselect);
- $aclselect_e = (($visitor) ? '' : template_escape(populate_acl($a->user)));
- } else {
- $albumselect_e = $albumselect;
- $aclselect_e = (($visitor) ? '' : populate_acl($a->user));
- }
+ $albumselect_e = $albumselect;
+ $aclselect_e = (($visitor) ? '' : populate_acl($a->user));
$o .= replace_macros($tpl,array(
'$pagename' => t('Upload Photos'),
if ($can_post) {
$edit_tpl = get_markup_template('album_edit.tpl');
- if ($a->theme['template_engine'] === 'internal') {
- $album_e = template_escape($album);
- } else {
- $album_e = $album;
- }
+ $album_e = $album;
$o .= replace_macros($edit_tpl,array(
'$nametext' => t('New album name: '),
$ext = $phototypes[$rr['type']];
- if ($a->theme['template_engine'] === 'internal') {
- $imgalt_e = template_escape($rr['filename']);
- $desc_e = template_escape($rr['desc']);
- } else {
- $imgalt_e = $rr['filename'];
- $desc_e = $rr['desc'];
- }
+ $imgalt_e = $rr['filename'];
+ $desc_e = $rr['desc'];
$photos[] = array(
'id' => $rr['id'],
$public_post_link = '&public=1';
}
- if ($a->theme['template_engine'] === 'internal') {
- $album_e = template_escape($ph[0]['album']);
- $caption_e = template_escape($ph[0]['desc']);
- $aclselect_e = template_escape(populate_acl($ph[0]));
- } else {
- $album_e = $ph[0]['album'];
- $caption_e = $ph[0]['desc'];
- $aclselect_e = populate_acl($ph[0]);
- }
+ $album_e = $ph[0]['album'];
+ $caption_e = $ph[0]['desc'];
+ $aclselect_e = populate_acl($ph[0]);
$edit = replace_macros($edit_tpl, array(
'$id' => $ph[0]['id'],
'delete' => t('Delete'),
);
- if ($a->theme['template_engine'] === 'internal') {
- $name_e = template_escape($profile_name);
- $title_e = template_escape($item['title']);
- $body_e = template_escape(bbcode($item['body']));
- } else {
- $name_e = $profile_name;
- $title_e = $item['title'];
- $body_e = bbcode($item['body']);
- }
+ $name_e = $profile_name;
+ $title_e = $item['title'];
+ $body_e = bbcode($item['body']);
$comments .= replace_macros($template,array(
'$id' => $item['item_id'],
$photo_tpl = get_markup_template('photo_view.tpl');
- if ($a->theme['template_engine'] === 'internal') {
- $album_e = array($album_link,template_escape($ph[0]['album']));
- $tags_e = template_escape($tags);
- $like_e = template_escape($like);
- $dislike_e = template_escape($dislike);
- } else {
- $album_e = array($album_link, $ph[0]['album']);
- $tags_e = $tags;
- $like_e = $like;
- $dislike_e = $dislike;
- }
+ $album_e = array($album_link, $ph[0]['album']);
+ $tags_e = $tags;
+ $like_e = $like;
+ $dislike_e = $dislike;
$o .= replace_macros($photo_tpl, array(
'$id' => $ph[0]['id'],
$ext = $phototypes[$rr['type']];
- if ($a->theme['template_engine'] === 'internal') {
- $alt_e = template_escape($rr['filename']);
- $name_e = template_escape($rr['album']);
- } else {
- $alt_e = $rr['filename'];
- $name_e = $rr['album'];
- }
+ $alt_e = $rr['filename'];
+ $name_e = $rr['album'];
$photos[] = array(
'id' => $rr['id'],
* @file include/ping.php
*/
use Friendica\App;
+use Friendica\Content\ForumManager;
use Friendica\Core\Cache;
use Friendica\Core\System;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
use Friendica\Util\XML;
require_once 'include/datetime.php';
require_once 'include/bbcode.php';
-require_once 'include/ForumManager.php';
require_once 'include/group.php';
require_once 'mod/proxy.php';
require_once 'include/enotify.php';
}
} else {
header("Content-type: text/xml");
- echo XML::from_array($data, $xml);
+ echo XML::fromArray($data, $xml);
}
killme();
}
}
if (intval(feature_enabled(local_user(), 'forumlist_widget'))) {
- $forum_counts = ForumManager::count_unseen_items();
+ $forum_counts = ForumManager::countUnseenItems();
if (DBM::is_result($forums_counts)) {
foreach ($forums_counts as $forum_count) {
if ($forum_count['count'] > 0) {
if ($a->config['register_policy'] == REGISTER_APPROVE && is_site_admin()) {
$regs = q(
- "SELECT `contact`.`name`, `contact`.`url`, `contact`.`micro`, `register`.`created`, COUNT(*) AS `total`
+ "SELECT `contact`.`name`, `contact`.`url`, `contact`.`micro`, `register`.`created`
FROM `contact` RIGHT JOIN `register` ON `register`.`uid` = `contact`.`uid`
WHERE `contact`.`self` = 1"
);
if (DBM::is_result($regs)) {
- $register_count = $regs[0]['total'];
+ $register_count = count($regs);
}
}
$notif['message'] = str_replace("{0}", $notif['name'], $notif['message']);
}
- $contact = get_contact_details_by_url($notif['url']);
+ $contact = Contact::getDetailsByURL($notif['url']);
if (isset($contact['micro'])) {
$notif['photo'] = proxy_url($contact['micro'], false, PROXY_SIZE_MICRO);
} else {
$data = ping_format_xml_data($data, $sysnotify_count, $notifications, $sysmsgs, $sysmsgs_info, $groups_unseen, $forums_unseen);
header("Content-type: text/xml");
- echo XML::from_array(array("result" => $data), $xml);
+ echo XML::fromArray(array("result" => $data), $xml);
}
killme();
use Friendica\Core\Cache;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Protocol\PortableContact;
function poco_init(App $a) {
$system_mode = false;
$global = false;
if ($a->argc > 1 && $a->argv[1] === '@server') {
- require_once 'include/socgraph.php';
// List of all servers that this server knows
- $ret = poco_serverlist();
+ $ret = PortableContact::serverlist();
header('Content-type: application/json');
echo json_encode($ret);
killme();
// intval($uid),
// intval($item_id)
//);
- Worker::add(PRIORITY_HIGH, "notifier", "tag", $item_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "tag", $item_id);
}
call_hooks('post_local_end', $arr);
- Worker::add(PRIORITY_HIGH, "notifier", "like", $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "like", $post_id);
return;
}
$category = ((x($_GET,'category')) ? $_GET['category'] : '');
}
+ $hashtags = (x($_GET, 'tag') ? $_GET['tag'] : '');
+
if (Config::get('system','block_public') && (! local_user()) && (! remote_user())) {
return login();
}
$a->page['aside'] .= posted_date_widget(System::baseUrl(true) . '/profile/' . $a->profile['nickname'],$a->profile['profile_uid'],true);
$a->page['aside'] .= categories_widget(System::baseUrl(true) . '/profile/' . $a->profile['nickname'],(x($category) ? xmlify($category) : ''));
+ $a->page['aside'] .= tagcloud_wall_widget();
if (can_write_wall($a,$a->profile['profile_uid'])) {
//$sql_extra .= protect_sprintf(file_tag_file_query('item',$category,'category'));
}
+ if (x($hashtags)) {
+ $sql_post_table .= sprintf("INNER JOIN (SELECT `oid` FROM `term` WHERE `term` = '%s' AND `otype` = %d AND `type` = %d AND `uid` = %d ORDER BY `tid` DESC) AS `term` ON `item`.`id` = `term`.`oid` ",
+ dbesc(protect_sprintf($hashtags)), intval(TERM_OBJ_POST), intval(TERM_HASHTAG), intval($a->profile['profile_uid']));
+ }
+
if ($datequery) {
$sql_extra2 .= protect_sprintf(sprintf(" AND `thread`.`created` <= '%s' ", dbesc(datetime_convert(date_default_timezone_get(),'',$datequery))));
}
// Update global directory in background
$url = System::baseUrl() . '/profile/' . $a->user['nickname'];
if ($url && strlen(Config::get('system','directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
- Worker::add(PRIORITY_LOW, 'profile_update', local_user());
+ Worker::add(PRIORITY_LOW, 'ProfileUpdate', local_user());
} else {
notice( t('Unable to process image') . EOL);
}
// Update global directory in background
$url = $_SESSION['my_url'];
if ($url && strlen(Config::get('system','directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
goaway(System::baseUrl() . '/profiles');
<?php
-
+/**
+ * @file mod/profiles.php
+ */
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
use Friendica\Network\Probe;
-
-require_once 'include/Contact.php';
-require_once 'include/socgraph.php';
+use Friendica\Object\Profile;
function profiles_init(App $a) {
}
if ($is_default) {
- $location = formatted_location(array("locality" => $locality, "region" => $region, "country-name" => $country_name));
+ $location = Profile::formatLocation(array("locality" => $locality, "region" => $region, "country-name" => $country_name));
q("UPDATE `contact` SET `about` = '%s', `location` = '%s', `keywords` = '%s', `gender` = '%s' WHERE `self` AND `uid` = %d",
dbesc($about),
// Update global directory in background
$url = $_SESSION['my_url'];
if ($url && strlen(Config::get('system', 'directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
- Worker::add(PRIORITY_LOW, 'profile_update', local_user());
+ Worker::add(PRIORITY_LOW, 'ProfileUpdate', local_user());
// Update the global contact for the user
- update_gcontact_for_user(local_user());
+ GlobalContact::updateForUser(local_user());
}
}
}
$i = item_store($arr);
if ($i) {
- Worker::add(PRIORITY_HIGH, "notifier", "activity", $i);
+ Worker::add(PRIORITY_HIGH, "Notifier", "activity", $i);
}
}
return $o;
} else {
-
// If we don't support multi profiles, don't display this list.
if (!feature_enabled(local_user(), 'multi_profiles')) {
$r = q("SELECT * FROM `profile` WHERE `uid` = %d AND `is-default`=1",
use Friendica\App;
use Friendica\Core\System;
+use Friendica\Model\GlobalContact;
function randprof_init(App $a) {
- require_once('include/Contact.php');
-
- $x = random_profile();
+ $x = GlobalContact::getRandomUrl();
if ($x) {
goaway(zrl($x));
}
logger('mod-diaspora: message is in the new format', LOGGER_DEBUG);
- $msg = Diaspora::decode_raw($importer, $postdata);
+ $msg = Diaspora::decodeRaw($importer, $postdata);
} else {
logger('mod-diaspora: decode message in the old format', LOGGER_DEBUG);
$msg = Diaspora::decode($importer, $xml);
if ($public && !$msg) {
logger('mod-diaspora: decode message in the new format', LOGGER_DEBUG);
- $msg = Diaspora::decode_raw($importer, $xml);
+ $msg = Diaspora::decodeRaw($importer, $xml);
}
}
$ret = true;
if ($public) {
- Diaspora::dispatch_public($msg);
+ Diaspora::dispatchPublic($msg);
} else {
$ret = Diaspora::dispatch($importer, $msg);
}
if($netpublish && $a->config['register_policy'] != REGISTER_APPROVE) {
$url = System::baseUrl() . '/profile/' . $user['nickname'];
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
$using_invites = Config::get('system','invitation_only');
if (DBM::is_result($r) && $r[0]['net-publish']) {
$url = System::baseUrl() . '/profile/' . $user[0]['nickname'];
if ($url && strlen(Config::get('system','directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
}
use Friendica\App;
use Friendica\Core\System;
+use Friendica\Model\User;
-function removeme_post(App $a) {
-
- if (! local_user()) {
+function removeme_post(App $a)
+{
+ if (!local_user()) {
return;
}
- if (x($_SESSION,'submanage') && intval($_SESSION['submanage'])) {
+ if (x($_SESSION, 'submanage') && intval($_SESSION['submanage'])) {
return;
}
- if ((! x($_POST,'qxz_password')) || (! strlen(trim($_POST['qxz_password'])))) {
+ if ((!x($_POST, 'qxz_password')) || (!strlen(trim($_POST['qxz_password'])))) {
return;
}
- if ((! x($_POST,'verify')) || (! strlen(trim($_POST['verify'])))) {
+ if ((!x($_POST, 'verify')) || (!strlen(trim($_POST['verify'])))) {
return;
}
return;
}
- $encrypted = hash('whirlpool',trim($_POST['qxz_password']));
-
- if ((strlen($a->user['password'])) && ($encrypted === $a->user['password'])) {
- require_once('include/Contact.php');
- user_remove($a->user['uid']);
+ if (User::authenticate($a->user['uid'], trim($_POST['qxz_password']))) {
+ User::remove($a->user['uid']);
// NOTREACHED
}
-
}
-function removeme_content(App $a) {
-
- if (! local_user()) {
+function removeme_content(App $a)
+{
+ if (!local_user()) {
goaway(System::baseUrl());
}
));
return $o;
-
}
<?php
-
+/**
+ * @file mod/salmon.php
+ */
use Friendica\App;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use Friendica\Protocol\OStatus;
-require_once('include/salmon.php');
-require_once('include/ostatus.php');
-require_once('include/crypto.php');
-require_once('include/items.php');
-require_once('include/follow.php');
+require_once 'include/salmon.php';
+require_once 'include/crypto.php';
+require_once 'include/items.php';
+require_once 'include/follow.php';
function salmon_return($val) {
// decode the data
$data = base64url_decode($data);
- $author = ostatus::salmon_author($data,$importer);
+ $author = OStatus::salmonAuthor($data, $importer);
$author_link = $author["author-link"];
if(! $author_link) {
$contact_rec = ((DBM::is_result($r)) ? $r[0] : null);
- ostatus::import($data,$importer,$contact_rec, $hub);
+ OStatus::import($data, $importer, $contact_rec, $hub);
http_status_exit(200);
}
<?php
-
+/**
+ * @file mod/settings.php
+ */
use Friendica\App;
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Model\User;
-require_once('include/group.php');
-require_once('include/socgraph.php');
+require_once 'include/group.php';
function get_theme_config_file($theme) {
$a = get_app();
$infinite_scroll = x($_POST, 'infinite_scroll') ? intval($_POST['infinite_scroll']) : 0;
$no_auto_update = x($_POST, 'no_auto_update') ? intval($_POST['no_auto_update']) : 0;
$bandwidth_saver = x($_POST, 'bandwidth_saver') ? intval($_POST['bandwidth_saver']) : 0;
+ $smart_threading = x($_POST, 'smart_threading') ? intval($_POST['smart_threading']) : 0;
$nowarn_insecure = x($_POST, 'nowarn_insecure') ? intval($_POST['nowarn_insecure']) : 0;
$browser_update = x($_POST, 'browser_update') ? intval($_POST['browser_update']) : 0;
if ($browser_update != -1) {
PConfig::set(local_user(), 'system', 'infinite_scroll' , $infinite_scroll);
PConfig::set(local_user(), 'system', 'no_auto_update' , $no_auto_update);
PConfig::set(local_user(), 'system', 'bandwidth_saver' , $bandwidth_saver);
+ PConfig::set(local_user(), 'system', 'smart_threading' , $smart_threading);
if ($theme == $a->user['theme']) {
// call theme_post only if theme has not been changed
check_form_security_token_redirectOnErr('/settings', 'settings');
if (x($_POST,'resend_relocate')) {
- Worker::add(PRIORITY_HIGH, 'notifier', 'relocate', local_user());
+ Worker::add(PRIORITY_HIGH, 'Notifier', 'relocate', local_user());
info(t("Relocate message has been send to your contacts"));
goaway('settings');
}
$newpass = $_POST['password'];
$confirm = $_POST['confirm'];
- $oldpass = hash('whirlpool', $_POST['opassword']);
$err = false;
if ($newpass != $confirm) {
// check if the old password was supplied correctly before
// changing it to the new value
- $r = q("SELECT `password` FROM `user`WHERE `uid` = %d LIMIT 1", intval(local_user()));
- if ($oldpass != $r[0]['password']) {
+ if (User::authenticate(intval(local_user()), $_POST['opassword'])) {
notice(t('Wrong password.') . EOL);
$err = true;
}
if ($email != $a->user['email']) {
$email_changed = true;
// check for the correct password
- $r = q("SELECT `password` FROM `user`WHERE `uid` = %d LIMIT 1", intval(local_user()));
- $password = hash('whirlpool', $_POST['mpassword']);
- if ($password != $r[0]['password']) {
+ if (!User::authenticate(intval(local_user()), $_POST['mpassword'])) {
$err .= t('Wrong Password') . EOL;
$email = $a->user['email'];
}
// check the email is valid
if (!valid_email($email)) {
- $err .= t(' Not valid email.');
+ $err .= t('Invalid email.');
}
// ensure new email is not the admin mail
//if ((x($a->config, 'admin_email')) && (strcasecmp($email, $a->config['admin_email']) == 0)) {
if (x($a->config, 'admin_email')) {
$adminlist = explode(",", str_replace(" ", "", strtolower($a->config['admin_email'])));
if (in_array(strtolower($email), $adminlist)) {
- $err .= t(' Cannot change to that email.');
+ $err .= t('Cannot change to that email.');
$email = $a->user['email'];
}
}
// Update global directory in background
$url = $_SESSION['my_url'];
if ($url && strlen(Config::get('system', 'directory'))) {
- Worker::add(PRIORITY_LOW, "directory", $url);
+ Worker::add(PRIORITY_LOW, "Directory", $url);
}
}
- Worker::add(PRIORITY_LOW, 'profile_update', local_user());
+ Worker::add(PRIORITY_LOW, 'ProfileUpdate', local_user());
// Update the global contact for the user
- update_gcontact_for_user(local_user());
+ GlobalContact::updateForUser(local_user());
//$_SESSION['theme'] = $theme;
if ($email_changed && $a->config['register_policy'] == REGISTER_VERIFY) {
$infinite_scroll = PConfig::get(local_user(), 'system', 'infinite_scroll', 0);
$no_auto_update = PConfig::get(local_user(), 'system', 'no_auto_update', 0);
$bandwidth_saver = PConfig::get(local_user(), 'system', 'bandwidth_saver', 0);
+ $smart_threading = PConfig::get(local_user(), 'system', 'smart_threading', 0);
$theme_config = "";
if (($themeconfigfile = get_theme_config_file($theme_selected)) != null) {
'$infinite_scroll' => array('infinite_scroll', t("Infinite scroll"), $infinite_scroll, ''),
'$no_auto_update' => array('no_auto_update', t("Automatic updates only at the top of the network page"), $no_auto_update, t('When disabled, the network page is updated all the time, which could be confusing while reading.')),
'$bandwidth_saver' => array('bandwidth_saver', t('Bandwith Saver Mode'), $bandwidth_saver, t('When enabled, embedded content is not displayed on automatic updates, they only show on page reload.')),
+ '$smart_threading' => array('smart_threading', t('Smart Threading'), $smart_threading, t('When enabled, suppress extraneous thread indentation while keeping it where it matters. Only works if threading is available and enabled.')),
'$d_tset' => t('General Theme Settings'),
'$d_ctset' => t('Custom Theme Settings'),
* @file mod/smilies.php
*/
use Friendica\App;
+use Friendica\Content\Smilies;
-require_once("include/Smilies.php");
-
-function smilies_content(App $a) {
+/**
+ * @param object $a App
+ * @return mixed
+ */
+function smilies_content(App $a)
+{
if ($a->argv[1] === "json") {
- $tmp = Smilies::get_list();
+ $tmp = Smilies::getList();
$results = array();
for ($i = 0; $i < count($tmp['texts']); $i++) {
$results[] = array('text' => $tmp['texts'][$i], 'icon' => $tmp['icons'][$i]);
<?php
-
+/**
+ * @file mod/suggest.php
+ */
use Friendica\App;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
-require_once('include/socgraph.php');
-require_once('include/contact_widgets.php');
+require_once 'include/contact_widgets.php';
function suggest_init(App $a) {
if (! local_user()) {
$a->page['aside'] .= follow_widget();
- $r = suggestion_query(local_user());
+ $r = GlobalContact::suggestionQuery(local_user());
if (! DBM::is_result($r)) {
$o .= t('No suggestions available. If this is a new site, please try again in 24 hours.');
'hide' => array(t('Ignore/Hide'), $ignlnk)
);
- $contact_details = get_contact_details_by_url($rr["url"], local_user(), $rr);
+ $contact_details = Contact::getDetailsByURL($rr["url"], local_user(), $rr);
$entry = array(
'url' => zrl($rr['url']),
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'ignlnk' => $ignlnk,
'ignid' => $rr['id'],
'conntxt' => t('Connect'),
call_hooks('post_local_end', $arr);
- Worker::add(PRIORITY_HIGH, "notifier", "tag", $post_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "tag", $post_id);
killme();
);
//echo "<pre>"; var_dump(json_encode($output)); killme();
- echo json_encode($output);
+ echo json_encode($output, JSON_PARTIAL_OUTPUT_ON_ERROR);
}
/**
);
$output = array('item' => $r);
- echo json_encode($output) . "\n";
+ echo json_encode($output, JSON_PARTIAL_OUTPUT_ON_ERROR). "\n";
}
}
use Friendica\App;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
require_once 'include/follow.php';
-require_once 'include/Contact.php';
require_once 'include/contact_selectors.php';
function unfollow_post(App $a) {
intval($uid)
);
if (DBM::is_result($r)) {
- $self = ""; // Unused parameter
- terminate_friendship($r[0], $self, $contact);
+ Contact::terminateFriendship($r[0], $contact);
}
}
dba::update('contact', array('rel' => CONTACT_IS_FOLLOWER), array('id' => $contact['id']));
));
$a->page['aside'] = "";
- profile_load($a, "", 0, get_contact_details_by_url($contact["url"]));
+ profile_load($a, "", 0, Contact::getDetailsByURL($contact["url"]));
$o .= replace_macros(get_markup_template('section_title.tpl'),
array('$title' => t('Status Messages and Posts')
));
// Show last public posts
- $o .= posts_from_contact_url($a, $contact["url"]);
+ $o .= Contact::getPostsFromUrl($contact["url"]);
return $o;
}
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
require_once('include/items.php');
require_once('include/acl_selectors.php');
$profile = get_profiledata_by_nick($nick, $a->profile_uid);
- $account_type = account_type($profile);
+ $account_type = Contact::getAccountType($profile);
$tpl = get_markup_template("vcard-widget.tpl");
$drop_id = intval($i[0]['id']);
if ($i[0]['visible']) {
- Worker::add(PRIORITY_HIGH, "notifier", "drop", $drop_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "drop", $drop_id);
}
}
}
$videos = array();
if (DBM::is_result($r)) {
foreach ($r as $rr) {
- if ($a->theme['template_engine'] === 'internal') {
- $alt_e = template_escape($rr['filename']);
- $name_e = template_escape($rr['album']);
- }
- else {
- $alt_e = $rr['filename'];
- $name_e = $rr['album'];
- }
+ $alt_e = $rr['filename'];
+ $name_e = $rr['album'];
$videos[] = array(
'id' => $rr['id'],
use Friendica\App;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
-require_once('include/Contact.php');
require_once('include/contact_selectors.php');
function viewcontacts_init(App $a) {
else
$url = zrl($url);
- $contact_details = get_contact_details_by_url($rr['url'], $a->profile['uid'], $rr);
+ $contact_details = Contact::getDetailsByURL($rr['url'], $a->profile['uid'], $rr);
$contacts[] = array(
'id' => $rr['id'],
'img_hover' => sprintf( t('Visit %s\'s profile [%s]'), $contact_details['name'], $rr['url']),
- 'photo_menu' => contact_photo_menu($rr),
+ 'photo_menu' => Contact::photoMenu($rr),
'thumb' => proxy_url($contact_details['thumb'], false, PROXY_SIZE_THUMB),
'name' => htmlentities(substr($contact_details['name'],0,20)),
'username' => htmlentities($contact_details['name']),
'details' => $contact_details['location'],
'tags' => $contact_details['keywords'],
'about' => $contact_details['about'],
- 'account_type' => account_type($contact_details),
+ 'account_type' => Contact::getAccountType($contact_details),
'url' => $url,
'sparkle' => '',
'itemurl' => (($contact_details['addr'] != "") ? $contact_details['addr'] : $rr['url']),
<?php
/**
* @file mod/worker.php
- * @brief Module for running the poller as frontend process
+ * @brief Module for running the worker as frontend process
*/
-require_once("include/poller.php");
use Friendica\Core\Worker;
use Friendica\Core\Config;
+++ /dev/null
-<?php
-if(class_exists('BaseObject'))
- return;
-
-require_once('boot.php');
-
-/**
- * Basic object
- *
- * Contains what is usefull to any object
- */
-class BaseObject {
- private static $app = null;
-
- /**
- * Get the app
- *
- * Same as get_app from boot.php
- */
- public function get_app() {
- if(self::$app)
- return self::$app;
-
- self::$app = get_app();
-
- return self::$app;
- }
-
- /**
- * Set the app
- */
- public static function set_app($app) {
- self::$app = $app;
- }
-}
+++ /dev/null
-<?php
-if(class_exists('Conversation'))
- return;
-
-require_once('boot.php');
-require_once('object/BaseObject.php');
-require_once('object/Item.php');
-require_once('include/text.php');
-
-/**
- * A list of threads
- *
- * We should think about making this a SPL Iterator
- */
-class Conversation extends BaseObject {
- private $threads = array();
- private $mode = null;
- private $writable = false;
- private $profile_owner = 0;
- private $preview = false;
-
- public function __construct($mode, $preview) {
- $this->set_mode($mode);
- $this->preview = $preview;
- }
-
- /**
- * Set the mode we'll be displayed on
- */
- private function set_mode($mode) {
- if($this->get_mode() == $mode)
- return;
-
- $a = $this->get_app();
-
- switch($mode) {
- case 'network':
- case 'notes':
- $this->profile_owner = local_user();
- $this->writable = true;
- break;
- case 'profile':
- $this->profile_owner = $a->profile['profile_uid'];
- $this->writable = can_write_wall($a,$this->profile_owner);
- break;
- case 'display':
- $this->profile_owner = $a->profile['uid'];
- $this->writable = can_write_wall($a,$this->profile_owner);
- break;
- default:
- logger('[ERROR] Conversation::set_mode : Unhandled mode ('. $mode .').', LOGGER_DEBUG);
- return false;
- break;
- }
- $this->mode = $mode;
- }
-
- /**
- * Get mode
- */
- public function get_mode() {
- return $this->mode;
- }
-
- /**
- * Check if page is writable
- */
- public function is_writable() {
- return $this->writable;
- }
-
- /**
- * Check if page is a preview
- */
- public function is_preview() {
- return $this->preview;
- }
-
- /**
- * Get profile owner
- */
- public function get_profile_owner() {
- return $this->profile_owner;
- }
-
- /**
- * Add a thread to the conversation
- *
- * Returns:
- * _ The inserted item on success
- * _ false on failure
- */
- public function add_thread($item) {
- $item_id = $item->get_id();
- if(!$item_id) {
- logger('[ERROR] Conversation::add_thread : Item has no ID!!', LOGGER_DEBUG);
- return false;
- }
- if($this->get_thread($item->get_id())) {
- logger('[WARN] Conversation::add_thread : Thread already exists ('. $item->get_id() .').', LOGGER_DEBUG);
- return false;
- }
-
- /*
- * Only add will be displayed
- */
- if($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid')) {
- logger('[WARN] Conversation::add_thread : Thread is a mail ('. $item->get_id() .').', LOGGER_DEBUG);
- return false;
- }
- if($item->get_data_value('verb') === ACTIVITY_LIKE || $item->get_data_value('verb') === ACTIVITY_DISLIKE) {
- logger('[WARN] Conversation::add_thread : Thread is a (dis)like ('. $item->get_id() .').', LOGGER_DEBUG);
- return false;
- }
- $item->set_conversation($this);
- $this->threads[] = $item;
- return end($this->threads);
- }
-
- /**
- * Get data in a form usable by a conversation template
- *
- * We should find a way to avoid using those arguments (at least most of them)
- *
- * Returns:
- * _ The data requested on success
- * _ false on failure
- */
- public function get_template_data($conv_responses) {
- $a = get_app();
- $result = array();
-
- $i = 0;
-
- foreach($this->threads as $item) {
- if($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid'))
- continue;
-
- $item_data = $item->get_template_data($conv_responses);
-
- if(!$item_data) {
- logger('[ERROR] Conversation::get_template_data : Failed to get item template data ('. $item->get_id() .').', LOGGER_DEBUG);
- return false;
- }
- $result[] = $item_data;
- }
-
- return $result;
- }
-
- /**
- * Get a thread based on its item id
- *
- * Returns:
- * _ The found item on success
- * _ false on failure
- */
- private function get_thread($id) {
- foreach($this->threads as $item) {
- if($item->get_id() == $id)
- return $item;
- }
-
- return false;
- }
-}
+++ /dev/null
-<?php
-if(class_exists('Item'))
- return;
-
-use Friendica\Core\Config;
-use Friendica\Core\PConfig;
-use Friendica\Database\DBM;
-use Friendica\Protocol\Diaspora;
-
-require_once('object/BaseObject.php');
-require_once('include/text.php');
-require_once('boot.php');
-
-/**
- * An item
- */
-class Item extends BaseObject {
- private $data = array();
- private $template = null;
- private $available_templates = array(
- 'wall' => 'wall_thread.tpl',
- 'wall2wall' => 'wallwall_thread.tpl'
- );
- private $comment_box_template = 'comment_item.tpl';
- private $toplevel = false;
- private $writable = false;
- private $children = array();
- private $parent = null;
- private $conversation = null;
- private $redirect_url = null;
- private $owner_url = '';
- private $owner_photo = '';
- private $owner_name = '';
- private $wall_to_wall = false;
- private $threaded = false;
- private $visiting = false;
-
- public function __construct($data) {
- $a = $this->get_app();
-
- $this->data = $data;
- $this->set_template('wall');
- $this->toplevel = ($this->get_id() == $this->get_data_value('parent'));
-
- if (is_array($_SESSION['remote'])) {
- foreach ($_SESSION['remote'] as $visitor) {
- if ($visitor['cid'] == $this->get_data_value('contact-id')) {
- $this->visiting = true;
- break;
- }
- }
- }
-
- $this->writable = ($this->get_data_value('writable') || $this->get_data_value('self'));
-
- $ssl_state = ((local_user()) ? true : false);
- $this->redirect_url = 'redir/' . $this->get_data_value('cid') ;
-
- if (Config::get('system','thread_allow') && $a->theme_thread_allow && !$this->is_toplevel()) {
- $this->threaded = true;
- }
-
- // Prepare the children
- if (count($data['children'])) {
- foreach ($data['children'] as $item) {
- /*
- * Only add will be displayed
- */
- if ($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) {
- continue;
- } elseif (! visible_activity($item)) {
- continue;
- }
-
- // You can always comment on Diaspora items
- if (($item['network'] == NETWORK_DIASPORA) && (local_user() == $item['uid'])) {
- $item['writable'] = true;
- }
-
- $item['pagedrop'] = $data['pagedrop'];
- $child = new Item($item);
- $this->add_child($child);
- }
- }
- }
-
- /**
- * Get data in a form usable by a conversation template
- *
- * Returns:
- * _ The data requested on success
- * _ false on failure
- */
- public function get_template_data($conv_responses, $thread_level=1) {
- require_once("mod/proxy.php");
-
- $result = array();
-
- $a = $this->get_app();
-
- $item = $this->get_data();
- $edited = false;
- // If the time between "created" and "edited" differs we add
- // a notice that the post was edited.
- // Note: In some networks reshared items seem to have (sometimes) a difference
- // between creation time and edit time of a second. Thats why we add the notice
- // only if the difference is more than 1 second.
- if (strtotime($item['edited']) - strtotime($item['created']) > 1) {
- $edited = array(
- 'label' => t('This entry was edited'),
- 'date' => datetime_convert('UTC', date_default_timezone_get(), $item['edited'], 'r'),
- 'relative' => relative_date($item['edited'])
- );
- }
- $commentww = '';
- $sparkle = '';
- $buttons = '';
- $dropping = false;
- $star = false;
- $ignore = false;
- $isstarred = "unstarred";
- $indent = '';
- $shiny = '';
- $osparkle = '';
- $total_children = $this->count_descendants();
-
- $conv = $this->get_conversation();
-
- $lock = ((($item['private'] == 1) || (($item['uid'] == local_user()) && (strlen($item['allow_cid']) || strlen($item['allow_gid'])
- || strlen($item['deny_cid']) || strlen($item['deny_gid']))))
- ? t('Private Message')
- : false);
- $shareable = ((($conv->get_profile_owner() == local_user()) && ($item['private'] != 1)) ? true : false);
- if (local_user() && link_compare($a->contact['url'],$item['author-link'])) {
- if ($item["event-id"] != 0) {
- $edpost = array("events/event/".$item['event-id'], t("Edit"));
- } else {
- $edpost = array("editpost/".$item['id'], t("Edit"));
- }
- } else {
- $edpost = false;
- }
-
- if (($this->get_data_value('uid') == local_user()) || $this->is_visiting()) {
- $dropping = true;
- }
-
- $drop = array(
- 'dropping' => $dropping,
- 'pagedrop' => ((feature_enabled($conv->get_profile_owner(),'multi_delete')) ? $item['pagedrop'] : ''),
- 'select' => t('Select'),
- 'delete' => t('Delete'),
- );
-
- $filer = (($conv->get_profile_owner() == local_user()) ? t("save to folder") : false);
-
- $diff_author = ((link_compare($item['url'],$item['author-link'])) ? false : true);
- $profile_name = htmlentities(((strlen($item['author-name'])) && $diff_author) ? $item['author-name'] : $item['name']);
- if ($item['author-link'] && (! $item['author-name'])) {
- $profile_name = $item['author-link'];
- }
-
- $sp = false;
- $profile_link = best_link_url($item,$sp);
- if ($profile_link === 'mailbox') {
- $profile_link = '';
- }
-
- if ($sp) {
- $sparkle = ' sparkle';
- } else {
- $profile_link = zrl($profile_link);
- }
-
- if (!isset($item['author-thumb']) || ($item['author-thumb'] == "")) {
- $author_contact = get_contact_details_by_url($item['author-link'], $conv->get_profile_owner());
- if ($author_contact["thumb"]) {
- $item['author-thumb'] = $author_contact["thumb"];
- } else {
- $item['author-thumb'] = $item['author-avatar'];
- }
- }
-
- if (!isset($item['owner-thumb']) || ($item['owner-thumb'] == "")) {
- $owner_contact = get_contact_details_by_url($item['owner-link'], $conv->get_profile_owner());
- if ($owner_contact["thumb"]) {
- $item['owner-thumb'] = $owner_contact["thumb"];
- } else {
- $item['owner-thumb'] = $item['owner-avatar'];
- }
- }
-
- $locate = array('location' => $item['location'], 'coord' => $item['coord'], 'html' => '');
- call_hooks('render_location',$locate);
- $location = ((strlen($locate['html'])) ? $locate['html'] : render_location_dummy($locate));
-
- $tags=array();
- $hashtags = array();
- $mentions = array();
-
-
- /*foreach(explode(',',$item['tag']) as $tag){
- $tag = trim($tag);
- if ($tag!="") {
- $t = bbcode($tag);
- $tags[] = $t;
- if($t[0] == '#')
- $hashtags[] = $t;
- elseif($t[0] == '@')
- $mentions[] = $t;
- }
- }*/
-
- // process action responses - e.g. like/dislike/attend/agree/whatever
- $response_verbs = array('like');
- if (feature_enabled($conv->get_profile_owner(),'dislike')) {
- $response_verbs[] = 'dislike';
- }
- if ($item['object-type'] === ACTIVITY_OBJ_EVENT) {
- $response_verbs[] = 'attendyes';
- $response_verbs[] = 'attendno';
- $response_verbs[] = 'attendmaybe';
- if ($conv->is_writable()) {
- $isevent = true;
- $attend = array( t('I will attend'), t('I will not attend'), t('I might attend'));
- }
- }
-
- $responses = get_responses($conv_responses,$response_verbs,$this,$item);
-
- foreach ($response_verbs as $value=>$verbs) {
- $responses[$verbs]['output'] = ((x($conv_responses[$verbs],$item['uri'])) ? format_like($conv_responses[$verbs][$item['uri']],$conv_responses[$verbs][$item['uri'] . '-l'],$verbs,$item['uri']) : '');
- }
-
- /*
- * We should avoid doing this all the time, but it depends on the conversation mode
- * And the conv mode may change when we change the conv, or it changes its mode
- * Maybe we should establish a way to be notified about conversation changes
- */
- $this->check_wall_to_wall();
-
- if ($this->is_wall_to_wall() && ($this->get_owner_url() == $this->get_redirect_url())) {
- $osparkle = ' sparkle';
- }
-
- if ($this->is_toplevel()) {
- if ($conv->get_profile_owner() == local_user()) {
- $isstarred = (($item['starred']) ? "starred" : "unstarred");
-
- $star = array(
- 'do' => t("add star"),
- 'undo' => t("remove star"),
- 'toggle' => t("toggle star status"),
- 'classdo' => (($item['starred']) ? "hidden" : ""),
- 'classundo' => (($item['starred']) ? "" : "hidden"),
- 'starred' => t('starred'),
- );
- $r = dba::select('thread', array('ignored'), array('uid' => $item['uid'], 'iid' => $item['id']), array('limit' => 1));
- if (DBM::is_result($r)) {
- $ignore = array(
- 'do' => t("ignore thread"),
- 'undo' => t("unignore thread"),
- 'toggle' => t("toggle ignore status"),
- 'classdo' => (($r['ignored']) ? "hidden" : ""),
- 'classundo' => (($r['ignored']) ? "" : "hidden"),
- 'ignored' => t('ignored'),
- );
- }
-
- $tagger = '';
- if(feature_enabled($conv->get_profile_owner(),'commtag')) {
- $tagger = array(
- 'add' => t("add tag"),
- 'class' => "",
- );
- }
- }
- } else {
- $indent = 'comment';
- }
-
- if ($conv->is_writable()) {
- $buttons = array(
- 'like' => array( t("I like this \x28toggle\x29"), t("like")),
- 'dislike' => ((feature_enabled($conv->get_profile_owner(),'dislike')) ? array( t("I don't like this \x28toggle\x29"), t("dislike")) : ''),
- );
- if ($shareable) {
- $buttons['share'] = array( t('Share this'), t('share'));
- }
- }
-
- $comment = $this->get_comment_box($indent);
-
- if (strcmp(datetime_convert('UTC','UTC',$item['created']),datetime_convert('UTC','UTC','now - 12 hours')) > 0){
- $shiny = 'shiny';
- }
-
- localize_item($item);
-
- $body = prepare_body($item,true);
-
- list($categories, $folders) = get_cats_and_terms($item);
-
- if ($a->theme['template_engine'] === 'internal') {
- $body_e = template_escape($body);
- $text_e = strip_tags(template_escape($body));
- $name_e = template_escape($profile_name);
- $title_e = template_escape($item['title']);
- $location_e = template_escape($location);
- $owner_name_e = template_escape($this->get_owner_name());
- } else {
- $body_e = $body;
- $text_e = strip_tags($body);
- $name_e = $profile_name;
- $title_e = $item['title'];
- $location_e = $location;
- $owner_name_e = $this->get_owner_name();
- }
-
- // Disable features that aren't available in several networks
-
- /// @todo Add NETWORK_DIASPORA when it will pass this information
- if (!in_array($item["item_network"], array(NETWORK_DFRN)) && isset($buttons["dislike"])) {
- unset($buttons["dislike"],$isevent);
- $tagger = '';
- }
-
- if (($item["item_network"] == NETWORK_FEED) && isset($buttons["like"])) {
- unset($buttons["like"]);
- }
-
- if (($item["item_network"] == NETWORK_MAIL) && isset($buttons["like"])) {
- unset($buttons["like"]);
- }
-
- $tmp_item = array(
- 'template' => $this->get_template(),
- 'type' => implode("",array_slice(explode("/",$item['verb']),-1)),
- 'tags' => $item['tags'],
- 'hashtags' => $item['hashtags'],
- 'mentions' => $item['mentions'],
- 'txt_cats' => t('Categories:'),
- 'txt_folders' => t('Filed under:'),
- 'has_cats' => ((count($categories)) ? 'true' : ''),
- 'has_folders' => ((count($folders)) ? 'true' : ''),
- 'categories' => $categories,
- 'folders' => $folders,
- 'body' => $body_e,
- 'text' => $text_e,
- 'id' => $this->get_id(),
- 'guid' => urlencode($item['guid']),
- 'isevent' => $isevent,
- 'attend' => $attend,
- 'linktitle' => sprintf( t('View %s\'s profile @ %s'), $profile_name, ((strlen($item['author-link'])) ? $item['author-link'] : $item['url'])),
- 'olinktitle' => sprintf( t('View %s\'s profile @ %s'), htmlentities($this->get_owner_name()), ((strlen($item['owner-link'])) ? $item['owner-link'] : $item['url'])),
- 'to' => t('to'),
- 'via' => t('via'),
- 'wall' => t('Wall-to-Wall'),
- 'vwall' => t('via Wall-To-Wall:'),
- 'profile_url' => $profile_link,
- 'item_photo_menu' => item_photo_menu($item),
- 'name' => $name_e,
- 'thumb' => $a->remove_baseurl(proxy_url($item['author-thumb'], false, PROXY_SIZE_THUMB)),
- 'osparkle' => $osparkle,
- 'sparkle' => $sparkle,
- 'title' => $title_e,
- 'localtime' => datetime_convert('UTC', date_default_timezone_get(), $item['created'], 'r'),
- 'ago' => (($item['app']) ? sprintf( t('%s from %s'),relative_date($item['created']),$item['app']) : relative_date($item['created'])),
- 'app' => $item['app'],
- 'created' => relative_date($item['created']),
- 'lock' => $lock,
- 'location' => $location_e,
- 'indent' => $indent,
- 'shiny' => $shiny,
- 'owner_url' => $this->get_owner_url(),
- 'owner_photo' => $a->remove_baseurl(proxy_url($item['owner-thumb'], false, PROXY_SIZE_THUMB)),
- 'owner_name' => htmlentities($owner_name_e),
- 'plink' => get_plink($item),
- 'edpost' => ((feature_enabled($conv->get_profile_owner(),'edit_posts')) ? $edpost : ''),
- 'isstarred' => $isstarred,
- 'star' => ((feature_enabled($conv->get_profile_owner(),'star_posts')) ? $star : ''),
- 'ignore' => ((feature_enabled($conv->get_profile_owner(),'ignore_posts')) ? $ignore : ''),
- 'tagger' => $tagger,
- 'filer' => ((feature_enabled($conv->get_profile_owner(),'filing')) ? $filer : ''),
- 'drop' => $drop,
- 'vote' => $buttons,
- 'like' => $responses['like']['output'],
- 'dislike' => $responses['dislike']['output'],
- 'responses' => $responses,
- 'switchcomment' => t('Comment'),
- 'comment' => $comment,
- 'previewing' => ($conv->is_preview() ? ' preview ' : ''),
- 'wait' => t('Please wait'),
- 'thread_level' => $thread_level,
- 'edited' => $edited,
- 'network' => $item["item_network"],
- 'network_name' => network_to_name($item['item_network'], $profile_link),
- 'received' => $item['received'],
- 'commented' => $item['commented'],
- 'created_date' => $item['created'],
- );
-
- $arr = array('item' => $item, 'output' => $tmp_item);
- call_hooks('display_item', $arr);
-
- $result = $arr['output'];
-
- $result['children'] = array();
- $children = $this->get_children();
- $nb_children = count($children);
- if ($nb_children > 0) {
- foreach ($children as $child) {
- $result['children'][] = $child->get_template_data($conv_responses, $thread_level + 1);
- }
- // Collapse
- if (($nb_children > 2) || ($thread_level > 1)) {
- $result['children'][0]['comment_firstcollapsed'] = true;
- $result['children'][0]['num_comments'] = sprintf( tt('%d comment','%d comments',$total_children),$total_children );
- $result['children'][0]['hidden_comments_num'] = $total_children;
- $result['children'][0]['hidden_comments_text'] = tt('comment', 'comments', $total_children);
- $result['children'][0]['hide_text'] = t('show more');
- if ($thread_level > 1) {
- $result['children'][$nb_children - 1]['comment_lastcollapsed'] = true;
- } else {
- $result['children'][$nb_children - 3]['comment_lastcollapsed'] = true;
- }
- }
- }
-
- if ($this->is_toplevel()) {
- $result['total_comments_num'] = "$total_children";
- $result['total_comments_text'] = tt('comment', 'comments', $total_children);
- }
-
- $result['private'] = $item['private'];
- $result['toplevel'] = ($this->is_toplevel() ? 'toplevel_item' : '');
-
- if ($this->is_threaded()) {
- $result['flatten'] = false;
- $result['threaded'] = true;
- } else {
- $result['flatten'] = true;
- $result['threaded'] = false;
- }
-
- return $result;
- }
-
- public function get_id() {
- return $this->get_data_value('id');
- }
-
- public function is_threaded() {
- return $this->threaded;
- }
-
- /**
- * Add a child item
- */
- public function add_child(Item $item) {
- $item_id = $item->get_id();
- if (!$item_id) {
- logger('[ERROR] Item::add_child : Item has no ID!!', LOGGER_DEBUG);
- return false;
- } elseif ($this->get_child($item->get_id())) {
- logger('[WARN] Item::add_child : Item already exists ('. $item->get_id() .').', LOGGER_DEBUG);
- return false;
- }
- /*
- * Only add what will be displayed
- */
- if ($item->get_data_value('network') === NETWORK_MAIL && local_user() != $item->get_data_value('uid')) {
- return false;
- } elseif (activity_match($item->get_data_value('verb'),ACTIVITY_LIKE) || activity_match($item->get_data_value('verb'),ACTIVITY_DISLIKE)) {
- return false;
- }
-
- $item->set_parent($this);
- $this->children[] = $item;
- return end($this->children);
- }
-
- /**
- * Get a child by its ID
- */
- public function get_child($id) {
- foreach ($this->get_children() as $child) {
- if ($child->get_id() == $id) {
- return $child;
- }
- }
- return null;
- }
-
- /**
- * Get all ou children
- */
- public function get_children() {
- return $this->children;
- }
-
- /**
- * Set our parent
- */
- protected function set_parent($item) {
- $parent = $this->get_parent();
- if($parent) {
- $parent->remove_child($this);
- }
- $this->parent = $item;
- $this->set_conversation($item->get_conversation());
- }
-
- /**
- * Remove our parent
- */
- protected function remove_parent() {
- $this->parent = null;
- $this->conversation = null;
- }
-
- /**
- * Remove a child
- */
- public function remove_child($item) {
- $id = $item->get_id();
- foreach ($this->get_children() as $key => $child) {
- if ($child->get_id() == $id) {
- $child->remove_parent();
- unset($this->children[$key]);
- // Reindex the array, in order to make sure there won't be any trouble on loops using count()
- $this->children = array_values($this->children);
- return true;
- }
- }
- logger('[WARN] Item::remove_child : Item is not a child ('. $id .').', LOGGER_DEBUG);
- return false;
- }
-
- /**
- * Get parent item
- */
- protected function get_parent() {
- return $this->parent;
- }
-
- /**
- * set conversation
- */
- public function set_conversation($conv) {
- $previous_mode = ($this->conversation ? $this->conversation->get_mode() : '');
-
- $this->conversation = $conv;
-
- // Set it on our children too
- foreach ($this->get_children() as $child) {
- $child->set_conversation($conv);
- }
- }
-
- /**
- * get conversation
- */
- public function get_conversation() {
- return $this->conversation;
- }
-
- /**
- * Get raw data
- *
- * We shouldn't need this
- */
- public function get_data() {
- return $this->data;
- }
-
- /**
- * Get a data value
- *
- * Returns:
- * _ value on success
- * _ false on failure
- */
- public function get_data_value($name) {
- if (!isset($this->data[$name])) {
-// logger('[ERROR] Item::get_data_value : Item has no value name "'. $name .'".', LOGGER_DEBUG);
- return false;
- }
-
- return $this->data[$name];
- }
-
- /**
- * Set template
- */
- private function set_template($name) {
- if (!x($this->available_templates, $name)) {
- logger('[ERROR] Item::set_template : Template not available ("'. $name .'").', LOGGER_DEBUG);
- return false;
- }
-
- $this->template = $this->available_templates[$name];
- }
-
- /**
- * Get template
- */
- private function get_template() {
- return $this->template;
- }
-
- /**
- * Check if this is a toplevel post
- */
- private function is_toplevel() {
- return $this->toplevel;
- }
-
- /**
- * Check if this is writable
- */
- private function is_writable() {
- $conv = $this->get_conversation();
-
- if ($conv) {
- // This will allow us to comment on wall-to-wall items owned by our friends
- // and community forums even if somebody else wrote the post.
-
- // bug #517 - this fixes for conversation owner
- if ($conv->get_mode() == 'profile' && $conv->get_profile_owner() == local_user()) {
- return true;
- }
-
- // this fixes for visitors
- return ($this->writable || ($this->is_visiting() && $conv->get_mode() == 'profile'));
- }
- return $this->writable;
- }
-
- /**
- * Count the total of our descendants
- */
- private function count_descendants() {
- $children = $this->get_children();
- $total = count($children);
- if ($total > 0) {
- foreach ($children as $child) {
- $total += $child->count_descendants();
- }
- }
- return $total;
- }
-
- /**
- * Get the template for the comment box
- */
- private function get_comment_box_template() {
- return $this->comment_box_template;
- }
-
- /**
- * Get the comment box
- *
- * Returns:
- * _ The comment box string (empty if no comment box)
- * _ false on failure
- */
- private function get_comment_box($indent) {
- $a = $this->get_app();
- if (!$this->is_toplevel() && !(Config::get('system','thread_allow') && $a->theme_thread_allow)) {
- return '';
- }
-
- $comment_box = '';
- $conv = $this->get_conversation();
- $template = get_markup_template($this->get_comment_box_template());
- $ww = '';
- if ( ($conv->get_mode() === 'network') && $this->is_wall_to_wall() )
- $ww = 'ww';
-
- if ($conv->is_writable() && $this->is_writable()) {
- $qc = $qcomment = null;
-
- /*
- * Hmmm, code depending on the presence of a particular plugin?
- * This should be better if done by a hook
- */
- if (in_array('qcomment',$a->plugins)) {
- $qc = ((local_user()) ? PConfig::get(local_user(),'qcomment','words') : null);
- $qcomment = (($qc) ? explode("\n",$qc) : null);
- }
- $comment_box = replace_macros($template,array(
- '$return_path' => $a->query_string,
- '$threaded' => $this->is_threaded(),
-// '$jsreload' => (($conv->get_mode() === 'display') ? $_SESSION['return_url'] : ''),
- '$jsreload' => '',
- '$type' => (($conv->get_mode() === 'profile') ? 'wall-comment' : 'net-comment'),
- '$id' => $this->get_id(),
- '$parent' => $this->get_id(),
- '$qcomment' => $qcomment,
- '$profile_uid' => $conv->get_profile_owner(),
- '$mylink' => $a->remove_baseurl($a->contact['url']),
- '$mytitle' => t('This is you'),
- '$myphoto' => $a->remove_baseurl($a->contact['thumb']),
- '$comment' => t('Comment'),
- '$submit' => t('Submit'),
- '$edbold' => t('Bold'),
- '$editalic' => t('Italic'),
- '$eduline' => t('Underline'),
- '$edquote' => t('Quote'),
- '$edcode' => t('Code'),
- '$edimg' => t('Image'),
- '$edurl' => t('Link'),
- '$edvideo' => t('Video'),
- '$preview' => ((feature_enabled($conv->get_profile_owner(),'preview')) ? t('Preview') : ''),
- '$indent' => $indent,
- '$sourceapp' => t($a->sourcename),
- '$ww' => (($conv->get_mode() === 'network') ? $ww : ''),
- '$rand_num' => random_digits(12)
- ));
- }
-
- return $comment_box;
- }
-
- private function get_redirect_url() {
- return $this->redirect_url;
- }
-
- /**
- * Check if we are a wall to wall item and set the relevant properties
- */
- protected function check_wall_to_wall() {
- $a = $this->get_app();
- $conv = $this->get_conversation();
- $this->wall_to_wall = false;
-
- if($this->is_toplevel()) {
- if($conv->get_mode() !== 'profile') {
- if($this->get_data_value('wall') && !$this->get_data_value('self')) {
- // On the network page, I am the owner. On the display page it will be the profile owner.
- // This will have been stored in $a->page_contact by our calling page.
- // Put this person as the wall owner of the wall-to-wall notice.
-
- $this->owner_url = zrl($a->page_contact['url']);
- $this->owner_photo = $a->page_contact['thumb'];
- $this->owner_name = $a->page_contact['name'];
- $this->wall_to_wall = true;
- } elseif($this->get_data_value('owner-link')) {
-
- $owner_linkmatch = (($this->get_data_value('owner-link')) && link_compare($this->get_data_value('owner-link'),$this->get_data_value('author-link')));
- $alias_linkmatch = (($this->get_data_value('alias')) && link_compare($this->get_data_value('alias'),$this->get_data_value('author-link')));
- $owner_namematch = (($this->get_data_value('owner-name')) && $this->get_data_value('owner-name') == $this->get_data_value('author-name'));
-
- if ((! $owner_linkmatch) && (! $alias_linkmatch) && (! $owner_namematch)) {
-
- // The author url doesn't match the owner (typically the contact)
- // and also doesn't match the contact alias.
- // The name match is a hack to catch several weird cases where URLs are
- // all over the park. It can be tricked, but this prevents you from
- // seeing "Bob Smith to Bob Smith via Wall-to-wall" and you know darn
- // well that it's the same Bob Smith.
-
- // But it could be somebody else with the same name. It just isn't highly likely.
-
-
- $this->owner_photo = $this->get_data_value('owner-avatar');
- $this->owner_name = $this->get_data_value('owner-name');
- $this->wall_to_wall = true;
- // If it is our contact, use a friendly redirect link
- if ((link_compare($this->get_data_value('owner-link'),$this->get_data_value('url')))
- && ($this->get_data_value('network') === NETWORK_DFRN)) {
- $this->owner_url = $this->get_redirect_url();
- } else {
- $this->owner_url = zrl($this->get_data_value('owner-link'));
- }
- }
- }
- }
- }
-
- if (!$this->wall_to_wall) {
- $this->set_template('wall');
- $this->owner_url = '';
- $this->owner_photo = '';
- $this->owner_name = '';
- }
- }
-
- private function is_wall_to_wall() {
- return $this->wall_to_wall;
- }
-
- private function get_owner_url() {
- return $this->owner_url;
- }
-
- private function get_owner_photo() {
- return $this->owner_photo;
- }
-
- private function get_owner_name() {
- return $this->owner_name;
- }
-
- private function is_visiting() {
- return $this->visiting;
- }
-
-}
+++ /dev/null
-<?php\r
-require_once 'boot.php';\r
-\r
-\r
-/**\r
- * Interface for template engines\r
- */\r
-interface ITemplateEngine {\r
- public function replace_macros($s,$v);\r
- public function get_template_file($file, $root='');\r
-}\r
--- /dev/null
+#!/usr/bin/env php
+<?php
+/*
+ * ejabberd extauth script for the integration with friendica
+ *
+ * Originally written for joomla by Dalibor Karlovic <dado@krizevci.info>
+ * modified for Friendica by Michael Vogel <icarus@dabo.de>
+ * published under GPL
+ *
+ * Latest version of the original script for joomla is available at:
+ * http://87.230.15.86/~dado/ejabberd/joomla-login
+ *
+ * Installation:
+ *
+ * - Change it's owner to whichever user is running the server, ie. ejabberd
+ * $ chown ejabberd:ejabberd /path/to/friendica/scripts/auth_ejabberd.php
+ *
+ * - Change the access mode so it is readable only to the user ejabberd and has exec
+ * $ chmod 700 /path/to/friendica/scripts/auth_ejabberd.php
+ *
+ * - Edit your ejabberd.cfg file, comment out your auth_method and add:
+ * {auth_method, external}.
+ * {extauth_program, "/path/to/friendica/script/auth_ejabberd.php"}.
+ *
+ * - Restart your ejabberd service, you should be able to login with your friendica auth info
+ *
+ * Other hints:
+ * - if your users have a space or a @ in their nickname, they'll run into trouble
+ * registering with any client so they should be instructed to replace these chars
+ * " " (space) is replaced with "%20"
+ * "@" is replaced with "(a)"
+ *
+ */
+
+use Friendica\App;
+use Friendica\Util\ExAuth;
+
+if (sizeof($_SERVER["argv"]) == 0) {
+ die();
+}
+
+$directory = dirname($_SERVER["argv"][0]);
+
+if (substr($directory, 0, 1) != DIRECTORY_SEPARATOR) {
+ $directory = $_SERVER["PWD"] . DIRECTORY_SEPARATOR . $directory;
+}
+
+$directory = realpath($directory . DIRECTORY_SEPARATOR . "..");
+
+chdir($directory);
+
+require_once "boot.php";
+require_once "include/dba.php";
+
+$a = new App(dirname(__DIR__));
+
+@include ".htconfig.php";
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
+
+$oAuth = new ExAuth();
+
+$oAuth->readStdin();
--- /dev/null
+<?php
+/**
+ * @file util/daemon.php
+ * @brief Run the worker from a daemon.
+ *
+ * This script was taken from http://php.net/manual/en/function.pcntl-fork.php
+ */
+function shutdown() {
+ posix_kill(posix_getpid(), SIGHUP);
+}
+
+if (in_array("start", $_SERVER["argv"])) {
+ $mode = "start";
+}
+
+if (in_array("stop", $_SERVER["argv"])) {
+ $mode = "stop";
+}
+
+if (in_array("status", $_SERVER["argv"])) {
+ $mode = "status";
+}
+
+if (!isset($mode)) {
+ die("Please use either 'start', 'stop' or 'status'.\n");
+}
+
+@include(".htconfig.php");
+
+if (!isset($pidfile)) {
+ die('Please specify a pid file in the variable $pidfile in the .htconfig.php. For example:'."\n".
+ '$pidfile = "/path/to/daemon.pid";'."\n");
+}
+
+if (in_array($mode, array("stop", "status"))) {
+ $pid = @file_get_contents($pidfile);
+
+ if (!$pid) {
+ die("Pidfile wasn't found. Is the daemon running?\n");
+ }
+}
+
+if ($mode == "status") {
+ if (posix_kill($pid, 0)) {
+ die("Daemon process $pid is running.\n");
+ }
+
+ unlink($pidfile);
+
+ die("Daemon process $pid isn't running.\n");
+}
+
+if ($mode == "stop") {
+ posix_kill($pid, SIGTERM);
+
+ unlink($pidfile);
+
+ die("Worker daemon process $pid was killed.\n");
+}
+
+echo "Starting worker daemon.\n";
+
+if (isset($a->config['php_path'])) {
+ $php = $a->config['php_path'];
+} else {
+ $php = "php";
+}
+
+// Switch over to daemon mode.
+if ($pid = pcntl_fork())
+ return; // Parent
+
+fclose(STDIN); // Close all of the standard
+fclose(STDOUT); // file descriptors as we
+fclose(STDERR); // are running as a daemon.
+
+register_shutdown_function('shutdown');
+
+if (posix_setsid() < 0)
+ return;
+
+if ($pid = pcntl_fork())
+ return; // Parent
+
+$pid = getmypid();
+file_put_contents($pidfile, $pid);
+
+// Now running as a daemon.
+while (true) {
+ // Just to be sure that this script really runs endlessly
+ set_time_limit(0);
+
+ // Call the worker
+ $cmdline = $php.' scripts/worker.php';
+
+ exec($cmdline);
+
+ // Now sleep for 5 minutes
+ sleep(300);
+}
--- /dev/null
+<?php
+/**
+ * @file scripts/dbstructure.php
+ * @brief Does database updates from the command line
+ */
+
+require_once 'include/dbstructure.php';
+
+use Friendica\App;
+
+$a = new App(dirname(__DIR__));
+
+@include ".htconfig.php";
+require_once "include/dba.php";
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
+
+if ($_SERVER["argc"] == 2) {
+ switch ($_SERVER["argv"][1]) {
+ case "dryrun":
+ update_structure(true, false);
+ return;
+ case "update":
+ update_structure(true, true);
+
+ $build = Config::get('system','build');
+ if (!x($build)) {
+ Config::set('system', 'build', DB_UPDATE_VERSION);
+ $build = DB_UPDATE_VERSION;
+ }
+
+ $stored = intval($build);
+ $current = intval(DB_UPDATE_VERSION);
+
+ // run any left update_nnnn functions in update.php
+ for ($x = $stored; $x < $current; $x ++) {
+ $r = run_update_function($x);
+ if (!$r) {
+ break;
+ }
+ }
+
+ Config::set('system','build',DB_UPDATE_VERSION);
+ return;
+ case "dumpsql":
+ print_structure(db_definition());
+ return;
+ case "toinnodb":
+ convert_to_innodb();
+ return;
+ }
+}
+
+// print help
+echo $_SERVER["argv"][0]." <command>\n";
+echo "\n";
+echo "Commands:\n";
+echo "dryrun show database update schema queries without running them\n";
+echo "update update database schema\n";
+echo "dumpsql dump database schema\n";
+echo "toinnodb convert all tables from MyISAM to InnoDB\n";
+killme();
+
--- /dev/null
+<?php
+use Friendica\App;
+use Friendica\Core\Worker;
+use Friendica\Core\Config;
+
+// Ensure that worker.php is executed from the base path of the installation
+if (!file_exists("boot.php") && (sizeof($_SERVER["argv"]) != 0)) {
+ $directory = dirname($_SERVER["argv"][0]);
+
+ if (substr($directory, 0, 1) != "/") {
+ $directory = $_SERVER["PWD"]."/".$directory;
+ }
+ $directory = realpath($directory."/..");
+
+ chdir($directory);
+}
+
+require_once "boot.php";
+require_once "include/dba.php";
+
+$a = new App(dirname(__DIR__));
+
+require_once ".htconfig.php";
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
+
+Config::load();
+
+// Check the database structure and possibly fixes it
+check_db(true);
+
+// Quit when in maintenance
+if (Config::get('system', 'maintenance', true)) {
+ return;
+}
+
+$a->set_baseurl(Config::get('system', 'url'));
+
+load_hooks();
+
+$run_cron = (($_SERVER["argc"] <= 1) || ($_SERVER["argv"][1] != "no_cron"));
+Worker::processQueue($run_cron);
+
+Worker::unclaimProcess();
+
+$a->end_process();
+
+killme();
+
public $videowidth = 425;
public $videoheight = 350;
public $force_max_items = 0;
- public $theme_thread_allow = true;
public $theme_events_in_profile = true;
/**
'videowidth' => 425,
'videoheight' => 350,
'force_max_items' => 0,
- 'thread_allow' => true,
'stylesheet' => '',
'template_engine' => 'smarty3',
);
// Register template engines
$dc = get_declared_classes();
foreach ($dc as $k) {
- if (in_array('ITemplateEngine', class_implements($k))) {
+ if (in_array('Friendica\Render\ITemplateEngine', class_implements($k))) {
$this->register_template_engine($k);
}
}
if (DBM::is_result($r)) {
foreach ($r AS $process) {
if (!posix_kill($process['pid'], 0)) {
- q('DELETE FROM `process` WHERE `pid` = %d', intval($process['pid']));
+ dba::delete('process', array('pid' => $process['pid']));
}
}
}
* @brief Remove the active process from the "process" table
*/
function end_process() {
- q('DELETE FROM `process` WHERE `pid` = %d', intval(getmypid()));
+ dba::delete('process', array('pid' => getmypid()));
}
function get_useragent() {
--- /dev/null
+<?php
+/**
+ * @file src/BaseObject.php
+ */
+namespace Friendica;
+
+require_once 'boot.php';
+
+/**
+ * Basic object
+ *
+ * Contains what is useful to any object
+ */
+class BaseObject
+{
+ private static $app = null;
+
+ /**
+ * Get the app
+ *
+ * Same as get_app from boot.php
+ *
+ * @return object
+ */
+ public static function getApp()
+ {
+ if (self::$app) {
+ return self::$app;
+ }
+
+ self::$app = get_app();
+
+ return self::$app;
+ }
+
+ /**
+ * Set the app
+ *
+ * @param object $app App
+ *
+ * @return void
+ */
+ public static function setApp($app)
+ {
+ self::$app = $app;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Content/ForumManager.php
+ * @brief ForumManager class with its methods related to forum functionality
+ */
+namespace Friendica\Content;
+
+use Friendica\App;
+use Friendica\Core\System;
+use Friendica\Database\DBM;
+use dba;
+
+/**
+ * @brief This class handles methods related to the forum functionality
+ */
+class ForumManager
+{
+ /**
+ * @brief Function to list all forums a user is connected with
+ *
+ * @param int $uid of the profile owner
+ * @param boolean $lastitem Sort by lastitem
+ * @param boolean $showhidden Show frorums which are not hidden
+ * @param boolean $showprivate Show private groups
+ *
+ * @return array
+ * 'url' => forum url
+ * 'name' => forum name
+ * 'id' => number of the key from the array
+ * 'micro' => contact photo in format micro
+ * 'thumb' => contact photo in format thumb
+ */
+ public static function getList($uid, $lastitem, $showhidden = true, $showprivate = false)
+ {
+ $forumlist = array();
+
+ $order = (($showhidden) ? '' : ' AND NOT `hidden` ');
+ $order .= (($lastitem) ? ' ORDER BY `last-item` DESC ' : ' ORDER BY `name` ASC ');
+ $select = '`forum` ';
+ if ($showprivate) {
+ $select = '(`forum` OR `prv`)';
+ }
+
+ $contacts = dba::p(
+ "SELECT `contact`.`id`, `contact`.`url`, `contact`.`name`, `contact`.`micro`, `contact`.`thumb`
+ FROM `contact`
+ WHERE `network`= 'dfrn' AND $select AND `uid` = ?
+ AND NOT `blocked` AND NOT `hidden` AND NOT `pending` AND NOT `archive`
+ AND `success_update` > `failure_update`
+ $order ",
+ $uid
+ );
+
+ if (!$contacts) {
+ return($forumlist);
+ }
+
+ while ($contact = dba::fetch($contacts)) {
+ $forumlist[] = array(
+ 'url' => $contact['url'],
+ 'name' => $contact['name'],
+ 'id' => $contact['id'],
+ 'micro' => $contact['micro'],
+ 'thumb' => $contact['thumb'],
+ );
+ }
+ dba::close($contacts);
+
+ return($forumlist);
+ }
+
+
+ /**
+ * @brief Forumlist widget
+ *
+ * Sidebar widget to show subcribed friendica forums. If activated
+ * in the settings, it appears at the notwork page sidebar
+ *
+ * @param int $uid The ID of the User
+ * @param int $cid The contact id which is used to mark a forum as "selected"
+ * @return string
+ */
+ public static function widget($uid, $cid = 0)
+ {
+ if (! intval(feature_enabled(local_user(), 'forumlist_widget'))) {
+ return;
+ }
+
+ $o = '';
+
+ //sort by last updated item
+ $lastitem = true;
+
+ $contacts = self::getList($uid, $lastitem, true, true);
+ $total = count($contacts);
+ $visible_forums = 10;
+
+ if (DBM::is_result($contacts)) {
+ $id = 0;
+
+ foreach ($contacts as $contact) {
+ $selected = (($cid == $contact['id']) ? ' forum-selected' : '');
+
+ $entry = array(
+ 'url' => 'network?f=&cid=' . $contact['id'],
+ 'external_url' => 'redir/' . $contact['id'],
+ 'name' => $contact['name'],
+ 'cid' => $contact['id'],
+ 'selected' => $selected,
+ 'micro' => System::removedBaseUrl(proxy_url($contact['micro'], false, PROXY_SIZE_MICRO)),
+ 'id' => ++$id,
+ );
+ $entries[] = $entry;
+ }
+
+ $tpl = get_markup_template('widget_forumlist.tpl');
+
+ $o .= replace_macros(
+ $tpl,
+ array(
+ '$title' => t('Forums'),
+ '$forums' => $entries,
+ '$link_desc' => t('External link to forum'),
+ '$total' => $total,
+ '$visible_forums' => $visible_forums,
+ '$showmore' => t('show more'))
+ );
+ }
+
+ return $o;
+ }
+
+ /**
+ * @brief Format forumlist as contact block
+ *
+ * This function is used to show the forumlist in
+ * the advanced profile.
+ *
+ * @param int $uid The ID of the User
+ * @return string
+ */
+ public static function profileAdvanced($uid)
+ {
+ $profile = intval(feature_enabled($uid, 'forumlist_profile'));
+ if (! $profile) {
+ return;
+ }
+
+ $o = '';
+
+ // place holder in case somebody wants configurability
+ $show_total = 9999;
+
+ //don't sort by last updated item
+ $lastitem = false;
+
+ $contacts = self::getList($uid, $lastitem, false, false);
+
+ $total_shown = 0;
+
+ foreach ($contacts as $contact) {
+ $forumlist .= micropro($contact, false, 'forumlist-profile-advanced');
+ $total_shown ++;
+ if ($total_shown == $show_total) {
+ break;
+ }
+ }
+
+ if (count($contacts) > 0) {
+ $o .= $forumlist;
+ return $o;
+ }
+ }
+
+ /**
+ * @brief count unread forum items
+ *
+ * Count unread items of connected forums and private groups
+ *
+ * @return array
+ * 'id' => contact id
+ * 'name' => contact/forum name
+ * 'count' => counted unseen forum items
+ */
+ public static function countUnseenItems()
+ {
+ $r = q(
+ "SELECT `contact`.`id`, `contact`.`name`, COUNT(*) AS `count` FROM `item`
+ INNER JOIN `contact` ON `item`.`contact-id` = `contact`.`id`
+ WHERE `item`.`uid` = %d AND `item`.`visible` AND NOT `item`.`deleted` AND `item`.`unseen`
+ AND `contact`.`network`= 'dfrn' AND (`contact`.`forum` OR `contact`.`prv`)
+ AND NOT `contact`.`blocked` AND NOT `contact`.`hidden`
+ AND NOT `contact`.`pending` AND NOT `contact`.`archive`
+ AND `contact`.`success_update` > `failure_update`
+ GROUP BY `contact`.`id` ",
+ intval(local_user())
+ );
+
+ return $r;
+ }
+}
--- /dev/null
+<?php
+
+/**
+ * @file src/Content/Smilies.php
+ * @brief This file contains the Smilies class which contains functions to handle smiles
+ *
+ * @todo Use the shortcodes from here:
+ * https://github.com/iamcal/emoji-data/blob/master/emoji_pretty.json?raw=true
+ * https://raw.githubusercontent.com/emojione/emojione/master/extras/alpha-codes/eac.json?raw=true
+ * https://github.com/johannhof/emoji-helper/blob/master/data/emoji.json?raw=true
+ *
+ * Have also a look here:
+ * https://www.webpagefx.com/tools/emoji-cheat-sheet/
+ */
+namespace Friendica\Content;
+
+use Friendica\App;
+use Friendica\Core\Config;
+use Friendica\Core\PConfig;
+use Friendica\Core\System;
+
+/**
+ * This class contains functions to handle smiles
+ */
+
+class Smilies
+{
+ /**
+ * @brief Replaces/adds the emoticon list
+ *
+ * This function should be used whenever emoticons are added
+ *
+ * @param array $b Array of emoticons
+ * @param string $smiley The text smilie
+ * @param string $representation The replacement
+ *
+ * @return void
+ */
+ public static function add(&$b, $smiley, $representation)
+ {
+ $found = array_search($smiley, $b['texts']);
+
+ if (!is_int($found)) {
+ $b['texts'][] = $smiley;
+ $b['icons'][] = $representation;
+ } else {
+ $b['icons'][$found] = $representation;
+ }
+ }
+
+ /**
+ * @brief Function to list all smilies
+ *
+ * Get an array of all smilies, both internal and from addons.
+ *
+ * @return array
+ * 'texts' => smilie shortcut
+ * 'icons' => icon in html
+ *
+ * @hook smilie ('texts' => smilies texts array, 'icons' => smilies html array)
+ */
+ public static function getList()
+ {
+ $texts = array(
+ '<3',
+ '</3',
+ '<\\3',
+ ':-)',
+ ';-)',
+ ':-(',
+ ':-P',
+ ':-p',
+ ':-"',
+ ':-"',
+ ':-x',
+ ':-X',
+ ':-D',
+ '8-|',
+ '8-O',
+ ':-O',
+ '\\o/',
+ 'o.O',
+ 'O.o',
+ 'o_O',
+ 'O_o',
+ ":'(",
+ ":-!",
+ ":-/",
+ ":-[",
+ "8-)",
+ ':beer',
+ ':homebrew',
+ ':coffee',
+ ':facepalm',
+ ':like',
+ ':dislike',
+ '~friendica',
+ 'red#',
+ 'red#matrix'
+
+ );
+
+ $icons = array(
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-heart.gif" alt="<3" title="<3" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-brokenheart.gif" alt="</3" title="</3" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-brokenheart.gif" alt="<\\3" title="<\\3" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-smile.gif" alt=":-)" title=":-)" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-wink.gif" alt=";-)" title=";-)" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-frown.gif" alt=":-(" title=":-(" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-tongue-out.gif" alt=":-P" title=":-P" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-tongue-out.gif" alt=":-p" title=":-P" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-\" title=":-\" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-\" title=":-\" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-x" title=":-x" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-kiss.gif" alt=":-X" title=":-X" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-laughing.gif" alt=":-D" title=":-D" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt="8-|" title="8-|" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt="8-O" title="8-O" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-surprised.gif" alt=":-O" title="8-O" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-thumbsup.gif" alt="\\o/" title="\\o/" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="o.O" title="o.O" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="O.o" title="O.o" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="o_O" title="o_O" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-Oo.gif" alt="O_o" title="O_o" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-cry.gif" alt=":\'(" title=":\'("/>',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-foot-in-mouth.gif" alt=":-!" title=":-!" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-undecided.gif" alt=":-/" title=":-/" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-embarassed.gif" alt=":-[" title=":-[" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-cool.gif" alt="8-)" title="8-)" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/beer_mug.gif" alt=":beer" title=":beer" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/beer_mug.gif" alt=":homebrew" title=":homebrew" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/coffee.gif" alt=":coffee" title=":coffee" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-facepalm.gif" alt=":facepalm" title=":facepalm" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/like.gif" alt=":like" title=":like" />',
+ '<img class="smiley" src="' . System::baseUrl() . '/images/dislike.gif" alt=":dislike" title=":dislike" />',
+ '<a href="https://friendi.ca">~friendica <img class="smiley" src="' . System::baseUrl() . '/images/friendica-16.png" alt="~friendica" title="~friendica" /></a>',
+ '<a href="http://redmatrix.me/">red<img class="smiley" src="' . System::baseUrl() . '/images/rm-16.png" alt="red#" title="red#" />matrix</a>',
+ '<a href="http://redmatrix.me/">red<img class="smiley" src="' . System::baseUrl() . '/images/rm-16.png" alt="red#matrix" title="red#matrix" />matrix</a>'
+ );
+
+ $params = array('texts' => $texts, 'icons' => $icons);
+ call_hooks('smilie', $params);
+
+ return $params;
+ }
+
+ /**
+ * @brief Replaces text emoticons with graphical images
+ *
+ * It is expected that this function will be called using HTML text.
+ * We will escape text between HTML pre and code blocks from being
+ * processed.
+ *
+ * At a higher level, the bbcode [nosmile] tag can be used to prevent this
+ * function from being executed by the prepare_text() routine when preparing
+ * bbcode source for HTML display
+ *
+ * @param string $s Text that should be replaced
+ * @param boolean $sample optional, default false
+ * @param boolean $no_images Only replace emoticons without images
+ *
+ * @return string HML Output of the Smilie
+ */
+ public static function replace($s, $sample = false, $no_images = false)
+ {
+ if (intval(Config::get('system', 'no_smilies'))
+ || (local_user() && intval(PConfig::get(local_user(), 'system', 'no_smilies')))
+ ) {
+ return $s;
+ }
+
+ $s = preg_replace_callback('/<pre>(.*?)<\/pre>/ism', 'self::encode', $s);
+ $s = preg_replace_callback('/<code>(.*?)<\/code>/ism', 'self::encode', $s);
+
+ $params = self::getList();
+
+ if ($no_images) {
+ $cleaned = array('texts' => array(), 'icons' => array());
+ $icons = $params['icons'];
+ foreach ($icons as $key => $icon) {
+ if (!strstr($icon, '<img ')) {
+ $cleaned['texts'][] = $params['texts'][$key];
+ $cleaned['icons'][] = $params['icons'][$key];
+ }
+ }
+ $params = $cleaned;
+ }
+
+ $params['string'] = $s;
+
+ if ($sample) {
+ $s = '<div class="smiley-sample">';
+ for ($x = 0; $x < count($params['texts']); $x ++) {
+ $s .= '<dl><dt>' . $params['texts'][$x] . '</dt><dd>' . $params['icons'][$x] . '</dd></dl>';
+ }
+ } else {
+ $params['string'] = preg_replace_callback('/<(3+)/', 'self::pregHeart', $params['string']);
+ $s = str_replace($params['texts'], $params['icons'], $params['string']);
+ }
+
+ $s = preg_replace_callback('/<pre>(.*?)<\/pre>/ism', 'self::decode', $s);
+ $s = preg_replace_callback('/<code>(.*?)<\/code>/ism', 'self::decode', $s);
+
+ return $s;
+ }
+
+ /**
+ * @param string $m string
+ *
+ * @return string base64 encoded string
+ */
+ private static function encode($m)
+ {
+ return(str_replace($m[1], base64url_encode($m[1]), $m[0]));
+ }
+
+ /**
+ * @param string $m string
+ *
+ * @return string base64 decoded string
+ */
+ private static function decode($m)
+ {
+ return(str_replace($m[1], base64url_decode($m[1]), $m[0]));
+ }
+
+
+ /**
+ * @brief expand <3333 to the correct number of hearts
+ *
+ * @param string $x string
+ *
+ * @return string HTML Output
+ *
+ * @todo: Rework because it doesn't work correctly
+ */
+ private static function pregHeart($x)
+ {
+ if (strlen($x[1]) == 1) {
+ return $x[0];
+ }
+ $t = '';
+ for ($cnt = 0; $cnt < strlen($x[1]); $cnt ++) {
+ $t .= '<img class="smiley" src="' . System::baseUrl() . '/images/smiley-heart.gif" alt="<3" />';
+ }
+ $r = str_replace($x[0], $t, $x[0]);
+ return $r;
+ }
+}
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Database\DBM;
+use dba;
/**
* @brief Class for storing data for a short time
// Frequently clear cache
self::clear($duration);
- $r = q(
- "SELECT `v` FROM `cache` WHERE `k`='%s' LIMIT 1",
- dbesc($key)
- );
+ $r = dba::select('cache', array('v'), array('k' => $key), array('limit' => 1));
if (DBM::is_result($r)) {
- $cached = $r[0]['v'];
+ $cached = $r['v'];
$value = @unserialize($cached);
// Only return a value if the serialized value is valid.
* @param string $key The key to the cached data
* @param mixed $value The value that is about to be stored
* @param integer $duration The cache lifespan
+ *
+ * @return void
*/
public static function set($key, $value, $duration = CACHE_MONTH)
{
$memcache->set(get_app()->get_hostname().":".$key, serialize($value), MEMCACHE_COMPRESSED, self::duration($duration));
return;
}
-
- /// @todo store the cache data in the same way like the config data
- q(
- "REPLACE INTO `cache` (`k`,`v`,`expire_mode`,`updated`) VALUES ('%s','%s',%d,'%s')",
- dbesc($key),
- dbesc(serialize($value)),
- intval($duration),
- dbesc(datetime_convert())
- );
+ $fields = array('v' => serialize($value), 'expire_mode' => $duration, 'updated' => datetime_convert());
+ $condition = array('k' => $key);
+ dba::update('cache', $fields, $condition, true);
}
/**
* @brief Remove outdated data from the cache
*
* @param integer $max_level The maximum cache level that is to be cleared
+ *
+ * @return void
*/
public static function clear($max_level = CACHE_MONTH)
{
// Clear long lasting cache entries only once a day
if (Config::get("system", "cache_cleared_day") < time() - self::duration(CACHE_DAY)) {
if ($max_level == CACHE_MONTH) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 30 days")),
- intval(CACHE_MONTH)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 30 days"),
+ CACHE_MONTH);
+ dba::delete('cache', $condition);
}
if ($max_level <= CACHE_WEEK) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 7 days")),
- intval(CACHE_WEEK)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 7 days"),
+ CACHE_WEEK);
+ dba::delete('cache', $condition);
}
if ($max_level <= CACHE_DAY) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 1 days")),
- intval(CACHE_DAY)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 1 days"),
+ CACHE_DAY);
+ dba::delete('cache', $condition);
}
Config::set("system", "cache_cleared_day", time());
}
if (($max_level <= CACHE_HOUR) && (Config::get("system", "cache_cleared_hour")) < time() - self::duration(CACHE_HOUR)) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 1 hours")),
- intval(CACHE_HOUR)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 1 hours"),
+ CACHE_HOUR);
+ dba::delete('cache', $condition);
Config::set("system", "cache_cleared_hour", time());
}
if (($max_level <= CACHE_HALF_HOUR) && (Config::get("system", "cache_cleared_half_hour")) < time() - self::duration(CACHE_HALF_HOUR)) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 30 minutes")),
- intval(CACHE_HALF_HOUR)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 30 minutes"),
+ CACHE_HALF_HOUR);
+ dba::delete('cache', $condition);
Config::set("system", "cache_cleared_half_hour", time());
}
if (($max_level <= CACHE_QUARTER_HOUR) && (Config::get("system", "cache_cleared_quarter_hour")) < time() - self::duration(CACHE_QUARTER_HOUR)) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 15 minutes")),
- intval(CACHE_QUARTER_HOUR)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 15 minutes"),
+ CACHE_QUARTER_HOUR);
+ dba::delete('cache', $condition);
Config::set("system", "cache_cleared_quarter_hour", time());
}
if (($max_level <= CACHE_FIVE_MINUTES) && (Config::get("system", "cache_cleared_five_minute")) < time() - self::duration(CACHE_FIVE_MINUTES)) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 5 minutes")),
- intval(CACHE_FIVE_MINUTES)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 5 minutes"),
+ CACHE_FIVE_MINUTES);
+ dba::delete('cache', $condition);
Config::set("system", "cache_cleared_five_minute", time());
}
if (($max_level <= CACHE_MINUTE) && (Config::get("system", "cache_cleared_minute")) < time() - self::duration(CACHE_MINUTE)) {
- q(
- "DELETE FROM `cache` WHERE `updated` < '%s' AND `expire_mode` = %d",
- dbesc(datetime_convert('UTC', 'UTC', "now - 1 minutes")),
- intval(CACHE_MINUTE)
- );
+ $condition = array("`updated` < ? AND `expire_mode` = ?",
+ datetime_convert('UTC', 'UTC', "now - 1 minutes"),
+ CACHE_MINUTE);
+ dba::delete('cache', $condition);
Config::set("system", "cache_cleared_minute", time());
}
/**
* @brief Arbitrary sytem configuration storage
+ *
* Note:
- * Please do not store booleans - convert to 0/1 integer values
- * The Config::get() functions return boolean false for keys that are unset,
- * and this could lead to subtle bugs.
+ * If we ever would decide to return exactly the variable type as entered,
+ * we will have fun with the additional features. :-)
+ *
+ * The config class always returns strings but in the default features
+ * we use a "false" to determine if the config value isn't set.
*
- * There are a few places in the code (such as the admin panel) where boolean
- * configurations need to be fixed as of 10/08/2011.
*/
-class Config {
-
+class Config
+{
private static $cache;
private static $in_db;
* All configuration values of the system are stored in global cache
* which is available under the global variable $a->config
*
- * @param string $family
- * The category of the configuration value
+ * @param string $family The category of the configuration value
+ *
* @return void
*/
- public static function load($family = "config") {
-
+ public static function load($family = "config")
+ {
// We don't preload "system" anymore.
// This reduces the number of database reads a lot.
if ($family === 'system') {
* local config cache, pull it into the cache so we don't have
* to hit the DB again for this item.
*
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to query
- * @param mixed $default_value optional
- * The value to return if key is not set (default: null)
- * @param boolean $refresh optional
- * If true the config is loaded from the db and not from the cache (default: false)
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to query
+ * @param mixed $default_value optional, The value to return if key is not set (default: null)
+ * @param boolean $refresh optional, If true the config is loaded from the db and not from the cache (default: false)
+ *
* @return mixed Stored value or null if it does not exist
*/
- public static function get($family, $key, $default_value = null, $refresh = false) {
-
+ public static function get($family, $key, $default_value = null, $refresh = false)
+ {
$a = get_app();
if (!$refresh) {
*
* Note: Please do not store booleans - convert to 0/1 integer values!
*
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to set
- * @param string $value
- * The value to store
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to set
+ * @param string $value The value to store
+ *
* @return mixed Stored $value or false if the database update failed
*/
- public static function set($family, $key, $value) {
+ public static function set($family, $key, $value)
+ {
$a = get_app();
// We store our setting values in a string variable.
* Removes the configured value from the stored cache in $a->config
* and removes it from the database.
*
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to delete
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to delete
+ *
* @return mixed
*/
- public static function delete($family, $key) {
-
+ public static function delete($family, $key)
+ {
if (isset(self::$cache[$family][$key])) {
unset(self::$cache[$family][$key]);
unset(self::$in_db[$family][$key]);
use Friendica\Core\Pconfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Object\Contact;
require_once 'include/html2plain.php';
require_once 'include/datetime.php';
require_once 'include/bbcode.php';
-require_once 'include/Contact.php';
/**
* @brief Methods for read and write notifications from/to database
'link' => System::baseUrl(true).'/display/'.$it['pguid'],
'image' => proxy_url($it['author-avatar'], false, PROXY_SIZE_MICRO),
'url' => $it['author-link'],
- 'text' => sprintf( t("%s is not attending %s's event"), $it['author-name'], $it['pname']),
+ 'text' => sprintf(t("%s is not attending %s's event"), $it['author-name'], $it['pname']),
'when' => $default_item_when,
'ago' => $default_item_ago,
'seen' => $it['seen']
/**
* @brief Total number of network notifications
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
+ *
* @return int Number of network notifications
*/
private function networkTotal($seen = 0)
/**
* @brief Get network notifications
*
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
* @param int $start Start the query at this point
* @param int $limit Maximum number of query results
*
/**
* @brief Total number of system notifications
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
+ *
* @return int Number of system notifications
*/
private function systemTotal($seen = 0)
/**
* @brief Get system notifications
*
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
* @param int $start Start the query at this point
* @param int $limit Maximum number of query results
*
*
* @return string The additional sql query
*/
- private function _personal_sql_extra()
+ private function personalSqlExtra()
{
$myurl = System::baseUrl(true) . '/profile/'. $this->a->user['nickname'];
$myurl = substr($myurl, strpos($myurl, '://') + 3);
/**
* @brief Total number of personal notifications
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
+ *
* @return int Number of personal notifications
*/
private function personalTotal($seen = 0)
{
$sql_seen = "";
- $sql_extra = $this->_personal_sql_extra();
+ $sql_extra = $this->personalSqlExtra();
if ($seen === 0) {
$sql_seen = " AND `item`.`unseen` = 1 ";
WHERE `item`.`visible` = 1
$sql_extra
$sql_seen
- AND `item`.`deleted` = 0 AND `item`.`uid` = %d AND `item`.`wall` = 0 " ,
+ AND `item`.`deleted` = 0 AND `item`.`uid` = %d AND `item`.`wall` = 0 ",
intval(local_user())
);
/**
* @brief Get personal notifications
*
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
* @param int $start Start the query at this point
* @param int $limit Maximum number of query results
*
{
$ident = 'personal';
$total = $this->personalTotal($seen);
- $sql_extra = $this->_personal_sql_extra();
+ $sql_extra = $this->personalSqlExtra();
$notifs = array();
$sql_seen = "";
/**
* @brief Total number of home notifications
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
+ *
* @return int Number of home notifications
*/
private function homeTotal($seen = 0)
/**
* @brief Get home notifications
*
- * @param int|string $seen
- * If 0 only include notifications into the query
- * which aren't marked as "seen"
+ * @param int|string $seen If 0 only include notifications into the query
+ * which aren't marked as "seen"
* @param int $start Start the query at this point
* @param int $limit Maximum number of query results
*
/**
* @brief Total number of introductions
- * @param bool $all
- * If false only include introductions into the query
- * which aren't marked as ignored
+ * @param bool $all If false only include introductions into the query
+ * which aren't marked as ignored
+ *
* @return int Number of introductions
*/
private function introTotal($all = false)
/**
* @brief Get introductions
*
- * @param bool $all
- * If false only include introductions into the query
- * which aren't marked as ignored
- * @param int $start Start the query at this point
- * @param int $limit Maximum number of query results
+ * @param bool $all If false only include introductions into the query
+ * which aren't marked as ignored
+ * @param int $start Start the query at this point
+ * @param int $limit Maximum number of query results
*
* @return array with
* string 'ident' => Notification identifier
* int 'total' => Total number of available introductions
* array 'notifications' => Introductions
*/
- public function introNotifs($all = false, $start = 0, $limit = 80) {
+ public function introNotifs($all = false, $start = 0, $limit = 80)
+ {
$ident = 'introductions';
$total = $this->introTotal($seen);
$notifs = array();
$sql_extra = " AND `ignore` = 0 ";
}
- /// @todo Fetch contact details by "get_contact_details_by_url" instead of queries to contact, fcontact and gcontact
+ /// @todo Fetch contact details by "Contact::getDetailsByUrl" instead of queries to contact, fcontact and gcontact
$r = q(
"SELECT `intro`.`id` AS `intro_id`, `intro`.*, `contact`.*,
`fcontact`.`name` AS `fname`, `fcontact`.`url` AS `furl`,
// If the network and addr is still not available
// get the missing data data from other sources
if ($arr['gnetwork'] == "" || $arr['gaddr'] == "") {
- $ret = get_contact_details_by_url($arr['url']);
+ $ret = Contact::getDetailsByURL($arr['url']);
if ($arr['gnetwork'] == "" && $ret['network'] != "") {
$arr['gnetwork'] = $ret['network'];
<?php
+/**
+ * @file src/Core/PConfig.php
+ */
namespace Friendica\Core;
use Friendica\Database\DBM;
* The PConfig::get() functions return boolean false for keys that are unset,
* and this could lead to subtle bugs.
*/
-class PConfig {
-
+class PConfig
+{
private static $in_db;
/**
* All configuration values of the given user are stored in global cache
* which is available under the global variable $a->config[$uid].
*
- * @param string $uid
- * The user_id
- * @param string $family
- * The category of the configuration value
+ * @param string $uid The user_id
+ * @param string $family The category of the configuration value
+ *
* @return void
*/
- public static function load($uid, $family) {
+ public static function load($uid, $family)
+ {
$a = get_app();
$r = dba::select('pconfig', array('v', 'k'), array('cat' => $family, 'uid' => $uid));
* Get a particular user's config value from the given category ($family)
* and the $key from a cached storage in $a->config[$uid].
*
- * @param string $uid
- * The user_id
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to query
- * @param mixed $default_value optional
- * The value to return if key is not set (default: null)
- * @param boolean $refresh optional
- * If true the config is loaded from the db and not from the cache (default: false)
+ * @param string $uid The user_id
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to query
+ * @param mixed $default_value optional, The value to return if key is not set (default: null)
+ * @param boolean $refresh optional, If true the config is loaded from the db and not from the cache (default: false)
+ *
* @return mixed Stored value or null if it does not exist
*/
- public static function get($uid, $family, $key, $default_value = null, $refresh = false) {
-
+ public static function get($uid, $family, $key, $default_value = null, $refresh = false)
+ {
$a = get_app();
if (!$refresh) {
*
* @note Please do not store booleans - convert to 0/1 integer values!
*
- * @param string $uid
- * The user_id
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to set
- * @param string $value
- * The value to store
+ * @param string $uid The user_id
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to set
+ * @param string $value The value to store
+ *
* @return mixed Stored $value or false
*/
- public static function set($uid, $family, $key, $value) {
-
+ public static function set($uid, $family, $key, $value)
+ {
$a = get_app();
// We store our setting values in a string variable.
* Removes the configured value from the stored cache in $a->config[$uid]
* and removes it from the database.
*
- * @param string $uid The user_id
- * @param string $family
- * The category of the configuration value
- * @param string $key
- * The configuration key to delete
+ * @param string $uid The user_id
+ * @param string $family The category of the configuration value
+ * @param string $key The configuration key to delete
+ *
* @return mixed
*/
- public static function delete($uid,$family,$key) {
-
+ public static function delete($uid, $family, $key)
+ {
$a = get_app();
if (x($a->config[$uid][$family], $key)) {
<?php
+/**
+ * @file src/Core/System.php
+ */
namespace Friendica\Core;
use Friendica\App;
/**
* @brief System methods
*/
-class System {
-
+class System
+{
private static $a;
/**
* @brief Initializes the static class variable
+ * @return void
*/
- private static function init() {
+ private static function init()
+ {
global $a;
if (!is_object(self::$a)) {
* @param bool $ssl Whether to append http or https under SSL_POLICY_SELFSIGN
* @return string Friendica server base URL
*/
- public static function baseUrl($ssl = false) {
+ public static function baseUrl($ssl = false)
+ {
self::init();
return self::$a->get_baseurl($ssl);
}
/**
* @brief Removes the baseurl from an url. This avoids some mixed content problems.
*
- * @param string $orig_url
+ * @param string $orig_url The url to be cleaned
*
* @return string The cleaned url
*/
- public static function removedBaseUrl($orig_url) {
+ public static function removedBaseUrl($orig_url)
+ {
self::init();
return self::$a->remove_baseurl($orig_url);
}
/**
* @brief Returns a string with a callstack. Can be used for logging.
- *
+ * @param integer $depth optional, default 4
* @return string
*/
- public static function callstack($depth = 4) {
+ public static function callstack($depth = 4)
+ {
$trace = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS);
// We remove the first two items from the list since they contain data that we don't need.
<?php
+/**
+ * @file src/Core/Worker.php
+ */
namespace Friendica\Core;
use Friendica\App;
/**
* @brief Worker methods
*/
-class Worker {
+class Worker
+{
private static $up_start;
private static $db_duration;
private static $last_update;
* @brief Processes the tasks that are in the workerqueue table
*
* @param boolean $run_cron Should the cron processes be executed?
+ * @return void
*/
- public static function processQueue($run_cron = true) {
+ public static function processQueue($run_cron = true)
+ {
$a = get_app();
self::$up_start = microtime(true);
// We fetch the next queue entry that is about to be executed
while ($r = self::workerProcess($passing_slow)) {
-
// When we are processing jobs with a lower priority, we don't refetch new jobs
// Otherwise fast jobs could wait behind slow ones and could be blocked.
$refetched = $passing_slow;
- foreach ($r AS $entry) {
+ foreach ($r as $entry) {
// Assure that the priority is an integer value
$entry['priority'] = (int)$entry['priority'];
}
}
- // To avoid the quitting of multiple pollers only one poller at a time will execute the check
+ // To avoid the quitting of multiple workers only one worker at a time will execute the check
if (Lock::set('poller_worker', 0)) {
$stamp = (float)microtime(true);
// Count active workers and compare them with a maximum value that depends on the load
self::$db_duration += (microtime(true) - $stamp);
}
- // Quit the poller once every 5 minutes
+ // Quit the worker once every 5 minutes
if (time() > ($starttime + 300)) {
logger('Process lifetime reached, quitting.', LOGGER_DEBUG);
return;
*
* @return integer Number of non executed entries in the worker queue
*/
- private static function totalEntries() {
+ private static function totalEntries()
+ {
$s = dba::fetch_first("SELECT COUNT(*) AS `total` FROM `workerqueue` WHERE `executed` <= ? AND NOT `done`", NULL_DATE);
if (DBM::is_result($s)) {
return $s["total"];
/**
* @brief Returns the highest priority in the worker queue that isn't executed
*
- * @return integer Number of active poller processes
+ * @return integer Number of active worker processes
*/
- private static function highestPriority() {
+ private static function highestPriority()
+ {
$condition = array("`executed` <= ? AND NOT `done`", NULL_DATE);
$s = dba::select('workerqueue', array('priority'), $condition, array('limit' => 1, 'order' => array('priority')));
if (DBM::is_result($s)) {
*
* @return integer Is there a process running with that priority?
*/
- private static function processWithPriorityActive($priority) {
+ private static function processWithPriorityActive($priority)
+ {
$condition = array("`priority` <= ? AND `executed` > ? AND NOT `done`", $priority, NULL_DATE);
return dba::exists('workerqueue', $condition);
}
*
* @return boolean "true" if further processing should be stopped
*/
- public static function execute($queue) {
+ public static function execute($queue)
+ {
$a = get_app();
$mypid = getmypid();
// Check for existance and validity of the include file
$include = $argv[0];
+ if (method_exists(sprintf('Friendica\Worker\%s', $include), 'execute')) {
+ // We constantly update the "executed" date every minute to avoid being killed too soon
+ if (!isset(self::$last_update)) {
+ self::$last_update = strtotime($queue["executed"]);
+ }
+
+ $age = (time() - self::$last_update) / 60;
+ self::$last_update = time();
+
+ if ($age > 1) {
+ $stamp = (float)microtime(true);
+ dba::update('workerqueue', array('executed' => datetime_convert()), array('pid' => $mypid, 'done' => false));
+ self::$db_duration += (microtime(true) - $stamp);
+ }
+
+ array_shift($argv);
+
+ self::execFunction($queue, $include, $argv, true);
+
+ $stamp = (float)microtime(true);
+ if (dba::update('workerqueue', array('done' => true), array('id' => $queue["id"]))) {
+ Config::set('system', 'last_poller_execution', datetime_convert());
+ }
+ self::$db_duration = (microtime(true) - $stamp);
+
+ return true;
+ }
+
// The script could be provided as full path or only with the function name
if ($include == basename($include)) {
$include = "include/".$include.".php";
return true;
}
- require_once($include);
+ require_once $include;
$funcname = str_replace(".php", "", basename($argv[0]))."_run";
if (function_exists($funcname)) {
-
// We constantly update the "executed" date every minute to avoid being killed too soon
if (!isset(self::$last_update)) {
self::$last_update = strtotime($queue["executed"]);
self::$db_duration += (microtime(true) - $stamp);
}
- self::execFunction($queue, $funcname, $argv);
+ self::execFunction($queue, $funcname, $argv, false);
$stamp = (float)microtime(true);
if (dba::update('workerqueue', array('done' => true), array('id' => $queue["id"]))) {
/**
* @brief Execute a function from the queue
*
- * @param array $queue Workerqueue entry
- * @param string $funcname name of the function
- * @param array $argv Array of values to be passed to the function
+ * @param array $queue Workerqueue entry
+ * @param string $funcname name of the function
+ * @param array $argv Array of values to be passed to the function
+ * @param boolean $method_call boolean
+ * @return void
*/
- private static function execFunction($queue, $funcname, $argv) {
+ private static function execFunction($queue, $funcname, $argv, $method_call)
+ {
$a = get_app();
$mypid = getmypid();
// Reset global data to avoid interferences
unset($_SESSION);
- $funcname($argv, $argc);
+ if ($method_call) {
+ call_user_func_array(sprintf('Friendica\Worker\%s::execute', $funcname), $argv);
+ } else {
+ $funcname($argv, $argc);
+ }
$a->process_id = $old_process_id;
unset($a->queue);
* The execution time is the productive time.
* By changing parameters like the maximum number of workers we can check the effectivness.
*/
- logger('DB: '.number_format(self::$db_duration, 2).
+ logger(
+ 'DB: '.number_format(self::$db_duration, 2).
' - Lock: '.number_format(self::$lock_duration, 2).
' - Rest: '.number_format($up_duration - self::$db_duration - self::$lock_duration, 2).
- ' - Execution: '.number_format($duration, 2), LOGGER_DEBUG);
+ ' - Execution: '.number_format($duration, 2),
+ LOGGER_DEBUG
+ );
+
self::$lock_duration = 0;
if ($duration > 3600) {
if (Config::get("rendertime", "callstack")) {
if (isset($a->callstack["database"])) {
$o = "\nDatabase Read:\n";
- foreach ($a->callstack["database"] AS $func => $time) {
+ foreach ($a->callstack["database"] as $func => $time) {
$time = round($time, 3);
if ($time > 0) {
$o .= $func.": ".$time."\n";
}
if (isset($a->callstack["database_write"])) {
$o .= "\nDatabase Write:\n";
- foreach ($a->callstack["database_write"] AS $func => $time) {
+ foreach ($a->callstack["database_write"] as $func => $time) {
$time = round($time, 3);
if ($time > 0) {
$o .= $func.": ".$time."\n";
}
if (isset($a->callstack["network"])) {
$o .= "\nNetwork:\n";
- foreach ($a->callstack["network"] AS $func => $time) {
+ foreach ($a->callstack["network"] as $func => $time) {
$time = round($time, 3);
if ($time > 0) {
$o .= $func.": ".$time."\n";
$o = '';
}
- logger("ID ".$queue["id"].": ".$funcname.": ".sprintf("DB: %s/%s, Net: %s, I/O: %s, Other: %s, Total: %s".$o,
- number_format($a->performance["database"] - $a->performance["database_write"], 2),
- number_format($a->performance["database_write"], 2),
- number_format($a->performance["network"], 2),
- number_format($a->performance["file"], 2),
- number_format($duration - ($a->performance["database"] + $a->performance["network"] + $a->performance["file"]), 2),
- number_format($duration, 2)),
- LOGGER_DEBUG);
+ logger(
+ "ID ".$queue["id"].": ".$funcname.": ".sprintf(
+ "DB: %s/%s, Net: %s, I/O: %s, Other: %s, Total: %s".$o,
+ number_format($a->performance["database"] - $a->performance["database_write"], 2),
+ number_format($a->performance["database_write"], 2),
+ number_format($a->performance["network"], 2),
+ number_format($a->performance["file"], 2),
+ number_format($duration - ($a->performance["database"] + $a->performance["network"] + $a->performance["file"]), 2),
+ number_format($duration, 2)
+ ),
+ LOGGER_DEBUG
+ );
}
$cooldown = Config::get("system", "worker_cooldown", 0);
*
* @return bool Are more than 3/4 of the maximum connections used?
*/
- private static function maxConnectionsReached() {
-
+ private static function maxConnectionsReached()
+ {
// Fetch the max value from the config. This is needed when the system cannot detect the correct value by itself.
$max = Config::get("system", "max_connections");
- // Fetch the percentage level where the poller will get active
+ // Fetch the percentage level where the worker will get active
$maxlevel = Config::get("system", "max_connections_level", 75);
if ($max == 0) {
/**
* @brief fix the queue entry if the worker process died
- *
+ * @return void
*/
- private static function killStaleWorkers() {
- $entries = dba::select('workerqueue', array('id', 'pid', 'executed', 'priority', 'parameter'),
- array('`executed` > ? AND NOT `done` AND `pid` != 0', NULL_DATE),
- array('order' => array('priority', 'created')));
+ private static function killStaleWorkers()
+ {
+ $entries = dba::select(
+ 'workerqueue',
+ array('id', 'pid', 'executed', 'priority', 'parameter'),
+ array('`executed` > ? AND NOT `done` AND `pid` != 0', NULL_DATE),
+ array('order' => array('priority', 'created'))
+ );
+
while ($entry = dba::fetch($entries)) {
if (!posix_kill($entry["pid"], 0)) {
- dba::update('workerqueue', array('executed' => NULL_DATE, 'pid' => 0),
- array('id' => $entry["id"]));
+ dba::update(
+ 'workerqueue',
+ array('executed' => NULL_DATE, 'pid' => 0),
+ array('id' => $entry["id"])
+ );
} else {
// Kill long running processes
// Check if the priority is in a valid range
} elseif ($entry["priority"] != PRIORITY_CRITICAL) {
$new_priority = PRIORITY_NEGLIGIBLE;
}
- dba::update('workerqueue',
- array('executed' => NULL_DATE, 'created' => datetime_convert(), 'priority' => $new_priority, 'pid' => 0),
- array('id' => $entry["id"]));
+ dba::update(
+ 'workerqueue',
+ array('executed' => NULL_DATE, 'created' => datetime_convert(), 'priority' => $new_priority, 'pid' => 0),
+ array('id' => $entry["id"])
+ );
} else {
logger("Worker process ".$entry["pid"]." (".implode(" ", $argv).") now runs for ".round($duration)." of ".$max_duration." allowed minutes. That's okay.", LOGGER_DEBUG);
}
*
* @return bool Are there too much workers running?
*/
- public static function tooMuchWorkers() {
+ public static function tooMuchWorkers()
+ {
$queues = Config::get("system", "worker_queues", 4);
$maxqueues = $queues;
$listitem = array();
// Adding all processes with no workerqueue entry
- $processes = dba::p("SELECT COUNT(*) AS `running` FROM `process` WHERE NOT EXISTS
+ $processes = dba::p(
+ "SELECT COUNT(*) AS `running` FROM `process` WHERE NOT EXISTS
(SELECT id FROM `workerqueue`
- WHERE `workerqueue`.`pid` = `process`.`pid` AND NOT `done` AND `pid` != ?)", getmypid());
+ WHERE `workerqueue`.`pid` = `process`.`pid` AND NOT `done` AND `pid` != ?)",
+ getmypid()
+ );
+
if ($process = dba::fetch($processes)) {
$listitem[0] = "0:".$process["running"];
}
$intervals = array(1, 10, 60);
$jobs_per_minute = array();
- foreach ($intervals AS $interval) {
+ foreach ($intervals as $interval) {
$jobs = dba::p("SELECT COUNT(*) AS `jobs` FROM `workerqueue` WHERE `done` AND `executed` > UTC_TIMESTAMP() - INTERVAL ".intval($interval)." MINUTE");
if ($job = dba::fetch($jobs)) {
$jobs_per_minute[$interval] = number_format($job['jobs'] / $interval, 0);
}
/**
- * @brief Returns the number of active poller processes
+ * @brief Returns the number of active worker processes
*
- * @return integer Number of active poller processes
+ * @return integer Number of active worker processes
*/
- private static function activeWorkers() {
+ private static function activeWorkers()
+ {
$workers = dba::fetch_first("SELECT COUNT(*) AS `processes` FROM `process` WHERE `command` = 'Worker.php'");
return $workers["processes"];
* @param string $highest_priority Returns the currently highest priority
* @return bool We let pass a slower process than $highest_priority
*/
- private static function passingSlow(&$highest_priority) {
+ private static function passingSlow(&$highest_priority)
+ {
$highest_priority = 0;
- $r = dba::p("SELECT `priority`
+ $r = dba::p(
+ "SELECT `priority`
FROM `process`
- INNER JOIN `workerqueue` ON `workerqueue`.`pid` = `process`.`pid` AND NOT `done`");
+ INNER JOIN `workerqueue` ON `workerqueue`.`pid` = `process`.`pid` AND NOT `done`"
+ );
// No active processes at all? Fine
if (!DBM::is_result($r)) {
return false;
}
$high = 0;
- foreach ($priorities AS $priority) {
+ foreach ($priorities as $priority) {
if ($priority == $highest_priority) {
++$high;
}
* @param boolean $passing_slow Returns if we had passed low priority processes
* @return boolean Have we found something?
*/
- private static function findWorkerProcesses(&$passing_slow) {
+ private static function findWorkerProcesses(&$passing_slow)
+ {
$mypid = getmypid();
// Check if we should pass some low priority process
if (self::passingSlow($highest_priority)) {
// Are there waiting processes with a higher priority than the currently highest?
- $result = dba::select('workerqueue', array('id'), array("`executed` <= ? AND `priority` < ? AND NOT `done`", NULL_DATE, $highest_priority),
- array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true));
+ $result = dba::select(
+ 'workerqueue',
+ array('id'),
+ array("`executed` <= ? AND `priority` < ? AND NOT `done`", NULL_DATE, $highest_priority),
+ array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true)
+ );
while ($id = dba::fetch($result)) {
$ids[] = $id["id"];
if (!$found) {
// Give slower processes some processing time
- $result = dba::select('workerqueue', array('id'), array("`executed` <= ? AND `priority` > ? AND NOT `done`", NULL_DATE, $highest_priority),
- array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true));
+ $result = dba::select(
+ 'workerqueue',
+ array('id'),
+ array("`executed` <= ? AND `priority` > ? AND NOT `done`", NULL_DATE, $highest_priority),
+ array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true)
+ );
while ($id = dba::fetch($result)) {
$ids[] = $id["id"];
// If there is no result (or we shouldn't pass lower processes) we check without priority limit
if (!$found) {
- $result = dba::select('workerqueue', array('id'), array("`executed` <= ? AND NOT `done`", NULL_DATE),
- array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true));
+ $result = dba::select(
+ 'workerqueue',
+ array('id'),
+ array("`executed` <= ? AND NOT `done`", NULL_DATE),
+ array('limit' => $limit, 'order' => array('priority', 'created'), 'only_query' => true)
+ );
while ($id = dba::fetch($result)) {
$ids[] = $id["id"];
* @param boolean $passing_slow Returns if we had passed low priority processes
* @return string SQL statement
*/
- public static function workerProcess(&$passing_slow) {
+ public static function workerProcess(&$passing_slow)
+ {
$stamp = (float)microtime(true);
// There can already be jobs for us in the queue.
/**
* @brief Removes a workerqueue entry from the current process
+ * @return void
*/
- public static function unclaimProcess() {
+ public static function unclaimProcess()
+ {
$mypid = getmypid();
dba::update('workerqueue', array('executed' => NULL_DATE, 'pid' => 0), array('pid' => $mypid, 'done' => false));
/**
* @brief Call the front end worker
+ * @return void
*/
- public static function callWorker() {
+ public static function callWorker()
+ {
if (!Config::get("system", "frontend_worker")) {
return;
}
/**
* @brief Call the front end worker if there aren't any active
+ * @return void
*/
- public static function executeIfIdle() {
+ public static function executeIfIdle()
+ {
if (!Config::get("system", "frontend_worker")) {
return;
}
- // Do we have "proc_open"? Then we can fork the poller
+ // Do we have "proc_open"? Then we can fork the worker
if (function_exists("proc_open")) {
// When was the last time that we called the worker?
// Less than one minute? Then we quit
self::runCron();
- logger('Call poller', LOGGER_DEBUG);
+ logger('Call worker', LOGGER_DEBUG);
self::spawnWorker();
return;
}
/**
* @brief Removes long running worker processes
+ * @return void
*/
- public static function clearProcesses() {
+ public static function clearProcesses()
+ {
$timeout = Config::get("system", "frontend_worker_timeout", 10);
/// @todo We should clean up the corresponding workerqueue entries as well
$condition = array("`created` < ? AND `command` = 'worker.php'",
- datetime_convert('UTC','UTC',"now - ".$timeout." minutes"));
+ datetime_convert('UTC', 'UTC', "now - ".$timeout." minutes"));
dba::delete('process', $condition);
}
/**
* @brief Runs the cron processes
+ * @return void
*/
- private static function runCron() {
+ private static function runCron()
+ {
logger('Add cron entries', LOGGER_DEBUG);
// Check for spooled items
- self::add(PRIORITY_HIGH, "spool_post");
+ self::add(PRIORITY_HIGH, "SpoolPost");
// Run the cron job that calls all other jobs
- self::add(PRIORITY_MEDIUM, "cron");
+ self::add(PRIORITY_MEDIUM, "Cron");
// Run the cronhooks job separately from cron for being able to use a different timing
- self::add(PRIORITY_MEDIUM, "cronhooks");
+ self::add(PRIORITY_MEDIUM, "CronHooks");
// Cleaning dead processes
self::killStaleWorkers();
}
- public static function spawnWorker() {
- $args = array("include/poller.php", "no_cron");
+ /**
+ * @return void
+ */
+ public static function spawnWorker()
+ {
+ $args = array("scripts/worker.php", "no_cron");
get_app()->proc_run($args);
}
* @param (integer|array) priority or parameter array, strings are deprecated and are ignored
*
* next args are passed as $cmd command line
- * or: Worker::add(PRIORITY_HIGH, "notifier", "drop", $drop_id);
- * or: Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "create_shadowentry", $post_id);
+ * or: Worker::add(PRIORITY_HIGH, "Notifier", "drop", $drop_id);
+ * or: Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), "CreateShadowEntry", $post_id);
*
* @note $cmd and string args are surrounded with ""
*
*
* @return boolean "false" if proc_run couldn't be executed
*/
- public static function add($cmd) {
+ public static function add($cmd)
+ {
$proc_args = func_get_args();
$args = array();
dba::insert('workerqueue', array('parameter' => $parameters, 'created' => $created, 'priority' => $priority));
}
- // Should we quit and wait for the poller to be called as a cronjob?
+ // Should we quit and wait for the worker to be called as a cronjob?
if ($dont_fork) {
return true;
}
return true;
}
- // Now call the poller to execute the jobs that we just added to the queue
+ // Now call the worker to execute the jobs that we just added to the queue
self::spawnWorker();
return true;
$processes = 0;
$states = array();
- foreach ($r AS $process) {
+ foreach ($r as $process) {
$state = trim($process["State"]);
// Filter out all non blocking processes
}
$statelist = "";
- foreach ($states AS $state => $usage) {
+ foreach ($states as $state => $usage) {
if ($statelist != "") {
$statelist .= ", ";
}
* @param mixed $value Array value
* @param string $key Array key
* @param boolean $add_quotation add quotation marks for string values
+ * @return void
*/
private static function esc_array_callback(&$value, $key, $add_quotation)
{
*
* @param mixed $arr Array with values to be escaped
* @param boolean $add_quotation add quotation marks for string values
+ * @return void
*/
public static function esc_array(&$arr, $add_quotation = false)
{
--- /dev/null
+<?php
+/**
+ * @file src/Model/GlobalContact.php
+ * @brief This file includes the GlobalContact class with directory related functions
+ */
+namespace Friendica\Model;
+
+use Friendica\Core\Config;
+use Friendica\Core\System;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+use Friendica\Object\Profile;
+use Friendica\Protocol\PortableContact;
+use dba;
+use Exception;
+
+require_once 'include/datetime.php';
+require_once 'include/network.php';
+require_once 'include/html2bbcode.php';
+require_once 'include/Photo.php';
+
+/**
+ * @brief This class handles GlobalContact related functions
+ */
+class GlobalContact
+{
+ /**
+ * @brief Search global contact table by nick or name
+ *
+ * @param string $search Name or nick
+ * @param string $mode Search mode (e.g. "community")
+ *
+ * @return array with search results
+ */
+ public static function searchByName($search, $mode = '')
+ {
+ if ($search) {
+ // check supported networks
+ if (Config::get('system', 'diaspora_enabled')) {
+ $diaspora = NETWORK_DIASPORA;
+ } else {
+ $diaspora = NETWORK_DFRN;
+ }
+
+ if (!Config::get('system', 'ostatus_disabled')) {
+ $ostatus = NETWORK_OSTATUS;
+ } else {
+ $ostatus = NETWORK_DFRN;
+ }
+
+ // check if we search only communities or every contact
+ if ($mode === "community") {
+ $extra_sql = " AND `community`";
+ } else {
+ $extra_sql = "";
+ }
+
+ $search .= "%";
+
+ $results = q(
+ "SELECT `contact`.`id` AS `cid`, `gcontact`.`url`, `gcontact`.`name`, `gcontact`.`nick`, `gcontact`.`photo`,
+ `gcontact`.`network`, `gcontact`.`keywords`, `gcontact`.`addr`, `gcontact`.`community`
+ FROM `gcontact`
+ LEFT JOIN `contact` ON `contact`.`nurl` = `gcontact`.`nurl`
+ AND `contact`.`uid` = %d AND NOT `contact`.`blocked`
+ AND NOT `contact`.`pending` AND `contact`.`rel` IN ('%s', '%s')
+ WHERE (`contact`.`id` > 0 OR (NOT `gcontact`.`hide` AND `gcontact`.`network` IN ('%s', '%s', '%s') AND
+ ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR
+ (`gcontact`.`updated` >= `gcontact`.`last_failure`)))) AND
+ (`gcontact`.`addr` LIKE '%s' OR `gcontact`.`name` LIKE '%s' OR `gcontact`.`nick` LIKE '%s') $extra_sql
+ GROUP BY `gcontact`.`nurl`
+ ORDER BY `gcontact`.`nurl` DESC
+ LIMIT 1000",
+ intval(local_user()),
+ dbesc(CONTACT_IS_SHARING),
+ dbesc(CONTACT_IS_FRIEND),
+ dbesc(NETWORK_DFRN),
+ dbesc($ostatus),
+ dbesc($diaspora),
+ dbesc(escape_tags($search)),
+ dbesc(escape_tags($search)),
+ dbesc(escape_tags($search))
+ );
+
+ return $results;
+ }
+ }
+
+ /**
+ * @brief Link the gcontact entry with user, contact and global contact
+ *
+ * @param integer $gcid Global contact ID
+ * @param integer $uid User ID
+ * @param integer $cid Contact ID
+ * @param integer $zcid Global Contact ID
+ * @return void
+ */
+ public static function link($gcid, $uid = 0, $cid = 0, $zcid = 0)
+ {
+ if ($gcid <= 0) {
+ return;
+ }
+
+ $r = q(
+ "SELECT * FROM `glink` WHERE `cid` = %d AND `uid` = %d AND `gcid` = %d AND `zcid` = %d LIMIT 1",
+ intval($cid),
+ intval($uid),
+ intval($gcid),
+ intval($zcid)
+ );
+
+ if (!DBM::is_result($r)) {
+ q(
+ "INSERT INTO `glink` (`cid`, `uid`, `gcid`, `zcid`, `updated`) VALUES (%d, %d, %d, %d, '%s') ",
+ intval($cid),
+ intval($uid),
+ intval($gcid),
+ intval($zcid),
+ dbesc(datetime_convert())
+ );
+ } else {
+ q(
+ "UPDATE `glink` SET `updated` = '%s' WHERE `cid` = %d AND `uid` = %d AND `gcid` = %d AND `zcid` = %d",
+ dbesc(datetime_convert()),
+ intval($cid),
+ intval($uid),
+ intval($gcid),
+ intval($zcid)
+ );
+ }
+ }
+
+ /**
+ * @brief Sanitize the given gcontact data
+ *
+ * @param array $gcontact array with gcontact data
+ * @throw Exception
+ *
+ * Generation:
+ * 0: No definition
+ * 1: Profiles on this server
+ * 2: Contacts of profiles on this server
+ * 3: Contacts of contacts of profiles on this server
+ * 4: ...
+ * @return array $gcontact
+ */
+ public static function sanitize($gcontact)
+ {
+ if ($gcontact['url'] == "") {
+ throw new Exception('URL is empty');
+ }
+
+ $urlparts = parse_url($gcontact['url']);
+ if (!isset($urlparts["scheme"])) {
+ throw new Exception("This (".$gcontact['url'].") doesn't seem to be an url.");
+ }
+
+ if (in_array($urlparts["host"], array("www.facebook.com", "facebook.com", "twitter.com", "identi.ca", "alpha.app.net"))) {
+ throw new Exception('Contact from a non federated network ignored. ('.$gcontact['url'].')');
+ }
+
+ // Don't store the statusnet connector as network
+ // We can't simply set this to NETWORK_OSTATUS since the connector could have fetched posts from friendica as well
+ if ($gcontact['network'] == NETWORK_STATUSNET) {
+ $gcontact['network'] = "";
+ }
+
+ // Assure that there are no parameter fragments in the profile url
+ if (in_array($gcontact['network'], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
+ $gcontact['url'] = self::cleanContactUrl($gcontact['url']);
+ }
+
+ $alternate = PortableContact::alternateOStatusUrl($gcontact['url']);
+
+ // The global contacts should contain the original picture, not the cached one
+ if (($gcontact['generation'] != 1) && stristr(normalise_link($gcontact['photo']), normalise_link(System::baseUrl()."/photo/"))) {
+ $gcontact['photo'] = "";
+ }
+
+ if (!isset($gcontact['network'])) {
+ $r = q(
+ "SELECT `network` FROM `contact` WHERE `uid` = 0 AND `nurl` = '%s' AND `network` != '' AND `network` != '%s' LIMIT 1",
+ dbesc(normalise_link($gcontact['url'])),
+ dbesc(NETWORK_STATUSNET)
+ );
+ if (DBM::is_result($r)) {
+ $gcontact['network'] = $r[0]["network"];
+ }
+
+ if (($gcontact['network'] == "") || ($gcontact['network'] == NETWORK_OSTATUS)) {
+ $r = q(
+ "SELECT `network`, `url` FROM `contact` WHERE `uid` = 0 AND `alias` IN ('%s', '%s') AND `network` != '' AND `network` != '%s' LIMIT 1",
+ dbesc($gcontact['url']),
+ dbesc(normalise_link($gcontact['url'])),
+ dbesc(NETWORK_STATUSNET)
+ );
+ if (DBM::is_result($r)) {
+ $gcontact['network'] = $r[0]["network"];
+ }
+ }
+ }
+
+ $gcontact['server_url'] = '';
+ $gcontact['network'] = '';
+
+ $x = q(
+ "SELECT * FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
+ dbesc(normalise_link($gcontact['url']))
+ );
+
+ if (DBM::is_result($x)) {
+ if (!isset($gcontact['network']) && ($x[0]["network"] != NETWORK_STATUSNET)) {
+ $gcontact['network'] = $x[0]["network"];
+ }
+ if ($gcontact['updated'] <= NULL_DATE) {
+ $gcontact['updated'] = $x[0]["updated"];
+ }
+ if (!isset($gcontact['server_url']) && (normalise_link($x[0]["server_url"]) != normalise_link($x[0]["url"]))) {
+ $gcontact['server_url'] = $x[0]["server_url"];
+ }
+ if (!isset($gcontact['addr'])) {
+ $gcontact['addr'] = $x[0]["addr"];
+ }
+ }
+
+ if ((!isset($gcontact['network']) || !isset($gcontact['name']) || !isset($gcontact['addr']) || !isset($gcontact['photo']) || !isset($gcontact['server_url']) || $alternate)
+ && PortableContact::reachable($gcontact['url'], $gcontact['server_url'], $gcontact['network'], false)
+ ) {
+ $data = Probe::uri($gcontact['url']);
+
+ if ($data["network"] == NETWORK_PHANTOM) {
+ throw new Exception('Probing for URL '.$gcontact['url'].' failed');
+ }
+
+ $orig_profile = $gcontact['url'];
+
+ $gcontact["server_url"] = $data["baseurl"];
+
+ $gcontact = array_merge($gcontact, $data);
+
+ if ($alternate && ($gcontact['network'] == NETWORK_OSTATUS)) {
+ // Delete the old entry - if it exists
+ $r = q("SELECT `id` FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($orig_profile)));
+ if (DBM::is_result($r)) {
+ q("DELETE FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($orig_profile)));
+ q("DELETE FROM `glink` WHERE `gcid` = %d", intval($r[0]["id"]));
+ }
+ }
+ }
+
+ if (!isset($gcontact['name']) || !isset($gcontact['photo'])) {
+ throw new Exception('No name and photo for URL '.$gcontact['url']);
+ }
+
+ if (!in_array($gcontact['network'], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_DIASPORA))) {
+ throw new Exception('No federated network ('.$gcontact['network'].') detected for URL '.$gcontact['url']);
+ }
+
+ if (!isset($gcontact['server_url'])) {
+ // We check the server url to be sure that it is a real one
+ $server_url = PortableContact::detectServer($gcontact['url']);
+
+ // We are now sure that it is a correct URL. So we use it in the future
+ if ($server_url != "") {
+ $gcontact['server_url'] = $server_url;
+ }
+ }
+
+ // The server URL doesn't seem to be valid, so we don't store it.
+ if (!PortableContact::checkServer($gcontact['server_url'], $gcontact['network'])) {
+ $gcontact['server_url'] = "";
+ }
+
+ return $gcontact;
+ }
+
+ /**
+ * @param integer $uid id
+ * @param integer $cid id
+ * @return integer
+ */
+ public static function countCommonFriends($uid, $cid)
+ {
+ $r = q(
+ "SELECT count(*) as `total`
+ FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
+ WHERE `glink`.`cid` = %d AND `glink`.`uid` = %d AND
+ ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR
+ (`gcontact`.`updated` >= `gcontact`.`last_failure`))
+ AND `gcontact`.`nurl` IN (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 and id != %d ) ",
+ intval($cid),
+ intval($uid),
+ intval($uid),
+ intval($cid)
+ );
+
+ // logger("countCommonFriends: $uid $cid {$r[0]['total']}");
+ if (DBM::is_result($r)) {
+ return $r[0]['total'];
+ }
+ return 0;
+ }
+
+ /**
+ * @param integer $uid id
+ * @param integer $zcid zcid
+ * @return integer
+ */
+ public static function countCommonFriendsZcid($uid, $zcid)
+ {
+ $r = q(
+ "SELECT count(*) as `total`
+ FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
+ where `glink`.`zcid` = %d
+ and `gcontact`.`nurl` in (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 ) ",
+ intval($zcid),
+ intval($uid)
+ );
+
+ if (DBM::is_result($r)) {
+ return $r[0]['total'];
+ }
+
+ return 0;
+ }
+
+ /**
+ * @param object $uid user
+ * @param object $cid cid
+ * @param integer $start optional, default 0
+ * @param integer $limit optional, default 9999
+ * @param boolean $shuffle optional, default false
+ * @return object
+ */
+ public static function commonFriends($uid, $cid, $start = 0, $limit = 9999, $shuffle = false)
+ {
+ if ($shuffle) {
+ $sql_extra = " order by rand() ";
+ } else {
+ $sql_extra = " order by `gcontact`.`name` asc ";
+ }
+
+ $r = q(
+ "SELECT `gcontact`.*, `contact`.`id` AS `cid`
+ FROM `glink`
+ INNER JOIN `gcontact` ON `glink`.`gcid` = `gcontact`.`id`
+ INNER JOIN `contact` ON `gcontact`.`nurl` = `contact`.`nurl`
+ WHERE `glink`.`cid` = %d and `glink`.`uid` = %d
+ AND `contact`.`uid` = %d AND `contact`.`self` = 0 AND `contact`.`blocked` = 0
+ AND `contact`.`hidden` = 0 AND `contact`.`id` != %d
+ AND ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))
+ $sql_extra LIMIT %d, %d",
+ intval($cid),
+ intval($uid),
+ intval($uid),
+ intval($cid),
+ intval($start),
+ intval($limit)
+ );
+
+ /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
+ return $r;
+ }
+
+ /**
+ * @param object $uid user
+ * @param object $zcid zcid
+ * @param integer $start optional, default 0
+ * @param integer $limit optional, default 9999
+ * @param boolean $shuffle optional, default false
+ * @return object
+ */
+ public static function commonFriendsZcid($uid, $zcid, $start = 0, $limit = 9999, $shuffle = false)
+ {
+ if ($shuffle) {
+ $sql_extra = " order by rand() ";
+ } else {
+ $sql_extra = " order by `gcontact`.`name` asc ";
+ }
+
+ $r = q(
+ "SELECT `gcontact`.*
+ FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
+ where `glink`.`zcid` = %d
+ and `gcontact`.`nurl` in (select nurl from contact where uid = %d and self = 0 and blocked = 0 and hidden = 0 )
+ $sql_extra limit %d, %d",
+ intval($zcid),
+ intval($uid),
+ intval($start),
+ intval($limit)
+ );
+
+ /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
+ return $r;
+ }
+
+ /**
+ * @param object $uid user
+ * @param object $cid cid
+ * @return integer
+ */
+ public static function countAllFriends($uid, $cid)
+ {
+ $r = q(
+ "SELECT count(*) as `total`
+ FROM `glink` INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
+ where `glink`.`cid` = %d and `glink`.`uid` = %d AND
+ ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))",
+ intval($cid),
+ intval($uid)
+ );
+
+ if (DBM::is_result($r)) {
+ return $r[0]['total'];
+ }
+
+ return 0;
+ }
+
+ /**
+ * @param object $uid user
+ * @param object $cid cid
+ * @param integer $start optional, default 0
+ * @param integer $limit optional, default 80
+ * @return object
+ */
+ public static function allFriends($uid, $cid, $start = 0, $limit = 80)
+ {
+ $r = q(
+ "SELECT `gcontact`.*, `contact`.`id` AS `cid`
+ FROM `glink`
+ INNER JOIN `gcontact` on `glink`.`gcid` = `gcontact`.`id`
+ LEFT JOIN `contact` ON `contact`.`nurl` = `gcontact`.`nurl` AND `contact`.`uid` = %d
+ WHERE `glink`.`cid` = %d AND `glink`.`uid` = %d AND
+ ((`gcontact`.`last_contact` >= `gcontact`.`last_failure`) OR (`gcontact`.`updated` >= `gcontact`.`last_failure`))
+ ORDER BY `gcontact`.`name` ASC LIMIT %d, %d ",
+ intval($uid),
+ intval($cid),
+ intval($uid),
+ intval($start),
+ intval($limit)
+ );
+
+ /// @TODO Check all calling-findings of this function if they properly use DBM::is_result()
+ return $r;
+ }
+
+ /**
+ * @param object $uid user
+ * @param integer $start optional, default 0
+ * @param integer $limit optional, default 80
+ * @return array
+ */
+ public static function suggestionQuery($uid, $start = 0, $limit = 80)
+ {
+ if (!$uid) {
+ return array();
+ }
+
+ /*
+ * Uncommented because the result of the queries are to big to store it in the cache.
+ * We need to decide if we want to change the db column type or if we want to delete it.
+ */
+ //$list = Cache::get("suggestion_query:".$uid.":".$start.":".$limit);
+ //if (!is_null($list)) {
+ // return $list;
+ //}
+
+ $network = array(NETWORK_DFRN);
+
+ if (Config::get('system', 'diaspora_enabled')) {
+ $network[] = NETWORK_DIASPORA;
+ }
+
+ if (!Config::get('system', 'ostatus_disabled')) {
+ $network[] = NETWORK_OSTATUS;
+ }
+
+ $sql_network = implode("', '", $network);
+ $sql_network = "'".$sql_network."'";
+
+ /// @todo This query is really slow
+ // By now we cache the data for five minutes
+ $r = q(
+ "SELECT count(glink.gcid) as `total`, gcontact.* from gcontact
+ INNER JOIN `glink` ON `glink`.`gcid` = `gcontact`.`id`
+ where uid = %d and not gcontact.nurl in ( select nurl from contact where uid = %d )
+ AND NOT `gcontact`.`name` IN (SELECT `name` FROM `contact` WHERE `uid` = %d)
+ AND NOT `gcontact`.`id` IN (SELECT `gcid` FROM `gcign` WHERE `uid` = %d)
+ AND `gcontact`.`updated` >= '%s'
+ AND `gcontact`.`last_contact` >= `gcontact`.`last_failure`
+ AND `gcontact`.`network` IN (%s)
+ GROUP BY `glink`.`gcid` ORDER BY `gcontact`.`updated` DESC,`total` DESC LIMIT %d, %d",
+ intval($uid),
+ intval($uid),
+ intval($uid),
+ intval($uid),
+ dbesc(NULL_DATE),
+ $sql_network,
+ intval($start),
+ intval($limit)
+ );
+
+ if (DBM::is_result($r) && count($r) >= ($limit -1)) {
+ /*
+ * Uncommented because the result of the queries are to big to store it in the cache.
+ * We need to decide if we want to change the db column type or if we want to delete it.
+ */
+ //Cache::set("suggestion_query:".$uid.":".$start.":".$limit, $r, CACHE_FIVE_MINUTES);
+
+ return $r;
+ }
+
+ $r2 = q(
+ "SELECT gcontact.* FROM gcontact
+ INNER JOIN `glink` ON `glink`.`gcid` = `gcontact`.`id`
+ WHERE `glink`.`uid` = 0 AND `glink`.`cid` = 0 AND `glink`.`zcid` = 0 AND NOT `gcontact`.`nurl` IN (SELECT `nurl` FROM `contact` WHERE `uid` = %d)
+ AND NOT `gcontact`.`name` IN (SELECT `name` FROM `contact` WHERE `uid` = %d)
+ AND NOT `gcontact`.`id` IN (SELECT `gcid` FROM `gcign` WHERE `uid` = %d)
+ AND `gcontact`.`updated` >= '%s'
+ AND `gcontact`.`last_contact` >= `gcontact`.`last_failure`
+ AND `gcontact`.`network` IN (%s)
+ ORDER BY rand() LIMIT %d, %d",
+ intval($uid),
+ intval($uid),
+ intval($uid),
+ dbesc(NULL_DATE),
+ $sql_network,
+ intval($start),
+ intval($limit)
+ );
+
+ $list = array();
+ foreach ($r2 as $suggestion) {
+ $list[$suggestion["nurl"]] = $suggestion;
+ }
+
+ foreach ($r as $suggestion) {
+ $list[$suggestion["nurl"]] = $suggestion;
+ }
+
+ while (sizeof($list) > ($limit)) {
+ array_pop($list);
+ }
+
+ /*
+ * Uncommented because the result of the queries are to big to store it in the cache.
+ * We need to decide if we want to change the db column type or if we want to delete it.
+ */
+ //Cache::set("suggestion_query:".$uid.":".$start.":".$limit, $list, CACHE_FIVE_MINUTES);
+ return $list;
+ }
+
+ /**
+ * @return void
+ */
+ public static function updateSuggestions()
+ {
+ $a = get_app();
+
+ $done = array();
+
+ /// @TODO Check if it is really neccessary to poll the own server
+ PortableContact::loadWorker(0, 0, 0, System::baseUrl() . '/poco');
+
+ $done[] = System::baseUrl() . '/poco';
+
+ if (strlen(Config::get('system', 'directory'))) {
+ $x = fetch_url(get_server()."/pubsites");
+ if ($x) {
+ $j = json_decode($x);
+ if ($j->entries) {
+ foreach ($j->entries as $entry) {
+ PortableContact::checkServer($entry->url);
+
+ $url = $entry->url . '/poco';
+ if (! in_array($url, $done)) {
+ PortableContact::loadWorker(0, 0, 0, $entry->url . '/poco');
+ }
+ }
+ }
+ }
+ }
+
+ // Query your contacts from Friendica and Redmatrix/Hubzilla for their contacts
+ $r = q(
+ "SELECT DISTINCT(`poco`) AS `poco` FROM `contact` WHERE `network` IN ('%s', '%s')",
+ dbesc(NETWORK_DFRN),
+ dbesc(NETWORK_DIASPORA)
+ );
+
+ if (DBM::is_result($r)) {
+ foreach ($r as $rr) {
+ $base = substr($rr['poco'], 0, strrpos($rr['poco'], '/'));
+ if (! in_array($base, $done)) {
+ PortableContact::loadWorker(0, 0, 0, $base);
+ }
+ }
+ }
+ }
+
+ /**
+ * @brief Removes unwanted parts from a contact url
+ *
+ * @param string $url Contact url
+ *
+ * @return string Contact url with the wanted parts
+ */
+ public static function cleanContactUrl($url)
+ {
+ $parts = parse_url($url);
+
+ if (!isset($parts["scheme"]) || !isset($parts["host"])) {
+ return $url;
+ }
+
+ $new_url = $parts["scheme"]."://".$parts["host"];
+
+ if (isset($parts["port"])) {
+ $new_url .= ":".$parts["port"];
+ }
+
+ if (isset($parts["path"])) {
+ $new_url .= $parts["path"];
+ }
+
+ if ($new_url != $url) {
+ logger("Cleaned contact url ".$url." to ".$new_url." - Called by: ".System::callstack(), LOGGER_DEBUG);
+ }
+
+ return $new_url;
+ }
+
+ /**
+ * @brief Replace alternate OStatus user format with the primary one
+ *
+ * @param arr $contact contact array (called by reference)
+ * @return void
+ */
+ public static function fixAlternateContactAddress(&$contact)
+ {
+ if (($contact["network"] == NETWORK_OSTATUS) && PortableContact::alternateOStatusUrl($contact["url"])) {
+ $data = Probe::uri($contact["url"]);
+ if ($contact["network"] == NETWORK_OSTATUS) {
+ logger("Fix primary url from ".$contact["url"]." to ".$data["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
+ $contact["url"] = $data["url"];
+ $contact["addr"] = $data["addr"];
+ $contact["alias"] = $data["alias"];
+ $contact["server_url"] = $data["baseurl"];
+ }
+ }
+ }
+
+ /**
+ * @brief Fetch the gcontact id, add an entry if not existed
+ *
+ * @param arr $contact contact array
+ *
+ * @return bool|int Returns false if not found, integer if contact was found
+ */
+ public static function getId($contact)
+ {
+ $gcontact_id = 0;
+ $doprobing = false;
+
+ if (in_array($contact["network"], array(NETWORK_PHANTOM))) {
+ logger("Invalid network for contact url ".$contact["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
+ return false;
+ }
+
+ if ($contact["network"] == NETWORK_STATUSNET) {
+ $contact["network"] = NETWORK_OSTATUS;
+ }
+
+ // All new contacts are hidden by default
+ if (!isset($contact["hide"])) {
+ $contact["hide"] = true;
+ }
+
+ // Replace alternate OStatus user format with the primary one
+ self::fixAlternateContactAddress($contact);
+
+ // Remove unwanted parts from the contact url (e.g. "?zrl=...")
+ if (in_array($contact["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
+ $contact["url"] = self::cleanContactUrl($contact["url"]);
+ }
+
+ dba::lock('gcontact');
+ $r = q(
+ "SELECT `id`, `last_contact`, `last_failure`, `network` FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
+ dbesc(normalise_link($contact["url"]))
+ );
+
+ if (DBM::is_result($r)) {
+ $gcontact_id = $r[0]["id"];
+
+ // Update every 90 days
+ if (in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
+ $last_failure_str = $r[0]["last_failure"];
+ $last_failure = strtotime($r[0]["last_failure"]);
+ $last_contact_str = $r[0]["last_contact"];
+ $last_contact = strtotime($r[0]["last_contact"]);
+ $doprobing = (((time() - $last_contact) > (90 * 86400)) && ((time() - $last_failure) > (90 * 86400)));
+ }
+ } else {
+ q(
+ "INSERT INTO `gcontact` (`name`, `nick`, `addr` , `network`, `url`, `nurl`, `photo`, `created`, `updated`, `location`, `about`, `hide`, `generation`)
+ VALUES ('%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d, %d)",
+ dbesc($contact["name"]),
+ dbesc($contact["nick"]),
+ dbesc($contact["addr"]),
+ dbesc($contact["network"]),
+ dbesc($contact["url"]),
+ dbesc(normalise_link($contact["url"])),
+ dbesc($contact["photo"]),
+ dbesc(datetime_convert()),
+ dbesc(datetime_convert()),
+ dbesc($contact["location"]),
+ dbesc($contact["about"]),
+ intval($contact["hide"]),
+ intval($contact["generation"])
+ );
+
+ $r = q(
+ "SELECT `id`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 2",
+ dbesc(normalise_link($contact["url"]))
+ );
+
+ if (DBM::is_result($r)) {
+ $gcontact_id = $r[0]["id"];
+
+ $doprobing = in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""));
+ }
+ }
+ dba::unlock();
+
+ if ($doprobing) {
+ logger("Last Contact: ". $last_contact_str." - Last Failure: ".$last_failure_str." - Checking: ".$contact["url"], LOGGER_DEBUG);
+ Worker::add(PRIORITY_LOW, 'GProbe', $contact["url"]);
+ }
+
+ return $gcontact_id;
+ }
+
+ /**
+ * @brief Updates the gcontact table from a given array
+ *
+ * @param arr $contact contact array
+ *
+ * @return bool|int Returns false if not found, integer if contact was found
+ */
+ public static function update($contact)
+ {
+ // Check for invalid "contact-type" value
+ if (isset($contact['contact-type']) && (intval($contact['contact-type']) < 0)) {
+ $contact['contact-type'] = 0;
+ }
+
+ /// @todo update contact table as well
+
+ $gcontact_id = self::getId($contact);
+
+ if (!$gcontact_id) {
+ return false;
+ }
+
+ $r = q(
+ "SELECT `name`, `nick`, `photo`, `location`, `about`, `addr`, `generation`, `birthday`, `gender`, `keywords`,
+ `contact-type`, `hide`, `nsfw`, `network`, `alias`, `notify`, `server_url`, `connect`, `updated`, `url`
+ FROM `gcontact` WHERE `id` = %d LIMIT 1",
+ intval($gcontact_id)
+ );
+
+ // Get all field names
+ $fields = array();
+ foreach ($r[0] as $field => $data) {
+ $fields[$field] = $data;
+ }
+
+ unset($fields["url"]);
+ unset($fields["updated"]);
+ unset($fields["hide"]);
+
+ // Bugfix: We had an error in the storing of keywords which lead to the "0"
+ // This value is still transmitted via poco.
+ if ($contact["keywords"] == "0") {
+ unset($contact["keywords"]);
+ }
+
+ if ($r[0]["keywords"] == "0") {
+ $r[0]["keywords"] = "";
+ }
+
+ // assign all unassigned fields from the database entry
+ foreach ($fields as $field => $data) {
+ if (!isset($contact[$field]) || ($contact[$field] == "")) {
+ $contact[$field] = $r[0][$field];
+ }
+ }
+
+ if (!isset($contact["hide"])) {
+ $contact["hide"] = $r[0]["hide"];
+ }
+
+ $fields["hide"] = $r[0]["hide"];
+
+ if ($contact["network"] == NETWORK_STATUSNET) {
+ $contact["network"] = NETWORK_OSTATUS;
+ }
+
+ // Replace alternate OStatus user format with the primary one
+ self::fixAlternateContactAddress($contact);
+
+ if (!isset($contact["updated"])) {
+ $contact["updated"] = DBM::date();
+ }
+
+ if ($contact["network"] == NETWORK_TWITTER) {
+ $contact["server_url"] = 'http://twitter.com';
+ }
+
+ if ($contact["server_url"] == "") {
+ $data = Probe::uri($contact["url"]);
+ if ($data["network"] != NETWORK_PHANTOM) {
+ $contact["server_url"] = $data['baseurl'];
+ }
+ } else {
+ $contact["server_url"] = normalise_link($contact["server_url"]);
+ }
+
+ if (($contact["addr"] == "") && ($contact["server_url"] != "") && ($contact["nick"] != "")) {
+ $hostname = str_replace("http://", "", $contact["server_url"]);
+ $contact["addr"] = $contact["nick"]."@".$hostname;
+ }
+
+ // Check if any field changed
+ $update = false;
+ unset($fields["generation"]);
+
+ if ((($contact["generation"] > 0) && ($contact["generation"] <= $r[0]["generation"])) || ($r[0]["generation"] == 0)) {
+ foreach ($fields as $field => $data) {
+ if ($contact[$field] != $r[0][$field]) {
+ logger("Difference for contact ".$contact["url"]." in field '".$field."'. New value: '".$contact[$field]."', old value '".$r[0][$field]."'", LOGGER_DEBUG);
+ $update = true;
+ }
+ }
+
+ if ($contact["generation"] < $r[0]["generation"]) {
+ logger("Difference for contact ".$contact["url"]." in field 'generation'. new value: '".$contact["generation"]."', old value '".$r[0]["generation"]."'", LOGGER_DEBUG);
+ $update = true;
+ }
+ }
+
+ if ($update) {
+ logger("Update gcontact for ".$contact["url"], LOGGER_DEBUG);
+ $condition = array('`nurl` = ? AND (`generation` = 0 OR `generation` >= ?)',
+ normalise_link($contact["url"]), $contact["generation"]);
+ $contact["updated"] = DBM::date($contact["updated"]);
+
+ $updated = array('photo' => $contact['photo'], 'name' => $contact['name'],
+ 'nick' => $contact['nick'], 'addr' => $contact['addr'],
+ 'network' => $contact['network'], 'birthday' => $contact['birthday'],
+ 'gender' => $contact['gender'], 'keywords' => $contact['keywords'],
+ 'hide' => $contact['hide'], 'nsfw' => $contact['nsfw'],
+ 'contact-type' => $contact['contact-type'], 'alias' => $contact['alias'],
+ 'notify' => $contact['notify'], 'url' => $contact['url'],
+ 'location' => $contact['location'], 'about' => $contact['about'],
+ 'generation' => $contact['generation'], 'updated' => $contact['updated'],
+ 'server_url' => $contact['server_url'], 'connect' => $contact['connect']);
+
+ dba::update('gcontact', $updated, $condition, $fields);
+
+ // Now update the contact entry with the user id "0" as well.
+ // This is used for the shadow copies of public items.
+ $r = q(
+ "SELECT `id` FROM `contact` WHERE `nurl` = '%s' AND `uid` = 0 ORDER BY `id` LIMIT 1",
+ dbesc(normalise_link($contact["url"]))
+ );
+
+ if (DBM::is_result($r)) {
+ logger("Update public contact ".$r[0]["id"], LOGGER_DEBUG);
+
+ update_contact_avatar($contact["photo"], 0, $r[0]["id"]);
+
+ $fields = array('name', 'nick', 'addr',
+ 'network', 'bd', 'gender',
+ 'keywords', 'alias', 'contact-type',
+ 'url', 'location', 'about');
+ $old_contact = dba::select('contact', $fields, array('id' => $r[0]["id"]), array('limit' => 1));
+
+ // Update it with the current values
+ $fields = array('name' => $contact['name'], 'nick' => $contact['nick'],
+ 'addr' => $contact['addr'], 'network' => $contact['network'],
+ 'bd' => $contact['birthday'], 'gender' => $contact['gender'],
+ 'keywords' => $contact['keywords'], 'alias' => $contact['alias'],
+ 'contact-type' => $contact['contact-type'], 'url' => $contact['url'],
+ 'location' => $contact['location'], 'about' => $contact['about']);
+
+ dba::update('contact', $fields, array('id' => $r[0]["id"]), $old_contact);
+ }
+ }
+
+ return $gcontact_id;
+ }
+
+ /**
+ * @brief Updates the gcontact entry from probe
+ *
+ * @param str $url profile link
+ * @return void
+ */
+ public static function updateFromProbe($url)
+ {
+ $data = Probe::uri($url);
+
+ if (in_array($data["network"], array(NETWORK_PHANTOM))) {
+ logger("Invalid network for contact url ".$data["url"]." - Called by: ".System::callstack(), LOGGER_DEBUG);
+ return;
+ }
+
+ $data["server_url"] = $data["baseurl"];
+
+ self::update($data);
+ }
+
+ /**
+ * @brief Update the gcontact entry for a given user id
+ *
+ * @param int $uid User ID
+ * @return void
+ */
+ public static function updateForUser($uid)
+ {
+ $r = q(
+ "SELECT `profile`.`locality`, `profile`.`region`, `profile`.`country-name`,
+ `profile`.`name`, `profile`.`about`, `profile`.`gender`,
+ `profile`.`pub_keywords`, `profile`.`dob`, `profile`.`photo`,
+ `profile`.`net-publish`, `user`.`nickname`, `user`.`hidewall`,
+ `contact`.`notify`, `contact`.`url`, `contact`.`addr`
+ FROM `profile`
+ INNER JOIN `user` ON `user`.`uid` = `profile`.`uid`
+ INNER JOIN `contact` ON `contact`.`uid` = `profile`.`uid`
+ WHERE `profile`.`uid` = %d AND `profile`.`is-default` AND `contact`.`self`",
+ intval($uid)
+ );
+
+ $location = Profile::formatLocation(
+ array("locality" => $r[0]["locality"], "region" => $r[0]["region"], "country-name" => $r[0]["country-name"])
+ );
+
+ // The "addr" field was added in 3.4.3 so it can be empty for older users
+ if ($r[0]["addr"] != "") {
+ $addr = $r[0]["nickname"].'@'.str_replace(array("http://", "https://"), "", System::baseUrl());
+ } else {
+ $addr = $r[0]["addr"];
+ }
+
+ $gcontact = array("name" => $r[0]["name"], "location" => $location, "about" => $r[0]["about"],
+ "gender" => $r[0]["gender"], "keywords" => $r[0]["pub_keywords"],
+ "birthday" => $r[0]["dob"], "photo" => $r[0]["photo"],
+ "notify" => $r[0]["notify"], "url" => $r[0]["url"],
+ "hide" => ($r[0]["hidewall"] || !$r[0]["net-publish"]),
+ "nick" => $r[0]["nickname"], "addr" => $addr,
+ "connect" => $addr, "server_url" => System::baseUrl(),
+ "generation" => 1, "network" => NETWORK_DFRN);
+
+ self::update($gcontact);
+ }
+
+ /**
+ * @brief Fetches users of given GNU Social server
+ *
+ * If the "Statistics" plugin is enabled (See http://gstools.org/ for details) we query user data with this.
+ *
+ * @param str $server Server address
+ * @return void
+ */
+ public static function fetchGsUsers($server)
+ {
+ logger("Fetching users from GNU Social server ".$server, LOGGER_DEBUG);
+
+ $url = $server."/main/statistics";
+
+ $result = z_fetch_url($url);
+ if (!$result["success"]) {
+ return false;
+ }
+
+ $statistics = json_decode($result["body"]);
+
+ if (is_object($statistics->config)) {
+ if ($statistics->config->instance_with_ssl) {
+ $server = "https://";
+ } else {
+ $server = "http://";
+ }
+
+ $server .= $statistics->config->instance_address;
+
+ $hostname = $statistics->config->instance_address;
+ } else {
+ /// @TODO is_object() above means here no object, still $statistics is being used as object
+ if ($statistics->instance_with_ssl) {
+ $server = "https://";
+ } else {
+ $server = "http://";
+ }
+
+ $server .= $statistics->instance_address;
+
+ $hostname = $statistics->instance_address;
+ }
+
+ if (is_object($statistics->users)) {
+ foreach ($statistics->users as $nick => $user) {
+ $profile_url = $server."/".$user->nickname;
+
+ $contact = array("url" => $profile_url,
+ "name" => $user->fullname,
+ "addr" => $user->nickname."@".$hostname,
+ "nick" => $user->nickname,
+ "about" => $user->bio,
+ "network" => NETWORK_OSTATUS,
+ "photo" => System::baseUrl()."/images/person-175.jpg");
+ self::getId($contact);
+ }
+ }
+ }
+
+ /**
+ * @brief Asking GNU Social server on a regular base for their user data
+ * @return void
+ */
+ public static function discoverGsUsers()
+ {
+ $requery_days = intval(Config::get("system", "poco_requery_days"));
+
+ $last_update = date("c", time() - (60 * 60 * 24 * $requery_days));
+
+ $r = q(
+ "SELECT `nurl`, `url` FROM `gserver` WHERE `last_contact` >= `last_failure` AND `network` = '%s' AND `last_poco_query` < '%s' ORDER BY RAND() LIMIT 5",
+ dbesc(NETWORK_OSTATUS),
+ dbesc($last_update)
+ );
+
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ foreach ($r as $server) {
+ self::fetchGsUsers($server["url"]);
+ q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
+ }
+ }
+
+ /**
+ * @return string
+ */
+ public static function getRandomUrl()
+ {
+ $r = q(
+ "SELECT `url` FROM `gcontact` WHERE `network` = '%s'
+ AND `last_contact` >= `last_failure`
+ AND `updated` > UTC_TIMESTAMP - INTERVAL 1 MONTH
+ ORDER BY rand() LIMIT 1",
+ dbesc(NETWORK_DFRN)
+ );
+
+ if (DBM::is_result($r)) {
+ return dirname($r[0]['url']);
+ }
+
+ return '';
+ }
+}
--- /dev/null
+<?php
+
+/**
+ * @file src/Model/User.php
+ * @brief This file includes the User class with user related database functions
+ */
+
+namespace Friendica\Model;
+
+use Friendica\Core\System;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use dba;
+
+require_once 'boot.php';
+require_once 'include/plugin.php';
+
+/**
+ * @brief This class handles User related functions
+ */
+class User
+{
+ public static function authenticate($user_info, $password)
+ {
+ if (is_object($user_info)) {
+ $user = (array) $user_info;
+ } elseif (is_int($user_info)) {
+ $user = dba::select('user',
+ ['uid', 'password'],
+ [
+ 'uid' => $user_info,
+ 'blocked' => 0,
+ 'account_expired' => 0,
+ 'account_removed' => 0,
+ 'verified' => 1
+ ],
+ ['limit' => 1]
+ );
+ } elseif (is_string($user_info)) {
+ $user = dba::fetch_first('SELECT `uid`, `password`
+ FROM `user`
+ WHERE (`email` = ? OR `username` = ? OR `nickname` = ?)
+ AND `blocked` = 0
+ AND `account_expired` = 0
+ AND `account_removed` = 0
+ AND `verified` = 1
+ LIMIT 1',
+ $user_info,
+ $user_info,
+ $user_info
+ );
+ } else {
+ $user = $user_info;
+ }
+
+ if (!DBM::is_result($user) || !isset($user['uid']) || !isset($user['password'])) {
+ return false;
+ }
+
+ $password_hashed = hash('whirlpool', $password);
+
+ if ($password_hashed !== $user['password']) {
+ return false;
+ }
+
+ return $user['uid'];
+ }
+
+ /**
+ * @param object $uid user to remove
+ * @return void
+ */
+ public static function remove($uid)
+ {
+ if (!$uid) {
+ return;
+ }
+
+ logger('Removing user: ' . $uid);
+
+ $user = dba::select('user', [], ['uid' => $uid], ['limit' => 1]);
+
+ call_hooks('remove_user', $user);
+
+ // save username (actually the nickname as it is guaranteed
+ // unique), so it cannot be re-registered in the future.
+ dba::insert('userd', ['username' => $user['nickname']]);
+
+ // The user and related data will be deleted in "cron_expire_and_remove_users" (cronjobs.php)
+ dba::update('user', ['account_removed' => true, 'account_expires_on' => datetime_convert()], ['uid' => $uid]);
+ Worker::add(PRIORITY_HIGH, "Notifier", "removeme", $uid);
+
+ // Send an update to the directory
+ Worker::add(PRIORITY_LOW, "Directory", $user['url']);
+
+ if ($uid == local_user()) {
+ unset($_SESSION['authenticated']);
+ unset($_SESSION['uid']);
+ goaway(System::baseUrl());
+ }
+ }
+}
--- /dev/null
+<?php\r
+\r
+/**\r
+ * Throwable exceptions to return HTTP status code\r
+ *\r
+ * This list of Exception has be extracted from\r
+ * here http://racksburg.com/choosing-an-http-status-code/\r
+ */\r
+\r
+namespace Friendica\Network;\r
+\r
+use Exception;\r
+\r
+class HTTPException extends Exception\r
+{\r
+ var $httpcode = 200;\r
+ var $httpdesc = "";\r
+\r
+ public function __construct($message = '', $code = 0, Exception $previous = null)\r
+ {\r
+ if ($this->httpdesc == '') {\r
+ $classname = str_replace('Exception', '', str_replace('Friendica\Network\HTTPException\\', '', get_class($this)));\r
+ $this->httpdesc = preg_replace("|([a-z])([A-Z])|",'$1 $2', $classname);\r
+ }\r
+ parent::__construct($message, $code, $previous);\r
+ }\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class BadGatewayException extends HTTPException\r
+{\r
+ var $httpcode = 502;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class BadRequestException extends HTTPException\r
+{\r
+ var $httpcode = 400;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class ConflictException extends HTTPException\r
+{\r
+ var $httpcode = 409;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class ExpectationFailedException extends HTTPException\r
+{\r
+ var $httpcode = 417;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class ForbiddenException extends HTTPException\r
+{\r
+ var $httpcode = 403;\r
+}
\ No newline at end of file
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class GatewayTimeoutException extends HTTPException\r
+{\r
+ var $httpcode = 504;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class GoneException extends HTTPException\r
+{\r
+ var $httpcode = 410;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class ImATeapotException extends HTTPException\r
+{\r
+ var $httpcode = 418;\r
+ var $httpdesc = "I'm A Teapot";\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class InternalServerErrorException extends HTTPException\r
+{\r
+ var $httpcode = 500;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class LenghtRequiredException extends HTTPException\r
+{\r
+ var $httpcode = 411;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class MethodNotAllowedException extends HTTPException\r
+{\r
+ var $httpcode = 405;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class NonAcceptableException extends HTTPException\r
+{\r
+ var $httpcode = 406;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class NotFoundException extends HTTPException {\r
+ var $httpcode = 404;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class NotImplementedException extends HTTPException\r
+{\r
+ var $httpcode = 501;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class PreconditionFailedException extends HTTPException\r
+{\r
+ var $httpcode = 412;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class ServiceUnavaiableException extends HTTPException\r
+{\r
+ var $httpcode = 503;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class TooManyRequestsException extends HTTPException\r
+{\r
+ var $httpcode = 429;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class UnauthorizedException extends HTTPException\r
+{\r
+ var $httpcode = 401;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class UnprocessableEntityException extends HTTPException\r
+{\r
+ var $httpcode = 422;\r
+}\r
--- /dev/null
+<?php\r
+\r
+namespace Friendica\Network\HTTPException;\r
+\r
+use Friendica\Network\HTTPException;\r
+\r
+class UnsupportedMediaTypeException extends HTTPException\r
+{\r
+ var $httpcode = 415;\r
+}\r
<?php
-
+/**
+ * @file src/Network/Probe.php
+ */
namespace Friendica\Network;
/**
* @file src/Network/Probe.php
* @brief Functions for probing URL
- *
*/
use Friendica\App;
use Friendica\Core\Cache;
use Friendica\Core\Config;
use Friendica\Database\DBM;
+use Friendica\Object\Profile;
use Friendica\Util\XML;
use dba;
* @brief This class contain functions for probing URL
*
*/
-class Probe {
-
+class Probe
+{
private static $baseurl;
/**
*
* @return array Ordered data
*/
- private static function rearrangeData($data) {
+ private static function rearrangeData($data)
+ {
$fields = array("name", "nick", "guid", "url", "addr", "alias",
"photo", "community", "keywords", "location", "about",
"batch", "notify", "poll", "request", "confirm", "poco",
*
* @return bool Does the testes hostname belongs to the own server?
*/
- private static function ownHost($host) {
+ private static function ownHost($host)
+ {
$own_host = get_app()->get_hostname();
$parts = parse_url($host);
*
* @return array with template and type of the webfinger template for JSON or XML
*/
- private static function hostMeta($host) {
-
+ private static function hostMeta($host)
+ {
// Reset the static variable
self::$baseurl = '';
return array();
}
- $links = XML::element_to_array($xrd);
+ $links = XML::elementToArray($xrd);
if (!isset($links["xrd"]["link"])) {
logger("No xrd data found for ".$host, LOGGER_DEBUG);
return array();
* amended 7/9/2011 to return an hcard which could save potentially loading
* a lengthy content page to scrape dfrn attributes
*
- * @param string $webbie Address that should be probed
+ * @param string $webbie Address that should be probed
* @param string $hcard_url Link to the hcard - is returned by reference
*
* @return string profile link
*/
- public static function webfingerDfrn($webbie, &$hcard_url) {
-
+ public static function webfingerDfrn($webbie, &$hcard_url)
+ {
$profile_link = '';
$links = self::lrdd($webbie);
*
* @return array uri data
*/
- public static function lrdd($uri) {
-
+ public static function lrdd($uri)
+ {
$lrdd = self::hostMeta($uri);
$webfinger = null;
return array();
}
- foreach ($lrdd AS $type => $template) {
+ foreach ($lrdd as $type => $template) {
if ($webfinger) {
continue;
}
/**
* @brief Fetch information (protocol endpoints and user information) about a given uri
*
- * @param string $uri Address that should be probed
- * @param string $network Test for this specific network
- * @param integer $uid User ID for the probe (only used for mails)
- * @param boolean $cache Use cached values?
+ * @param string $uri Address that should be probed
+ * @param string $network Test for this specific network
+ * @param integer $uid User ID for the probe (only used for mails)
+ * @param boolean $cache Use cached values?
*
* @return array uri data
*/
- public static function uri($uri, $network = "", $uid = -1, $cache = true) {
-
+ public static function uri($uri, $network = "", $uid = -1, $cache = true)
+ {
if ($cache) {
$result = Cache::get("Probe::uri:".$network.":".$uri);
if (!is_null($result)) {
$fieldnames = array();
- foreach ($fields AS $key => $val) {
+ foreach ($fields as $key => $val) {
if (empty($val)) {
unset($fields[$key]);
} else {
$fieldnames = array();
- foreach ($fields AS $key => $val) {
+ foreach ($fields as $key => $val) {
if (empty($val)) {
unset($fields[$key]);
} else {
*
* @return string switched URL
*/
- private static function switchScheme($url) {
+ private static function switchScheme($url)
+ {
$parts = parse_url($url);
if (!isset($parts['scheme'])) {
/**
* @brief Checks if a profile url should be OStatus but only provides partial information
*
- * @param array $webfinger Webfinger data
- * @param string $lrdd Path template for webfinger request
+ * @param array $webfinger Webfinger data
+ * @param string $lrdd Path template for webfinger request
+ * @param string $type type
*
* @return array fixed webfinger data
*/
- private static function fixOstatus($webfinger, $lrdd, $type) {
+ private static function fixOStatus($webfinger, $lrdd, $type)
+ {
if (empty($webfinger['links']) || empty($webfinger['subject'])) {
return $webfinger;
}
*
* This function is only called by the "uri" function that adds caching and rearranging of data.
*
- * @param string $uri Address that should be probed
- * @param string $network Test for this specific network
- * @param integer $uid User ID for the probe (only used for mails)
+ * @param string $uri Address that should be probed
+ * @param string $network Test for this specific network
+ * @param integer $uid User ID for the probe (only used for mails)
*
* @return array uri data
*/
- private static function detect($uri, $network, $uid) {
+ private static function detect($uri, $network, $uid)
+ {
$parts = parse_url($uri);
if (!empty($parts["scheme"]) && !empty($parts["host"]) && !empty($parts["path"])) {
$nick = ltrim($nick, '@');
$addr = $nick."@".$host;
-
} elseif (strstr($uri, '@')) {
// If the URI starts with "mailto:" then jump directly to the mail detection
if (strpos($uri, 'mailto:') !== false) {
return self::mail($uri, $uid);
}
$addr = $uri;
-
} else {
logger("Uri ".$uri." was not detectable", LOGGER_DEBUG);
return false;
/// @todo Do we need the prefix "acct:" or "acct://"?
- foreach ($lrdd AS $type => $template) {
+ foreach ($lrdd as $type => $template) {
if ($webfinger) {
continue;
}
$webfinger = self::webfinger($path, $type);
// Fix possible problems with GNU Social probing to wrong scheme
- $webfinger = self::fixOstatus($webfinger, $template, $type);
+ $webfinger = self::fixOStatus($webfinger, $template, $type);
// We cannot be sure that the detected address was correct, so we don't use the values
if ($webfinger && ($uri != $addr)) {
*
* For details see RFC 7033: <https://tools.ietf.org/html/rfc7033>
*
- * @param string $url Address that should be probed
+ * @param string $url Address that should be probed
+ * @param string $type type
*
* @return array webfinger data
*/
- private static function webfinger($url, $type) {
-
+ private static function webfinger($url, $type)
+ {
$xrd_timeout = Config::get('system', 'xrd_timeout', 20);
$redirects = 0;
$ret = z_fetch_url($url, false, $redirects, array('timeout' => $xrd_timeout, 'accept_content' => $type));
- if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
+ if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
return false;
}
$data = $ret['body'];
return false;
}
- $xrd_arr = XML::element_to_array($xrd);
+ $xrd_arr = XML::elementToArray($xrd);
if (!isset($xrd_arr["xrd"]["link"])) {
logger("No XML webfinger links for ".$url, LOGGER_DEBUG);
return false;
* This functionality was originally created for the directory.
*
* @param string $noscrape_url Link to the noscrape page
- * @param array $data The already fetched data
+ * @param array $data The already fetched data
*
* @return array noscrape data
*/
- private static function pollNoscrape($noscrape_url, $data) {
+ private static function pollNoscrape($noscrape_url, $data)
+ {
$ret = z_fetch_url($noscrape_url);
if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
return false;
}
}
- $location = formatted_location($json);
+ $location = Profile::formatLocation($json);
if ($location) {
$data["location"] = $location;
}
*
* @return int Number of errors
*/
- public static function validDfrn($data) {
+ public static function validDfrn($data)
+ {
$errors = 0;
if (!isset($data['key'])) {
$errors ++;
*
* @return array profile data
*/
- public static function profile($profile_link) {
-
+ public static function profile($profile_link)
+ {
$data = array();
logger("Check profile ".$profile_link, LOGGER_DEBUG);
*
* @return array DFRN data
*/
- private static function dfrn($webfinger) {
+ private static function dfrn($webfinger)
+ {
$hcard_url = "";
$data = array();
foreach ($webfinger["links"] as $link) {
/**
* @brief Poll the hcard page (Diaspora and Friendica specific)
*
- * @param string $hcard_url Link to the hcard page
- * @param array $data The already fetched data
- * @param boolean $dfrn Poll DFRN specific data
+ * @param string $hcard_url Link to the hcard page
+ * @param array $data The already fetched data
+ * @param boolean $dfrn Poll DFRN specific data
*
* @return array hcard data
*/
- private static function pollHcard($hcard_url, $data, $dfrn = false) {
+ private static function pollHcard($hcard_url, $data, $dfrn = false)
+ {
$ret = z_fetch_url($hcard_url);
if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
return false;
*
* @return array Diaspora data
*/
- private static function diaspora($webfinger) {
+ private static function diaspora($webfinger)
+ {
$hcard_url = "";
$data = array();
foreach ($webfinger["links"] as $link) {
* @brief Check for OStatus contact
*
* @param array $webfinger Webfinger data
- * @param bool $short Short detection mode
+ * @param bool $short Short detection mode
*
* @return array|bool OStatus data or "false" on error or "true" on short mode
*/
- private static function ostatus($webfinger, $short = false) {
+ private static function ostatus($webfinger, $short = false)
+ {
$data = array();
if (is_array($webfinger["aliases"])) {
}
}
- if (is_string($webfinger["subject"]) && strstr($webfinger["subject"], "@") &&
- !strstr(normalise_link($webfinger["subject"]), "http://")) {
+ if (is_string($webfinger["subject"]) && strstr($webfinger["subject"], "@")
+ && !strstr(normalise_link($webfinger["subject"]), "http://")
+ ) {
$data["addr"] = str_replace('acct:', '', $webfinger["subject"]);
}
*
* @return array profile data
*/
- private static function pumpioProfileData($profile_link) {
-
+ private static function pumpioProfileData($profile_link)
+ {
$doc = new DOMDocument();
if (!@$doc->loadHTMLFile($profile_link)) {
return false;
*
* @return array pump.io data
*/
- private static function pumpio($webfinger) {
-
+ private static function pumpio($webfinger)
+ {
$data = array();
foreach ($webfinger["links"] as $link) {
if (($link["rel"] == "http://webfinger.net/rel/profile-page")
*
* @return string feed link
*/
- private static function getFeedLink($url) {
+ private static function getFeedLink($url)
+ {
$doc = new DOMDocument();
if (!@$doc->loadHTMLFile($url)) {
/**
* @brief Check for feed contact
*
- * @param string $url Profile link
+ * @param string $url Profile link
* @param boolean $probe Do a probe if the page contains a feed link
*
* @return array feed data
*/
- private static function feed($url, $probe = true) {
+ private static function feed($url, $probe = true)
+ {
$ret = z_fetch_url($url);
if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
return false;
/**
* @brief Check for mail contact
*
- * @param string $uri Profile link
+ * @param string $uri Profile link
* @param integer $uid User ID
*
* @return array mail data
*/
- private static function mail($uri, $uid) {
-
+ private static function mail($uri, $uid)
+ {
if (!validate_email($uri)) {
return false;
}
* @brief Mix two paths together to possibly fix missing parts
*
* @param string $avatar Path to the avatar
- * @param string $base Another path that is hopefully complete
+ * @param string $base Another path that is hopefully complete
*
* @return string fixed avatar path
*/
- public static function fixAvatar($avatar, $base) {
+ public static function fixAvatar($avatar, $base)
+ {
$base_parts = parse_url($base);
// Remove all parts that could create a problem
--- /dev/null
+<?php
+
+/**
+ * @file src/Object/Contact.php
+ */
+
+namespace Friendica\Object;
+
+use Friendica\App;
+use Friendica\BaseObject;
+use Friendica\Core\PConfig;
+use Friendica\Core\System;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+use Friendica\Protocol\Diaspora;
+use Friendica\Protocol\DFRN;
+use Friendica\Protocol\OStatus;
+use dba;
+
+require_once 'boot.php';
+require_once 'include/text.php';
+
+/**
+ * @brief functions for interacting with a contact
+ */
+class Contact extends BaseObject
+{
+ /**
+ * @brief Marks a contact for removal
+ *
+ * @param int $id contact id
+ * @return null
+ */
+ public static function remove($id)
+ {
+ // We want just to make sure that we don't delete our "self" contact
+ $r = dba::select('contact', array('uid'), array('id' => $id, 'self' => false), array('limit' => 1));
+
+ if (!DBM::is_result($r) || !intval($r['uid'])) {
+ return;
+ }
+
+ $archive = PConfig::get($r['uid'], 'system', 'archive_removed_contacts');
+ if ($archive) {
+ dba::update('contact', array('archive' => true, 'network' => 'none', 'writable' => false), array('id' => $id));
+ return;
+ }
+
+ dba::delete('contact', array('id' => $id));
+
+ // Delete the rest in the background
+ Worker::add(PRIORITY_LOW, 'RemoveContact', $id);
+ }
+
+ /**
+ * @brief Sends an unfriend message. Does not remove the contact
+ *
+ * @param array $user User unfriending
+ * @param array $contact Contact unfriended
+ * @return void
+ */
+ public static function terminateFriendship(array $user, array $contact)
+ {
+ if ($contact['network'] === NETWORK_OSTATUS) {
+ // create an unfollow slap
+ $item = array();
+ $item['verb'] = NAMESPACE_OSTATUS . "/unfollow";
+ $item['follow'] = $contact["url"];
+ $slap = OStatus::salmon($item, $user);
+
+ if ((x($contact, 'notify')) && (strlen($contact['notify']))) {
+ require_once 'include/salmon.php';
+ slapper($user, $contact['notify'], $slap);
+ }
+ } elseif ($contact['network'] === NETWORK_DIASPORA) {
+ Diaspora::sendUnshare($user, $contact);
+ } elseif ($contact['network'] === NETWORK_DFRN) {
+ DFRN::deliver($user, $contact, 'placeholder', 1);
+ }
+ }
+
+ /**
+ * @brief Marks a contact for archival after a communication issue delay
+ *
+ * Contact has refused to recognise us as a friend. We will start a countdown.
+ * If they still don't recognise us in 32 days, the relationship is over,
+ * and we won't waste any more time trying to communicate with them.
+ * This provides for the possibility that their database is temporarily messed
+ * up or some other transient event and that there's a possibility we could recover from it.
+ *
+ * @param array $contact contact to mark for archival
+ * @return type
+ */
+ public static function markForArchival(array $contact)
+ {
+ // Contact already archived, nothing to do
+ if ($contact['archive']) {
+ return;
+ }
+
+ if ($contact['term-date'] <= NULL_DATE) {
+ dba::update('contact', array('term-date' => datetime_convert()), array('id' => $contact['id']));
+
+ if ($contact['url'] != '') {
+ dba::update('contact', array('term-date' => datetime_convert()), array('`nurl` = ? AND `term-date` <= ?', normalise_link($contact['url']), NULL_DATE));
+ }
+ } else {
+ /* @todo
+ * We really should send a notification to the owner after 2-3 weeks
+ * so they won't be surprised when the contact vanishes and can take
+ * remedial action if this was a serious mistake or glitch
+ */
+
+ /// @todo Check for contact vitality via probing
+ $expiry = $contact['term-date'] . ' + 32 days ';
+ if (datetime_convert() > datetime_convert('UTC', 'UTC', $expiry)) {
+ /* Relationship is really truly dead. archive them rather than
+ * delete, though if the owner tries to unarchive them we'll start
+ * the whole process over again.
+ */
+ dba::update('contact', array('archive' => 1), array('id' => $contact['id']));
+
+ if ($contact['url'] != '') {
+ dba::update('contact', array('archive' => 1), array('nurl' => normalise_link($contact['url'])));
+ }
+ }
+ }
+ }
+
+ /**
+ * @brief Cancels the archival countdown
+ *
+ * @see Contact::markForArchival()
+ *
+ * @param array $contact contact to be unmarked for archival
+ * @return null
+ */
+ public static function unmarkForArchival(array $contact)
+ {
+ $condition = array('`id` = ? AND (`term-date` > ? OR `archive`)', $contact[`id`], NULL_DATE);
+ $exists = dba::exists('contact', $condition);
+
+ // We don't need to update, we never marked this contact for archival
+ if (!$exists) {
+ return;
+ }
+
+ // It's a miracle. Our dead contact has inexplicably come back to life.
+ $fields = array('term-date' => NULL_DATE, 'archive' => false);
+ dba::update('contact', $fields, array('id' => $contact['id']));
+
+ if ($contact['url'] != '') {
+ dba::update('contact', $fields, array('nurl' => normalise_link($contact['url'])));
+ }
+ }
+
+ /**
+ * @brief Get contact data for a given profile link
+ *
+ * The function looks at several places (contact table and gcontact table) for the contact
+ * It caches its result for the same script execution to prevent duplicate calls
+ *
+ * @param string $url The profile link
+ * @param int $uid User id
+ * @param array $default If not data was found take this data as default value
+ *
+ * @return array Contact data
+ */
+ public static function getDetailsByURL($url, $uid = -1, array $default = [])
+ {
+ static $cache = array();
+
+ if ($url == '') {
+ return $default;
+ }
+
+ if ($uid == -1) {
+ $uid = local_user();
+ }
+
+ if (isset($cache[$url][$uid])) {
+ return $cache[$url][$uid];
+ }
+
+ $ssl_url = str_replace('http://', 'https://', $url);
+
+ // Fetch contact data from the contact table for the given user
+ $s = dba::p("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
+ FROM `contact` WHERE `nurl` = ? AND `uid` = ?", normalise_link($url), $uid);
+ $r = dba::inArray($s);
+
+ // Fetch contact data from the contact table for the given user, checking with the alias
+ if (!DBM::is_result($r)) {
+ $s = dba::p("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
+ FROM `contact` WHERE `alias` IN (?, ?, ?) AND `uid` = ?", normalise_link($url), $url, $ssl_url, $uid);
+ $r = dba::inArray($s);
+ }
+
+ // Fetch the data from the contact table with "uid=0" (which is filled automatically)
+ if (!DBM::is_result($r)) {
+ $s = dba::p("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
+ FROM `contact` WHERE `nurl` = ? AND `uid` = 0", normalise_link($url));
+ $r = dba::inArray($s);
+ }
+
+ // Fetch the data from the contact table with "uid=0" (which is filled automatically) - checked with the alias
+ if (!DBM::is_result($r)) {
+ $s = dba::p("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
+ FROM `contact` WHERE `alias` IN (?, ?, ?) AND `uid` = 0", normalise_link($url), $url, $ssl_url);
+ $r = dba::inArray($s);
+ }
+
+ // Fetch the data from the gcontact table
+ if (!DBM::is_result($r)) {
+ $s = dba::p("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, '' AS `xmpp`,
+ `keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `contact-type`, `birthday`, 0 AS `self`
+ FROM `gcontact` WHERE `nurl` = ?", normalise_link($url));
+ $r = dba::inArray($s);
+ }
+
+ if (DBM::is_result($r)) {
+ // If there is more than one entry we filter out the connector networks
+ if (count($r) > 1) {
+ foreach ($r as $id => $result) {
+ if ($result["network"] == NETWORK_STATUSNET) {
+ unset($r[$id]);
+ }
+ }
+ }
+
+ $profile = array_shift($r);
+
+ // "bd" always contains the upcoming birthday of a contact.
+ // "birthday" might contain the birthday including the year of birth.
+ if ($profile["birthday"] > '0001-01-01') {
+ $bd_timestamp = strtotime($profile["birthday"]);
+ $month = date("m", $bd_timestamp);
+ $day = date("d", $bd_timestamp);
+
+ $current_timestamp = time();
+ $current_year = date("Y", $current_timestamp);
+ $current_month = date("m", $current_timestamp);
+ $current_day = date("d", $current_timestamp);
+
+ $profile["bd"] = $current_year . "-" . $month . "-" . $day;
+ $current = $current_year . "-" . $current_month . "-" . $current_day;
+
+ if ($profile["bd"] < $current) {
+ $profile["bd"] = ( ++$current_year) . "-" . $month . "-" . $day;
+ }
+ } else {
+ $profile["bd"] = '0001-01-01';
+ }
+ } else {
+ $profile = $default;
+ }
+
+ if (($profile["photo"] == "") && isset($default["photo"])) {
+ $profile["photo"] = $default["photo"];
+ }
+
+ if (($profile["name"] == "") && isset($default["name"])) {
+ $profile["name"] = $default["name"];
+ }
+
+ if (($profile["network"] == "") && isset($default["network"])) {
+ $profile["network"] = $default["network"];
+ }
+
+ if (($profile["thumb"] == "") && isset($profile["photo"])) {
+ $profile["thumb"] = $profile["photo"];
+ }
+
+ if (($profile["micro"] == "") && isset($profile["thumb"])) {
+ $profile["micro"] = $profile["thumb"];
+ }
+
+ if ((($profile["addr"] == "") || ($profile["name"] == "")) && ($profile["gid"] != 0)
+ && in_array($profile["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))
+ ) {
+ Worker::add(PRIORITY_LOW, "UpdateGContact", $profile["gid"]);
+ }
+
+ // Show contact details of Diaspora contacts only if connected
+ if (($profile["cid"] == 0) && ($profile["network"] == NETWORK_DIASPORA)) {
+ $profile["location"] = "";
+ $profile["about"] = "";
+ $profile["gender"] = "";
+ $profile["birthday"] = '0001-01-01';
+ }
+
+ $cache[$url][$uid] = $profile;
+
+ return $profile;
+ }
+
+ /**
+ * @brief Get contact data for a given address
+ *
+ * The function looks at several places (contact table and gcontact table) for the contact
+ *
+ * @param string $addr The profile link
+ * @param int $uid User id
+ *
+ * @return array Contact data
+ */
+ public static function getDetailsByAddr($addr, $uid = -1)
+ {
+ static $cache = array();
+
+ if ($addr == '') {
+ return array();
+ }
+
+ if ($uid == -1) {
+ $uid = local_user();
+ }
+
+ // Fetch contact data from the contact table for the given user
+ $r = q("SELECT `id`, `id` AS `cid`, 0 AS `gid`, 0 AS `zid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, `self`
+ FROM `contact` WHERE `addr` = '%s' AND `uid` = %d", dbesc($addr), intval($uid));
+
+ // Fetch the data from the contact table with "uid=0" (which is filled automatically)
+ if (!DBM::is_result($r))
+ $r = q("SELECT `id`, 0 AS `cid`, `id` AS `zid`, 0 AS `gid`, `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, `xmpp`,
+ `keywords`, `gender`, `photo`, `thumb`, `micro`, `forum`, `prv`, (`forum` | `prv`) AS `community`, `contact-type`, `bd` AS `birthday`, 0 AS `self`
+ FROM `contact` WHERE `addr` = '%s' AND `uid` = 0", dbesc($addr));
+
+ // Fetch the data from the gcontact table
+ if (!DBM::is_result($r))
+ $r = q("SELECT 0 AS `id`, 0 AS `cid`, `id` AS `gid`, 0 AS `zid`, 0 AS `uid`, `url`, `nurl`, `alias`, `network`, `name`, `nick`, `addr`, `location`, `about`, '' AS `xmpp`,
+ `keywords`, `gender`, `photo`, `photo` AS `thumb`, `photo` AS `micro`, `community` AS `forum`, 0 AS `prv`, `community`, `contact-type`, `birthday`, 0 AS `self`
+ FROM `gcontact` WHERE `addr` = '%s'", dbesc($addr));
+
+ if (!DBM::is_result($r)) {
+ $data = Probe::uri($addr);
+
+ $profile = self::getDetailsByURL($data['url'], $uid);
+ } else {
+ $profile = $r[0];
+ }
+
+ return $profile;
+ }
+
+ /**
+ * @brief Returns the data array for the photo menu of a given contact
+ *
+ * @param array $contact contact
+ * @param int $uid optional, default 0
+ * @return array
+ */
+ public static function photoMenu(array $contact, $uid = 0)
+ {
+ // @todo Unused, to be removed
+ $a = get_app();
+
+ $contact_url = '';
+ $pm_url = '';
+ $status_link = '';
+ $photos_link = '';
+ $posts_link = '';
+ $contact_drop_link = '';
+ $poke_link = '';
+
+ if ($uid == 0) {
+ $uid = local_user();
+ }
+
+ if ($contact['uid'] != $uid) {
+ if ($uid == 0) {
+ $profile_link = zrl($contact['url']);
+ $menu = array('profile' => array(t('View Profile'), $profile_link, true));
+
+ return $menu;
+ }
+
+ $r = dba::select('contact', array(), array('nurl' => $contact['nurl'], 'network' => $contact['network'], 'uid' => $uid), array('limit' => 1));
+ if ($r) {
+ return self::photoMenu($r, $uid);
+ } else {
+ $profile_link = zrl($contact['url']);
+ $connlnk = 'follow/?url=' . $contact['url'];
+ $menu = array(
+ 'profile' => array(t('View Profile'), $profile_link, true),
+ 'follow' => array(t('Connect/Follow'), $connlnk, true)
+ );
+
+ return $menu;
+ }
+ }
+
+ $sparkle = false;
+ if ($contact['network'] === NETWORK_DFRN) {
+ $sparkle = true;
+ $profile_link = System::baseUrl() . '/redir/' . $contact['id'];
+ } else {
+ $profile_link = $contact['url'];
+ }
+
+ if ($profile_link === 'mailbox') {
+ $profile_link = '';
+ }
+
+ if ($sparkle) {
+ $status_link = $profile_link . '?url=status';
+ $photos_link = $profile_link . '?url=photos';
+ $profile_link = $profile_link . '?url=profile';
+ }
+
+ if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_DIASPORA))) {
+ $pm_url = System::baseUrl() . '/message/new/' . $contact['id'];
+ }
+
+ if ($contact['network'] == NETWORK_DFRN) {
+ $poke_link = System::baseUrl() . '/poke/?f=&c=' . $contact['id'];
+ }
+
+ $contact_url = System::baseUrl() . '/contacts/' . $contact['id'];
+
+ $posts_link = System::baseUrl() . '/contacts/' . $contact['id'] . '/posts';
+ $contact_drop_link = System::baseUrl() . '/contacts/' . $contact['id'] . '/drop?confirm=1';
+
+ /**
+ * Menu array:
+ * "name" => [ "Label", "link", (bool)Should the link opened in a new tab? ]
+ */
+ $menu = array(
+ 'status' => array(t("View Status"), $status_link, true),
+ 'profile' => array(t("View Profile"), $profile_link, true),
+ 'photos' => array(t("View Photos"), $photos_link, true),
+ 'network' => array(t("Network Posts"), $posts_link, false),
+ 'edit' => array(t("View Contact"), $contact_url, false),
+ 'drop' => array(t("Drop Contact"), $contact_drop_link, false),
+ 'pm' => array(t("Send PM"), $pm_url, false),
+ 'poke' => array(t("Poke"), $poke_link, false),
+ );
+
+
+ $args = array('contact' => $contact, 'menu' => &$menu);
+
+ call_hooks('contact_photo_menu', $args);
+
+ $menucondensed = array();
+
+ foreach ($menu as $menuname => $menuitem) {
+ if ($menuitem[1] != '') {
+ $menucondensed[$menuname] = $menuitem;
+ }
+ }
+
+ return $menucondensed;
+ }
+
+ /**
+ * @brief Returns ungrouped contact count or list for user
+ *
+ * Returns either the total number of ungrouped contacts for the given user
+ * id or a paginated list of ungrouped contacts.
+ *
+ * @param int $uid uid
+ * @param int $start optional, default 0
+ * @param int $count optional, default 0
+ *
+ * @return array
+ */
+ public static function getUngroupedList($uid, $start = 0, $count = 0)
+ {
+ if (!$count) {
+ $r = q(
+ "SELECT COUNT(*) AS `total`
+ FROM `contact`
+ WHERE `uid` = %d
+ AND NOT `self`
+ AND NOT `blocked`
+ AND NOT `pending`
+ AND `id` NOT IN (
+ SELECT DISTINCT(`contact-id`)
+ FROM `group_member`
+ WHERE `uid` = %d
+ )", intval($uid), intval($uid)
+ );
+
+ return $r;
+ }
+
+ $r = q(
+ "SELECT *
+ FROM `contact`
+ WHERE `uid` = %d
+ AND NOT `self`
+ AND NOT `blocked`
+ AND NOT `pending`
+ AND `id` NOT IN (
+ SELECT DISTINCT(`contact-id`)
+ FROM `group_member` WHERE `uid` = %d
+ )
+ LIMIT %d, %d", intval($uid), intval($uid), intval($start), intval($count)
+ );
+ return $r;
+ }
+
+ /**
+ * @brief Fetch the contact id for a given url and user
+ *
+ * First lookup in the contact table to find a record matching either `url`, `nurl`,
+ * `addr` or `alias`.
+ *
+ * If there's no record and we aren't looking for a public contact, we quit.
+ * If there's one, we check that it isn't time to update the picture else we
+ * directly return the found contact id.
+ *
+ * Second, we probe the provided $url wether it's http://server.tld/profile or
+ * nick@server.tld. We quit if we can't get any info back.
+ *
+ * Third, we create the contact record if it doesn't exist
+ *
+ * Fourth, we update the existing record with the new data (avatar, alias, nick)
+ * if there's any updates
+ *
+ * @param string $url Contact URL
+ * @param integer $uid The user id for the contact (0 = public contact)
+ * @param boolean $no_update Don't update the contact
+ *
+ * @return integer Contact ID
+ */
+ public static function getIdForURL($url, $uid = 0, $no_update = false)
+ {
+ logger("Get contact data for url " . $url . " and user " . $uid . " - " . System::callstack(), LOGGER_DEBUG);
+
+ $contact_id = 0;
+
+ if ($url == '') {
+ return 0;
+ }
+
+ /// @todo Verify if we can't use Contact::getDetailsByUrl instead of the following
+ // We first try the nurl (http://server.tld/nick), most common case
+ $contact = dba::select('contact', array('id', 'avatar-date'), array('nurl' => normalise_link($url), 'uid' => $uid), array('limit' => 1));
+
+ // Then the addr (nick@server.tld)
+ if (!DBM::is_result($contact)) {
+ $contact = dba::select('contact', array('id', 'avatar-date'), array('addr' => $url, 'uid' => $uid), array('limit' => 1));
+ }
+
+ // Then the alias (which could be anything)
+ if (!DBM::is_result($contact)) {
+ // The link could be provided as http although we stored it as https
+ $ssl_url = str_replace('http://', 'https://', $url);
+ $r = dba::select('contact', array('id', 'avatar-date'), array('`alias` IN (?, ?, ?) AND `uid` = ?', $url, normalise_link($url), $ssl_url, $uid), array('limit' => 1));
+ $contact = dba::fetch($r);
+ dba::close($r);
+ }
+
+ if (DBM::is_result($contact)) {
+ $contact_id = $contact["id"];
+
+ // Update the contact every 7 days
+ $update_contact = ($contact['avatar-date'] < datetime_convert('', '', 'now -7 days'));
+
+ // We force the update if the avatar is empty
+ if ($contact['avatar'] == '') {
+ $update_contact = true;
+ }
+
+ if (!$update_contact || $no_update) {
+ return $contact_id;
+ }
+ } elseif ($uid != 0) {
+ // Non-existing user-specific contact, exiting
+ return 0;
+ }
+
+ $data = Probe::uri($url, "", $uid);
+
+ // Last try in gcontact for unsupported networks
+ if (!in_array($data["network"], array(NETWORK_DFRN, NETWORK_OSTATUS, NETWORK_DIASPORA, NETWORK_PUMPIO, NETWORK_MAIL))) {
+ if ($uid != 0) {
+ return 0;
+ }
+
+ // Get data from the gcontact table
+ $gcontacts = dba::select('gcontact', array('name', 'nick', 'url', 'photo', 'addr', 'alias', 'network'), array('nurl' => normalise_link($url)), array('limit' => 1));
+ if (!DBM::is_result($gcontacts)) {
+ return 0;
+ }
+
+ $data = array_merge($data, $gcontacts);
+ }
+
+ if (!$contact_id && ($data["alias"] != '') && ($data["alias"] != $url)) {
+ $contact_id = self::getIdForURL($data["alias"], $uid, true);
+ }
+
+ $url = $data["url"];
+ if (!$contact_id) {
+ dba::insert(
+ 'contact', array('uid' => $uid, 'created' => datetime_convert(), 'url' => $data["url"],
+ 'nurl' => normalise_link($data["url"]), 'addr' => $data["addr"],
+ 'alias' => $data["alias"], 'notify' => $data["notify"], 'poll' => $data["poll"],
+ 'name' => $data["name"], 'nick' => $data["nick"], 'photo' => $data["photo"],
+ 'keywords' => $data["keywords"], 'location' => $data["location"], 'about' => $data["about"],
+ 'network' => $data["network"], 'pubkey' => $data["pubkey"],
+ 'rel' => CONTACT_IS_SHARING, 'priority' => $data["priority"],
+ 'batch' => $data["batch"], 'request' => $data["request"],
+ 'confirm' => $data["confirm"], 'poco' => $data["poco"],
+ 'name-date' => datetime_convert(), 'uri-date' => datetime_convert(),
+ 'avatar-date' => datetime_convert(), 'writable' => 1, 'blocked' => 0,
+ 'readonly' => 0, 'pending' => 0)
+ );
+
+ $s = dba::select('contact', array('id'), array('nurl' => normalise_link($data["url"]), 'uid' => $uid), array('order' => array('id'), 'limit' => 2));
+ $contacts = dba::inArray($s);
+ if (!DBM::is_result($contacts)) {
+ return 0;
+ }
+
+ $contact_id = $contacts[0]["id"];
+
+ // Update the newly created contact from data in the gcontact table
+ $gcontact = dba::select('gcontact', array('location', 'about', 'keywords', 'gender'), array('nurl' => normalise_link($data["url"])), array('limit' => 1));
+ if (DBM::is_result($gcontact)) {
+ // Only use the information when the probing hadn't fetched these values
+ if ($data['keywords'] != '') {
+ unset($gcontact['keywords']);
+ }
+ if ($data['location'] != '') {
+ unset($gcontact['location']);
+ }
+ if ($data['about'] != '') {
+ unset($gcontact['about']);
+ }
+ dba::update('contact', $gcontact, array('id' => $contact_id));
+ }
+
+ if (count($contacts) > 1 && $uid == 0 && $contact_id != 0 && $data["url"] != "") {
+ dba::delete('contact', array("`nurl` = ? AND `uid` = 0 AND `id` != ? AND NOT `self`",
+ normalise_link($data["url"]), $contact_id));
+ }
+ }
+
+ require_once 'include/Photo.php';
+
+ update_contact_avatar($data["photo"], $uid, $contact_id);
+
+ $contact = dba::select('contact', array('url', 'nurl', 'addr', 'alias', 'name', 'nick', 'keywords', 'location', 'about', 'avatar-date'), array('id' => $contact_id), array('limit' => 1));
+
+ // This condition should always be true
+ if (!DBM::is_result($contact)) {
+ return $contact_id;
+ }
+
+ $updated = array('addr' => $data['addr'],
+ 'alias' => $data['alias'],
+ 'url' => $data['url'],
+ 'nurl' => normalise_link($data['url']),
+ 'name' => $data['name'],
+ 'nick' => $data['nick']);
+
+ if ($data['keywords'] != '') {
+ $updated['keywords'] = $data['keywords'];
+ }
+ if ($data['location'] != '') {
+ $updated['location'] = $data['location'];
+ }
+ if ($data['about'] != '') {
+ $updated['about'] = $data['about'];
+ }
+
+ if (($data["addr"] != $contact["addr"]) || ($data["alias"] != $contact["alias"])) {
+ $updated['uri-date'] = datetime_convert();
+ }
+ if (($data["name"] != $contact["name"]) || ($data["nick"] != $contact["nick"])) {
+ $updated['name-date'] = datetime_convert();
+ }
+
+ $updated['avatar-date'] = datetime_convert();
+
+ dba::update('contact', $updated, array('id' => $contact_id), $contact);
+
+ return $contact_id;
+ }
+
+ /**
+ * @brief Checks if the contact is blocked
+ *
+ * @param int $cid contact id
+ *
+ * @return boolean Is the contact blocked?
+ */
+ public static function isBlocked($cid)
+ {
+ if ($cid == 0) {
+ return false;
+ }
+
+ $blocked = dba::select('contact', array('blocked'), array('id' => $cid), array('limit' => 1));
+ if (!DBM::is_result($blocked)) {
+ return false;
+ }
+ return (bool) $blocked['blocked'];
+ }
+
+ /**
+ * @brief Checks if the contact is hidden
+ *
+ * @param int $cid contact id
+ *
+ * @return boolean Is the contact hidden?
+ */
+ public static function isHidden($cid)
+ {
+ if ($cid == 0) {
+ return false;
+ }
+
+ $hidden = dba::select('contact', array('hidden'), array('id' => $cid), array('limit' => 1));
+ if (!DBM::is_result($hidden)) {
+ return false;
+ }
+ return (bool) $hidden['hidden'];
+ }
+
+ /**
+ * @brief Returns posts from a given contact url
+ *
+ * @param string $contact_url Contact URL
+ *
+ * @return string posts in HTML
+ */
+ public static function getPostsFromUrl($contact_url)
+ {
+ $a = self::getApp();
+
+ require_once 'include/conversation.php';
+
+ // There are no posts with "uid = 0" with connector networks
+ // This speeds up the query a lot
+ $r = q("SELECT `network`, `id` AS `author-id`, `contact-type` FROM `contact`
+ WHERE `contact`.`nurl` = '%s' AND `contact`.`uid` = 0", dbesc(normalise_link($contact_url)));
+
+ if (!DBM::is_result($r)) {
+ return '';
+ }
+
+ if (in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, ""))) {
+ $sql = "(`item`.`uid` = 0 OR (`item`.`uid` = %d AND NOT `item`.`global`))";
+ } else {
+ $sql = "`item`.`uid` = %d";
+ }
+
+ $author_id = intval($r[0]["author-id"]);
+
+ $contact = ($r[0]["contact-type"] == ACCOUNT_TYPE_COMMUNITY ? 'owner-id' : 'author-id');
+
+ $r = q(item_query() . " AND `item`.`" . $contact . "` = %d AND " . $sql .
+ " ORDER BY `item`.`created` DESC LIMIT %d, %d", intval($author_id), intval(local_user()), intval($a->pager['start']), intval($a->pager['itemspage'])
+ );
+
+
+ $o = conversation($a, $r, 'community', false);
+
+ $o .= alt_pager($a, count($r));
+
+ return $o;
+ }
+
+ /**
+ * @brief Returns the account type name
+ *
+ * The function can be called with either the user or the contact array
+ *
+ * @param array $contact contact or user array
+ * @return string
+ */
+ public static function getAccountType(array $contact)
+ {
+ // There are several fields that indicate that the contact or user is a forum
+ // "page-flags" is a field in the user table,
+ // "forum" and "prv" are used in the contact table. They stand for PAGE_COMMUNITY and PAGE_PRVGROUP.
+ // "community" is used in the gcontact table and is true if the contact is PAGE_COMMUNITY or PAGE_PRVGROUP.
+ if ((isset($contact['page-flags']) && (intval($contact['page-flags']) == PAGE_COMMUNITY))
+ || (isset($contact['page-flags']) && (intval($contact['page-flags']) == PAGE_PRVGROUP))
+ || (isset($contact['forum']) && intval($contact['forum']))
+ || (isset($contact['prv']) && intval($contact['prv']))
+ || (isset($contact['community']) && intval($contact['community']))
+ ) {
+ $type = ACCOUNT_TYPE_COMMUNITY;
+ } else {
+ $type = ACCOUNT_TYPE_PERSON;
+ }
+
+ // The "contact-type" (contact table) and "account-type" (user table) are more general then the chaos from above.
+ if (isset($contact["contact-type"])) {
+ $type = $contact["contact-type"];
+ }
+ if (isset($contact["account-type"])) {
+ $type = $contact["account-type"];
+ }
+
+ switch ($type) {
+ case ACCOUNT_TYPE_ORGANISATION:
+ $account_type = t("Organisation");
+ break;
+ case ACCOUNT_TYPE_NEWS:
+ $account_type = t('News');
+ break;
+ case ACCOUNT_TYPE_COMMUNITY:
+ $account_type = t("Forum");
+ break;
+ default:
+ $account_type = "";
+ break;
+ }
+
+ return $account_type;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Object/Conversation.php
+ */
+namespace Friendica\Object;
+
+use Friendica\BaseObject;
+use Friendica\Object\Item;
+
+require_once 'boot.php';
+require_once 'include/text.php';
+
+/**
+ * A list of threads
+ *
+ * We should think about making this a SPL Iterator
+ */
+class Conversation extends BaseObject
+{
+ private $threads = array();
+ private $mode = null;
+ private $writable = false;
+ private $profile_owner = 0;
+ private $preview = false;
+
+ /**
+ * Constructor
+ *
+ * @param string $mode The mode
+ * @param boolean $preview boolean value
+ */
+ public function __construct($mode, $preview)
+ {
+ $this->setMode($mode);
+ $this->preview = $preview;
+ }
+
+ /**
+ * Set the mode we'll be displayed on
+ *
+ * @param string $mode The mode to set
+ *
+ * @return void
+ */
+ private function setMode($mode)
+ {
+ if ($this->getMode() == $mode) {
+ return;
+ }
+
+ $a = self::getApp();
+
+ switch ($mode) {
+ case 'network':
+ case 'notes':
+ $this->profile_owner = local_user();
+ $this->writable = true;
+ break;
+ case 'profile':
+ $this->profile_owner = $a->profile['profile_uid'];
+ $this->writable = can_write_wall($a, $this->profile_owner);
+ break;
+ case 'display':
+ $this->profile_owner = $a->profile['uid'];
+ $this->writable = can_write_wall($a, $this->profile_owner);
+ break;
+ default:
+ logger('[ERROR] Conversation::setMode : Unhandled mode ('. $mode .').', LOGGER_DEBUG);
+ return false;
+ break;
+ }
+ $this->mode = $mode;
+ }
+
+ /**
+ * Get mode
+ *
+ * @return string
+ */
+ public function getMode()
+ {
+ return $this->mode;
+ }
+
+ /**
+ * Check if page is writable
+ *
+ * @return boolean
+ */
+ public function isWritable()
+ {
+ return $this->writable;
+ }
+
+ /**
+ * Check if page is a preview
+ *
+ * @return boolean
+ */
+ public function isPreview()
+ {
+ return $this->preview;
+ }
+
+ /**
+ * Get profile owner
+ *
+ * @return integer
+ */
+ public function getProfileOwner()
+ {
+ return $this->profile_owner;
+ }
+
+ /**
+ * Add a thread to the conversation
+ *
+ * @param object $item The item to insert
+ *
+ * @return mixed The inserted item on success
+ * false on failure
+ */
+ public function addThread($item)
+ {
+ $item_id = $item->getId();
+
+ if (!$item_id) {
+ logger('[ERROR] Conversation::addThread : Item has no ID!!', LOGGER_DEBUG);
+ return false;
+ }
+
+ if ($this->getThread($item->getId())) {
+ logger('[WARN] Conversation::addThread : Thread already exists ('. $item->getId() .').', LOGGER_DEBUG);
+ return false;
+ }
+
+ /*
+ * Only add will be displayed
+ */
+ if ($item->getDataValue('network') === NETWORK_MAIL && local_user() != $item->getDataValue('uid')) {
+ logger('[WARN] Conversation::addThread : Thread is a mail ('. $item->getId() .').', LOGGER_DEBUG);
+ return false;
+ }
+
+ if ($item->getDataValue('verb') === ACTIVITY_LIKE || $item->getDataValue('verb') === ACTIVITY_DISLIKE) {
+ logger('[WARN] Conversation::addThread : Thread is a (dis)like ('. $item->getId() .').', LOGGER_DEBUG);
+ return false;
+ }
+
+ $item->setConversation($this);
+ $this->threads[] = $item;
+
+ return end($this->threads);
+ }
+
+ /**
+ * Get data in a form usable by a conversation template
+ *
+ * We should find a way to avoid using those arguments (at least most of them)
+ *
+ * @param object $conv_responses data
+ *
+ * @return mixed The data requested on success
+ * false on failure
+ */
+ public function getTemplateData($conv_responses)
+ {
+ $a = self::getApp();
+ $result = array();
+ $i = 0;
+
+ foreach ($this->threads as $item) {
+ if ($item->getDataValue('network') === NETWORK_MAIL && local_user() != $item->getDataValue('uid')) {
+ continue;
+ }
+
+ $item_data = $item->getTemplateData($conv_responses);
+
+ if (!$item_data) {
+ logger('[ERROR] Conversation::getTemplateData : Failed to get item template data ('. $item->getId() .').', LOGGER_DEBUG);
+ return false;
+ }
+ $result[] = $item_data;
+ }
+
+ return $result;
+ }
+
+ /**
+ * Get a thread based on its item id
+ *
+ * @param integer $id Item id
+ *
+ * @return mixed The found item on success
+ * false on failure
+ */
+ private function getThread($id)
+ {
+ foreach ($this->threads as $item) {
+ if ($item->getId() == $id) {
+ return $item;
+ }
+ }
+
+ return false;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Object/Item.php
+ */
+namespace Friendica\Object;
+
+use Friendica\BaseObject;
+use Friendica\Core\Config;
+use Friendica\Core\PConfig;
+use Friendica\Database\DBM;
+use Friendica\Object\Contact;
+use dba;
+
+require_once 'include/text.php';
+require_once 'boot.php';
+require_once "include/conversation.php";
+
+/**
+ * An item
+ */
+class Item extends BaseObject
+{
+ private $data = array();
+ private $template = null;
+ private $available_templates = array(
+ 'wall' => 'wall_thread.tpl',
+ 'wall2wall' => 'wallwall_thread.tpl'
+ );
+ private $comment_box_template = 'comment_item.tpl';
+ private $toplevel = false;
+ private $writable = false;
+ private $children = array();
+ private $parent = null;
+ private $conversation = null;
+ private $redirect_url = null;
+ private $owner_url = '';
+ private $owner_photo = '';
+ private $owner_name = '';
+ private $wall_to_wall = false;
+ private $threaded = false;
+ private $visiting = false;
+
+ /**
+ * Constructor
+ *
+ * @param array $data data array
+ */
+ public function __construct($data)
+ {
+ $a = self::getApp();
+
+ $this->data = $data;
+ $this->setTemplate('wall');
+ $this->toplevel = ($this->getId() == $this->getDataValue('parent'));
+
+ if (is_array($_SESSION['remote'])) {
+ foreach ($_SESSION['remote'] as $visitor) {
+ if ($visitor['cid'] == $this->getDataValue('contact-id')) {
+ $this->visiting = true;
+ break;
+ }
+ }
+ }
+
+ $this->writable = ($this->getDataValue('writable') || $this->getDataValue('self'));
+
+ $ssl_state = ((local_user()) ? true : false);
+ $this->redirect_url = 'redir/' . $this->getDataValue('cid');
+
+ if (!$this->isToplevel()) {
+ $this->threaded = true;
+ }
+
+ // Prepare the children
+ if (count($data['children'])) {
+ foreach ($data['children'] as $item) {
+ /*
+ * Only add will be displayed
+ */
+ if ($item['network'] === NETWORK_MAIL && local_user() != $item['uid']) {
+ continue;
+ } elseif (! visible_activity($item)) {
+ continue;
+ }
+
+ // You can always comment on Diaspora items
+ if (($item['network'] == NETWORK_DIASPORA) && (local_user() == $item['uid'])) {
+ $item['writable'] = true;
+ }
+
+ $item['pagedrop'] = $data['pagedrop'];
+ $child = new Item($item);
+ $this->addChild($child);
+ }
+ }
+ }
+
+ /**
+ * Get data in a form usable by a conversation template
+ *
+ * @param object $conv_responses conversation responses
+ * @param integer $thread_level default = 1
+ *
+ * @return mixed The data requested on success
+ * false on failure
+ */
+ public function getTemplateData($conv_responses, $thread_level = 1)
+ {
+ require_once "mod/proxy.php";
+
+ $result = array();
+
+ $a = self::getApp();
+
+ $item = $this->getData();
+ $edited = false;
+ // If the time between "created" and "edited" differs we add
+ // a notice that the post was edited.
+ // Note: In some networks reshared items seem to have (sometimes) a difference
+ // between creation time and edit time of a second. Thats why we add the notice
+ // only if the difference is more than 1 second.
+ if (strtotime($item['edited']) - strtotime($item['created']) > 1) {
+ $edited = array(
+ 'label' => t('This entry was edited'),
+ 'date' => datetime_convert('UTC', date_default_timezone_get(), $item['edited'], 'r'),
+ 'relative' => relative_date($item['edited'])
+ );
+ }
+ $commentww = '';
+ $sparkle = '';
+ $buttons = '';
+ $dropping = false;
+ $star = false;
+ $ignore = false;
+ $isstarred = "unstarred";
+ $indent = '';
+ $shiny = '';
+ $osparkle = '';
+ $total_children = $this->countDescendants();
+
+ $conv = $this->getConversation();
+
+ $lock = ((($item['private'] == 1) || (($item['uid'] == local_user()) && (strlen($item['allow_cid']) || strlen($item['allow_gid'])
+ || strlen($item['deny_cid']) || strlen($item['deny_gid']))))
+ ? t('Private Message')
+ : false);
+ $shareable = ((($conv->getProfileOwner() == local_user()) && ($item['private'] != 1)) ? true : false);
+ if (local_user() && link_compare($a->contact['url'], $item['author-link'])) {
+ if ($item["event-id"] != 0) {
+ $edpost = array("events/event/".$item['event-id'], t("Edit"));
+ } else {
+ $edpost = array("editpost/".$item['id'], t("Edit"));
+ }
+ } else {
+ $edpost = false;
+ }
+
+ if (($this->getDataValue('uid') == local_user()) || $this->isVisiting()) {
+ $dropping = true;
+ }
+
+ $drop = array(
+ 'dropping' => $dropping,
+ 'pagedrop' => ((feature_enabled($conv->getProfileOwner(), 'multi_delete')) ? $item['pagedrop'] : ''),
+ 'select' => t('Select'),
+ 'delete' => t('Delete'),
+ );
+
+ $filer = (($conv->getProfileOwner() == local_user()) ? t("save to folder") : false);
+
+ $diff_author = ((link_compare($item['url'], $item['author-link'])) ? false : true);
+ $profile_name = htmlentities(((strlen($item['author-name'])) && $diff_author) ? $item['author-name'] : $item['name']);
+ if ($item['author-link'] && (! $item['author-name'])) {
+ $profile_name = $item['author-link'];
+ }
+
+ $sp = false;
+ $profile_link = best_link_url($item, $sp);
+ if ($profile_link === 'mailbox') {
+ $profile_link = '';
+ }
+
+ if ($sp) {
+ $sparkle = ' sparkle';
+ } else {
+ $profile_link = zrl($profile_link);
+ }
+
+ if (!isset($item['author-thumb']) || ($item['author-thumb'] == "")) {
+ $author_contact = Contact::getDetailsByURL($item['author-link'], $conv->getProfileOwner());
+ if ($author_contact["thumb"]) {
+ $item['author-thumb'] = $author_contact["thumb"];
+ } else {
+ $item['author-thumb'] = $item['author-avatar'];
+ }
+ }
+
+ if (!isset($item['owner-thumb']) || ($item['owner-thumb'] == "")) {
+ $owner_contact = Contact::getDetailsByURL($item['owner-link'], $conv->getProfileOwner());
+ if ($owner_contact["thumb"]) {
+ $item['owner-thumb'] = $owner_contact["thumb"];
+ } else {
+ $item['owner-thumb'] = $item['owner-avatar'];
+ }
+ }
+
+ $locate = array('location' => $item['location'], 'coord' => $item['coord'], 'html' => '');
+ call_hooks('render_location', $locate);
+ $location = ((strlen($locate['html'])) ? $locate['html'] : render_location_dummy($locate));
+
+ $tags=array();
+ $hashtags = array();
+ $mentions = array();
+
+ /*foreach(explode(',',$item['tag']) as $tag){
+ $tag = trim($tag);
+ if ($tag!="") {
+ $t = bbcode($tag);
+ $tags[] = $t;
+ if($t[0] == '#')
+ $hashtags[] = $t;
+ elseif($t[0] == '@')
+ $mentions[] = $t;
+ }
+ }*/
+
+ // process action responses - e.g. like/dislike/attend/agree/whatever
+ $response_verbs = array('like', 'dislike');
+
+ if ($item['object-type'] === ACTIVITY_OBJ_EVENT) {
+ $response_verbs[] = 'attendyes';
+ $response_verbs[] = 'attendno';
+ $response_verbs[] = 'attendmaybe';
+ if ($conv->isWritable()) {
+ $isevent = true;
+ $attend = array( t('I will attend'), t('I will not attend'), t('I might attend'));
+ }
+ }
+
+ $responses = get_responses($conv_responses, $response_verbs, $this, $item);
+
+ foreach ($response_verbs as $value => $verbs) {
+ $responses[$verbs]['output'] = ((x($conv_responses[$verbs], $item['uri'])) ? format_like($conv_responses[$verbs][$item['uri']], $conv_responses[$verbs][$item['uri'] . '-l'], $verbs, $item['uri']) : '');
+ }
+
+ /*
+ * We should avoid doing this all the time, but it depends on the conversation mode
+ * And the conv mode may change when we change the conv, or it changes its mode
+ * Maybe we should establish a way to be notified about conversation changes
+ */
+ $this->checkWallToWall();
+
+ if ($this->isWallToWall() && ($this->getOwnerUrl() == $this->getRedirectUrl())) {
+ $osparkle = ' sparkle';
+ }
+
+ if ($this->isToplevel()) {
+ if ($conv->getProfileOwner() == local_user()) {
+ $isstarred = (($item['starred']) ? "starred" : "unstarred");
+
+ $star = array(
+ 'do' => t("add star"),
+ 'undo' => t("remove star"),
+ 'toggle' => t("toggle star status"),
+ 'classdo' => (($item['starred']) ? "hidden" : ""),
+ 'classundo' => (($item['starred']) ? "" : "hidden"),
+ 'starred' => t('starred'),
+ );
+ $r = dba::select('thread', array('ignored'), array('uid' => $item['uid'], 'iid' => $item['id']), array('limit' => 1));
+ if (DBM::is_result($r)) {
+ $ignore = array(
+ 'do' => t("ignore thread"),
+ 'undo' => t("unignore thread"),
+ 'toggle' => t("toggle ignore status"),
+ 'classdo' => (($r['ignored']) ? "hidden" : ""),
+ 'classundo' => (($r['ignored']) ? "" : "hidden"),
+ 'ignored' => t('ignored'),
+ );
+ }
+
+ $tagger = '';
+ if (feature_enabled($conv->getProfileOwner(), 'commtag')) {
+ $tagger = array(
+ 'add' => t("add tag"),
+ 'class' => "",
+ );
+ }
+ }
+ } else {
+ $indent = 'comment';
+ }
+
+ if ($conv->isWritable()) {
+ $buttons = array(
+ 'like' => array( t("I like this \x28toggle\x29"), t("like")),
+ 'dislike' => ((feature_enabled($conv->getProfileOwner(), 'dislike')) ? array( t("I don't like this \x28toggle\x29"), t("dislike")) : ''),
+ );
+ if ($shareable) {
+ $buttons['share'] = array( t('Share this'), t('share'));
+ }
+ }
+
+ $comment = $this->getCommentBox($indent);
+
+ if (strcmp(datetime_convert('UTC', 'UTC', $item['created']), datetime_convert('UTC', 'UTC', 'now - 12 hours')) > 0) {
+ $shiny = 'shiny';
+ }
+
+ localize_item($item);
+
+ $body = prepare_body($item, true);
+
+ list($categories, $folders) = get_cats_and_terms($item);
+
+ $body_e = $body;
+ $text_e = strip_tags($body);
+ $name_e = $profile_name;
+ $title_e = $item['title'];
+ $location_e = $location;
+ $owner_name_e = $this->getOwnerName();
+
+ // Disable features that aren't available in several networks
+
+ /// @todo Add NETWORK_DIASPORA when it will pass this information
+ if (!in_array($item["item_network"], array(NETWORK_DFRN)) && isset($buttons["dislike"])) {
+ unset($buttons["dislike"], $isevent);
+ $tagger = '';
+ }
+
+ if (($item["item_network"] == NETWORK_FEED) && isset($buttons["like"])) {
+ unset($buttons["like"]);
+ }
+
+ if (($item["item_network"] == NETWORK_MAIL) && isset($buttons["like"])) {
+ unset($buttons["like"]);
+ }
+
+ $tmp_item = array(
+ 'template' => $this->getTemplate(),
+ 'type' => implode("", array_slice(explode("/", $item['verb']), -1)),
+ 'tags' => $item['tags'],
+ 'hashtags' => $item['hashtags'],
+ 'mentions' => $item['mentions'],
+ 'txt_cats' => t('Categories:'),
+ 'txt_folders' => t('Filed under:'),
+ 'has_cats' => ((count($categories)) ? 'true' : ''),
+ 'has_folders' => ((count($folders)) ? 'true' : ''),
+ 'categories' => $categories,
+ 'folders' => $folders,
+ 'body' => $body_e,
+ 'text' => $text_e,
+ 'id' => $this->getId(),
+ 'guid' => urlencode($item['guid']),
+ 'isevent' => $isevent,
+ 'attend' => $attend,
+ 'linktitle' => sprintf(t('View %s\'s profile @ %s'), $profile_name, ((strlen($item['author-link'])) ? $item['author-link'] : $item['url'])),
+ 'olinktitle' => sprintf(t('View %s\'s profile @ %s'), htmlentities($this->getOwnerName()), ((strlen($item['owner-link'])) ? $item['owner-link'] : $item['url'])),
+ 'to' => t('to'),
+ 'via' => t('via'),
+ 'wall' => t('Wall-to-Wall'),
+ 'vwall' => t('via Wall-To-Wall:'),
+ 'profile_url' => $profile_link,
+ 'item_photo_menu' => item_photo_menu($item),
+ 'name' => $name_e,
+ 'thumb' => $a->remove_baseurl(proxy_url($item['author-thumb'], false, PROXY_SIZE_THUMB)),
+ 'osparkle' => $osparkle,
+ 'sparkle' => $sparkle,
+ 'title' => $title_e,
+ 'localtime' => datetime_convert('UTC', date_default_timezone_get(), $item['created'], 'r'),
+ 'ago' => (($item['app']) ? sprintf(t('%s from %s'), relative_date($item['created']), $item['app']) : relative_date($item['created'])),
+ 'app' => $item['app'],
+ 'created' => relative_date($item['created']),
+ 'lock' => $lock,
+ 'location' => $location_e,
+ 'indent' => $indent,
+ 'shiny' => $shiny,
+ 'owner_url' => $this->getOwnerUrl(),
+ 'owner_photo' => $a->remove_baseurl(proxy_url($item['owner-thumb'], false, PROXY_SIZE_THUMB)),
+ 'owner_name' => htmlentities($owner_name_e),
+ 'plink' => get_plink($item),
+ 'edpost' => ((feature_enabled($conv->getProfileOwner(), 'edit_posts')) ? $edpost : ''),
+ 'isstarred' => $isstarred,
+ 'star' => ((feature_enabled($conv->getProfileOwner(), 'star_posts')) ? $star : ''),
+ 'ignore' => ((feature_enabled($conv->getProfileOwner(), 'ignore_posts')) ? $ignore : ''),
+ 'tagger' => $tagger,
+ 'filer' => ((feature_enabled($conv->getProfileOwner(), 'filing')) ? $filer : ''),
+ 'drop' => $drop,
+ 'vote' => $buttons,
+ 'like' => $responses['like']['output'],
+ 'dislike' => $responses['dislike']['output'],
+ 'responses' => $responses,
+ 'switchcomment' => t('Comment'),
+ 'comment' => $comment,
+ 'previewing' => ($conv->isPreview() ? ' preview ' : ''),
+ 'wait' => t('Please wait'),
+ 'thread_level' => $thread_level,
+ 'edited' => $edited,
+ 'network' => $item["item_network"],
+ 'network_name' => network_to_name($item['item_network'], $profile_link),
+ 'received' => $item['received'],
+ 'commented' => $item['commented'],
+ 'created_date' => $item['created'],
+ );
+
+ $arr = array('item' => $item, 'output' => $tmp_item);
+ call_hooks('display_item', $arr);
+
+ $result = $arr['output'];
+
+ $result['children'] = array();
+ $children = $this->getChildren();
+ $nb_children = count($children);
+ if ($nb_children > 0) {
+ foreach ($children as $child) {
+ $result['children'][] = $child->getTemplateData($conv_responses, $thread_level + 1);
+ }
+ // Collapse
+ if (($nb_children > 2) || ($thread_level > 1)) {
+ $result['children'][0]['comment_firstcollapsed'] = true;
+ $result['children'][0]['num_comments'] = sprintf(tt('%d comment', '%d comments', $total_children), $total_children);
+ $result['children'][0]['hidden_comments_num'] = $total_children;
+ $result['children'][0]['hidden_comments_text'] = tt('comment', 'comments', $total_children);
+ $result['children'][0]['hide_text'] = t('show more');
+ if ($thread_level > 1) {
+ $result['children'][$nb_children - 1]['comment_lastcollapsed'] = true;
+ } else {
+ $result['children'][$nb_children - 3]['comment_lastcollapsed'] = true;
+ }
+ }
+ }
+
+ if ($this->isToplevel()) {
+ $result['total_comments_num'] = "$total_children";
+ $result['total_comments_text'] = tt('comment', 'comments', $total_children);
+ }
+
+ $result['private'] = $item['private'];
+ $result['toplevel'] = ($this->isToplevel() ? 'toplevel_item' : '');
+
+ if ($this->isThreaded()) {
+ $result['flatten'] = false;
+ $result['threaded'] = true;
+ } else {
+ $result['flatten'] = true;
+ $result['threaded'] = false;
+ }
+
+ return $result;
+ }
+
+ /**
+ * @return integer
+ */
+ public function getId()
+ {
+ return $this->getDataValue('id');
+ }
+
+ /**
+ * @return boolean
+ */
+ public function isThreaded()
+ {
+ return $this->threaded;
+ }
+
+ /**
+ * Add a child item
+ *
+ * @param object $item The child item to add
+ *
+ * @return mixed
+ */
+ public function addChild(Item $item)
+ {
+ $item_id = $item->getId();
+ if (!$item_id) {
+ logger('[ERROR] Item::addChild : Item has no ID!!', LOGGER_DEBUG);
+ return false;
+ } elseif ($this->getChild($item->getId())) {
+ logger('[WARN] Item::addChild : Item already exists ('. $item->getId() .').', LOGGER_DEBUG);
+ return false;
+ }
+ /*
+ * Only add what will be displayed
+ */
+ if ($item->getDataValue('network') === NETWORK_MAIL && local_user() != $item->getDataValue('uid')) {
+ return false;
+ } elseif (activity_match($item->getDataValue('verb'), ACTIVITY_LIKE) || activity_match($item->getDataValue('verb'), ACTIVITY_DISLIKE)) {
+ return false;
+ }
+
+ $item->setParent($this);
+ $this->children[] = $item;
+
+ return end($this->children);
+ }
+
+ /**
+ * Get a child by its ID
+ *
+ * @param integer $id The child id
+ *
+ * @return mixed
+ */
+ public function getChild($id)
+ {
+ foreach ($this->getChildren() as $child) {
+ if ($child->getId() == $id) {
+ return $child;
+ }
+ }
+
+ return null;
+ }
+
+ /**
+ * Get all our children
+ *
+ * @return object
+ */
+ public function getChildren()
+ {
+ return $this->children;
+ }
+
+ /**
+ * Set our parent
+ *
+ * @param object $item The item to set as parent
+ *
+ * @return void
+ */
+ protected function setParent($item)
+ {
+ $parent = $this->getParent();
+ if ($parent) {
+ $parent->removeChild($this);
+ }
+
+ $this->parent = $item;
+ $this->setConversation($item->getConversation());
+ }
+
+ /**
+ * Remove our parent
+ *
+ * @return void
+ */
+ protected function removeParent()
+ {
+ $this->parent = null;
+ $this->conversation = null;
+ }
+
+ /**
+ * Remove a child
+ *
+ * @param object $item The child to be removed
+ *
+ * @return boolean Success or failure
+ */
+ public function removeChild($item)
+ {
+ $id = $item->getId();
+ foreach ($this->getChildren() as $key => $child) {
+ if ($child->getId() == $id) {
+ $child->removeParent();
+ unset($this->children[$key]);
+ // Reindex the array, in order to make sure there won't be any trouble on loops using count()
+ $this->children = array_values($this->children);
+ return true;
+ }
+ }
+ logger('[WARN] Item::removeChild : Item is not a child ('. $id .').', LOGGER_DEBUG);
+ return false;
+ }
+
+ /**
+ * Get parent item
+ *
+ * @return object
+ */
+ protected function getParent()
+ {
+ return $this->parent;
+ }
+
+ /**
+ * Set conversation
+ *
+ * @param object $conv The conversation
+ *
+ * @return void
+ */
+ public function setConversation($conv)
+ {
+ $previous_mode = ($this->conversation ? $this->conversation->getMode() : '');
+
+ $this->conversation = $conv;
+
+ // Set it on our children too
+ foreach ($this->getChildren() as $child) {
+ $child->setConversation($conv);
+ }
+ }
+
+ /**
+ * Get conversation
+ *
+ * @return object
+ */
+ public function getConversation()
+ {
+ return $this->conversation;
+ }
+
+ /**
+ * Get raw data
+ *
+ * We shouldn't need this
+ *
+ * @return array
+ */
+ public function getData()
+ {
+ return $this->data;
+ }
+
+ /**
+ * Get a data value
+ *
+ * @param object $name key
+ *
+ * @return mixed value on success
+ * false on failure
+ */
+ public function getDataValue($name)
+ {
+ if (!isset($this->data[$name])) {
+ // logger('[ERROR] Item::getDataValue : Item has no value name "'. $name .'".', LOGGER_DEBUG);
+ return false;
+ }
+
+ return $this->data[$name];
+ }
+
+ /**
+ * Set template
+ *
+ * @param object $name template name
+ *
+ * @return void
+ */
+ private function setTemplate($name)
+ {
+ if (!x($this->available_templates, $name)) {
+ logger('[ERROR] Item::setTemplate : Template not available ("'. $name .'").', LOGGER_DEBUG);
+ return false;
+ }
+
+ $this->template = $this->available_templates[$name];
+ }
+
+ /**
+ * Get template
+ *
+ * @return object
+ */
+ private function getTemplate()
+ {
+ return $this->template;
+ }
+
+ /**
+ * Check if this is a toplevel post
+ *
+ * @return boolean
+ */
+ private function isToplevel()
+ {
+ return $this->toplevel;
+ }
+
+ /**
+ * Check if this is writable
+ *
+ * @return boolean
+ */
+ private function isWritable()
+ {
+ $conv = $this->getConversation();
+
+ if ($conv) {
+ // This will allow us to comment on wall-to-wall items owned by our friends
+ // and community forums even if somebody else wrote the post.
+
+ // bug #517 - this fixes for conversation owner
+ if ($conv->getMode() == 'profile' && $conv->getProfileOwner() == local_user()) {
+ return true;
+ }
+
+ // this fixes for visitors
+ return ($this->writable || ($this->isVisiting() && $conv->getMode() == 'profile'));
+ }
+ return $this->writable;
+ }
+
+ /**
+ * Count the total of our descendants
+ *
+ * @return integer
+ */
+ private function countDescendants()
+ {
+ $children = $this->getChildren();
+ $total = count($children);
+ if ($total > 0) {
+ foreach ($children as $child) {
+ $total += $child->countDescendants();
+ }
+ }
+
+ return $total;
+ }
+
+ /**
+ * Get the template for the comment box
+ *
+ * @return string
+ */
+ private function getCommentBoxTemplate()
+ {
+ return $this->comment_box_template;
+ }
+
+ /**
+ * Get the comment box
+ *
+ * @param string $indent Indent value
+ *
+ * @return mixed The comment box string (empty if no comment box)
+ * false on failure
+ */
+ private function getCommentBox($indent)
+ {
+ $a = self::getApp();
+
+ $comment_box = '';
+ $conv = $this->getConversation();
+ $template = get_markup_template($this->getCommentBoxTemplate());
+ $ww = '';
+ if (($conv->getMode() === 'network') && $this->isWallToWall()) {
+ $ww = 'ww';
+ }
+
+ if ($conv->isWritable() && $this->isWritable()) {
+ $qc = $qcomment = null;
+
+ /*
+ * Hmmm, code depending on the presence of a particular plugin?
+ * This should be better if done by a hook
+ */
+ if (in_array('qcomment', $a->plugins)) {
+ $qc = ((local_user()) ? PConfig::get(local_user(), 'qcomment', 'words') : null);
+ $qcomment = (($qc) ? explode("\n", $qc) : null);
+ }
+
+ $comment_box = replace_macros(
+ $template,
+ array(
+ '$return_path' => $a->query_string,
+ '$threaded' => $this->isThreaded(),
+ // '$jsreload' => (($conv->getMode() === 'display') ? $_SESSION['return_url'] : ''),
+ '$jsreload' => '',
+ '$type' => (($conv->getMode() === 'profile') ? 'wall-comment' : 'net-comment'),
+ '$id' => $this->getId(),
+ '$parent' => $this->getId(),
+ '$qcomment' => $qcomment,
+ '$profile_uid' => $conv->getProfileOwner(),
+ '$mylink' => $a->remove_baseurl($a->contact['url']),
+ '$mytitle' => t('This is you'),
+ '$myphoto' => $a->remove_baseurl($a->contact['thumb']),
+ '$comment' => t('Comment'),
+ '$submit' => t('Submit'),
+ '$edbold' => t('Bold'),
+ '$editalic' => t('Italic'),
+ '$eduline' => t('Underline'),
+ '$edquote' => t('Quote'),
+ '$edcode' => t('Code'),
+ '$edimg' => t('Image'),
+ '$edurl' => t('Link'),
+ '$edvideo' => t('Video'),
+ '$preview' => ((feature_enabled($conv->getProfileOwner(), 'preview')) ? t('Preview') : ''),
+ '$indent' => $indent,
+ '$sourceapp' => t($a->sourcename),
+ '$ww' => (($conv->getMode() === 'network') ? $ww : ''),
+ '$rand_num' => random_digits(12))
+ );
+ }
+
+ return $comment_box;
+ }
+
+ /**
+ * @return string
+ */
+ private function getRedirectUrl()
+ {
+ return $this->redirect_url;
+ }
+
+ /**
+ * Check if we are a wall to wall item and set the relevant properties
+ *
+ * @return void
+ */
+ protected function checkWallToWall()
+ {
+ $a = self::getApp();
+ $conv = $this->getConversation();
+ $this->wall_to_wall = false;
+
+ if ($this->isToplevel()) {
+ if ($conv->getMode() !== 'profile') {
+ if ($this->getDataValue('wall') && !$this->getDataValue('self')) {
+ // On the network page, I am the owner. On the display page it will be the profile owner.
+ // This will have been stored in $a->page_contact by our calling page.
+ // Put this person as the wall owner of the wall-to-wall notice.
+
+ $this->owner_url = zrl($a->page_contact['url']);
+ $this->owner_photo = $a->page_contact['thumb'];
+ $this->owner_name = $a->page_contact['name'];
+ $this->wall_to_wall = true;
+ } elseif ($this->getDataValue('owner-link')) {
+ $owner_linkmatch = (($this->getDataValue('owner-link')) && link_compare($this->getDataValue('owner-link'), $this->getDataValue('author-link')));
+ $alias_linkmatch = (($this->getDataValue('alias')) && link_compare($this->getDataValue('alias'), $this->getDataValue('author-link')));
+ $owner_namematch = (($this->getDataValue('owner-name')) && $this->getDataValue('owner-name') == $this->getDataValue('author-name'));
+
+ if ((! $owner_linkmatch) && (! $alias_linkmatch) && (! $owner_namematch)) {
+ // The author url doesn't match the owner (typically the contact)
+ // and also doesn't match the contact alias.
+ // The name match is a hack to catch several weird cases where URLs are
+ // all over the park. It can be tricked, but this prevents you from
+ // seeing "Bob Smith to Bob Smith via Wall-to-wall" and you know darn
+ // well that it's the same Bob Smith.
+
+ // But it could be somebody else with the same name. It just isn't highly likely.
+
+
+ $this->owner_photo = $this->getDataValue('owner-avatar');
+ $this->owner_name = $this->getDataValue('owner-name');
+ $this->wall_to_wall = true;
+ // If it is our contact, use a friendly redirect link
+ if ((link_compare($this->getDataValue('owner-link'), $this->getDataValue('url')))
+ && ($this->getDataValue('network') === NETWORK_DFRN)
+ ) {
+ $this->owner_url = $this->getRedirectUrl();
+ } else {
+ $this->owner_url = zrl($this->getDataValue('owner-link'));
+ }
+ }
+ }
+ }
+ }
+
+ if (!$this->wall_to_wall) {
+ $this->setTemplate('wall');
+ $this->owner_url = '';
+ $this->owner_photo = '';
+ $this->owner_name = '';
+ }
+ }
+
+ /**
+ * @return boolean
+ */
+ private function isWallToWall()
+ {
+ return $this->wall_to_wall;
+ }
+
+ /**
+ * @return string
+ */
+ private function getOwnerUrl()
+ {
+ return $this->owner_url;
+ }
+
+ /**
+ * @return string
+ */
+ private function getOwnerPhoto()
+ {
+ return $this->owner_photo;
+ }
+
+ /**
+ * @return string
+ */
+ private function getOwnerName()
+ {
+ return $this->owner_name;
+ }
+
+ /**
+ * @return boolean
+ */
+ private function isVisiting()
+ {
+ return $this->visiting;
+ }
+}
--- /dev/null
+<?php
+
+/**
+ * @file src/Object/Profile.php
+ */
+
+namespace Friendica\Object;
+
+use Friendica\BaseObject;
+
+class Profile extends BaseObject
+{
+ /**
+ * @brief Returns a formatted location string from the given profile array
+ *
+ * @param array $profile Profile array (Generated from the "profile" table)
+ *
+ * @return string Location string
+ */
+ public static function formatLocation(array $profile)
+ {
+ $location = '';
+
+ if ($profile['locality']) {
+ $location .= $profile['locality'];
+ }
+
+ if ($profile['region'] && ($profile['locality'] != $profile['region'])) {
+ if ($location) {
+ $location .= ', ';
+ }
+
+ $location .= $profile['region'];
+ }
+
+ if ($profile['country-name']) {
+ if ($location) {
+ $location .= ', ';
+ }
+
+ $location .= $profile['country-name'];
+ }
+
+ return $location;
+ }
+}
*
* @param string $tag The pure tag name
* @param int $k Counter for internal use
+ * @return void
*/
private static function arrAddHashes(&$tag, $k)
{
use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Object\Contact;
+use Friendica\Object\Profile;
+use Friendica\Protocol\OStatus;
use Friendica\Util\XML;
use dba;
use DOMDocument;
use DomXPath;
-use ostatus;
-require_once "include/Contact.php";
require_once "include/enotify.php";
require_once "include/threads.php";
-require_once "include/socgraph.php";
require_once "include/items.php";
require_once "include/tags.php";
require_once "include/files.php";
$doc = new DOMDocument('1.0', 'utf-8');
$doc->formatOutput = true;
- $root = self::add_header($doc, $owner, "dfrn:owner", "", false);
+ $root = self::addHeader($doc, $owner, "dfrn:owner", "", false);
if (! count($items)) {
return trim($doc->saveXML());
$author = "author";
}
- $root = self::add_header($doc, $owner, $author, $alternatelink, true);
+ $root = self::addHeader($doc, $owner, $author, $alternatelink, true);
/// @TODO This hook can't work anymore
// call_hooks('atom_feed', $atom);
$root->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
$root->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
- //$root = self::add_header($doc, $owner, "dfrn:owner", "", false);
+ //$root = self::addHeader($doc, $owner, "dfrn:owner", "", false);
foreach ($items as $item) {
$entry = self::entry($doc, $type, $item, $owner, true, 0);
$doc = new DOMDocument('1.0', 'utf-8');
$doc->formatOutput = true;
- $root = self::add_header($doc, $owner, "dfrn:owner", "", false);
+ $root = self::addHeader($doc, $owner, "dfrn:owner", "", false);
$mail = $doc->createElement("dfrn:mail");
$sender = $doc->createElement("dfrn:sender");
- XML::add_element($doc, $sender, "dfrn:name", $owner['name']);
- XML::add_element($doc, $sender, "dfrn:uri", $owner['url']);
- XML::add_element($doc, $sender, "dfrn:avatar", $owner['thumb']);
+ XML::addElement($doc, $sender, "dfrn:name", $owner['name']);
+ XML::addElement($doc, $sender, "dfrn:uri", $owner['url']);
+ XML::addElement($doc, $sender, "dfrn:avatar", $owner['thumb']);
$mail->appendChild($sender);
- XML::add_element($doc, $mail, "dfrn:id", $item['uri']);
- XML::add_element($doc, $mail, "dfrn:in-reply-to", $item['parent-uri']);
- XML::add_element($doc, $mail, "dfrn:sentdate", datetime_convert('UTC', 'UTC', $item['created'] . '+00:00' , ATOM_TIME));
- XML::add_element($doc, $mail, "dfrn:subject", $item['title']);
- XML::add_element($doc, $mail, "dfrn:content", $item['body']);
+ XML::addElement($doc, $mail, "dfrn:id", $item['uri']);
+ XML::addElement($doc, $mail, "dfrn:in-reply-to", $item['parent-uri']);
+ XML::addElement($doc, $mail, "dfrn:sentdate", datetime_convert('UTC', 'UTC', $item['created'] . '+00:00', ATOM_TIME));
+ XML::addElement($doc, $mail, "dfrn:subject", $item['title']);
+ XML::addElement($doc, $mail, "dfrn:content", $item['body']);
$root->appendChild($mail);
$doc = new DOMDocument('1.0', 'utf-8');
$doc->formatOutput = true;
- $root = self::add_header($doc, $owner, "dfrn:owner", "", false);
+ $root = self::addHeader($doc, $owner, "dfrn:owner", "", false);
$suggest = $doc->createElement("dfrn:suggest");
- XML::add_element($doc, $suggest, "dfrn:url", $item['url']);
- XML::add_element($doc, $suggest, "dfrn:name", $item['name']);
- XML::add_element($doc, $suggest, "dfrn:photo", $item['photo']);
- XML::add_element($doc, $suggest, "dfrn:request", $item['request']);
- XML::add_element($doc, $suggest, "dfrn:note", $item['note']);
+ XML::addElement($doc, $suggest, "dfrn:url", $item['url']);
+ XML::addElement($doc, $suggest, "dfrn:name", $item['name']);
+ XML::addElement($doc, $suggest, "dfrn:photo", $item['photo']);
+ XML::addElement($doc, $suggest, "dfrn:request", $item['request']);
+ XML::addElement($doc, $suggest, "dfrn:note", $item['note']);
$root->appendChild($suggest);
$doc = new DOMDocument('1.0', 'utf-8');
$doc->formatOutput = true;
- $root = self::add_header($doc, $owner, "dfrn:owner", "", false);
+ $root = self::addHeader($doc, $owner, "dfrn:owner", "", false);
$relocate = $doc->createElement("dfrn:relocate");
- XML::add_element($doc, $relocate, "dfrn:url", $owner['url']);
- XML::add_element($doc, $relocate, "dfrn:name", $owner['name']);
- XML::add_element($doc, $relocate, "dfrn:addr", $owner['addr']);
- XML::add_element($doc, $relocate, "dfrn:avatar", $owner['avatar']);
- XML::add_element($doc, $relocate, "dfrn:photo", $photos[4]);
- XML::add_element($doc, $relocate, "dfrn:thumb", $photos[5]);
- XML::add_element($doc, $relocate, "dfrn:micro", $photos[6]);
- XML::add_element($doc, $relocate, "dfrn:request", $owner['request']);
- XML::add_element($doc, $relocate, "dfrn:confirm", $owner['confirm']);
- XML::add_element($doc, $relocate, "dfrn:notify", $owner['notify']);
- XML::add_element($doc, $relocate, "dfrn:poll", $owner['poll']);
- XML::add_element($doc, $relocate, "dfrn:sitepubkey", Config::get('system','site_pubkey'));
+ XML::addElement($doc, $relocate, "dfrn:url", $owner['url']);
+ XML::addElement($doc, $relocate, "dfrn:name", $owner['name']);
+ XML::addElement($doc, $relocate, "dfrn:addr", $owner['addr']);
+ XML::addElement($doc, $relocate, "dfrn:avatar", $owner['avatar']);
+ XML::addElement($doc, $relocate, "dfrn:photo", $photos[4]);
+ XML::addElement($doc, $relocate, "dfrn:thumb", $photos[5]);
+ XML::addElement($doc, $relocate, "dfrn:micro", $photos[6]);
+ XML::addElement($doc, $relocate, "dfrn:request", $owner['request']);
+ XML::addElement($doc, $relocate, "dfrn:confirm", $owner['confirm']);
+ XML::addElement($doc, $relocate, "dfrn:notify", $owner['notify']);
+ XML::addElement($doc, $relocate, "dfrn:poll", $owner['poll']);
+ XML::addElement($doc, $relocate, "dfrn:sitepubkey", Config::get('system', 'site_pubkey'));
$root->appendChild($relocate);
* @return object XML root object
* @todo Add type-hints
*/
- private static function add_header($doc, $owner, $authorelement, $alternatelink = "", $public = false)
+ private static function addHeader($doc, $owner, $authorelement, $alternatelink = "", $public = false)
{
if ($alternatelink == "") {
$root->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
$root->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
- XML::add_element($doc, $root, "id", System::baseUrl()."/profile/".$owner["nick"]);
- XML::add_element($doc, $root, "title", $owner["name"]);
+ XML::addElement($doc, $root, "id", System::baseUrl()."/profile/".$owner["nick"]);
+ XML::addElement($doc, $root, "title", $owner["name"]);
$attributes = array("uri" => "https://friendi.ca", "version" => FRIENDICA_VERSION."-".DB_UPDATE_VERSION);
- XML::add_element($doc, $root, "generator", FRIENDICA_PLATFORM, $attributes);
+ XML::addElement($doc, $root, "generator", FRIENDICA_PLATFORM, $attributes);
$attributes = array("rel" => "license", "href" => "http://creativecommons.org/licenses/by/3.0/");
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
$attributes = array("rel" => "alternate", "type" => "text/html", "href" => $alternatelink);
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
if ($public) {
// DFRN itself doesn't uses this. But maybe someone else wants to subscribe to the public feed.
- ostatus::hublinks($doc, $root, $owner["nick"]);
+ OStatus::hublinks($doc, $root, $owner["nick"]);
$attributes = array("rel" => "salmon", "href" => System::baseUrl()."/salmon/".$owner["nick"]);
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
$attributes = array("rel" => "http://salmon-protocol.org/ns/salmon-replies", "href" => System::baseUrl()."/salmon/".$owner["nick"]);
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
$attributes = array("rel" => "http://salmon-protocol.org/ns/salmon-mention", "href" => System::baseUrl()."/salmon/".$owner["nick"]);
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
}
// For backward compatibility we keep this element
if ($owner['page-flags'] == PAGE_COMMUNITY) {
- XML::add_element($doc, $root, "dfrn:community", 1);
+ XML::addElement($doc, $root, "dfrn:community", 1);
}
// The former element is replaced by this one
- XML::add_element($doc, $root, "dfrn:account_type", $owner["account-type"]);
+ XML::addElement($doc, $root, "dfrn:account_type", $owner["account-type"]);
/// @todo We need a way to transmit the different page flags like "PAGE_PRVGROUP"
- XML::add_element($doc, $root, "updated", datetime_convert("UTC", "UTC", "now", ATOM_TIME));
+ XML::addElement($doc, $root, "updated", datetime_convert("UTC", "UTC", "now", ATOM_TIME));
- $author = self::add_author($doc, $owner, $authorelement, $public);
+ $author = self::addAuthor($doc, $owner, $authorelement, $public);
$root->appendChild($author);
return $root;
/**
* @brief Adds the author element in the header for the DFRN protocol
*
- * @param object $doc XML document
- * @param array $owner Owner record
- * @param string $authorelement Element name for the author
+ * @param object $doc XML document
+ * @param array $owner Owner record
+ * @param string $authorelement Element name for the author
+ * @param boolean $public boolean
*
* @return object XML author object
* @todo Add type-hints
*/
- private static function add_author($doc, $owner, $authorelement, $public)
+ private static function addAuthor($doc, $owner, $authorelement, $public)
{
// Is the profile hidden or shouldn't be published in the net? Then add the "hide" element
$r = q(
$attributes = array("dfrn:updated" => $namdate);
}
- XML::add_element($doc, $author, "name", $owner["name"], $attributes);
- XML::add_element($doc, $author, "uri", System::baseUrl().'/profile/'.$owner["nickname"], $attributes);
- XML::add_element($doc, $author, "dfrn:handle", $owner["addr"], $attributes);
+ XML::addElement($doc, $author, "name", $owner["name"], $attributes);
+ XML::addElement($doc, $author, "uri", System::baseUrl().'/profile/'.$owner["nickname"], $attributes);
+ XML::addElement($doc, $author, "dfrn:handle", $owner["addr"], $attributes);
$attributes = array("rel" => "photo", "type" => "image/jpeg",
"media:width" => 175, "media:height" => 175, "href" => $owner['photo']);
$attributes["dfrn:updated"] = $picdate;
}
- XML::add_element($doc, $author, "link", "", $attributes);
+ XML::addElement($doc, $author, "link", "", $attributes);
$attributes["rel"] = "avatar";
- XML::add_element($doc, $author, "link", "", $attributes);
+ XML::addElement($doc, $author, "link", "", $attributes);
if ($hidewall) {
- XML::add_element($doc, $author, "dfrn:hide", "true");
+ XML::addElement($doc, $author, "dfrn:hide", "true");
}
// The following fields will only be generated if the data isn't meant for a public feed
$birthday = feed_birthday($owner['uid'], $owner['timezone']);
if ($birthday) {
- XML::add_element($doc, $author, "dfrn:birthday", $birthday);
+ XML::addElement($doc, $author, "dfrn:birthday", $birthday);
}
// Only show contact details when we are allowed to
if (DBM::is_result($r)) {
$profile = $r[0];
- XML::add_element($doc, $author, "poco:displayName", $profile["name"]);
- XML::add_element($doc, $author, "poco:updated", $namdate);
+ XML::addElement($doc, $author, "poco:displayName", $profile["name"]);
+ XML::addElement($doc, $author, "poco:updated", $namdate);
if (trim($profile["dob"]) > '0001-01-01') {
- XML::add_element($doc, $author, "poco:birthday", "0000-".date("m-d", strtotime($profile["dob"])));
+ XML::addElement($doc, $author, "poco:birthday", "0000-".date("m-d", strtotime($profile["dob"])));
}
- XML::add_element($doc, $author, "poco:note", $profile["about"]);
- XML::add_element($doc, $author, "poco:preferredUsername", $profile["nickname"]);
+ XML::addElement($doc, $author, "poco:note", $profile["about"]);
+ XML::addElement($doc, $author, "poco:preferredUsername", $profile["nickname"]);
$savetz = date_default_timezone_get();
date_default_timezone_set($profile["timezone"]);
- XML::add_element($doc, $author, "poco:utcOffset", date("P"));
+ XML::addElement($doc, $author, "poco:utcOffset", date("P"));
date_default_timezone_set($savetz);
if (trim($profile["homepage"]) != "") {
$urls = $doc->createElement("poco:urls");
- XML::add_element($doc, $urls, "poco:type", "homepage");
- XML::add_element($doc, $urls, "poco:value", $profile["homepage"]);
- XML::add_element($doc, $urls, "poco:primary", "true");
+ XML::addElement($doc, $urls, "poco:type", "homepage");
+ XML::addElement($doc, $urls, "poco:value", $profile["homepage"]);
+ XML::addElement($doc, $urls, "poco:primary", "true");
$author->appendChild($urls);
}
$keywords = explode(",", $profile["pub_keywords"]);
foreach ($keywords as $keyword) {
- XML::add_element($doc, $author, "poco:tags", trim($keyword));
+ XML::addElement($doc, $author, "poco:tags", trim($keyword));
}
}
if (trim($profile["xmpp"]) != "") {
$ims = $doc->createElement("poco:ims");
- XML::add_element($doc, $ims, "poco:type", "xmpp");
- XML::add_element($doc, $ims, "poco:value", $profile["xmpp"]);
- XML::add_element($doc, $ims, "poco:primary", "true");
+ XML::addElement($doc, $ims, "poco:type", "xmpp");
+ XML::addElement($doc, $ims, "poco:value", $profile["xmpp"]);
+ XML::addElement($doc, $ims, "poco:primary", "true");
$author->appendChild($ims);
}
if (trim($profile["locality"].$profile["region"].$profile["country-name"]) != "") {
$element = $doc->createElement("poco:address");
- XML::add_element($doc, $element, "poco:formatted", formatted_location($profile));
+ XML::addElement($doc, $element, "poco:formatted", Profile::formatLocation($profile));
if (trim($profile["locality"]) != "") {
- XML::add_element($doc, $element, "poco:locality", $profile["locality"]);
+ XML::addElement($doc, $element, "poco:locality", $profile["locality"]);
}
if (trim($profile["region"]) != "") {
- XML::add_element($doc, $element, "poco:region", $profile["region"]);
+ XML::addElement($doc, $element, "poco:region", $profile["region"]);
}
if (trim($profile["country-name"]) != "") {
- XML::add_element($doc, $element, "poco:country", $profile["country-name"]);
+ XML::addElement($doc, $element, "poco:country", $profile["country-name"]);
}
$author->appendChild($element);
* @return object XML author object
* @todo Add type-hints
*/
- private static function add_entry_author($doc, $element, $contact_url, $item)
+ private static function addEntryAuthor($doc, $element, $contact_url, $item)
{
-
- $contact = get_contact_details_by_url($contact_url, $item["uid"]);
+ $contact = Contact::getDetailsByURL($contact_url, $item["uid"]);
$author = $doc->createElement($element);
- XML::add_element($doc, $author, "name", $contact["name"]);
- XML::add_element($doc, $author, "uri", $contact["url"]);
- XML::add_element($doc, $author, "dfrn:handle", $contact["addr"]);
+ XML::addElement($doc, $author, "name", $contact["name"]);
+ XML::addElement($doc, $author, "uri", $contact["url"]);
+ XML::addElement($doc, $author, "dfrn:handle", $contact["addr"]);
/// @Todo
/// - Check real image type and image size
"media:width" => 80,
"media:height" => 80,
"href" => $contact["photo"]);
- XML::add_element($doc, $author, "link", "", $attributes);
+ XML::addElement($doc, $author, "link", "", $attributes);
$attributes = array(
"rel" => "avatar",
"media:width" => 80,
"media:height" => 80,
"href" => $contact["photo"]);
- XML::add_element($doc, $author, "link", "", $attributes);
+ XML::addElement($doc, $author, "link", "", $attributes);
return $author;
}
* @return object XML activity object
* @todo Add type-hints
*/
- private static function create_activity($doc, $element, $activity)
+ private static function createActivity($doc, $element, $activity)
{
if ($activity) {
$entry = $doc->createElement($element);
return false;
}
if ($r->type) {
- XML::add_element($doc, $entry, "activity:object-type", $r->type);
+ XML::addElement($doc, $entry, "activity:object-type", $r->type);
}
if ($r->id) {
- XML::add_element($doc, $entry, "id", $r->id);
+ XML::addElement($doc, $entry, "id", $r->id);
}
if ($r->title) {
- XML::add_element($doc, $entry, "title", $r->title);
+ XML::addElement($doc, $entry, "title", $r->title);
}
if ($r->link) {
// XML does need a single element as root element so we add a dummy element here
$data = parse_xml_string("<dummy>" . $r->link . "</dummy>", false);
if (is_object($data)) {
- foreach ($data->link AS $link) {
+ foreach ($data->link as $link) {
$attributes = array();
foreach ($link->attributes() as $parameter => $value) {
$attributes[$parameter] = $value;
}
- XML::add_element($doc, $entry, "link", "", $attributes);
+ XML::addElement($doc, $entry, "link", "", $attributes);
}
}
} else {
$attributes = array("rel" => "alternate", "type" => "text/html", "href" => $r->link);
- XML::add_element($doc, $entry, "link", "", $attributes);
+ XML::addElement($doc, $entry, "link", "", $attributes);
}
}
if ($r->content) {
- XML::add_element($doc, $entry, "content", bbcode($r->content), array("type" => "html"));
+ XML::addElement($doc, $entry, "content", bbcode($r->content), array("type" => "html"));
}
return $entry;
* @return object XML attachment object
* @todo Add type-hints
*/
- private static function get_attachment($doc, $root, $item)
+ private static function getAttachment($doc, $root, $item)
{
$arr = explode('[/attach],', $item['attach']);
if (count($arr)) {
$attributes["title"] = trim($matches[4]);
}
- XML::add_element($doc, $root, "link", "", $attributes);
+ XML::addElement($doc, $root, "link", "", $attributes);
}
}
}
if ($item['deleted']) {
$attributes = array("ref" => $item['uri'], "when" => datetime_convert('UTC', 'UTC', $item['edited'] . '+00:00', ATOM_TIME));
- return XML::create_element($doc, "at:deleted-entry", "", $attributes);
+ return XML::createElement($doc, "at:deleted-entry", "", $attributes);
}
if (!$single) {
$htmlbody = bbcode($htmlbody, false, false, 7);
}
- $author = self::add_entry_author($doc, "author", $item["author-link"], $item);
+ $author = self::addEntryAuthor($doc, "author", $item["author-link"], $item);
$entry->appendChild($author);
- $dfrnowner = self::add_entry_author($doc, "dfrn:owner", $item["owner-link"], $item);
+ $dfrnowner = self::addEntryAuthor($doc, "dfrn:owner", $item["owner-link"], $item);
$entry->appendChild($dfrnowner);
if (($item['parent'] != $item['id']) || ($item['parent-uri'] !== $item['uri']) || (($item['thr-parent'] !== '') && ($item['thr-parent'] !== $item['uri']))) {
$attributes = array("ref" => $parent_item, "type" => "text/html",
"href" => $parent[0]['plink'],
"dfrn:diaspora_guid" => $parent[0]['guid']);
- XML::add_element($doc, $entry, "thr:in-reply-to", "", $attributes);
+ XML::addElement($doc, $entry, "thr:in-reply-to", "", $attributes);
}
// Add conversation data. This is used for OStatus
"href" => $conversation_href,
"ref" => $conversation_uri);
- XML::add_element($doc, $entry, "ostatus:conversation", $conversation_uri, $attributes);
+ XML::addElement($doc, $entry, "ostatus:conversation", $conversation_uri, $attributes);
- XML::add_element($doc, $entry, "id", $item["uri"]);
- XML::add_element($doc, $entry, "title", $item["title"]);
+ XML::addElement($doc, $entry, "id", $item["uri"]);
+ XML::addElement($doc, $entry, "title", $item["title"]);
- XML::add_element($doc, $entry, "published", datetime_convert("UTC", "UTC", $item["created"] . "+00:00", ATOM_TIME));
- XML::add_element($doc, $entry, "updated", datetime_convert("UTC", "UTC", $item["edited"] . "+00:00", ATOM_TIME));
+ XML::addElement($doc, $entry, "published", datetime_convert("UTC", "UTC", $item["created"] . "+00:00", ATOM_TIME));
+ XML::addElement($doc, $entry, "updated", datetime_convert("UTC", "UTC", $item["edited"] . "+00:00", ATOM_TIME));
// "dfrn:env" is used to read the content
- XML::add_element($doc, $entry, "dfrn:env", base64url_encode($body, true));
+ XML::addElement($doc, $entry, "dfrn:env", base64url_encode($body, true));
// The "content" field is not read by the receiver. We could remove it when the type is "text"
// We keep it at the moment, maybe there is some old version that doesn't read "dfrn:env"
- XML::add_element($doc, $entry, "content", (($type == 'html') ? $htmlbody : $body), array("type" => $type));
+ XML::addElement($doc, $entry, "content", (($type == 'html') ? $htmlbody : $body), array("type" => $type));
// We save this value in "plink". Maybe we should read it from there as well?
- XML::add_element(
+ XML::addElement(
$doc,
$entry,
"link",
// "comment-allow" is some old fashioned stuff for old Friendica versions.
// It is included in the rewritten code for completeness
if ($comment) {
- XML::add_element($doc, $entry, "dfrn:comment-allow", intval($item['last-child']));
+ XML::addElement($doc, $entry, "dfrn:comment-allow", intval($item['last-child']));
}
if ($item['location']) {
- XML::add_element($doc, $entry, "dfrn:location", $item['location']);
+ XML::addElement($doc, $entry, "dfrn:location", $item['location']);
}
if ($item['coord']) {
- XML::add_element($doc, $entry, "georss:point", $item['coord']);
+ XML::addElement($doc, $entry, "georss:point", $item['coord']);
}
if (($item['private']) || strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid'])) {
- XML::add_element($doc, $entry, "dfrn:private", (($item['private']) ? $item['private'] : 1));
+ XML::addElement($doc, $entry, "dfrn:private", (($item['private']) ? $item['private'] : 1));
}
if ($item['extid']) {
- XML::add_element($doc, $entry, "dfrn:extid", $item['extid']);
+ XML::addElement($doc, $entry, "dfrn:extid", $item['extid']);
}
if ($item['bookmark']) {
- XML::add_element($doc, $entry, "dfrn:bookmark", "true");
+ XML::addElement($doc, $entry, "dfrn:bookmark", "true");
}
if ($item['app']) {
- XML::add_element($doc, $entry, "statusnet:notice_info", "", array("local_id" => $item['id'], "source" => $item['app']));
+ XML::addElement($doc, $entry, "statusnet:notice_info", "", array("local_id" => $item['id'], "source" => $item['app']));
}
- XML::add_element($doc, $entry, "dfrn:diaspora_guid", $item["guid"]);
+ XML::addElement($doc, $entry, "dfrn:diaspora_guid", $item["guid"]);
// The signed text contains the content in Markdown, the sender handle and the signatur for the content
// It is needed for relayed comments to Diaspora.
if ($item['signed_text']) {
$sign = base64_encode(json_encode(array('signed_text' => $item['signed_text'],'signature' => $item['signature'],'signer' => $item['signer'])));
- XML::add_element($doc, $entry, "dfrn:diaspora_signature", $sign);
+ XML::addElement($doc, $entry, "dfrn:diaspora_signature", $sign);
}
- XML::add_element($doc, $entry, "activity:verb", construct_verb($item));
+ XML::addElement($doc, $entry, "activity:verb", construct_verb($item));
if ($item['object-type'] != "") {
- XML::add_element($doc, $entry, "activity:object-type", $item['object-type']);
+ XML::addElement($doc, $entry, "activity:object-type", $item['object-type']);
} elseif ($item['id'] == $item['parent']) {
- XML::add_element($doc, $entry, "activity:object-type", ACTIVITY_OBJ_NOTE);
+ XML::addElement($doc, $entry, "activity:object-type", ACTIVITY_OBJ_NOTE);
} else {
- XML::add_element($doc, $entry, "activity:object-type", ACTIVITY_OBJ_COMMENT);
+ XML::addElement($doc, $entry, "activity:object-type", ACTIVITY_OBJ_COMMENT);
}
- $actobj = self::create_activity($doc, "activity:object", $item['object']);
+ $actobj = self::createActivity($doc, "activity:object", $item['object']);
if ($actobj) {
$entry->appendChild($actobj);
}
- $actarg = self::create_activity($doc, "activity:target", $item['target']);
+ $actarg = self::createActivity($doc, "activity:target", $item['target']);
if ($actarg) {
$entry->appendChild($actarg);
}
if (count($tags)) {
foreach ($tags as $t) {
if (($type != 'html') || ($t[0] != "@")) {
- XML::add_element($doc, $entry, "category", "", array("scheme" => "X-DFRN:".$t[0].":".$t[1], "term" => $t[2]));
+ XML::addElement($doc, $entry, "category", "", array("scheme" => "X-DFRN:".$t[0].":".$t[1], "term" => $t[2]));
}
}
}
);
if (DBM::is_result($r) && ($r[0]["forum"] || $r[0]["prv"])) {
- XML::add_element(
+ XML::addElement(
$doc,
$entry,
"link",
"href" => $mention)
);
} else {
- XML::add_element(
+ XML::addElement(
$doc,
$entry,
"link",
}
}
- self::get_attachment($doc, $entry, $item);
+ self::getAttachment($doc, $entry, $item);
return $entry;
}
*
* @return string encrypted data
*/
- private static function aes_encrypt($data, $key)
+ private static function aesEncrypt($data, $key)
{
return openssl_encrypt($data, 'aes-128-ecb', $key, OPENSSL_RAW_DATA);
}
*
* @return string decrypted data
*/
- public static function aes_decrypt($encrypted, $key)
+ public static function aesDecrypt($encrypted, $key)
{
return openssl_decrypt($encrypted, 'aes-128-ecb', $key, OPENSSL_RAW_DATA);
}
case 1:
// Deprecated rino version!
$key = openssl_random_pseudo_bytes(16);
- $data = self::aes_encrypt($postvars['data'], $key);
+ $data = self::aesEncrypt($postvars['data'], $key);
break;
case 2:
// RINO 2 based on php-encryption
if ($contact['term-date'] > NULL_DATE) {
logger("dfrn_deliver: $url back from the dead - removing mark for death");
- include_once 'include/Contact.php';
- unmark_for_death($contact);
+ Contact::unmarkForArchival($contact);
}
$res = parse_xml_string($xml);
*
* @param array $contact Contact record
* @param string $birthday Birthday of the contact
+ * @return void
* @todo Add array type-hint for $contact
*/
- private static function birthday_event($contact, $birthday)
+ private static function birthdayEvent($contact, $birthday)
{
// Check for duplicates
$r = q(
logger("updating birthday: ".$birthday." for contact ".$contact["id"]);
$bdtext = sprintf(t("%s\'s birthday"), $contact["name"]);
- $bdtext2 = sprintf(t("Happy Birthday %s"), " [url=".$contact["url"]."]".$contact["name"]."[/url]") ;
+ $bdtext2 = sprintf(t("Happy Birthday %s"), " [url=".$contact["url"]."]".$contact["name"]."[/url]");
$r = q(
"INSERT INTO `event` (`uid`,`cid`,`created`,`edited`,`start`,`finish`,`summary`,`desc`,`type`)
* @param array $importer Record of the importer user mixed with contact of the content
* @param string $element Element name from which the data is fetched
* @param bool $onlyfetch Should the data only be fetched or should it update the contact record as well
+ * @param string $xml optional, default empty
*
* @return Returns an array with relevant data of the author
* @todo Find good type-hints for all parameter
$avatarlist = array();
/// @todo check if "avatar" or "photo" would be the best field in the specification
$avatars = $xpath->query($element."/atom:link[@rel='avatar']", $context);
- foreach ($avatars AS $avatar) {
+ foreach ($avatars as $avatar) {
$href = "";
$width = 0;
- foreach ($avatar->attributes AS $attributes) {
+ foreach ($avatar->attributes as $attributes) {
/// @TODO Rewrite these similar if () to one switch
if ($attributes->name == "href") {
$href = $attributes->textContent;
// When was the last change to name or uri?
$name_element = $xpath->query($element . "/atom:name", $context)->item(0);
- foreach ($name_element->attributes AS $attributes) {
+ foreach ($name_element->attributes as $attributes) {
if ($attributes->name == "updated") {
$poco["name-date"] = $attributes->textContent;
}
}
$link_element = $xpath->query($element . "/atom:link", $context)->item(0);
- foreach ($link_element->attributes AS $attributes) {
+ foreach ($link_element->attributes as $attributes) {
if ($attributes->name == "updated") {
$poco["uri-date"] = $attributes->textContent;
}
// Save the keywords into the contact table
$tags = array();
$tagelements = $xpath->evaluate($element . "/poco:tags/text()", $context);
- foreach ($tagelements AS $tag) {
+ foreach ($tagelements as $tag) {
$tags[$tag->nodeValue] = $tag->nodeValue;
}
$contact = array_merge($contact, $poco);
if ($old_bdyear != $contact["bdyear"]) {
- self::birthday_event($contact, $birthday);
+ self::birthdayEvent($contact, $birthday);
}
// Get all field names
$fields = array();
- foreach ($r[0] AS $field => $data) {
+ foreach ($r[0] as $field => $data) {
$fields[$field] = $data;
}
// Update check for this field has to be done differently
$datefields = array("name-date", "uri-date");
- foreach ($datefields AS $field) {
+ foreach ($datefields as $field) {
if (strtotime($contact[$field]) > strtotime($r[0][$field])) {
logger("Difference for contact " . $contact["id"] . " in field '" . $field . "'. New value: '" . $contact[$field] . "', old value '" . $r[0][$field] . "'", LOGGER_DEBUG);
$update = true;
}
}
- foreach ($fields AS $field => $data) {
+ foreach ($fields as $field => $data) {
if ($contact[$field] != $r[0][$field]) {
logger("Difference for contact " . $contact["id"] . " in field '" . $field . "'. New value: '" . $contact[$field] . "', old value '" . $r[0][$field] . "'", LOGGER_DEBUG);
$update = true;
$poco["photo"] = $author["avatar"];
$poco["hide"] = $hide;
$poco["contact-type"] = $contact["contact-type"];
- $gcid = update_gcontact($poco);
+ $gcid = GlobalContact::update($poco);
- link_gcontact($gcid, $importer["uid"], $contact["id"]);
+ GlobalContact::link($gcid, $importer["uid"], $contact["id"]);
}
return($author);
* @return string XML string
* @todo Find good type-hints for all parameter
*/
- private static function transform_activity($xpath, $activity, $element)
+ private static function transformActivity($xpath, $activity, $element)
{
if (!is_object($activity)) {
return "";
$obj_element = $obj_doc->createElementNS(NAMESPACE_ATOM1, $element);
$activity_type = $xpath->query("activity:object-type/text()", $activity)->item(0)->nodeValue;
- XML::add_element($obj_doc, $obj_element, "type", $activity_type);
+ XML::addElement($obj_doc, $obj_element, "type", $activity_type);
$id = $xpath->query("atom:id", $activity)->item(0);
if (is_object($id)) {
* @param object $xpath XPath object
* @param object $mail mail elements
* @param array $importer Record of the importer user mixed with contact of the content
+ * @return void
* @todo Find good type-hints for all parameter
*/
- private static function process_mail($xpath, $mail, $importer)
+ private static function processMail($xpath, $mail, $importer)
{
logger("Processing mails");
* @param object $xpath XPath object
* @param object $suggestion suggestion elements
* @param array $importer Record of the importer user mixed with contact of the content
+ * @return boolean
* @todo Find good type-hints for all parameter
*/
- private static function process_suggestion($xpath, $suggestion, $importer)
+ private static function processSuggestion($xpath, $suggestion, $importer)
{
$a = get_app();
intval(0)
);
- notification(array(
- "type" => NOTIFY_SUGGEST,
- "notify_flags" => $importer["notify-flags"],
- "language" => $importer["language"],
- "to_name" => $importer["username"],
- "to_email" => $importer["email"],
- "uid" => $importer["importer_uid"],
- "item" => $suggest,
- "link" => System::baseUrl()."/notifications/intros",
- "source_name" => $importer["name"],
- "source_link" => $importer["url"],
- "source_photo" => $importer["photo"],
- "verb" => ACTIVITY_REQ_FRIEND,
- "otype" => "intro")
+ notification(
+ array(
+ "type" => NOTIFY_SUGGEST,
+ "notify_flags" => $importer["notify-flags"],
+ "language" => $importer["language"],
+ "to_name" => $importer["username"],
+ "to_email" => $importer["email"],
+ "uid" => $importer["importer_uid"],
+ "item" => $suggest,
+ "link" => System::baseUrl()."/notifications/intros",
+ "source_name" => $importer["name"],
+ "source_link" => $importer["url"],
+ "source_photo" => $importer["photo"],
+ "verb" => ACTIVITY_REQ_FRIEND,
+ "otype" => "intro")
);
return true;
* @param object $xpath XPath object
* @param object $relocation relocation elements
* @param array $importer Record of the importer user mixed with contact of the content
+ * @return boolean
* @todo Find good type-hints for all parameter
*/
- private static function process_relocation($xpath, $relocation, $importer)
+ private static function processRelocation($xpath, $relocation, $importer)
{
logger("Processing relocations");
* @param array $item the new item record
* @param array $importer Record of the importer user mixed with contact of the content
* @param int $entrytype Is it a toplevel entry, a comment or a relayed comment?
+ * @return mixed
* @todo set proper type-hints (array?)
*/
- private static function update_content($current, $item, $importer, $entrytype)
+ private static function updateContent($current, $item, $importer, $entrytype)
{
$changed = false;
$changed = true;
if ($entrytype == DFRN_REPLY_RC) {
- Worker::add(PRIORITY_HIGH, "notifier", "comment-import", $current["id"]);
+ Worker::add(PRIORITY_HIGH, "Notifier", "comment-import", $current["id"]);
}
}
* @return int Is it a toplevel entry, a comment or a relayed comment?
* @todo set proper type-hints (array?)
*/
- private static function get_entry_type($importer, $item)
+ private static function getEntryType($importer, $item)
{
if ($item["parent-uri"] != $item["uri"]) {
$community = false;
* @param array $item the new item record
* @param array $importer Record of the importer user mixed with contact of the content
* @param int $posted_id The record number of item record that was just posted
+ * @return void
* @todo set proper type-hints (array?)
*/
- private static function do_poke($item, $importer, $posted_id)
+ private static function doPoke($item, $importer, $posted_id)
{
$verb = urldecode(substr($item["verb"], strpos($item["verb"], "#")+1));
if (!$verb) {
"link" => System::baseUrl()."/display/".urlencode(get_item_guid($posted_id)),
"source_name" => stripslashes($item["author-name"]),
"source_link" => $item["author-link"],
- "source_photo" => ((link_compare($item["author-link"],$importer["url"]))
+ "source_photo" => ((link_compare($item["author-link"], $importer["url"]))
? $importer["thumb"] : $item["author-avatar"]),
"verb" => $item["verb"],
"otype" => "person",
* @return bool Should the processing of the entries be continued?
* @todo set proper type-hints (array?)
*/
- private static function process_verbs($entrytype, $importer, &$item, &$is_like)
+ private static function processVerbs($entrytype, $importer, &$item, &$is_like)
{
logger("Process verb ".$item["verb"]." and object-type ".$item["object-type"]." for entrytype ".$entrytype, LOGGER_DEBUG);
}
if (($item["verb"] == ACTIVITY_TAG) && ($item["object-type"] == ACTIVITY_OBJ_TAGTERM)) {
-
$xo = parse_xml_string($item["object"], false);
$xt = parse_xml_string($item["target"], false);
// extract tag, if not duplicate, add to parent item
if ($xo->content) {
- if (!(stristr($r[0]["tag"],trim($xo->content)))) {
- q("UPDATE `item` SET `tag` = '%s' WHERE `id` = %d",
+ if (!(stristr($r[0]["tag"], trim($xo->content)))) {
+ q(
+ "UPDATE `item` SET `tag` = '%s' WHERE `id` = %d",
dbesc($r[0]["tag"] . (strlen($r[0]["tag"]) ? ',' : '') . '#[url=' . $xo->id . ']'. $xo->content . '[/url]'),
intval($r[0]["id"])
);
*
* @param object $links link elements
* @param array $item the item record
+ * @return void
* @todo set proper type-hints
*/
- private static function parse_links($links, &$item)
+ private static function parseLinks($links, &$item)
{
$rel = "";
$href = "";
$type = "";
$length = "0";
$title = "";
- foreach ($links AS $link) {
- foreach ($link->attributes AS $attributes) {
+ foreach ($links as $link) {
+ foreach ($link->attributes as $attributes) {
/// @TODO Rewrite these repeated (same) if () statements to a switch()
if ($attributes->name == "href") {
$href = $attributes->textContent;
/**
* @brief Processes the entry elements which contain the items and comments
*
- * @param array $header Array of the header elements that always stay the same
- * @param object $xpath XPath object
- * @param object $entry entry elements
- * @param array $importer Record of the importer user mixed with contact of the content
+ * @param array $header Array of the header elements that always stay the same
+ * @param object $xpath XPath object
+ * @param object $entry entry elements
+ * @param array $importer Record of the importer user mixed with contact of the content
+ * @param object $xml xml
+ * @return void
* @todo Add type-hints
*/
- private static function process_entry($header, $xpath, $entry, $importer, $xml)
+ private static function processEntry($header, $xpath, $entry, $importer, $xml)
{
logger("Processing entries");
$notice_info = $xpath->query("statusnet:notice_info", $entry);
if ($notice_info && ($notice_info->length > 0)) {
- foreach ($notice_info->item(0)->attributes AS $attributes) {
+ foreach ($notice_info->item(0)->attributes as $attributes) {
if ($attributes->name == "source") {
$item["app"] = strip_tags($attributes->textContent);
}
}
$object = $xpath->query("activity:object", $entry)->item(0);
- $item["object"] = self::transform_activity($xpath, $object, "object");
+ $item["object"] = self::transformActivity($xpath, $object, "object");
if (trim($item["object"]) != "") {
$r = parse_xml_string($item["object"], false);
}
$target = $xpath->query("activity:target", $entry)->item(0);
- $item["target"] = self::transform_activity($xpath, $target, "target");
+ $item["target"] = self::transformActivity($xpath, $target, "target");
$categories = $xpath->query("atom:category", $entry);
if ($categories) {
- foreach ($categories AS $category) {
+ foreach ($categories as $category) {
$term = "";
$scheme = "";
- foreach ($category->attributes AS $attributes) {
+ foreach ($category->attributes as $attributes) {
if ($attributes->name == "term") {
$term = $attributes->textContent;
}
$links = $xpath->query("atom:link", $entry);
if ($links) {
- self::parse_links($links, $item);
+ self::parseLinks($links, $item);
}
$item['conversation-uri'] = $xpath->query('ostatus:conversation/text()', $entry)->item(0)->nodeValue;
$conv = $xpath->query('ostatus:conversation', $entry);
if (is_object($conv->item(0))) {
- foreach ($conv->item(0)->attributes AS $attributes) {
+ foreach ($conv->item(0)->attributes as $attributes) {
if ($attributes->name == "ref") {
$item['conversation-uri'] = $attributes->textContent;
}
$inreplyto = $xpath->query("thr:in-reply-to", $entry);
if (is_object($inreplyto->item(0))) {
- foreach ($inreplyto->item(0)->attributes AS $attributes) {
+ foreach ($inreplyto->item(0)->attributes as $attributes) {
if ($attributes->name == "ref") {
$item["parent-uri"] = $attributes->textContent;
}
}
// Get the type of the item (Top level post, reply or remote reply)
- $entrytype = self::get_entry_type($importer, $item);
+ $entrytype = self::getEntryType($importer, $item);
// Now assign the rest of the values that depend on the type of the message
if (in_array($entrytype, array(DFRN_REPLY, DFRN_REPLY_RC))) {
}
}
- if (!self::process_verbs($entrytype, $importer, $item, $is_like)) {
- logger("Exiting because 'process_verbs' told us so", LOGGER_DEBUG);
+ if (!self::processVerbs($entrytype, $importer, $item, $is_like)) {
+ logger("Exiting because 'processVerbs' told us so", LOGGER_DEBUG);
return;
}
// Update content if 'updated' changes
if (DBM::is_result($current)) {
- if (self::update_content($r[0], $item, $importer, $entrytype)) {
+ if (self::updateContent($r[0], $item, $importer, $entrytype)) {
logger("Item ".$item["uri"]." was updated.", LOGGER_DEBUG);
} else {
logger("Item ".$item["uri"]." already existed.", LOGGER_DEBUG);
if ($posted_id && $parent && ($entrytype == DFRN_REPLY_RC)) {
logger("Notifying followers about comment ".$posted_id, LOGGER_DEBUG);
- Worker::add(PRIORITY_HIGH, "notifier", "comment-import", $posted_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "comment-import", $posted_id);
}
return true;
logger("Item was stored with id ".$posted_id, LOGGER_DEBUG);
- if (stristr($item["verb"],ACTIVITY_POKE))
- self::do_poke($item, $importer, $posted_id);
+ if (stristr($item["verb"], ACTIVITY_POKE)) {
+ self::doPoke($item, $importer, $posted_id);
+ }
}
}
* @param object $xpath XPath object
* @param object $deletion deletion elements
* @param array $importer Record of the importer user mixed with contact of the content
+ * @return void
* @todo set proper type-hints
*/
- private static function process_deletion($xpath, $deletion, $importer)
+ private static function processDeletion($xpath, $deletion, $importer)
{
logger("Processing deletions");
- foreach ($deletion->attributes AS $attributes) {
+ foreach ($deletion->attributes as $attributes) {
if ($attributes->name == "ref") {
$uri = $attributes->textContent;
}
} else {
$item = $r[0];
- $entrytype = self::get_entry_type($importer, $item);
+ $entrytype = self::getEntryType($importer, $item);
if (!$item["deleted"]) {
logger('deleting item '.$item["id"].' uri='.$uri, LOGGER_DEBUG);
}
if (($item["verb"] == ACTIVITY_TAG) && ($item["object-type"] == ACTIVITY_OBJ_TAGTERM)) {
-
$xo = parse_xml_string($item["object"], false);
$xt = parse_xml_string($item["target"], false);
if ($entrytype == DFRN_REPLY_RC) {
logger("Notifying followers about deletion of post " . $item["id"], LOGGER_DEBUG);
- Worker::add(PRIORITY_HIGH, "notifier", "drop", $item["id"]);
+ Worker::add(PRIORITY_HIGH, "Notifier", "drop", $item["id"]);
}
}
}
// We are processing relocations even if we are ignoring a contact
$relocations = $xpath->query("/atom:feed/dfrn:relocate");
- foreach ($relocations AS $relocation) {
- self::process_relocation($xpath, $relocation, $importer);
+ foreach ($relocations as $relocation) {
+ self::processRelocation($xpath, $relocation, $importer);
}
if ($importer["readonly"]) {
}
$mails = $xpath->query("/atom:feed/dfrn:mail");
- foreach ($mails AS $mail) {
- self::process_mail($xpath, $mail, $importer);
+ foreach ($mails as $mail) {
+ self::processMail($xpath, $mail, $importer);
}
$suggestions = $xpath->query("/atom:feed/dfrn:suggest");
- foreach ($suggestions AS $suggestion) {
- self::process_suggestion($xpath, $suggestion, $importer);
+ foreach ($suggestions as $suggestion) {
+ self::processSuggestion($xpath, $suggestion, $importer);
}
$deletions = $xpath->query("/atom:feed/at:deleted-entry");
- foreach ($deletions AS $deletion) {
- self::process_deletion($xpath, $deletion, $importer);
+ foreach ($deletions as $deletion) {
+ self::processDeletion($xpath, $deletion, $importer);
}
if (!$sort_by_date) {
$entries = $xpath->query("/atom:feed/atom:entry");
- foreach ($entries AS $entry) {
- self::process_entry($header, $xpath, $entry, $importer, $xml);
+ foreach ($entries as $entry) {
+ self::processEntry($header, $xpath, $entry, $importer, $xml);
}
} else {
$newentries = array();
$entries = $xpath->query("/atom:feed/atom:entry");
- foreach ($entries AS $entry) {
+ foreach ($entries as $entry) {
$created = $xpath->query("atom:published/text()", $entry)->item(0)->nodeValue;
$newentries[strtotime($created)] = $entry;
}
// Now sort after the publishing date
ksort($newentries);
- foreach ($newentries AS $entry) {
- self::process_entry($header, $xpath, $entry, $importer, $xml);
+ foreach ($newentries as $entry) {
+ self::processEntry($header, $xpath, $entry, $importer, $xml);
}
}
logger("Import done for user " . $importer["uid"] . " from contact " . $importer["id"], LOGGER_DEBUG);
*
* The new protocol is described here: http://diaspora.github.io/diaspora_federation/index.html
* This implementation here interprets the old and the new protocol and sends the new one.
- * In the future we will remove most stuff from "valid_posting" and interpret only the new protocol.
+ * In the future we will remove most stuff from "validPosting" and interpret only the new protocol.
*/
namespace Friendica\Protocol;
use Friendica\Core\PConfig;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
use Friendica\Network\Probe;
+use Friendica\Object\Contact;
+use Friendica\Object\Profile;
use Friendica\Util\XML;
use dba;
require_once 'include/items.php';
require_once 'include/bb2diaspora.php';
-require_once 'include/Contact.php';
require_once 'include/Photo.php';
-require_once 'include/socgraph.php';
require_once 'include/group.php';
require_once 'include/datetime.php';
require_once 'include/queue_fn.php';
*
* @return array of relay servers
*/
- public static function relay_list()
+ public static function relayList()
{
$serverdata = Config::get("system", "relay_server");
if ($serverdata == "") {
*
* @return string the repaired signature
*/
- private static function repair_signature($signature, $handle = "", $level = 1)
+ private static function repairSignature($signature, $handle = "", $level = 1)
{
if ($signature == "") {
return ($signature);
// Do a recursive call to be able to fix even multiple levels
if ($level < 10) {
- $signature = self::repair_signature($signature, $handle, ++$level);
+ $signature = self::repairSignature($signature, $handle, ++$level);
}
}
*
* @return string verified data
*/
- private static function verify_magic_envelope($envelope)
+ private static function verifyMagicEnvelope($envelope)
{
$basedom = parse_xml_string($envelope);
*
* @return string encrypted data
*/
- private static function aes_encrypt($key, $iv, $data)
+ private static function aesEncrypt($key, $iv, $data)
{
return openssl_encrypt($data, 'aes-256-cbc', str_pad($key, 32, "\0"), OPENSSL_RAW_DATA, str_pad($iv, 16, "\0"));
}
*
* @return string decrypted data
*/
- private static function aes_decrypt($key, $iv, $encrypted)
+ private static function aesDecrypt($key, $iv, $encrypted)
{
return openssl_decrypt($encrypted, 'aes-256-cbc', str_pad($key, 32, "\0"), OPENSSL_RAW_DATA, str_pad($iv, 16, "\0"));
}
* 'author' -> author diaspora handle
* 'key' -> author public key (converted to pkcs#8)
*/
- public static function decode_raw($importer, $raw)
+ public static function decodeRaw($importer, $raw)
{
$data = json_decode($raw);
$outer_iv = base64_decode($j_outer_key_bundle->iv);
$outer_key = base64_decode($j_outer_key_bundle->key);
- $xml = self::aes_decrypt($outer_key, $outer_iv, $ciphertext);
+ $xml = self::aesDecrypt($outer_key, $outer_iv, $ciphertext);
} else {
$xml = $raw;
}
$outer_iv = base64_decode($j_outer_key_bundle->iv);
$outer_key = base64_decode($j_outer_key_bundle->key);
- $decrypted = self::aes_decrypt($outer_key, $outer_iv, $ciphertext);
+ $decrypted = self::aesDecrypt($outer_key, $outer_iv, $ciphertext);
logger('decrypted: '.$decrypted, LOGGER_DEBUG);
$idom = parse_xml_string($decrypted);
} else {
// Decode the encrypted blob
$inner_encrypted = base64_decode($data);
- $inner_decrypted = self::aes_decrypt($inner_aes_key, $inner_iv, $inner_encrypted);
+ $inner_decrypted = self::aesDecrypt($inner_aes_key, $inner_iv, $inner_encrypted);
}
if (!$author_link) {
*
* @return int The message id of the generated message, "true" or "false" if there was an error
*/
- public static function dispatch_public($msg)
+ public static function dispatchPublic($msg)
{
$enabled = intval(Config::get("system", "diaspora_enabled"));
if (!$enabled) {
return false;
}
- if (!($postdata = self::valid_posting($msg))) {
+ if (!($postdata = self::validPosting($msg))) {
logger("Invalid posting");
return false;
}
// Is it a an action (comment, like, ...) for our own post?
if (isset($fields->parent_guid) && !$postdata["relayed"]) {
$guid = notags(unxmlify($fields->parent_guid));
- $importer = self::importer_for_guid($guid);
+ $importer = self::importerForGuid($guid);
if (is_array($importer)) {
logger("delivering to origin: ".$importer["name"]);
$message_id = self::dispatch($importer, $msg, $fields);
// This is only needed for private postings since this is already done for public ones before
if (is_null($fields)) {
- if (!($postdata = self::valid_posting($msg))) {
+ if (!($postdata = self::validPosting($msg))) {
logger("Invalid posting");
return false;
}
return self::receiveAccountMigration($importer, $fields);
case "account_deletion":
- return self::receive_account_deletion($importer, $fields);
+ return self::receiveAccountDeletion($importer, $fields);
case "comment":
- return self::receive_comment($importer, $sender, $fields, $msg["message"]);
+ return self::receiveComment($importer, $sender, $fields, $msg["message"]);
case "contact":
- return self::receive_contact_request($importer, $fields);
+ return self::receiveContactRequest($importer, $fields);
case "conversation":
- return self::receive_conversation($importer, $msg, $fields);
+ return self::receiveConversation($importer, $msg, $fields);
case "like":
- return self::receive_like($importer, $sender, $fields);
+ return self::receiveLike($importer, $sender, $fields);
case "message":
- return self::receive_message($importer, $fields);
+ return self::receiveMessage($importer, $fields);
case "participation": // Not implemented
- return self::receive_participation($importer, $fields);
+ return self::receiveParticipation($importer, $fields);
case "photo": // Not implemented
- return self::receive_photo($importer, $fields);
+ return self::receivePhoto($importer, $fields);
case "poll_participation": // Not implemented
- return self::receive_poll_participation($importer, $fields);
+ return self::receivePollParticipation($importer, $fields);
case "profile":
- return self::receive_profile($importer, $fields);
+ return self::receiveProfile($importer, $fields);
case "reshare":
- return self::receive_reshare($importer, $fields, $msg["message"]);
+ return self::receiveReshare($importer, $fields, $msg["message"]);
case "retraction":
- return self::receive_retraction($importer, $sender, $fields);
+ return self::receiveRetraction($importer, $sender, $fields);
case "status_message":
- return self::receive_status_message($importer, $fields, $msg["message"]);
+ return self::receiveStatusMessage($importer, $fields, $msg["message"]);
default:
logger("Unknown message type ".$type);
*
* @return bool|array If the posting is valid then an array with an SimpleXML object is returned
*/
- private static function valid_posting($msg)
+ private static function validPosting($msg)
{
$data = parse_xml_string($msg["message"]);
logger("Fetching diaspora key for: ".$handle);
- $r = self::person_by_handle($handle);
+ $r = self::personByHandle($handle);
if ($r) {
return $r["pubkey"];
}
*
* @return array the queried data
*/
- public static function person_by_handle($handle)
+ public static function personByHandle($handle)
{
$r = q(
"SELECT * FROM `fcontact` WHERE `network` = '%s' AND `addr` = '%s' LIMIT 1",
// Note that Friendica contacts will return a "Diaspora person"
// if Diaspora connectivity is enabled on their server
if ($r && ($r["network"] === NETWORK_DIASPORA)) {
- self::add_fcontact($r, $update);
+ self::addFContact($r, $update);
$person = $r;
}
}
*
* @return string The id of the fcontact entry
*/
- private static function add_fcontact($arr, $update = false)
+ private static function addFContact($arr, $update = false)
{
if ($update) {
$r = q(
*
* @return string the handle
*/
- public static function handle_from_contact($contact_id, $gcontact_id = 0)
+ public static function handleFromContact($contact_id, $gcontact_id = 0)
{
$handle = false;
*
* @return string the contact url or null
*/
- public static function url_from_contact_guid($fcontact_guid)
+ public static function urlFromContactGuid($fcontact_guid)
{
logger("fcontact guid is ".$fcontact_guid, LOGGER_DEBUG);
*
* @return The contact id
*/
- private static function contact_by_handle($uid, $handle)
+ private static function contactByHandle($uid, $handle)
{
// First do a direct search on the contact table
$r = q(
* We haven't found it?
* We use another function for it that will possibly create a contact entry.
*/
- $cid = get_contact($handle, $uid);
+ $cid = Contact::getIdForURL($handle, $uid);
if ($cid > 0) {
/// @TODO Contact retrieval should be encapsulated into an "entity" class like `Contact`
*
* @return bool is the contact allowed to post?
*/
- private static function post_allow($importer, $contact, $is_comment = false) {
-
+ private static function postAllow($importer, $contact, $is_comment = false)
+ {
/*
* Perhaps we were already sharing with this person. Now they're sharing with us.
* That makes us friends.
if ($contact["blocked"] || $contact["readonly"] || $contact["archive"]) {
// Maybe blocked, don't accept.
return false;
- // We are following this person?
+ // We are following this person?
} elseif (($contact["rel"] == CONTACT_IS_SHARING) || ($contact["rel"] == CONTACT_IS_FRIEND)) {
// Yes, then it is fine.
return true;
- // Is it a post to a community?
+ // Is it a post to a community?
} elseif (($contact["rel"] == CONTACT_IS_FOLLOWER) && ($importer["page-flags"] == PAGE_COMMUNITY)) {
// That's good
return true;
- // Is the message a global user or a comment?
+ // Is the message a global user or a comment?
} elseif (($importer["uid"] == 0) || $is_comment) {
// Messages for the global users and comments are always accepted
return true;
*
* @return array The contact data
*/
- private static function allowed_contact_by_handle($importer, $handle, $is_comment = false)
+ private static function allowedContactByHandle($importer, $handle, $is_comment = false)
{
- $contact = self::contact_by_handle($importer["uid"], $handle);
+ $contact = self::contactByHandle($importer["uid"], $handle);
if (!$contact) {
logger("A Contact for handle ".$handle." and user ".$importer["uid"]." was not found");
// If a contact isn't found, we accept it anyway if it is a comment
}
}
- if (!self::post_allow($importer, $contact, $is_comment)) {
+ if (!self::postAllow($importer, $contact, $is_comment)) {
logger("The handle: ".$handle." is not allowed to post to user ".$importer["uid"]);
return false;
}
*
* @return int|bool message id if the message already was stored into the system - or false.
*/
- private static function message_exists($uid, $guid)
+ private static function messageExists($uid, $guid)
{
$r = q(
"SELECT `id` FROM `item` WHERE `uid` = %d AND `guid` = '%s' LIMIT 1",
* @brief Checks for links to posts in a message
*
* @param array $item The item array
+ * @return void
*/
- private static function fetch_guid($item)
+ private static function fetchGuid($item)
{
$expression = "=diaspora://.*?/post/([0-9A-Za-z\-_@.:]{15,254}[0-9A-Za-z])=ism";
preg_replace_callback(
$expression,
function ($match) use ($item) {
- return self::fetch_guid_sub($match, $item);
+ return self::fetchGuidSub($match, $item);
},
$item["body"]
);
preg_replace_callback(
"&\[url=/posts/([^\[\]]*)\](.*)\[\/url\]&Usi",
function ($match) use ($item) {
- return self::fetch_guid_sub($match, $item);
+ return self::fetchGuidSub($match, $item);
},
$item["body"]
);
*
* @return the replaced string
*/
- public static function replace_people_guid($body, $author_link)
+ public static function replacePeopleGuid($body, $author_link)
{
$return = preg_replace_callback(
"&\[url=/people/([^\[\]]*)\](.*)\[\/url\]&Usi",
// 0 => '[url=/people/0123456789abcdef]Foo Bar[/url]'
// 1 => '0123456789abcdef'
// 2 => 'Foo Bar'
- $handle = self::url_from_contact_guid($match[1]);
+ $handle = self::urlFromContactGuid($match[1]);
if ($handle) {
$return = '@[url='.$handle.']'.$match[2].'[/url]';
}
/**
- * @brief sub function of "fetch_guid" which checks for links in messages
+ * @brief sub function of "fetchGuid" which checks for links in messages
*
* @param array $match array containing a link that has to be checked for a message link
* @param array $item The item array
+ * @return void
*/
- private static function fetch_guid_sub($match, $item)
+ private static function fetchGuidSub($match, $item)
{
- if (!self::store_by_guid($match[1], $item["author-link"])) {
- self::store_by_guid($match[1], $item["owner-link"]);
+ if (!self::storeByGuid($match[1], $item["author-link"])) {
+ self::storeByGuid($match[1], $item["owner-link"]);
}
}
*
* @return int the message id of the stored message or false
*/
- private static function store_by_guid($guid, $server, $uid = 0)
+ private static function storeByGuid($guid, $server, $uid = 0)
{
$serverparts = parse_url($server);
$server = $serverparts["scheme"]."://".$serverparts["host"];
logger("Successfully fetched item ".$guid." from ".$server, LOGGER_DEBUG);
// Now call the dispatcher
- return self::dispatch_public($msg);
+ return self::dispatchPublic($msg);
}
/**
$envelope = fetch_url($source_url);
if ($envelope) {
logger("Envelope was fetched.", LOGGER_DEBUG);
- $x = self::verify_magic_envelope($envelope);
+ $x = self::verifyMagicEnvelope($envelope);
if (!$x) {
logger("Envelope could not be verified.", LOGGER_DEBUG);
} else {
*
* @return array the item record
*/
- private static function parent_item($uid, $guid, $author, $contact)
+ private static function parentItem($uid, $guid, $author, $contact)
{
$r = q(
"SELECT `id`, `parent`, `body`, `wall`, `uri`, `guid`, `private`, `origin`,
);
if (!$r) {
- $result = self::store_by_guid($guid, $contact["url"], $uid);
+ $result = self::storeByGuid($guid, $contact["url"], $uid);
if (!$result) {
- $person = self::person_by_handle($author);
- $result = self::store_by_guid($guid, $person["url"], $uid);
+ $person = self::personByHandle($author);
+ $result = self::storeByGuid($guid, $person["url"], $uid);
}
if ($result) {
* 'cid' => contact id
* 'network' => network type
*/
- private static function author_contact_by_url($contact, $person, $uid)
+ private static function authorContactByUrl($contact, $person, $uid)
{
$r = q(
"SELECT `id`, `network`, `url` FROM `contact` WHERE `nurl` = '%s' AND `uid` = %d LIMIT 1",
// We are receiving content from a user that possibly is about to be terminated
// This means the user is vital, so we remove a possible termination date.
- unmark_for_death($r[0]);
+ Contact::unmarkForArchival($r[0]);
} else {
$cid = $contact["id"];
$network = NETWORK_DIASPORA;
*
* @return bool is it a hubzilla server?
*/
- public static function is_redmatrix($url)
+ public static function isRedmatrix($url)
{
return(strstr($url, "/channel/"));
}
return str_replace("/profile/".$r[0]["nick"]."/", "/display/".$guid, $r[0]["url"]."/");
}
- if (self::is_redmatrix($r[0]["url"])) {
+ if (self::isRedmatrix($r[0]["url"])) {
return $r[0]["url"]."/?f=&mid=".$guid;
}
$new_handle = notags(unxmlify($data->profile->author));
$signature = notags(unxmlify($data->signature));
- $contact = self::contact_by_handle($importer["uid"], $old_handle);
+ $contact = self::contactByHandle($importer["uid"], $old_handle);
if (!$contact) {
logger("cannot find contact for sender: ".$old_handle." and user ".$importer["uid"]);
return false;
}
// Update the profile
- self::receive_profile($importer, $data->profile);
+ self::receiveProfile($importer, $data->profile);
// change the technical stuff in contact and gcontact
$data = Probe::uri($new_handle);
*
* @return bool Success
*/
- private static function receive_account_deletion($importer, $data)
+ private static function receiveAccountDeletion($importer, $data)
{
/// @todo Account deletion should remove the contact from the global contacts as well
$author = notags(unxmlify($data->author));
- $contact = self::contact_by_handle($importer["uid"], $author);
+ $contact = self::contactByHandle($importer["uid"], $author);
if (!$contact) {
logger("cannot find contact for author: ".$author);
return false;
}
// We now remove the contact
- contact_remove($contact["id"]);
+ Contact::remove($contact["id"]);
return true;
}
*
* @return string The constructed uri or the one from our database
*/
- private static function get_uri_from_guid($author, $guid, $onlyfound = false)
+ private static function getUriFromGuid($author, $guid, $onlyfound = false)
{
$r = q("SELECT `uri` FROM `item` WHERE `guid` = '%s' LIMIT 1", dbesc($guid));
if (DBM::is_result($r)) {
*
* @return string The post guid
*/
- private static function get_guid_from_uri($uri, $uid)
+ private static function getGuidFromUri($uri, $uid)
{
$r = q("SELECT `guid` FROM `item` WHERE `uri` = '%s' AND `uid` = %d LIMIT 1", dbesc($uri), intval($uid));
if (DBM::is_result($r)) {
*
* @return array|boolean the origin owner of that post - or false
*/
- private static function importer_for_guid($guid)
+ private static function importerForGuid($guid)
{
$item = dba::fetch_first("SELECT `uid` FROM `item` WHERE `origin` AND `guid` = ? LIMIT 1", $guid);
*
* @return int The message id of the generated comment or "false" if there was an error
*/
- private static function receive_comment($importer, $sender, $data, $xml)
+ private static function receiveComment($importer, $sender, $data, $xml)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
if (isset($data->thread_parent_guid)) {
$thread_parent_guid = notags(unxmlify($data->thread_parent_guid));
- $thr_uri = self::get_uri_from_guid("", $thread_parent_guid, true);
+ $thr_uri = self::getUriFromGuid("", $thread_parent_guid, true);
} else {
$thr_uri = "";
}
- $contact = self::allowed_contact_by_handle($importer, $sender, true);
+ $contact = self::allowedContactByHandle($importer, $sender, true);
if (!$contact) {
return false;
}
- $message_id = self::message_exists($importer["uid"], $guid);
+ $message_id = self::messageExists($importer["uid"], $guid);
if ($message_id) {
return true;
}
- $parent_item = self::parent_item($importer["uid"], $parent_guid, $author, $contact);
+ $parent_item = self::parentItem($importer["uid"], $parent_guid, $author, $contact);
if (!$parent_item) {
return false;
}
- $person = self::person_by_handle($author);
+ $person = self::personByHandle($author);
if (!is_array($person)) {
logger("unable to find author details");
return false;
}
// Fetch the contact id - if we know this contact
- $author_contact = self::author_contact_by_url($contact, $person, $importer["uid"]);
+ $author_contact = self::authorContactByUrl($contact, $person, $importer["uid"]);
$datarray = array();
$datarray["owner-avatar"] = ((x($contact, "thumb")) ? $contact["thumb"] : $contact["photo"]);
$datarray["guid"] = $guid;
- $datarray["uri"] = self::get_uri_from_guid($author, $guid);
+ $datarray["uri"] = self::getUriFromGuid($author, $guid);
$datarray["type"] = "remote-comment";
$datarray["verb"] = ACTIVITY_POST;
$body = diaspora2bb($text);
- $datarray["body"] = self::replace_people_guid($body, $person["url"]);
+ $datarray["body"] = self::replacePeopleGuid($body, $person["url"]);
- self::fetch_guid($datarray);
+ self::fetchGuid($datarray);
$message_id = item_store($datarray);
dba::insert('sign', array('iid' => $message_id, 'signed_text' => json_encode($data)));
// notify others
- Worker::add(PRIORITY_HIGH, "notifier", "comment-import", $message_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "comment-import", $message_id);
}
return true;
*
* @return bool "true" if it was successful
*/
- private static function receive_conversation_message($importer, $contact, $data, $msg, $mesg, $conversation)
+ private static function receiveConversationMessage($importer, $contact, $data, $msg, $mesg, $conversation)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
$body = diaspora2bb($msg_text);
$message_uri = $msg_author.":".$msg_guid;
- $person = self::person_by_handle($msg_author);
+ $person = self::personByHandle($msg_author);
dba::lock('mail');
"source_link" => $person["url"],
"source_photo" => $person["thumb"],
"verb" => ACTIVITY_POST,
- "otype" => "mail"
- ));
+ "otype" => "mail")
+ );
return true;
}
*
* @return bool Success
*/
- private static function receive_conversation($importer, $msg, $data)
+ private static function receiveConversation($importer, $msg, $data)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
return false;
}
- $contact = self::allowed_contact_by_handle($importer, $msg["author"], true);
+ $contact = self::allowedContactByHandle($importer, $msg["author"], true);
if (!$contact) {
return false;
}
}
foreach ($messages as $mesg) {
- self::receive_conversation_message($importer, $contact, $data, $msg, $mesg, $conversation);
+ self::receiveConversationMessage($importer, $contact, $data, $msg, $mesg, $conversation);
}
return true;
*
* @return string the body
*/
- private static function construct_like_body($contact, $parent_item, $guid) {
+ private static function constructLikeBody($contact, $parent_item, $guid)
+ {
$bodyverb = t('%1$s likes %2$s\'s %3$s');
$ulink = "[url=".$contact["url"]."]".$contact["name"]."[/url]";
*
* @return string The XML
*/
- private static function construct_like_object($importer, $parent_item)
+ private static function constructLikeObject($importer, $parent_item)
{
$objtype = ACTIVITY_OBJ_NOTE;
$link = '<link rel="alternate" type="text/html" href="'.System::baseUrl()."/display/".$importer["nickname"]."/".$parent_item["id"].'" />';
"title" => "",
"content" => $parent_body));
- return XML::from_array($xmldata, $xml, true);
+ return XML::fromArray($xmldata, $xml, true);
}
/**
*
* @return int The message id of the generated like or "false" if there was an error
*/
- private static function receive_like($importer, $sender, $data)
+ private static function receiveLike($importer, $sender, $data)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
return false;
}
- $contact = self::allowed_contact_by_handle($importer, $sender, true);
+ $contact = self::allowedContactByHandle($importer, $sender, true);
if (!$contact) {
return false;
}
- $message_id = self::message_exists($importer["uid"], $guid);
+ $message_id = self::messageExists($importer["uid"], $guid);
if ($message_id) {
return true;
}
- $parent_item = self::parent_item($importer["uid"], $parent_guid, $author, $contact);
+ $parent_item = self::parentItem($importer["uid"], $parent_guid, $author, $contact);
if (!$parent_item) {
return false;
}
- $person = self::person_by_handle($author);
+ $person = self::personByHandle($author);
if (!is_array($person)) {
logger("unable to find author details");
return false;
}
// Fetch the contact id - if we know this contact
- $author_contact = self::author_contact_by_url($contact, $person, $importer["uid"]);
+ $author_contact = self::authorContactByUrl($contact, $person, $importer["uid"]);
// "positive" = "false" would be a Dislike - wich isn't currently supported by Diaspora
// We would accept this anyhow.
$datarray["owner-avatar"] = ((x($contact, "thumb")) ? $contact["thumb"] : $contact["photo"]);
$datarray["guid"] = $guid;
- $datarray["uri"] = self::get_uri_from_guid($author, $guid);
+ $datarray["uri"] = self::getUriFromGuid($author, $guid);
$datarray["type"] = "activity";
$datarray["verb"] = $verb;
$datarray["parent-uri"] = $parent_item["uri"];
$datarray["object-type"] = ACTIVITY_OBJ_NOTE;
- $datarray["object"] = self::construct_like_object($importer, $parent_item);
+ $datarray["object"] = self::constructLikeObject($importer, $parent_item);
- $datarray["body"] = self::construct_like_body($contact, $parent_item, $guid);
+ $datarray["body"] = self::constructLikeBody($contact, $parent_item, $guid);
$message_id = item_store($datarray);
dba::insert('sign', array('iid' => $message_id, 'signed_text' => json_encode($data)));
// notify others
- Worker::add(PRIORITY_HIGH, "notifier", "comment-import", $message_id);
+ Worker::add(PRIORITY_HIGH, "Notifier", "comment-import", $message_id);
}
return true;
*
* @return bool Success?
*/
- private static function receive_message($importer, $data)
+ private static function receiveMessage($importer, $data)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
$text = unxmlify($data->text);
$created_at = datetime_convert("UTC", "UTC", notags(unxmlify($data->created_at)));
- $contact = self::allowed_contact_by_handle($importer, $author, true);
+ $contact = self::allowedContactByHandle($importer, $author, true);
if (!$contact) {
return false;
}
$message_uri = $author.":".$guid;
- $person = self::person_by_handle($author);
+ $person = self::personByHandle($author);
if (!$person) {
logger("unable to find author details");
return false;
$body = diaspora2bb($text);
- $body = self::replace_people_guid($body, $person["url"]);
+ $body = self::replacePeopleGuid($body, $person["url"]);
dba::lock('mail');
*
* @return bool always true
*/
- private static function receive_participation($importer, $data)
+ private static function receiveParticipation($importer, $data)
{
// I'm not sure if we can fully support this message type
return true;
*
* @return bool always true
*/
- private static function receive_photo($importer, $data)
+ private static function receivePhoto($importer, $data)
{
// There doesn't seem to be a reason for this function,
// since the photo data is transmitted in the status message as well
*
* @return bool always true
*/
- private static function receive_poll_participation($importer, $data)
+ private static function receivePollParticipation($importer, $data)
{
// We don't support polls by now
return true;
*
* @return bool Success
*/
- private static function receive_profile($importer, $data)
+ private static function receiveProfile($importer, $data)
{
$author = strtolower(notags(unxmlify($data->author)));
- $contact = self::contact_by_handle($importer["uid"], $author);
+ $contact = self::contactByHandle($importer["uid"], $author);
if (!$contact) {
return false;
}
"addr" => $author, "nick" => $nick, "keywords" => $keywords,
"hide" => !$searchable, "nsfw" => $nsfw);
- $gcid = update_gcontact($gcontact);
+ $gcid = GlobalContact::update($gcontact);
- link_gcontact($gcid, $importer["uid"], $contact["id"]);
+ GlobalContact::link($gcid, $importer["uid"], $contact["id"]);
logger("Profile of contact ".$contact["id"]." stored for user ".$importer["uid"], LOGGER_DEBUG);
*
* @param array $importer Array of the importer user
* @param array $contact The contact that send the request
+ * @return void
*/
- private static function receive_request_make_friend($importer, $contact)
+ private static function receiveRequestMakeFriend($importer, $contact)
{
$a = get_app();
);
if ($r && !$r[0]["hide-friends"] && !$contact["hidden"] && intval(PConfig::get($importer["uid"], "system", "post_newfriend"))) {
-
$self = q(
"SELECT * FROM `contact` WHERE `self` AND `uid` = %d LIMIT 1",
intval($importer["uid"])
$BPhoto = "[url=".$contact["url"]."][img]".$contact["thumb"]."[/img][/url]";
$arr["body"] = sprintf(t("%1$s is now friends with %2$s"), $A, $B)."\n\n\n".$Bphoto;
- $arr["object"] = self::construct_new_friend_object($contact);
+ $arr["object"] = self::constructNewFriendObject($contact);
$arr["last-child"] = 1;
$i = item_store($arr);
if ($i) {
- Worker::add(PRIORITY_HIGH, "notifier", "activity", $i);
+ Worker::add(PRIORITY_HIGH, "Notifier", "activity", $i);
}
}
}
*
* @return string The XML
*/
- private static function construct_new_friend_object($contact)
+ private static function constructNewFriendObject($contact)
{
$objtype = ACTIVITY_OBJ_PERSON;
$link = '<link rel="alternate" type="text/html" href="'.$contact["url"].'" />'."\n".
"id" => $contact["url"]."/".$contact["name"],
"link" => $link));
- return XML::from_array($xmldata, $xml, true);
+ return XML::fromArray($xmldata, $xml, true);
}
/**
*
* @return bool Success
*/
- private static function receive_contact_request($importer, $data)
+ private static function receiveContactRequest($importer, $data)
{
$author = unxmlify($data->author);
$recipient = unxmlify($data->recipient);
$sharing = true;
}
- $contact = self::contact_by_handle($importer["uid"], $author);
+ $contact = self::contactByHandle($importer["uid"], $author);
// perhaps we were already sharing with this person. Now they're sharing with us.
// That makes us friends.
if ($contact) {
if ($following) {
logger("Author ".$author." (Contact ".$contact["id"].") wants to follow us.", LOGGER_DEBUG);
- self::receive_request_make_friend($importer, $contact);
+ self::receiveRequestMakeFriend($importer, $contact);
// refetch the contact array
- $contact = self::contact_by_handle($importer["uid"], $author);
+ $contact = self::contactByHandle($importer["uid"], $author);
// If we are now friends, we are sending a share message.
// Normally we needn't to do so, but the first message could have been vanished.
$u = q("SELECT * FROM `user` WHERE `uid` = %d LIMIT 1", intval($importer["uid"]));
if ($u) {
logger("Sending share message to author ".$author." - Contact: ".$contact["id"]." - User: ".$importer["uid"], LOGGER_DEBUG);
- $ret = self::send_share($u[0], $contact);
+ $ret = self::sendShare($u[0], $contact);
}
}
return true;
logger("Author ".$author." wants to listen to us.", LOGGER_DEBUG);
}
- $ret = self::person_by_handle($author);
+ $ret = self::personByHandle($author);
if (!$ret || ($ret["network"] != NETWORK_DIASPORA)) {
logger("Cannot resolve diaspora handle ".$author." for ".$recipient);
// find the contact record we just created
- $contact_record = self::contact_by_handle($importer["uid"], $author);
+ $contact_record = self::contactByHandle($importer["uid"], $author);
if (!$contact_record) {
logger("unable to locate newly created contact record.");
$u = q("SELECT * FROM `user` WHERE `uid` = %d LIMIT 1", intval($importer["uid"]));
if ($u) {
logger("Sending share message (Relation: ".$new_relation.") to author ".$author." - Contact: ".$contact_record["id"]." - User: ".$importer["uid"], LOGGER_DEBUG);
- $ret = self::send_share($u[0], $contact_record);
+ $ret = self::sendShare($u[0], $contact_record);
// Send the profile data, maybe it weren't transmitted before
- self::send_profile($importer["uid"], array($contact_record));
+ self::sendProfile($importer["uid"], array($contact_record));
}
}
*
* @return array The fetched item
*/
- private static function original_item($guid, $orig_author, $author)
+ private static function originalItem($guid, $orig_author, $author)
{
// Do we already have this item?
$r = q(
// Maybe it is already a reshared item?
// Then refetch the content, if it is a reshare from a reshare.
// If it is a reshared post from another network then reformat to avoid display problems with two share elements
- if (self::is_reshare($r[0]["body"], true)) {
+ if (self::isReshare($r[0]["body"], true)) {
$r = array();
- } elseif (self::is_reshare($r[0]["body"], false) || strstr($r[0]["body"], "[share")) {
+ } elseif (self::isReshare($r[0]["body"], false) || strstr($r[0]["body"], "[share")) {
$r[0]["body"] = diaspora2bb(bb2diaspora($r[0]["body"]));
- $r[0]["body"] = self::replace_people_guid($r[0]["body"], $r[0]["author-link"]);
+ $r[0]["body"] = self::replacePeopleGuid($r[0]["body"], $r[0]["author-link"]);
// Add OEmbed and other information to the body
$r[0]["body"] = add_page_info_to_body($r[0]["body"], false, true);
if (!DBM::is_result($r)) {
$server = "https://".substr($orig_author, strpos($orig_author, "@") + 1);
logger("1st try: reshared message ".$guid." will be fetched via SSL from the server ".$server);
- $item_id = self::store_by_guid($guid, $server);
+ $item_id = self::storeByGuid($guid, $server);
if (!$item_id) {
$server = "http://".substr($orig_author, strpos($orig_author, "@") + 1);
logger("2nd try: reshared message ".$guid." will be fetched without SLL from the server ".$server);
- $item_id = self::store_by_guid($guid, $server);
+ $item_id = self::storeByGuid($guid, $server);
}
if ($item_id) {
if (DBM::is_result($r)) {
// If it is a reshared post from another network then reformat to avoid display problems with two share elements
- if (self::is_reshare($r[0]["body"], false)) {
+ if (self::isReshare($r[0]["body"], false)) {
$r[0]["body"] = diaspora2bb(bb2diaspora($r[0]["body"]));
- $r[0]["body"] = self::replace_people_guid($r[0]["body"], $r[0]["author-link"]);
+ $r[0]["body"] = self::replacePeopleGuid($r[0]["body"], $r[0]["author-link"]);
}
return $r[0];
*
* @return int the message id
*/
- private static function receive_reshare($importer, $data, $xml)
+ private static function receiveReshare($importer, $data, $xml)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
/// @todo handle unprocessed property "provider_display_name"
$public = notags(unxmlify($data->public));
- $contact = self::allowed_contact_by_handle($importer, $author, false);
+ $contact = self::allowedContactByHandle($importer, $author, false);
if (!$contact) {
return false;
}
- $message_id = self::message_exists($importer["uid"], $guid);
+ $message_id = self::messageExists($importer["uid"], $guid);
if ($message_id) {
return true;
}
- $original_item = self::original_item($root_guid, $root_author, $author);
+ $original_item = self::originalItem($root_guid, $root_author, $author);
if (!$original_item) {
return false;
}
$datarray["owner-avatar"] = $datarray["author-avatar"];
$datarray["guid"] = $guid;
- $datarray["uri"] = $datarray["parent-uri"] = self::get_uri_from_guid($author, $guid);
+ $datarray["uri"] = $datarray["parent-uri"] = self::getUriFromGuid($author, $guid);
$datarray["verb"] = ACTIVITY_POST;
$datarray["gravity"] = GRAVITY_PARENT;
$datarray["object-type"] = $original_item["object-type"];
- self::fetch_guid($datarray);
+ self::fetchGuid($datarray);
$message_id = item_store($datarray);
if ($message_id) {
*
* @return bool success
*/
- private static function item_retraction($importer, $contact, $data)
+ private static function itemRetraction($importer, $contact, $data)
{
$author = notags(unxmlify($data->author));
$target_guid = notags(unxmlify($data->target_guid));
$target_type = notags(unxmlify($data->target_type));
- $person = self::person_by_handle($author);
+ $person = self::personByHandle($author);
if (!is_array($person)) {
logger("unable to find author detail for ".$author);
return false;
// Now check if the retraction needs to be relayed by us
if ($parent["origin"]) {
// notify others
- Worker::add(PRIORITY_HIGH, "notifier", "drop", $item["id"]);
+ Worker::add(PRIORITY_HIGH, "Notifier", "drop", $item["id"]);
}
}
*
* @return bool Success
*/
- private static function receive_retraction($importer, $sender, $data)
+ private static function receiveRetraction($importer, $sender, $data)
{
$target_type = notags(unxmlify($data->target_type));
- $contact = self::contact_by_handle($importer["uid"], $sender);
+ $contact = self::contactByHandle($importer["uid"], $sender);
if (!$contact && (in_array($target_type, array("Contact", "Person")))) {
logger("cannot find contact for sender: ".$sender." and user ".$importer["uid"]);
return false;
case "Post":
case "Reshare":
case "StatusMessage":
- return self::item_retraction($importer, $contact, $data);
+ return self::itemRetraction($importer, $contact, $data);
case "Contact":
case "Person":
/// @todo What should we do with an "unshare"?
// Removing the contact isn't correct since we still can read the public items
- contact_remove($contact["id"]);
+ Contact::remove($contact["id"]);
return true;
default:
*
* @return int The message id of the newly created item
*/
- private static function receive_status_message($importer, $data, $xml)
+ private static function receiveStatusMessage($importer, $data, $xml)
{
$author = notags(unxmlify($data->author));
$guid = notags(unxmlify($data->guid));
$text = unxmlify($data->text);
$provider_display_name = notags(unxmlify($data->provider_display_name));
- $contact = self::allowed_contact_by_handle($importer, $author, false);
+ $contact = self::allowedContactByHandle($importer, $author, false);
if (!$contact) {
return false;
}
- $message_id = self::message_exists($importer["uid"], $guid);
+ $message_id = self::messageExists($importer["uid"], $guid);
if ($message_id) {
return true;
}
$datarray["object-type"] = ACTIVITY_OBJ_NOTE;
// Add OEmbed and other information to the body
- if (!self::is_redmatrix($contact["url"])) {
+ if (!self::isRedmatrix($contact["url"])) {
$body = add_page_info_to_body($body, false, true);
}
}
$datarray["owner-avatar"] = $datarray["author-avatar"];
$datarray["guid"] = $guid;
- $datarray["uri"] = $datarray["parent-uri"] = self::get_uri_from_guid($author, $guid);
+ $datarray["uri"] = $datarray["parent-uri"] = self::getUriFromGuid($author, $guid);
$datarray["verb"] = ACTIVITY_POST;
$datarray["gravity"] = GRAVITY_PARENT;
$datarray["protocol"] = PROTOCOL_DIASPORA;
$datarray["source"] = $xml;
- $datarray["body"] = self::replace_people_guid($body, $contact["url"]);
+ $datarray["body"] = self::replacePeopleGuid($body, $contact["url"]);
if ($provider_display_name != "") {
$datarray["app"] = $provider_display_name;
$datarray["coord"] = $address["lat"]." ".$address["lng"];
}
- self::fetch_guid($datarray);
+ self::fetchGuid($datarray);
$message_id = item_store($datarray);
if ($message_id) {
*
* @return string the handle in the format user@domain.tld
*/
- private static function my_handle($contact)
+ private static function myHandle($contact)
{
if ($contact["addr"] != "") {
return $contact["addr"];
*
* @return string The encrypted data
*/
- public static function encode_private_data($msg, $user, $contact, $prvkey, $pubkey)
+ public static function encodePrivateData($msg, $user, $contact, $prvkey, $pubkey)
{
logger("Message: ".$msg, LOGGER_DATA);
$iv = openssl_random_pseudo_bytes(16);
$b_iv = base64_encode($iv);
- $ciphertext = self::aes_encrypt($aes_key, $iv, $msg);
+ $ciphertext = self::aesEncrypt($aes_key, $iv, $msg);
$json = json_encode(array("iv" => $b_iv, "key" => $b_aes_key));
*
* @return string The envelope
*/
- public static function build_magic_envelope($msg, $user)
+ public static function buildMagicEnvelope($msg, $user)
{
$b64url_data = base64url_encode($msg);
$data = str_replace(array("\n", "\r", " ", "\t"), array("", "", "", ""), $b64url_data);
- $key_id = base64url_encode(self::my_handle($user));
+ $key_id = base64url_encode(self::myHandle($user));
$type = "application/xml";
$encoding = "base64url";
$alg = "RSA-SHA256";
$namespaces = array("me" => "http://salmon-protocol.org/ns/magic-env");
- return XML::from_array($xmldata, $xml, false, $namespaces);
+ return XML::fromArray($xmldata, $xml, false, $namespaces);
}
/**
*
* @return string The message that will be transmitted to other servers
*/
- private static function build_message($msg, $user, $contact, $prvkey, $pubkey, $public = false)
+ private static function buildMessage($msg, $user, $contact, $prvkey, $pubkey, $public = false)
{
// The message is put into an envelope with the sender's signature
- $envelope = self::build_magic_envelope($msg, $user);
+ $envelope = self::buildMagicEnvelope($msg, $user);
// Private messages are put into a second envelope, encrypted with the receivers public key
if (!$public) {
- $envelope = self::encode_private_data($envelope, $user, $contact, $prvkey, $pubkey);
+ $envelope = self::encodePrivateData($envelope, $user, $contact, $prvkey, $pubkey);
}
return $envelope;
add_to_queue($contact["id"], NETWORK_DIASPORA, $envelope, $public_batch);
// The message could not be delivered. We mark the contact as "dead"
- mark_for_death($contact);
+ Contact::markForArchival($contact);
}
} elseif (($return_code >= 200) && ($return_code <= 299)) {
// We successfully delivered a message, the contact is alive
- unmark_for_death($contact);
+ Contact::unmarkForArchival($contact);
}
return(($return_code) ? $return_code : (-1));
*
* @return string The post XML
*/
- public static function build_post_xml($type, $message)
+ public static function buildPostXml($type, $message)
{
$data = array($type => $message);
- return XML::from_array($data, $xml);
+ return XML::fromArray($data, $xml);
}
/**
*
* @return int Result of the transmission
*/
- private static function build_and_transmit($owner, $contact, $type, $message, $public_batch = false, $guid = "", $spool = false)
+ private static function buildAndTransmit($owner, $contact, $type, $message, $public_batch = false, $guid = "", $spool = false)
{
- $msg = self::build_post_xml($type, $message);
+ $msg = self::buildPostXml($type, $message);
logger('message: '.$msg, LOGGER_DATA);
logger('send guid '.$guid, LOGGER_DEBUG);
$owner['uprvkey'] = $owner['prvkey'];
}
- $envelope = self::build_message($msg, $owner, $contact, $owner['uprvkey'], $contact['pubkey'], $public_batch);
+ $envelope = self::buildMessage($msg, $owner, $contact, $owner['uprvkey'], $contact['pubkey'], $public_batch);
if ($spool) {
add_to_queue($contact['id'], NETWORK_DIASPORA, $envelope, $public_batch);
logger("Send account migration ".print_r($message, true), LOGGER_DEBUG);
- return self::build_and_transmit($owner, $contact, "account_migration", $message);
+ return self::buildAndTransmit($owner, $contact, "account_migration", $message);
}
/**
*
* @return int The result of the transmission
*/
- public static function send_share($owner, $contact)
+ public static function sendShare($owner, $contact)
{
/**
* @todo support the different possible combinations of "following" and "sharing"
* Currently, Diaspora only interprets the "sharing" field
*
- * Before switching this code productive, we have to check all "send_share" calls if "rel" is set correctly
+ * Before switching this code productive, we have to check all "sendShare" calls if "rel" is set correctly
*/
/*
}
*/
- $message = array("author" => self::my_handle($owner),
+ $message = array("author" => self::myHandle($owner),
"recipient" => $contact["addr"],
"following" => "true",
"sharing" => "true");
logger("Send share ".print_r($message, true), LOGGER_DEBUG);
- return self::build_and_transmit($owner, $contact, "contact", $message);
+ return self::buildAndTransmit($owner, $contact, "contact", $message);
}
/**
*
* @return int The result of the transmission
*/
- public static function send_unshare($owner, $contact)
+ public static function sendUnshare($owner, $contact)
{
- $message = array("author" => self::my_handle($owner),
+ $message = array("author" => self::myHandle($owner),
"recipient" => $contact["addr"],
"following" => "false",
"sharing" => "false");
logger("Send unshare ".print_r($message, true), LOGGER_DEBUG);
- return self::build_and_transmit($owner, $contact, "contact", $message);
+ return self::buildAndTransmit($owner, $contact, "contact", $message);
}
/**
*
* @return array|bool Reshare details or "false" if no reshare
*/
- public static function is_reshare($body, $complete = true)
+ public static function isReshare($body, $complete = true)
{
$body = trim($body);
);
if ($r) {
$ret= array();
- $ret["root_handle"] = self::handle_from_contact($r[0]["contact-id"]);
+ $ret["root_handle"] = self::handleFromContact($r[0]["contact-id"]);
$ret["root_guid"] = $guid;
return($ret);
}
*
* @return array with event data
*/
- private static function build_event($event_id)
+ private static function buildEvent($event_id)
{
$r = q("SELECT `guid`, `uid`, `start`, `finish`, `nofinish`, `summary`, `desc`, `location`, `adjust` FROM `event` WHERE `id` = %d", intval($event_id));
if (!DBM::is_result($r)) {
$owner = $r[0];
- $eventdata['author'] = self::my_handle($owner);
+ $eventdata['author'] = self::myHandle($owner);
if ($event['guid']) {
$eventdata['guid'] = $event['guid'];
* 'type' -> Message type ("status_message" or "reshare")
* 'message' -> Array of XML elements of the status
*/
- public static function build_status($item, $owner)
+ public static function buildStatus($item, $owner)
{
- $cachekey = "diaspora:build_status:".$item['guid'];
+ $cachekey = "diaspora:buildStatus:".$item['guid'];
$result = Cache::get($cachekey);
if (!is_null($result)) {
return $result;
}
- $myaddr = self::my_handle($owner);
+ $myaddr = self::myHandle($owner);
$public = (($item["private"]) ? "false" : "true");
$created = datetime_convert("UTC", "UTC", $item["created"], 'Y-m-d\TH:i:s\Z');
// Detect a share element and do a reshare
- if (!$item['private'] && ($ret = self::is_reshare($item["body"]))) {
+ if (!$item['private'] && ($ret = self::isReshare($item["body"]))) {
$message = array("author" => $myaddr,
"guid" => $item["guid"],
"created_at" => $created,
}
if ($item['event-id'] > 0) {
- $event = self::build_event($item['event-id']);
+ $event = self::buildEvent($item['event-id']);
if (count($event)) {
$message['event'] = $event;
*
* @return int The result of the transmission
*/
- public static function send_status($item, $owner, $contact, $public_batch = false)
+ public static function sendStatus($item, $owner, $contact, $public_batch = false)
{
- $status = self::build_status($item, $owner);
+ $status = self::buildStatus($item, $owner);
- return self::build_and_transmit($owner, $contact, $status["type"], $status["message"], $public_batch, $item["guid"]);
+ return self::buildAndTransmit($owner, $contact, $status["type"], $status["message"], $public_batch, $item["guid"]);
}
/**
*
* @return array The data for a "like"
*/
- private static function construct_like($item, $owner)
+ private static function constructLike($item, $owner)
{
$p = q(
"SELECT `guid`, `uri`, `parent-uri` FROM `item` WHERE `uri` = '%s' LIMIT 1",
$positive = "false";
}
- return(array("author" => self::my_handle($owner),
+ return(array("author" => self::myHandle($owner),
"guid" => $item["guid"],
"parent_guid" => $parent["guid"],
"parent_type" => $target_type,
*
* @return array The data for an "EventParticipation"
*/
- private static function construct_attend($item, $owner) {
-
+ private static function constructAttend($item, $owner)
+ {
$p = q(
"SELECT `guid`, `uri`, `parent-uri` FROM `item` WHERE `uri` = '%s' LIMIT 1",
dbesc($item["thr-parent"])
return false;
}
- return(array("author" => self::my_handle($owner),
+ return(array("author" => self::myHandle($owner),
"guid" => $item["guid"],
"parent_guid" => $parent["guid"],
"status" => $attend_answer,
*
* @return array The data for a comment
*/
- private static function construct_comment($item, $owner)
+ private static function constructComment($item, $owner)
{
- $cachekey = "diaspora:construct_comment:".$item['guid'];
+ $cachekey = "diaspora:constructComment:".$item['guid'];
$result = Cache::get($cachekey);
if (!is_null($result)) {
$text = html_entity_decode(bb2diaspora($item["body"]));
$created = datetime_convert("UTC", "UTC", $item["created"], 'Y-m-d\TH:i:s\Z');
- $comment = array("author" => self::my_handle($owner),
+ $comment = array("author" => self::myHandle($owner),
"guid" => $item["guid"],
"created_at" => $created,
"parent_guid" => $parent["guid"],
// Send the thread parent guid only if it is a threaded comment
if ($item['thr-parent'] != $item['parent-uri']) {
- $comment['thread_parent_guid'] = self::get_guid_from_uri($item['thr-parent'], $item['uid']);
+ $comment['thread_parent_guid'] = self::getGuidFromUri($item['thr-parent'], $item['uid']);
}
Cache::set($cachekey, $comment, CACHE_QUARTER_HOUR);
*
* @return int The result of the transmission
*/
- public static function send_followup($item, $owner, $contact, $public_batch = false)
+ public static function sendFollowup($item, $owner, $contact, $public_batch = false)
{
if (in_array($item['verb'], array(ACTIVITY_ATTEND, ACTIVITY_ATTENDNO, ACTIVITY_ATTENDMAYBE))) {
- $message = self::construct_attend($item, $owner);
+ $message = self::constructAttend($item, $owner);
$type = "event_participation";
} elseif (in_array($item["verb"], array(ACTIVITY_LIKE, ACTIVITY_DISLIKE))) {
- $message = self::construct_like($item, $owner);
+ $message = self::constructLike($item, $owner);
$type = "like";
} else {
- $message = self::construct_comment($item, $owner);
+ $message = self::constructComment($item, $owner);
$type = "comment";
}
$message["author_signature"] = self::signature($owner, $message);
- return self::build_and_transmit($owner, $contact, $type, $message, $public_batch, $item["guid"]);
+ return self::buildAndTransmit($owner, $contact, $type, $message, $public_batch, $item["guid"]);
}
/**
*
* @return string The message
*/
- private static function message_from_signature($item, $signature)
+ private static function messageFromSignature($item, $signature)
{
// Split the signed text
$signed_parts = explode(";", $signature['signed_text']);
*
* @return int The result of the transmission
*/
- public static function send_relay($item, $owner, $contact, $public_batch = false)
+ public static function sendRelay($item, $owner, $contact, $public_batch = false)
{
if ($item["deleted"]) {
- return self::send_retraction($item, $owner, $contact, $public_batch, true);
+ return self::sendRetraction($item, $owner, $contact, $public_batch, true);
} elseif (in_array($item["verb"], array(ACTIVITY_LIKE, ACTIVITY_DISLIKE))) {
$type = "like";
} else {
// Old way - is used by the internal Friendica functions
/// @todo Change all signatur storing functions to the new format
if ($signature['signed_text'] && $signature['signature'] && $signature['signer']) {
- $message = self::message_from_signature($item, $signature);
+ $message = self::messageFromSignature($item, $signature);
} else {// New way
$msg = json_decode($signature['signed_text'], true);
$message = array();
if (is_array($msg)) {
- foreach ($msg AS $field => $data) {
+ foreach ($msg as $field => $data) {
if (!$item["deleted"]) {
if ($field == "diaspora_handle") {
$field = "author";
logger("Relayed data ".print_r($message, true), LOGGER_DEBUG);
- return self::build_and_transmit($owner, $contact, $type, $message, $public_batch, $item["guid"]);
+ return self::buildAndTransmit($owner, $contact, $type, $message, $public_batch, $item["guid"]);
}
/**
*
* @return int The result of the transmission
*/
- public static function send_retraction($item, $owner, $contact, $public_batch = false, $relay = false)
+ public static function sendRetraction($item, $owner, $contact, $public_batch = false, $relay = false)
{
- $itemaddr = self::handle_from_contact($item["contact-id"], $item["gcontact-id"]);
+ $itemaddr = self::handleFromContact($item["contact-id"], $item["gcontact-id"]);
$msg_type = "retraction";
logger("Got message ".print_r($message, true), LOGGER_DEBUG);
- return self::build_and_transmit($owner, $contact, $msg_type, $message, $public_batch, $item["guid"]);
+ return self::buildAndTransmit($owner, $contact, $msg_type, $message, $public_batch, $item["guid"]);
}
/**
*
* @return int The result of the transmission
*/
- public static function send_mail($item, $owner, $contact)
+ public static function sendMail($item, $owner, $contact)
{
- $myaddr = self::my_handle($owner);
+ $myaddr = self::myHandle($owner);
$r = q(
"SELECT * FROM `conv` WHERE `id` = %d AND `uid` = %d LIMIT 1",
$type = "conversation";
}
- return self::build_and_transmit($owner, $contact, $type, $message, false, $item["guid"]);
+ return self::buildAndTransmit($owner, $contact, $type, $message, false, $item["guid"]);
}
/**
$about = $profile['about'];
$about = strip_tags(bbcode($about));
- $location = formatted_location($profile);
+ $location = Profile::formatLocation($profile);
$tags = '';
if ($profile['pub_keywords']) {
$kw = str_replace(',', ' ', $profile['pub_keywords']);
/**
* @brief Sends profile data
*
- * @param int $uid The user id
+ * @param int $uid The user id
+ * @param bool $recips optional, default false
+ * @return void
*/
- public static function send_profile($uid, $recips = false)
+ public static function sendProfile($uid, $recips = false)
{
if (!$uid) {
return;
foreach ($recips as $recip) {
logger("Send updated profile data for user ".$uid." to contact ".$recip["id"], LOGGER_DEBUG);
- self::build_and_transmit($profile, $recip, "profile", $message, false, "", true);
+ self::buildAndTransmit($profile, $recip, "profile", $message, false, "", true);
}
}
*
* @return bool Success
*/
- public static function store_like_signature($contact, $post_id)
+ public static function storeLikeSignature($contact, $post_id)
{
// Is the contact the owner? Then fetch the private key
if (!$contact['self'] || ($contact['uid'] == 0)) {
return false;
}
- $message = self::construct_like($r[0], $contact);
+ $message = self::constructLike($r[0], $contact);
$message["author_signature"] = self::signature($contact, $message);
/*
*
* @return bool Success
*/
- public static function store_comment_signature($item, $contact, $uprvkey, $message_id)
+ public static function storeCommentSignature($item, $contact, $uprvkey, $message_id)
{
if ($uprvkey == "") {
logger('No private key, so not storing comment signature', LOGGER_DEBUG);
$contact["uprvkey"] = $uprvkey;
- $message = self::construct_comment($item, $contact);
+ $message = self::constructComment($item, $contact);
$message["author_signature"] = self::signature($contact, $message);
/*
--- /dev/null
+<?php
+/**
+ * @file src/Protocol/OStatus.php
+ */
+namespace Friendica\Protocol;
+
+use Friendica\App;
+use Friendica\Core\Cache;
+use Friendica\Core\Config;
+use Friendica\Core\System;
+use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Network\Probe;
+use Friendica\Object\Contact;
+use Friendica\Util\Lock;
+use Friendica\Util\XML;
+use dba;
+use DOMDocument;
+use DomXPath;
+
+require_once 'include/threads.php';
+require_once 'include/html2bbcode.php';
+require_once 'include/bbcode.php';
+require_once 'include/items.php';
+require_once 'mod/share.php';
+require_once 'include/enotify.php';
+require_once 'include/Photo.php';
+require_once 'include/follow.php';
+require_once 'include/api.php';
+require_once 'mod/proxy.php';
+
+/**
+ * @brief This class contain functions for the OStatus protocol
+ */
+class OStatus
+{
+ private static $itemlist;
+ private static $conv_list = array();
+
+ /**
+ * @brief Fetches author data
+ *
+ * @param object $xpath The xpath object
+ * @param object $context The xml context of the author details
+ * @param array $importer user record of the importing user
+ * @param array $contact Called by reference, will contain the fetched contact
+ * @param bool $onlyfetch Only fetch the header without updating the contact entries
+ *
+ * @return array Array of author related entries for the item
+ */
+ private static function fetchAuthor($xpath, $context, $importer, &$contact, $onlyfetch)
+ {
+ $author = array();
+ $author["author-link"] = $xpath->evaluate('atom:author/atom:uri/text()', $context)->item(0)->nodeValue;
+ $author["author-name"] = $xpath->evaluate('atom:author/atom:name/text()', $context)->item(0)->nodeValue;
+ $addr = $xpath->evaluate('atom:author/atom:email/text()', $context)->item(0)->nodeValue;
+
+ $aliaslink = $author["author-link"];
+
+ $alternate = $xpath->query("atom:author/atom:link[@rel='alternate']", $context)->item(0)->attributes;
+ if (is_object($alternate)) {
+ foreach ($alternate as $attributes) {
+ if (($attributes->name == "href") && ($attributes->textContent != "")) {
+ $author["author-link"] = $attributes->textContent;
+ }
+ }
+ }
+ $author["contact-id"] = $contact["id"];
+
+ $found = false;
+
+ if ($aliaslink != '') {
+ $condition = array("`uid` = ? AND `alias` = ? AND `network` != ?",
+ $importer["uid"], $aliaslink, NETWORK_STATUSNET);
+ $r = dba::select('contact', array(), $condition, array('limit' => 1));
+
+ if (DBM::is_result($r)) {
+ $found = true;
+ if ($r['blocked']) {
+ $r['id'] = -1;
+ }
+ $contact = $r;
+ $author["contact-id"] = $r["id"];
+ }
+ }
+
+ if (!$found && ($author["author-link"] != "")) {
+ if ($aliaslink == "") {
+ $aliaslink = $author["author-link"];
+ }
+
+ $condition = array("`uid` = ? AND `nurl` IN (?, ?) AND `network` != ?", $importer["uid"],
+ normalise_link($author["author-link"]), normalise_link($aliaslink), NETWORK_STATUSNET);
+ $r = dba::select('contact', array(), $condition, array('limit' => 1));
+
+ if (DBM::is_result($r)) {
+ $found = true;
+ if ($r['blocked']) {
+ $r['id'] = -1;
+ }
+ $contact = $r;
+ $author["contact-id"] = $r["id"];
+ }
+ }
+
+ if (!$found && ($addr != "")) {
+ $condition = array("`uid` = ? AND `addr` = ? AND `network` != ?",
+ $importer["uid"], $addr, NETWORK_STATUSNET);
+ $r = dba::select('contact', array(), $condition, array('limit' => 1));
+
+ if (DBM::is_result($r)) {
+ $found = true;
+ if ($r['blocked']) {
+ $r['id'] = -1;
+ }
+ $contact = $r;
+ $author["contact-id"] = $r["id"];
+ }
+ }
+
+ $avatarlist = array();
+ $avatars = $xpath->query("atom:author/atom:link[@rel='avatar']", $context);
+ foreach ($avatars as $avatar) {
+ $href = "";
+ $width = 0;
+ foreach ($avatar->attributes as $attributes) {
+ if ($attributes->name == "href") {
+ $href = $attributes->textContent;
+ }
+ if ($attributes->name == "width") {
+ $width = $attributes->textContent;
+ }
+ }
+ if ($href != "") {
+ $avatarlist[$width] = $href;
+ }
+ }
+ if (count($avatarlist) > 0) {
+ krsort($avatarlist);
+ $author["author-avatar"] = Probe::fixAvatar(current($avatarlist), $author["author-link"]);
+ }
+
+ $displayname = $xpath->evaluate('atom:author/poco:displayName/text()', $context)->item(0)->nodeValue;
+ if ($displayname != "") {
+ $author["author-name"] = $displayname;
+ }
+
+ $author["owner-name"] = $author["author-name"];
+ $author["owner-link"] = $author["author-link"];
+ $author["owner-avatar"] = $author["author-avatar"];
+
+ // Only update the contacts if it is an OStatus contact
+ if ($r && ($r['id'] > 0) && !$onlyfetch && ($contact["network"] == NETWORK_OSTATUS)) {
+ // This contact is vital, so we awake it from the dead
+ Contact::unmarkForArchival($contact);
+
+ // Update contact data
+
+ $current = $contact;
+ unset($current['name-date']);
+
+ // This query doesn't seem to work
+ // $value = $xpath->query("atom:link[@rel='salmon']", $context)->item(0)->nodeValue;
+ // if ($value != "")
+ // $contact["notify"] = $value;
+
+ // This query doesn't seem to work as well - I hate these queries
+ // $value = $xpath->query("atom:link[@rel='self' and @type='application/atom+xml']", $context)->item(0)->nodeValue;
+ // if ($value != "")
+ // $contact["poll"] = $value;
+
+ $contact['url'] = $author["author-link"];
+ $contact['nurl'] = normalise_link($contact['url']);
+
+ $value = $xpath->evaluate('atom:author/atom:uri/text()', $context)->item(0)->nodeValue;
+ if ($value != "") {
+ $contact["alias"] = $value;
+ }
+
+ $value = $xpath->evaluate('atom:author/poco:displayName/text()', $context)->item(0)->nodeValue;
+ if ($value != "") {
+ $contact["name"] = $value;
+ }
+
+ $value = $xpath->evaluate('atom:author/poco:preferredUsername/text()', $context)->item(0)->nodeValue;
+ if ($value != "") {
+ $contact["nick"] = $value;
+ }
+
+ $value = $xpath->evaluate('atom:author/poco:note/text()', $context)->item(0)->nodeValue;
+ if ($value != "") {
+ $contact["about"] = html2bbcode($value);
+ }
+
+ $value = $xpath->evaluate('atom:author/poco:address/poco:formatted/text()', $context)->item(0)->nodeValue;
+ if ($value != "") {
+ $contact["location"] = $value;
+ }
+
+ $contact['name-date'] = datetime_convert();
+
+ dba::update('contact', $contact, array('id' => $contact["id"]), $current);
+
+ if (!empty($author["author-avatar"]) && ($author["author-avatar"] != $current['avatar'])) {
+ logger("Update profile picture for contact ".$contact["id"], LOGGER_DEBUG);
+ update_contact_avatar($author["author-avatar"], $importer["uid"], $contact["id"]);
+ }
+
+ // Ensure that we are having this contact (with uid=0)
+ $cid = Contact::getIdForURL($aliaslink, 0);
+
+ if ($cid) {
+ $fields = array('url', 'nurl', 'name', 'nick', 'alias', 'about', 'location');
+ $old_contact = dba::select('contact', $fields, array('id' => $cid), array('limit' => 1));
+
+ // Update it with the current values
+ $fields = array('url' => $author["author-link"], 'name' => $contact["name"],
+ 'nurl' => normalise_link($author["author-link"]),
+ 'nick' => $contact["nick"], 'alias' => $contact["alias"],
+ 'about' => $contact["about"], 'location' => $contact["location"],
+ 'success_update' => datetime_convert(), 'last-update' => datetime_convert());
+
+ dba::update('contact', $fields, array('id' => $cid), $old_contact);
+
+ // Update the avatar
+ update_contact_avatar($author["author-avatar"], 0, $cid);
+ }
+
+ $contact["generation"] = 2;
+ $contact["hide"] = false; // OStatus contacts are never hidden
+ $contact["photo"] = $author["author-avatar"];
+ $gcid = GlobalContact::update($contact);
+
+ GlobalContact::link($gcid, $contact["uid"], $contact["id"]);
+ }
+
+ return $author;
+ }
+
+ /**
+ * @brief Fetches author data from a given XML string
+ *
+ * @param string $xml The XML
+ * @param array $importer user record of the importing user
+ *
+ * @return array Array of author related entries for the item
+ */
+ public static function salmonAuthor($xml, $importer)
+ {
+ if ($xml == "") {
+ return;
+ }
+
+ $doc = new DOMDocument();
+ @$doc->loadXML($xml);
+
+ $xpath = new DomXPath($doc);
+ $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
+ $xpath->registerNamespace('thr', NAMESPACE_THREAD);
+ $xpath->registerNamespace('georss', NAMESPACE_GEORSS);
+ $xpath->registerNamespace('activity', NAMESPACE_ACTIVITY);
+ $xpath->registerNamespace('media', NAMESPACE_MEDIA);
+ $xpath->registerNamespace('poco', NAMESPACE_POCO);
+ $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
+ $xpath->registerNamespace('statusnet', NAMESPACE_STATUSNET);
+
+ $entries = $xpath->query('/atom:entry');
+
+ foreach ($entries as $entry) {
+ // fetch the author
+ $author = self::fetchAuthor($xpath, $entry, $importer, $contact, true);
+ return $author;
+ }
+ }
+
+ /**
+ * @brief Read attributes from element
+ *
+ * @param object $element Element object
+ *
+ * @return array attributes
+ */
+ private static function readAttributes($element)
+ {
+ $attribute = array();
+
+ foreach ($element->attributes as $attributes) {
+ $attribute[$attributes->name] = $attributes->textContent;
+ }
+
+ return $attribute;
+ }
+
+ /**
+ * @brief Imports an XML string containing OStatus elements
+ *
+ * @param string $xml The XML
+ * @param array $importer user record of the importing user
+ * @param array $contact contact
+ * @param string $hub Called by reference, returns the fetched hub data
+ * @return void
+ */
+ public static function import($xml, $importer, &$contact, &$hub)
+ {
+ self::process($xml, $importer, $contact, $hub);
+ }
+
+ /**
+ * @brief Internal feed processing
+ *
+ * @param string $xml The XML
+ * @param array $importer user record of the importing user
+ * @param array $contact contact
+ * @param string $hub Called by reference, returns the fetched hub data
+ * @param boolean $stored Is the post fresh imported or from the database?
+ * @param boolean $initialize Is it the leading post so that data has to be initialized?
+ *
+ * @return boolean Could the XML be processed?
+ */
+ private static function process($xml, $importer, &$contact, &$hub, $stored = false, $initialize = true)
+ {
+ if ($initialize) {
+ self::$itemlist = array();
+ self::$conv_list = array();
+ }
+
+ logger("Import OStatus message", LOGGER_DEBUG);
+
+ if ($xml == "") {
+ return false;
+ }
+ $doc = new DOMDocument();
+ @$doc->loadXML($xml);
+
+ $xpath = new DomXPath($doc);
+ $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
+ $xpath->registerNamespace('thr', NAMESPACE_THREAD);
+ $xpath->registerNamespace('georss', NAMESPACE_GEORSS);
+ $xpath->registerNamespace('activity', NAMESPACE_ACTIVITY);
+ $xpath->registerNamespace('media', NAMESPACE_MEDIA);
+ $xpath->registerNamespace('poco', NAMESPACE_POCO);
+ $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
+ $xpath->registerNamespace('statusnet', NAMESPACE_STATUSNET);
+
+ $hub = "";
+ $hub_attributes = $xpath->query("/atom:feed/atom:link[@rel='hub']")->item(0)->attributes;
+ if (is_object($hub_attributes)) {
+ foreach ($hub_attributes as $hub_attribute) {
+ if ($hub_attribute->name == "href") {
+ $hub = $hub_attribute->textContent;
+ logger("Found hub ".$hub, LOGGER_DEBUG);
+ }
+ }
+ }
+
+ $header = array();
+ $header["uid"] = $importer["uid"];
+ $header["network"] = NETWORK_OSTATUS;
+ $header["type"] = "remote";
+ $header["wall"] = 0;
+ $header["origin"] = 0;
+ $header["gravity"] = GRAVITY_PARENT;
+
+ $first_child = $doc->firstChild->tagName;
+
+ if ($first_child == "feed") {
+ $entries = $xpath->query('/atom:feed/atom:entry');
+ } else {
+ $entries = $xpath->query('/atom:entry');
+ }
+
+ if ($entries->length == 1) {
+ // We reformat the XML to make it better readable
+ $doc2 = new DOMDocument();
+ $doc2->loadXML($xml);
+ $doc2->preserveWhiteSpace = false;
+ $doc2->formatOutput = true;
+ $xml2 = $doc2->saveXML();
+
+ $header["protocol"] = PROTOCOL_OSTATUS_SALMON;
+ $header["source"] = $xml2;
+ } elseif (!$initialize) {
+ return false;
+ }
+
+ // Fetch the first author
+ $authordata = $xpath->query('//author')->item(0);
+ $author = self::fetchAuthor($xpath, $authordata, $importer, $contact, $stored);
+
+ $entry = $xpath->query('/atom:entry');
+
+ // Reverse the order of the entries
+ $entrylist = array();
+
+ foreach ($entries as $entry) {
+ $entrylist[] = $entry;
+ }
+
+ foreach (array_reverse($entrylist) as $entry) {
+ // fetch the author
+ $authorelement = $xpath->query('/atom:entry/atom:author', $entry);
+
+ if ($authorelement->length == 0) {
+ $authorelement = $xpath->query('atom:author', $entry);
+ }
+
+ if ($authorelement->length > 0) {
+ $author = self::fetchAuthor($xpath, $entry, $importer, $contact, $stored);
+ }
+
+ $value = $xpath->evaluate('atom:author/poco:preferredUsername/text()', $entry)->item(0)->nodeValue;
+ if ($value != "") {
+ $nickname = $value;
+ } else {
+ $nickname = $author["author-name"];
+ }
+
+ $item = array_merge($header, $author);
+
+ $item["uri"] = $xpath->query('atom:id/text()', $entry)->item(0)->nodeValue;
+
+ $item["verb"] = $xpath->query('activity:verb/text()', $entry)->item(0)->nodeValue;
+
+ // Delete a message
+ if (in_array($item["verb"], array('qvitter-delete-notice', ACTIVITY_DELETE, 'delete'))) {
+ self::deleteNotice($item);
+ continue;
+ }
+
+ if (in_array($item["verb"], array(NAMESPACE_OSTATUS."/unfavorite", ACTIVITY_UNFAVORITE))) {
+ // Ignore "Unfavorite" message
+ logger("Ignore unfavorite message ".print_r($item, true), LOGGER_DEBUG);
+ continue;
+ }
+
+ // Deletions come with the same uri, so we check for duplicates after processing deletions
+ if (dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item["uri"]))) {
+ logger('Post with URI '.$item["uri"].' already existed for user '.$importer["uid"].'.', LOGGER_DEBUG);
+ continue;
+ } else {
+ logger('Processing post with URI '.$item["uri"].' for user '.$importer["uid"].'.', LOGGER_DEBUG);
+ }
+
+ if ($item["verb"] == ACTIVITY_JOIN) {
+ // ignore "Join" messages
+ logger("Ignore join message ".print_r($item, true), LOGGER_DEBUG);
+ continue;
+ }
+
+ if ($item["verb"] == "http://mastodon.social/schema/1.0/block") {
+ // ignore mastodon "block" messages
+ logger("Ignore block message ".print_r($item, true), LOGGER_DEBUG);
+ continue;
+ }
+
+ if ($item["verb"] == ACTIVITY_FOLLOW) {
+ new_follower($importer, $contact, $item, $nickname);
+ continue;
+ }
+
+ if ($item["verb"] == NAMESPACE_OSTATUS."/unfollow") {
+ lose_follower($importer, $contact, $item, $dummy);
+ continue;
+ }
+
+ if ($item["verb"] == ACTIVITY_FAVORITE) {
+ $orig_uri = $xpath->query("activity:object/atom:id", $entry)->item(0)->nodeValue;
+ logger("Favorite ".$orig_uri." ".print_r($item, true));
+
+ $item["verb"] = ACTIVITY_LIKE;
+ $item["parent-uri"] = $orig_uri;
+ $item["gravity"] = GRAVITY_LIKE;
+ }
+
+ // http://activitystrea.ms/schema/1.0/rsvp-yes
+ if (!in_array($item["verb"], array(ACTIVITY_POST, ACTIVITY_LIKE, ACTIVITY_SHARE))) {
+ logger("Unhandled verb ".$item["verb"]." ".print_r($item, true), LOGGER_DEBUG);
+ }
+
+ self::processPost($xpath, $entry, $item, $importer);
+
+ if ($initialize && (count(self::$itemlist) > 0)) {
+ if (self::$itemlist[0]['uri'] == self::$itemlist[0]['parent-uri']) {
+ // We will import it everytime, when it is started by our contacts
+ $valid = !empty(self::$itemlist[0]['contact-id']);
+ if (!$valid) {
+ // If not, then it depends on this setting
+ $valid = !Config::get('system', 'ostatus_full_threads');
+ }
+ if ($valid) {
+ // Never post a thread when the only interaction by our contact was a like
+ $valid = false;
+ $verbs = array(ACTIVITY_POST, ACTIVITY_SHARE);
+ foreach (self::$itemlist as $item) {
+ if (!empty($item['contact-id']) && in_array($item['verb'], $verbs)) {
+ $valid = true;
+ }
+ }
+ }
+ } else {
+ // But we will only import complete threads
+ $valid = dba::exists('item', array('uid' => $importer["uid"], 'uri' => self::$itemlist[0]['parent-uri']));
+ }
+
+ if ($valid) {
+ $default_contact = 0;
+ $key = count(self::$itemlist);
+ for ($key = count(self::$itemlist) - 1; $key >= 0; $key--) {
+ if (empty(self::$itemlist[$key]['contact-id'])) {
+ self::$itemlist[$key]['contact-id'] = $default_contact;
+ } else {
+ $default_contact = $item['contact-id'];
+ }
+ }
+ foreach (self::$itemlist as $item) {
+ $found = dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item["uri"]));
+ if ($found) {
+ logger("Item with uri ".$item["uri"]." for user ".$importer["uid"]." already exists.", LOGGER_DEBUG);
+ } elseif ($item['contact-id'] < 0) {
+ logger("Item with uri ".$item["uri"]." is from a blocked contact.", LOGGER_DEBUG);
+ } else {
+ // We are having duplicated entries. Hopefully this solves it.
+ if (Lock::set('ostatus_process_item_store')) {
+ $ret = item_store($item);
+ Lock::remove('ostatus_process_item_store');
+ logger("Item with uri ".$item["uri"]." for user ".$importer["uid"].' stored. Return value: '.$ret);
+ } else {
+ $ret = item_store($item);
+ logger("We couldn't lock - but tried to store the item anyway. Return value is ".$ret);
+ }
+ }
+ }
+ }
+ self::$itemlist = array();
+ }
+ logger('Processing done for post with URI '.$item["uri"].' for user '.$importer["uid"].'.', LOGGER_DEBUG);
+ }
+ return true;
+ }
+
+ /**
+ * @param object $item item
+ * @return void
+ */
+ private static function deleteNotice($item)
+ {
+ $condition = array('uid' => $item['uid'], 'author-link' => $item['author-link'], 'uri' => $item['uri']);
+ $deleted = dba::select('item', array('id', 'parent-uri'), $condition, array('limit' => 1));
+ if (!DBM::is_result($deleted)) {
+ logger('Item from '.$item['author-link'].' with uri '.$item['uri'].' for user '.$item['uid']." wasn't found. We don't delete it. ");
+ return;
+ }
+
+ // Currently we don't have a central deletion function that we could use in this case
+ // The function "item_drop" doesn't work for that case
+ dba::update(
+ 'item',
+ array('deleted' => true, 'title' => '', 'body' => '',
+ 'edited' => datetime_convert(), 'changed' => datetime_convert()),
+ array('id' => $deleted["id"])
+ );
+
+ delete_thread($deleted["id"], $deleted["parent-uri"]);
+
+ logger('Deleted item with uri '.$item['uri'].' for user '.$item['uid']);
+ }
+
+ /**
+ * @brief Processes the XML for a post
+ *
+ * @param object $xpath The xpath object
+ * @param object $entry The xml entry that is processed
+ * @param array $item The item array
+ * @param array $importer user record of the importing user
+ * @return void
+ */
+ private static function processPost($xpath, $entry, &$item, $importer)
+ {
+ $item["body"] = html2bbcode($xpath->query('atom:content/text()', $entry)->item(0)->nodeValue);
+ $item["object-type"] = $xpath->query('activity:object-type/text()', $entry)->item(0)->nodeValue;
+ if (($item["object-type"] == ACTIVITY_OBJ_BOOKMARK) || ($item["object-type"] == ACTIVITY_OBJ_EVENT)) {
+ $item["title"] = $xpath->query('atom:title/text()', $entry)->item(0)->nodeValue;
+ $item["body"] = $xpath->query('atom:summary/text()', $entry)->item(0)->nodeValue;
+ } elseif ($item["object-type"] == ACTIVITY_OBJ_QUESTION) {
+ $item["title"] = $xpath->query('atom:title/text()', $entry)->item(0)->nodeValue;
+ }
+
+ $item["created"] = $xpath->query('atom:published/text()', $entry)->item(0)->nodeValue;
+ $item["edited"] = $xpath->query('atom:updated/text()', $entry)->item(0)->nodeValue;
+ $conversation = $xpath->query('ostatus:conversation/text()', $entry)->item(0)->nodeValue;
+ $item['conversation-uri'] = $conversation;
+
+ $conv = $xpath->query('ostatus:conversation', $entry);
+ if (is_object($conv->item(0))) {
+ foreach ($conv->item(0)->attributes as $attributes) {
+ if ($attributes->name == "ref") {
+ $item['conversation-uri'] = $attributes->textContent;
+ }
+ if ($attributes->name == "href") {
+ $item['conversation-href'] = $attributes->textContent;
+ }
+ }
+ }
+
+ $related = "";
+
+ $inreplyto = $xpath->query('thr:in-reply-to', $entry);
+ if (is_object($inreplyto->item(0))) {
+ foreach ($inreplyto->item(0)->attributes as $attributes) {
+ if ($attributes->name == "ref") {
+ $item["parent-uri"] = $attributes->textContent;
+ }
+ if ($attributes->name == "href") {
+ $related = $attributes->textContent;
+ }
+ }
+ }
+
+ $georsspoint = $xpath->query('georss:point', $entry);
+ if (!empty($georsspoint) && ($georsspoint->length > 0)) {
+ $item["coord"] = $georsspoint->item(0)->nodeValue;
+ }
+
+ $categories = $xpath->query('atom:category', $entry);
+ if ($categories) {
+ foreach ($categories as $category) {
+ foreach ($category->attributes as $attributes) {
+ if ($attributes->name == "term") {
+ $term = $attributes->textContent;
+ if (strlen($item["tag"])) {
+ $item["tag"] .= ',';
+ }
+ $item["tag"] .= "#[url=".System::baseUrl()."/search?tag=".$term."]".$term."[/url]";
+ }
+ }
+ }
+ }
+
+ $self = '';
+ $add_body = '';
+
+ $links = $xpath->query('atom:link', $entry);
+ if ($links) {
+ $link_data = self::processLinks($links, $item);
+ $self = $link_data['self'];
+ $add_body = $link_data['add_body'];
+ }
+
+ $repeat_of = "";
+
+ $notice_info = $xpath->query('statusnet:notice_info', $entry);
+ if ($notice_info && ($notice_info->length > 0)) {
+ foreach ($notice_info->item(0)->attributes as $attributes) {
+ if ($attributes->name == "source") {
+ $item["app"] = strip_tags($attributes->textContent);
+ }
+ if ($attributes->name == "repeat_of") {
+ $repeat_of = $attributes->textContent;
+ }
+ }
+ }
+ // Is it a repeated post?
+ if (($repeat_of != "") || ($item["verb"] == ACTIVITY_SHARE)) {
+ $link_data = self::processRepeatedItem($xpath, $entry, $item, $importer);
+ if (!empty($link_data['add_body'])) {
+ $add_body .= $link_data['add_body'];
+ }
+ }
+
+ $item["body"] .= $add_body;
+
+ // Only add additional data when there is no picture in the post
+ if (!strstr($item["body"], '[/img]')) {
+ $item["body"] = add_page_info_to_body($item["body"]);
+ }
+
+ // Mastodon Content Warning
+ if (($item["verb"] == ACTIVITY_POST) && $xpath->evaluate('boolean(atom:summary)', $entry)) {
+ $clear_text = $xpath->query('atom:summary/text()', $entry)->item(0)->nodeValue;
+
+ $item["body"] = html2bbcode($clear_text) . '[spoiler]' . $item["body"] . '[/spoiler]';
+ }
+
+ if (($self != '') && empty($item['protocol'])) {
+ self::fetchSelf($self, $item);
+ }
+
+ if (!empty($item["conversation-href"])) {
+ self::fetchConversation($item['conversation-href'], $item['conversation-uri']);
+ }
+
+ if (isset($item["parent-uri"]) && ($related != '')) {
+ if (!dba::exists('item', array('uid' => $importer["uid"], 'uri' => $item['parent-uri']))) {
+ self::fetchRelated($related, $item["parent-uri"], $importer);
+ } else {
+ logger('Reply with URI '.$item["uri"].' already existed for user '.$importer["uid"].'.', LOGGER_DEBUG);
+ }
+
+ $item["type"] = 'remote-comment';
+ $item["gravity"] = GRAVITY_COMMENT;
+ } else {
+ $item["parent-uri"] = $item["uri"];
+ }
+
+ if (($item['author-link'] != '') && !empty($item['protocol'])) {
+ $item = store_conversation($item);
+ }
+
+ self::$itemlist[] = $item;
+ }
+
+ /**
+ * @brief Fetch the conversation for posts
+ *
+ * @param string $conversation The link to the conversation
+ * @param string $conversation_uri The conversation in "uri" format
+ * @return void
+ */
+ private static function fetchConversation($conversation, $conversation_uri)
+ {
+ // Ensure that we only store a conversation once in a process
+ if (isset(self::$conv_list[$conversation])) {
+ return;
+ }
+
+ self::$conv_list[$conversation] = true;
+
+ $conversation_data = z_fetch_url($conversation, false, $redirects, array('accept_content' => 'application/atom+xml, text/html'));
+
+ if (!$conversation_data['success']) {
+ return;
+ }
+
+ $xml = '';
+
+ if (stristr($conversation_data['header'], 'Content-Type: application/atom+xml')) {
+ $xml = $conversation_data['body'];
+ }
+
+ if ($xml == '') {
+ $doc = new DOMDocument();
+ if (!@$doc->loadHTML($conversation_data['body'])) {
+ return;
+ }
+ $xpath = new DomXPath($doc);
+
+ $links = $xpath->query('//link');
+ if ($links) {
+ foreach ($links as $link) {
+ $attribute = self::readAttributes($link);
+ if (($attribute['rel'] == 'alternate') && ($attribute['type'] == 'application/atom+xml')) {
+ $file = $attribute['href'];
+ }
+ }
+ if ($file != '') {
+ $conversation_atom = z_fetch_url($attribute['href']);
+
+ if ($conversation_atom['success']) {
+ $xml = $conversation_atom['body'];
+ }
+ }
+ }
+ }
+
+ if ($xml == '') {
+ return;
+ }
+
+ self::storeConversation($xml, $conversation, $conversation_uri);
+ }
+
+ /**
+ * @brief Store a feed in several conversation entries
+ *
+ * @param string $xml The feed
+ * @param string $conversation conversation
+ * @param string $conversation_uri conversation uri
+ * @return void
+ */
+ private static function storeConversation($xml, $conversation = '', $conversation_uri = '')
+ {
+ $doc = new DOMDocument();
+ @$doc->loadXML($xml);
+
+ $xpath = new DomXPath($doc);
+ $xpath->registerNamespace('atom', NAMESPACE_ATOM1);
+ $xpath->registerNamespace('thr', NAMESPACE_THREAD);
+ $xpath->registerNamespace('ostatus', NAMESPACE_OSTATUS);
+
+ $entries = $xpath->query('/atom:feed/atom:entry');
+
+ // Now store the entries
+ foreach ($entries as $entry) {
+ $doc2 = new DOMDocument();
+ $doc2->preserveWhiteSpace = false;
+ $doc2->formatOutput = true;
+
+ $conv_data = array();
+
+ $conv_data['protocol'] = PROTOCOL_SPLITTED_CONV;
+ $conv_data['network'] = NETWORK_OSTATUS;
+ $conv_data['uri'] = $xpath->query('atom:id/text()', $entry)->item(0)->nodeValue;
+
+ $inreplyto = $xpath->query('thr:in-reply-to', $entry);
+ if (is_object($inreplyto->item(0))) {
+ foreach ($inreplyto->item(0)->attributes as $attributes) {
+ if ($attributes->name == "ref") {
+ $conv_data['reply-to-uri'] = $attributes->textContent;
+ }
+ }
+ }
+
+ $conv = $xpath->query('ostatus:conversation/text()', $entry)->item(0)->nodeValue;
+ $conv_data['conversation-uri'] = $conv;
+
+ $conv = $xpath->query('ostatus:conversation', $entry);
+ if (is_object($conv->item(0))) {
+ foreach ($conv->item(0)->attributes as $attributes) {
+ if ($attributes->name == "ref") {
+ $conv_data['conversation-uri'] = $attributes->textContent;
+ }
+ if ($attributes->name == "href") {
+ $conv_data['conversation-href'] = $attributes->textContent;
+ }
+ }
+ }
+
+ if ($conversation != '') {
+ $conv_data['conversation-uri'] = $conversation;
+ }
+
+ if ($conversation_uri != '') {
+ $conv_data['conversation-uri'] = $conversation_uri;
+ }
+
+ $entry = $doc2->importNode($entry, true);
+
+ $doc2->appendChild($entry);
+
+ $conv_data['source'] = $doc2->saveXML();
+
+ $condition = array('item-uri' => $conv_data['uri'],'protocol' => PROTOCOL_OSTATUS_FEED);
+ if (dba::exists('conversation', $condition)) {
+ logger('Delete deprecated entry for URI '.$conv_data['uri'], LOGGER_DEBUG);
+ dba::delete('conversation', array('item-uri' => $conv_data['uri']));
+ }
+
+ logger('Store conversation data for uri '.$conv_data['uri'], LOGGER_DEBUG);
+ store_conversation($conv_data);
+ }
+ }
+
+ /**
+ * @brief Fetch the own post so that it can be stored later
+ *
+ * We want to store the original data for later processing.
+ * This function is meant for cases where we process a feed with multiple entries.
+ * In that case we need to fetch the single posts here.
+ *
+ * @param string $self The link to the self item
+ * @param array $item The item array
+ * @return void
+ */
+ private static function fetchSelf($self, &$item)
+ {
+ $condition = array('`item-uri` = ? AND `protocol` IN (?, ?)', $self, PROTOCOL_DFRN, PROTOCOL_OSTATUS_SALMON);
+ if (dba::exists('conversation', $condition)) {
+ logger('Conversation '.$item['uri'].' is already stored.', LOGGER_DEBUG);
+ return;
+ }
+
+ $self_data = z_fetch_url($self);
+
+ if (!$self_data['success']) {
+ return;
+ }
+
+ // We reformat the XML to make it better readable
+ $doc = new DOMDocument();
+ $doc->loadXML($self_data['body']);
+ $doc->preserveWhiteSpace = false;
+ $doc->formatOutput = true;
+ $xml = $doc->saveXML();
+
+ $item["protocol"] = PROTOCOL_OSTATUS_SALMON;
+ $item["source"] = $xml;
+
+ logger('Conversation '.$item['uri'].' is now fetched.', LOGGER_DEBUG);
+ }
+
+ /**
+ * @brief Fetch related posts and processes them
+ *
+ * @param string $related The link to the related item
+ * @param string $related_uri The related item in "uri" format
+ * @param array $importer user record of the importing user
+ * @return void
+ */
+ private static function fetchRelated($related, $related_uri, $importer)
+ {
+ $condition = array('`item-uri` = ? AND `protocol` IN (?, ?)', $related_uri, PROTOCOL_DFRN, PROTOCOL_OSTATUS_SALMON);
+ $conversation = dba::select('conversation', array('source', 'protocol'), $condition, array('limit' => 1));
+ if (DBM::is_result($conversation)) {
+ $stored = true;
+ $xml = $conversation['source'];
+ if (self::process($xml, $importer, $contact, $hub, $stored, false)) {
+ logger('Got valid cached XML for URI '.$related_uri, LOGGER_DEBUG);
+ return;
+ }
+ if ($conversation['protocol'] == PROTOCOL_OSTATUS_SALMON) {
+ logger('Delete invalid cached XML for URI '.$related_uri, LOGGER_DEBUG);
+ dba::delete('conversation', array('item-uri' => $related_uri));
+ }
+ }
+
+ $stored = false;
+ $related_data = z_fetch_url($related, false, $redirects, array('accept_content' => 'application/atom+xml, text/html'));
+
+ if (!$related_data['success']) {
+ return;
+ }
+
+ $xml = '';
+
+ if (stristr($related_data['header'], 'Content-Type: application/atom+xml')) {
+ logger('Directly fetched XML for URI '.$related_uri, LOGGER_DEBUG);
+ $xml = $related_data['body'];
+ }
+
+ if ($xml == '') {
+ $doc = new DOMDocument();
+ if (!@$doc->loadHTML($related_data['body'])) {
+ return;
+ }
+ $xpath = new DomXPath($doc);
+
+ $atom_file = '';
+
+ $links = $xpath->query('//link');
+ if ($links) {
+ foreach ($links as $link) {
+ $attribute = self::readAttributes($link);
+ if (($attribute['rel'] == 'alternate') && ($attribute['type'] == 'application/atom+xml')) {
+ $atom_file = $attribute['href'];
+ }
+ }
+ if ($atom_file != '') {
+ $related_atom = z_fetch_url($atom_file);
+
+ if ($related_atom['success']) {
+ logger('Fetched XML for URI '.$related_uri, LOGGER_DEBUG);
+ $xml = $related_atom['body'];
+ }
+ }
+ }
+ }
+
+ // Workaround for older GNU Social servers
+ if (($xml == '') && strstr($related, '/notice/')) {
+ $related_atom = z_fetch_url(str_replace('/notice/', '/api/statuses/show/', $related).'.atom');
+
+ if ($related_atom['success']) {
+ logger('GNU Social workaround to fetch XML for URI '.$related_uri, LOGGER_DEBUG);
+ $xml = $related_atom['body'];
+ }
+ }
+
+ // Even more worse workaround for GNU Social ;-)
+ if ($xml == '') {
+ $related_guess = OStatus::convertHref($related_uri);
+ $related_atom = z_fetch_url(str_replace('/notice/', '/api/statuses/show/', $related_guess).'.atom');
+
+ if ($related_atom['success']) {
+ logger('GNU Social workaround 2 to fetch XML for URI '.$related_uri, LOGGER_DEBUG);
+ $xml = $related_atom['body'];
+ }
+ }
+
+ // Finally we take the data that we fetched from "ostatus:conversation"
+ if ($xml == '') {
+ $condition = array('item-uri' => $related_uri, 'protocol' => PROTOCOL_SPLITTED_CONV);
+ $conversation = dba::select('conversation', array('source'), $condition, array('limit' => 1));
+ if (DBM::is_result($conversation)) {
+ $stored = true;
+ logger('Got cached XML from conversation for URI '.$related_uri, LOGGER_DEBUG);
+ $xml = $conversation['source'];
+ }
+ }
+
+ if ($xml != '') {
+ self::process($xml, $importer, $contact, $hub, $stored, false);
+ } else {
+ logger("XML couldn't be fetched for URI: ".$related_uri." - href: ".$related, LOGGER_DEBUG);
+ }
+ return;
+ }
+
+ /**
+ * @brief Processes the XML for a repeated post
+ *
+ * @param object $xpath The xpath object
+ * @param object $entry The xml entry that is processed
+ * @param array $item The item array
+ * @param array $importer user record of the importing user
+ *
+ * @return array with data from links
+ */
+ private static function processRepeatedItem($xpath, $entry, &$item, $importer)
+ {
+ $activityobjects = $xpath->query('activity:object', $entry)->item(0);
+
+ if (!is_object($activityobjects)) {
+ return array();
+ }
+
+ $link_data = array();
+
+ $orig_uri = $xpath->query('atom:id/text()', $activityobjects)->item(0)->nodeValue;
+
+ $links = $xpath->query("atom:link", $activityobjects);
+ if ($links) {
+ $link_data = self::processLinks($links, $item);
+ }
+
+ $orig_body = $xpath->query('atom:content/text()', $activityobjects)->item(0)->nodeValue;
+ $orig_created = $xpath->query('atom:published/text()', $activityobjects)->item(0)->nodeValue;
+ $orig_edited = $xpath->query('atom:updated/text()', $activityobjects)->item(0)->nodeValue;
+
+ $orig_contact = $contact;
+ $orig_author = self::fetchAuthor($xpath, $activityobjects, $importer, $orig_contact, false);
+
+ $item["author-name"] = $orig_author["author-name"];
+ $item["author-link"] = $orig_author["author-link"];
+ $item["author-avatar"] = $orig_author["author-avatar"];
+
+ $item["body"] = html2bbcode($orig_body);
+ $item["created"] = $orig_created;
+ $item["edited"] = $orig_edited;
+
+ $item["uri"] = $orig_uri;
+
+ $item["verb"] = $xpath->query('activity:verb/text()', $activityobjects)->item(0)->nodeValue;
+
+ $item["object-type"] = $xpath->query('activity:object-type/text()', $activityobjects)->item(0)->nodeValue;
+
+ $inreplyto = $xpath->query('thr:in-reply-to', $activityobjects);
+ if (is_object($inreplyto->item(0))) {
+ foreach ($inreplyto->item(0)->attributes as $attributes) {
+ if ($attributes->name == "ref") {
+ $item["parent-uri"] = $attributes->textContent;
+ }
+ }
+ }
+
+ return $link_data;
+ }
+
+ /**
+ * @brief Processes links in the XML
+ *
+ * @param object $links The xml data that contain links
+ * @param array $item The item array
+ *
+ * @return array with data from the links
+ */
+ private static function processLinks($links, &$item)
+ {
+ $link_data = array('add_body' => '', 'self' => '');
+
+ foreach ($links as $link) {
+ $attribute = self::readAttributes($link);
+
+ if (($attribute['rel'] != "") && ($attribute['href'] != "")) {
+ switch ($attribute['rel']) {
+ case "alternate":
+ $item["plink"] = $attribute['href'];
+ if (($item["object-type"] == ACTIVITY_OBJ_QUESTION)
+ || ($item["object-type"] == ACTIVITY_OBJ_EVENT)
+ ) {
+ $item["body"] .= add_page_info($attribute['href']);
+ }
+ break;
+ case "ostatus:conversation":
+ $link_data['conversation'] = $attribute['href'];
+ $item['conversation-href'] = $link_data['conversation'];
+ if (!isset($item['conversation-uri'])) {
+ $item['conversation-uri'] = $item['conversation-href'];
+ }
+ break;
+ case "enclosure":
+ $filetype = strtolower(substr($attribute['type'], 0, strpos($attribute['type'], '/')));
+ if ($filetype == 'image') {
+ $link_data['add_body'] .= "\n[img]".$attribute['href'].'[/img]';
+ } else {
+ if (strlen($item["attach"])) {
+ $item["attach"] .= ',';
+ }
+ if (!isset($attribute['length'])) {
+ $attribute['length'] = "0";
+ }
+ $item["attach"] .= '[attach]href="'.$attribute['href'].'" length="'.$attribute['length'].'" type="'.$attribute['type'].'" title="'.$attribute['title'].'"[/attach]';
+ }
+ break;
+ case "related":
+ if ($item["object-type"] != ACTIVITY_OBJ_BOOKMARK) {
+ if (!isset($item["parent-uri"])) {
+ $item["parent-uri"] = $attribute['href'];
+ }
+ $link_data['related'] = $attribute['href'];
+ } else {
+ $item["body"] .= add_page_info($attribute['href']);
+ }
+ break;
+ case "self":
+ if ($item["plink"] == '') {
+ $item["plink"] = $attribute['href'];
+ }
+ $link_data['self'] = $attribute['href'];
+ break;
+ }
+ }
+ }
+ return $link_data;
+ }
+
+ /**
+ * @brief Create an url out of an uri
+ *
+ * @param string $href URI in the format "parameter1:parameter1:..."
+ *
+ * @return string URL in the format http(s)://....
+ */
+ public static function convertHref($href)
+ {
+ $elements = explode(":", $href);
+
+ if ((count($elements) <= 2) || ($elements[0] != "tag")) {
+ return $href;
+ }
+
+ $server = explode(",", $elements[1]);
+ $conversation = explode("=", $elements[2]);
+
+ if ((count($elements) == 4) && ($elements[2] == "post")) {
+ return "http://".$server[0]."/notice/".$elements[3];
+ }
+
+ if ((count($conversation) != 2) || ($conversation[1] =="")) {
+ return $href;
+ }
+ if ($elements[3] == "objectType=thread") {
+ return "http://".$server[0]."/conversation/".$conversation[1];
+ } else {
+ return "http://".$server[0]."/notice/".$conversation[1];
+ }
+ return $href;
+ }
+
+ /**
+ * @brief Checks if the current post is a reshare
+ *
+ * @param array $item The item array of thw post
+ *
+ * @return string The guid if the post is a reshare
+ */
+ private static function getResharedGuid($item)
+ {
+ $body = trim($item["body"]);
+
+ // Skip if it isn't a pure repeated messages
+ // Does it start with a share?
+ if (strpos($body, "[share") > 0) {
+ return "";
+ }
+
+ // Does it end with a share?
+ if (strlen($body) > (strrpos($body, "[/share]") + 8)) {
+ return "";
+ }
+
+ $attributes = preg_replace("/\[share(.*?)\]\s?(.*?)\s?\[\/share\]\s?/ism", "$1", $body);
+ // Skip if there is no shared message in there
+ if ($body == $attributes) {
+ return false;
+ }
+
+ $guid = "";
+ preg_match("/guid='(.*?)'/ism", $attributes, $matches);
+ if ($matches[1] != "") {
+ $guid = $matches[1];
+ }
+
+ preg_match('/guid="(.*?)"/ism', $attributes, $matches);
+ if ($matches[1] != "") {
+ $guid = $matches[1];
+ }
+
+ return $guid;
+ }
+
+ /**
+ * @brief Cleans the body of a post if it contains picture links
+ *
+ * @param string $body The body
+ *
+ * @return string The cleaned body
+ */
+ private static function formatPicturePost($body)
+ {
+ $siteinfo = get_attached_data($body);
+
+ if (($siteinfo["type"] == "photo")) {
+ if (isset($siteinfo["preview"])) {
+ $preview = $siteinfo["preview"];
+ } else {
+ $preview = $siteinfo["image"];
+ }
+
+ // Is it a remote picture? Then make a smaller preview here
+ $preview = proxy_url($preview, false, PROXY_SIZE_SMALL);
+
+ // Is it a local picture? Then make it smaller here
+ $preview = str_replace(array("-0.jpg", "-0.png"), array("-2.jpg", "-2.png"), $preview);
+ $preview = str_replace(array("-1.jpg", "-1.png"), array("-2.jpg", "-2.png"), $preview);
+
+ if (isset($siteinfo["url"])) {
+ $url = $siteinfo["url"];
+ } else {
+ $url = $siteinfo["image"];
+ }
+
+ $body = trim($siteinfo["text"])." [url]".$url."[/url]\n[img]".$preview."[/img]";
+ }
+
+ return $body;
+ }
+
+ /**
+ * @brief Adds the header elements to the XML document
+ *
+ * @param object $doc XML document
+ * @param array $owner Contact data of the poster
+ *
+ * @return object header root element
+ */
+ private static function addHeader($doc, $owner)
+ {
+ $a = get_app();
+
+ $root = $doc->createElementNS(NAMESPACE_ATOM1, 'feed');
+ $doc->appendChild($root);
+
+ $root->setAttribute("xmlns:thr", NAMESPACE_THREAD);
+ $root->setAttribute("xmlns:georss", NAMESPACE_GEORSS);
+ $root->setAttribute("xmlns:activity", NAMESPACE_ACTIVITY);
+ $root->setAttribute("xmlns:media", NAMESPACE_MEDIA);
+ $root->setAttribute("xmlns:poco", NAMESPACE_POCO);
+ $root->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
+ $root->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
+ $root->setAttribute("xmlns:mastodon", NAMESPACE_MASTODON);
+
+ $attributes = array("uri" => "https://friendi.ca", "version" => FRIENDICA_VERSION."-".DB_UPDATE_VERSION);
+ XML::addElement($doc, $root, "generator", FRIENDICA_PLATFORM, $attributes);
+ XML::addElement($doc, $root, "id", System::baseUrl()."/profile/".$owner["nick"]);
+ XML::addElement($doc, $root, "title", sprintf("%s timeline", $owner["name"]));
+ XML::addElement($doc, $root, "subtitle", sprintf("Updates from %s on %s", $owner["name"], $a->config["sitename"]));
+ XML::addElement($doc, $root, "logo", $owner["photo"]);
+ XML::addElement($doc, $root, "updated", datetime_convert("UTC", "UTC", "now", ATOM_TIME));
+
+ $author = self::addAuthor($doc, $owner);
+ $root->appendChild($author);
+
+ $attributes = array("href" => $owner["url"], "rel" => "alternate", "type" => "text/html");
+ XML::addElement($doc, $root, "link", "", $attributes);
+
+ /// @TODO We have to find out what this is
+ /// $attributes = array("href" => System::baseUrl()."/sup",
+ /// "rel" => "http://api.friendfeed.com/2008/03#sup",
+ /// "type" => "application/json");
+ /// XML::addElement($doc, $root, "link", "", $attributes);
+
+ self::hublinks($doc, $root, $owner["nick"]);
+
+ $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "salmon");
+ XML::addElement($doc, $root, "link", "", $attributes);
+
+ $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "http://salmon-protocol.org/ns/salmon-replies");
+ XML::addElement($doc, $root, "link", "", $attributes);
+
+ $attributes = array("href" => System::baseUrl()."/salmon/".$owner["nick"], "rel" => "http://salmon-protocol.org/ns/salmon-mention");
+ XML::addElement($doc, $root, "link", "", $attributes);
+
+ $attributes = array("href" => System::baseUrl()."/api/statuses/user_timeline/".$owner["nick"].".atom",
+ "rel" => "self", "type" => "application/atom+xml");
+ XML::addElement($doc, $root, "link", "", $attributes);
+
+ return $root;
+ }
+
+ /**
+ * @brief Add the link to the push hubs to the XML document
+ *
+ * @param object $doc XML document
+ * @param object $root XML root element where the hub links are added
+ * @param object $nick nick
+ * @return void
+ */
+ public static function hublinks($doc, $root, $nick)
+ {
+ $h = System::baseUrl() . '/pubsubhubbub/'.$nick;
+ XML::addElement($doc, $root, "link", "", array("href" => $h, "rel" => "hub"));
+ }
+
+ /**
+ * @brief Adds attachement data to the XML document
+ *
+ * @param object $doc XML document
+ * @param object $root XML root element where the hub links are added
+ * @param array $item Data of the item that is to be posted
+ * @return void
+ */
+ private static function getAttachment($doc, $root, $item)
+ {
+ $o = "";
+ $siteinfo = get_attached_data($item["body"]);
+
+ switch ($siteinfo["type"]) {
+ case 'photo':
+ $imgdata = get_photo_info($siteinfo["image"]);
+ $attributes = array("rel" => "enclosure",
+ "href" => $siteinfo["image"],
+ "type" => $imgdata["mime"],
+ "length" => intval($imgdata["size"]));
+ XML::addElement($doc, $root, "link", "", $attributes);
+ break;
+ case 'video':
+ $attributes = array("rel" => "enclosure",
+ "href" => $siteinfo["url"],
+ "type" => "text/html; charset=UTF-8",
+ "length" => "",
+ "title" => $siteinfo["title"]);
+ XML::addElement($doc, $root, "link", "", $attributes);
+ break;
+ default:
+ break;
+ }
+
+ if (!Config::get('system', 'ostatus_not_attach_preview') && ($siteinfo["type"] != "photo") && isset($siteinfo["image"])) {
+ $imgdata = get_photo_info($siteinfo["image"]);
+ $attributes = array("rel" => "enclosure",
+ "href" => $siteinfo["image"],
+ "type" => $imgdata["mime"],
+ "length" => intval($imgdata["size"]));
+
+ XML::addElement($doc, $root, "link", "", $attributes);
+ }
+
+ $arr = explode('[/attach],', $item['attach']);
+ if (count($arr)) {
+ foreach ($arr as $r) {
+ $matches = false;
+ $cnt = preg_match('|\[attach\]href=\"(.*?)\" length=\"(.*?)\" type=\"(.*?)\" title=\"(.*?)\"|', $r, $matches);
+ if ($cnt) {
+ $attributes = array("rel" => "enclosure",
+ "href" => $matches[1],
+ "type" => $matches[3]);
+
+ if (intval($matches[2])) {
+ $attributes["length"] = intval($matches[2]);
+ }
+ if (trim($matches[4]) != "") {
+ $attributes["title"] = trim($matches[4]);
+ }
+ XML::addElement($doc, $root, "link", "", $attributes);
+ }
+ }
+ }
+ }
+
+ /**
+ * @brief Adds the author element to the XML document
+ *
+ * @param object $doc XML document
+ * @param array $owner Contact data of the poster
+ *
+ * @return object author element
+ */
+ private static function addAuthor($doc, $owner)
+ {
+ $r = q("SELECT `homepage`, `publish` FROM `profile` WHERE `uid` = %d AND `is-default` LIMIT 1", intval($owner["uid"]));
+ if (DBM::is_result($r)) {
+ $profile = $r[0];
+ }
+ $author = $doc->createElement("author");
+ XML::addElement($doc, $author, "id", $owner["url"]);
+ XML::addElement($doc, $author, "activity:object-type", ACTIVITY_OBJ_PERSON);
+ XML::addElement($doc, $author, "uri", $owner["url"]);
+ XML::addElement($doc, $author, "name", $owner["nick"]);
+ XML::addElement($doc, $author, "email", $owner["addr"]);
+ XML::addElement($doc, $author, "summary", bbcode($owner["about"], false, false, 7));
+
+ $attributes = array("rel" => "alternate", "type" => "text/html", "href" => $owner["url"]);
+ XML::addElement($doc, $author, "link", "", $attributes);
+
+ $attributes = array(
+ "rel" => "avatar",
+ "type" => "image/jpeg", // To-Do?
+ "media:width" => 175,
+ "media:height" => 175,
+ "href" => $owner["photo"]);
+ XML::addElement($doc, $author, "link", "", $attributes);
+
+ if (isset($owner["thumb"])) {
+ $attributes = array(
+ "rel" => "avatar",
+ "type" => "image/jpeg", // To-Do?
+ "media:width" => 80,
+ "media:height" => 80,
+ "href" => $owner["thumb"]);
+ XML::addElement($doc, $author, "link", "", $attributes);
+ }
+
+ XML::addElement($doc, $author, "poco:preferredUsername", $owner["nick"]);
+ XML::addElement($doc, $author, "poco:displayName", $owner["name"]);
+ XML::addElement($doc, $author, "poco:note", bbcode($owner["about"], false, false, 7));
+
+ if (trim($owner["location"]) != "") {
+ $element = $doc->createElement("poco:address");
+ XML::addElement($doc, $element, "poco:formatted", $owner["location"]);
+ $author->appendChild($element);
+ }
+
+ if (trim($profile["homepage"]) != "") {
+ $urls = $doc->createElement("poco:urls");
+ XML::addElement($doc, $urls, "poco:type", "homepage");
+ XML::addElement($doc, $urls, "poco:value", $profile["homepage"]);
+ XML::addElement($doc, $urls, "poco:primary", "true");
+ $author->appendChild($urls);
+ }
+
+ if (count($profile)) {
+ XML::addElement($doc, $author, "followers", "", array("url" => System::baseUrl()."/viewcontacts/".$owner["nick"]));
+ XML::addElement($doc, $author, "statusnet:profile_info", "", array("local_id" => $owner["uid"]));
+ }
+
+ if ($profile["publish"]) {
+ XML::addElement($doc, $author, "mastodon:scope", "public");
+ }
+ return $author;
+ }
+
+ /**
+ * @TODO Picture attachments should look like this:
+ * <a href="https://status.pirati.ca/attachment/572819" title="https://status.pirati.ca/file/heluecht-20151202T222602-rd3u49p.gif"
+ * class="attachment thumbnail" id="attachment-572819" rel="nofollow external">https://status.pirati.ca/attachment/572819</a>
+ */
+
+ /**
+ * @brief Returns the given activity if present - otherwise returns the "post" activity
+ *
+ * @param array $item Data of the item that is to be posted
+ *
+ * @return string activity
+ */
+ private static function constructVerb($item)
+ {
+ if ($item['verb']) {
+ return $item['verb'];
+ }
+
+ return ACTIVITY_POST;
+ }
+
+ /**
+ * @brief Returns the given object type if present - otherwise returns the "note" object type
+ *
+ * @param array $item Data of the item that is to be posted
+ *
+ * @return string Object type
+ */
+ private static function constructObjecttype($item)
+ {
+ if (in_array($item['object-type'], array(ACTIVITY_OBJ_NOTE, ACTIVITY_OBJ_COMMENT)))
+ return $item['object-type'];
+ return ACTIVITY_OBJ_NOTE;
+ }
+
+ /**
+ * @brief Adds an entry element to the XML document
+ *
+ * @param object $doc XML document
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param bool $toplevel optional default false
+ *
+ * @return object Entry element
+ */
+ private static function entry($doc, $item, $owner, $toplevel = false)
+ {
+ $repeated_guid = self::getResharedGuid($item);
+ if ($repeated_guid != "") {
+ $xml = self::reshareEntry($doc, $item, $owner, $repeated_guid, $toplevel);
+ }
+
+ if ($xml) {
+ return $xml;
+ }
+
+ if ($item["verb"] == ACTIVITY_LIKE) {
+ return self::likeEntry($doc, $item, $owner, $toplevel);
+ } elseif (in_array($item["verb"], array(ACTIVITY_FOLLOW, NAMESPACE_OSTATUS."/unfollow"))) {
+ return self::followEntry($doc, $item, $owner, $toplevel);
+ } else {
+ return self::noteEntry($doc, $item, $owner, $toplevel);
+ }
+ }
+
+ /**
+ * @brief Adds a source entry to the XML document
+ *
+ * @param object $doc XML document
+ * @param array $contact Array of the contact that is added
+ *
+ * @return object Source element
+ */
+ private static function sourceEntry($doc, $contact)
+ {
+ $source = $doc->createElement("source");
+ XML::addElement($doc, $source, "id", $contact["poll"]);
+ XML::addElement($doc, $source, "title", $contact["name"]);
+ XML::addElement($doc, $source, "link", "", array("rel" => "alternate", "type" => "text/html", "href" => $contact["alias"]));
+ XML::addElement($doc, $source, "link", "", array("rel" => "self", "type" => "application/atom+xml", "href" => $contact["poll"]));
+ XML::addElement($doc, $source, "icon", $contact["photo"]);
+ XML::addElement($doc, $source, "updated", datetime_convert("UTC", "UTC", $contact["success_update"]."+00:00", ATOM_TIME));
+
+ return $source;
+ }
+
+ /**
+ * @brief Fetches contact data from the contact or the gcontact table
+ *
+ * @param string $url URL of the contact
+ * @param array $owner Contact data of the poster
+ *
+ * @return array Contact array
+ */
+ private static function contactEntry($url, $owner)
+ {
+ $r = q(
+ "SELECT * FROM `contact` WHERE `nurl` = '%s' AND `uid` IN (0, %d) ORDER BY `uid` DESC LIMIT 1",
+ dbesc(normalise_link($url)),
+ intval($owner["uid"])
+ );
+ if (DBM::is_result($r)) {
+ $contact = $r[0];
+ $contact["uid"] = -1;
+ }
+
+ if (!DBM::is_result($r)) {
+ $r = q(
+ "SELECT * FROM `gcontact` WHERE `nurl` = '%s' LIMIT 1",
+ dbesc(normalise_link($url))
+ );
+ if (DBM::is_result($r)) {
+ $contact = $r[0];
+ $contact["uid"] = -1;
+ $contact["success_update"] = $contact["updated"];
+ }
+ }
+
+ if (!DBM::is_result($r)) {
+ $contact = owner;
+ }
+
+ if (!isset($contact["poll"])) {
+ $data = Probe::uri($url);
+ $contact["poll"] = $data["poll"];
+
+ if (!$contact["alias"]) {
+ $contact["alias"] = $data["alias"];
+ }
+ }
+
+ if (!isset($contact["alias"])) {
+ $contact["alias"] = $contact["url"];
+ }
+
+ return $contact;
+ }
+
+ /**
+ * @brief Adds an entry element with reshared content
+ *
+ * @param object $doc XML document
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param string $repeated_guid guid
+ * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
+ *
+ * @return object Entry element
+ */
+ private static function reshareEntry($doc, $item, $owner, $repeated_guid, $toplevel)
+ {
+ if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
+ logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
+ }
+
+ $title = self::entryHeader($doc, $entry, $owner, $toplevel);
+
+ $r = q(
+ "SELECT * FROM `item` WHERE `uid` = %d AND `guid` = '%s' AND NOT `private` AND `network` IN ('%s', '%s', '%s') LIMIT 1",
+ intval($owner["uid"]),
+ dbesc($repeated_guid),
+ dbesc(NETWORK_DFRN),
+ dbesc(NETWORK_DIASPORA),
+ dbesc(NETWORK_OSTATUS)
+ );
+ if (DBM::is_result($r)) {
+ $repeated_item = $r[0];
+ } else {
+ return false;
+ }
+ $contact = self::contactEntry($repeated_item['author-link'], $owner);
+
+ $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
+
+ $title = $owner["nick"]." repeated a notice by ".$contact["nick"];
+
+ self::entryContent($doc, $entry, $item, $owner, $title, ACTIVITY_SHARE, false);
+
+ $as_object = $doc->createElement("activity:object");
+
+ XML::addElement($doc, $as_object, "activity:object-type", NAMESPACE_ACTIVITY_SCHEMA."activity");
+
+ self::entryContent($doc, $as_object, $repeated_item, $owner, "", "", false);
+
+ $author = self::addAuthor($doc, $contact);
+ $as_object->appendChild($author);
+
+ $as_object2 = $doc->createElement("activity:object");
+
+ XML::addElement($doc, $as_object2, "activity:object-type", self::constructObjecttype($repeated_item));
+
+ $title = sprintf("New comment by %s", $contact["nick"]);
+
+ self::entryContent($doc, $as_object2, $repeated_item, $owner, $title);
+
+ $as_object->appendChild($as_object2);
+
+ self::entryFooter($doc, $as_object, $item, $owner, false);
+
+ $source = self::sourceEntry($doc, $contact);
+
+ $as_object->appendChild($source);
+
+ $entry->appendChild($as_object);
+
+ self::entryFooter($doc, $entry, $item, $owner);
+
+ return $entry;
+ }
+
+ /**
+ * @brief Adds an entry element with a "like"
+ *
+ * @param object $doc XML document
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
+ *
+ * @return object Entry element with "like"
+ */
+ private static function likeEntry($doc, $item, $owner, $toplevel)
+ {
+ if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
+ logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
+ }
+
+ $title = self::entryHeader($doc, $entry, $owner, $toplevel);
+
+ $verb = NAMESPACE_ACTIVITY_SCHEMA."favorite";
+ self::entryContent($doc, $entry, $item, $owner, "Favorite", $verb, false);
+
+ $as_object = $doc->createElement("activity:object");
+
+ $parent = q(
+ "SELECT * FROM `item` WHERE `uri` = '%s' AND `uid` = %d",
+ dbesc($item["thr-parent"]),
+ intval($item["uid"])
+ );
+ $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
+
+ XML::addElement($doc, $as_object, "activity:object-type", self::constructObjecttype($parent[0]));
+
+ self::entryContent($doc, $as_object, $parent[0], $owner, "New entry");
+
+ $entry->appendChild($as_object);
+
+ self::entryFooter($doc, $entry, $item, $owner);
+
+ return $entry;
+ }
+
+ /**
+ * @brief Adds the person object element to the XML document
+ *
+ * @param object $doc XML document
+ * @param array $owner Contact data of the poster
+ * @param array $contact Contact data of the target
+ *
+ * @return object author element
+ */
+ private static function addPersonObject($doc, $owner, $contact)
+ {
+ $object = $doc->createElement("activity:object");
+ XML::addElement($doc, $object, "activity:object-type", ACTIVITY_OBJ_PERSON);
+
+ if ($contact['network'] == NETWORK_PHANTOM) {
+ XML::addElement($doc, $object, "id", $contact['url']);
+ return $object;
+ }
+
+ XML::addElement($doc, $object, "id", $contact["alias"]);
+ XML::addElement($doc, $object, "title", $contact["nick"]);
+
+ $attributes = array("rel" => "alternate", "type" => "text/html", "href" => $contact["url"]);
+ XML::addElement($doc, $object, "link", "", $attributes);
+
+ $attributes = array(
+ "rel" => "avatar",
+ "type" => "image/jpeg", // To-Do?
+ "media:width" => 175,
+ "media:height" => 175,
+ "href" => $contact["photo"]);
+ XML::addElement($doc, $object, "link", "", $attributes);
+
+ XML::addElement($doc, $object, "poco:preferredUsername", $contact["nick"]);
+ XML::addElement($doc, $object, "poco:displayName", $contact["name"]);
+
+ if (trim($contact["location"]) != "") {
+ $element = $doc->createElement("poco:address");
+ XML::addElement($doc, $element, "poco:formatted", $contact["location"]);
+ $object->appendChild($element);
+ }
+
+ return $object;
+ }
+
+ /**
+ * @brief Adds a follow/unfollow entry element
+ *
+ * @param object $doc XML document
+ * @param array $item Data of the follow/unfollow message
+ * @param array $owner Contact data of the poster
+ * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
+ *
+ * @return object Entry element
+ */
+ private static function followEntry($doc, $item, $owner, $toplevel)
+ {
+ $item["id"] = $item["parent"] = 0;
+ $item["created"] = $item["edited"] = date("c");
+ $item["private"] = true;
+
+ $contact = Probe::uri($item['follow']);
+
+ if ($contact['alias'] == '') {
+ $contact['alias'] = $contact["url"];
+ } else {
+ $item['follow'] = $contact['alias'];
+ }
+
+ $r = q(
+ "SELECT `id` FROM `contact` WHERE `uid` = %d AND `nurl` = '%s'",
+ intval($owner['uid']),
+ dbesc(normalise_link($contact["url"]))
+ );
+
+ if (DBM::is_result($r)) {
+ $connect_id = $r[0]['id'];
+ } else {
+ $connect_id = 0;
+ }
+
+ if ($item['verb'] == ACTIVITY_FOLLOW) {
+ $message = t('%s is now following %s.');
+ $title = t('following');
+ $action = "subscription";
+ } else {
+ $message = t('%s stopped following %s.');
+ $title = t('stopped following');
+ $action = "unfollow";
+ }
+
+ $item["uri"] = $item['parent-uri'] = $item['thr-parent']
+ = 'tag:'.get_app()->get_hostname().
+ ','.date('Y-m-d').':'.$action.':'.$owner['uid'].
+ ':person:'.$connect_id.':'.$item['created'];
+
+ $item["body"] = sprintf($message, $owner["nick"], $contact["nick"]);
+
+ self::entryHeader($doc, $entry, $owner, $toplevel);
+
+ self::entryContent($doc, $entry, $item, $owner, $title);
+
+ $object = self::addPersonObject($doc, $owner, $contact);
+ $entry->appendChild($object);
+
+ self::entryFooter($doc, $entry, $item, $owner);
+
+ return $entry;
+ }
+
+ /**
+ * @brief Adds a regular entry element
+ *
+ * @param object $doc XML document
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
+ *
+ * @return object Entry element
+ */
+ private static function noteEntry($doc, $item, $owner, $toplevel)
+ {
+ if (($item["id"] != $item["parent"]) && (normalise_link($item["author-link"]) != normalise_link($owner["url"]))) {
+ logger("OStatus entry is from author ".$owner["url"]." - not from ".$item["author-link"].". Quitting.", LOGGER_DEBUG);
+ }
+
+ $title = self::entryHeader($doc, $entry, $owner, $toplevel);
+
+ XML::addElement($doc, $entry, "activity:object-type", ACTIVITY_OBJ_NOTE);
+
+ self::entryContent($doc, $entry, $item, $owner, $title);
+
+ self::entryFooter($doc, $entry, $item, $owner);
+
+ return $entry;
+ }
+
+ /**
+ * @brief Adds a header element to the XML document
+ *
+ * @param object $doc XML document
+ * @param object $entry The entry element where the elements are added
+ * @param array $owner Contact data of the poster
+ * @param bool $toplevel Is it for en entry element (false) or a feed entry (true)?
+ *
+ * @return string The title for the element
+ */
+ private static function entryHeader($doc, &$entry, $owner, $toplevel)
+ {
+ /// @todo Check if this title stuff is really needed (I guess not)
+ if (!$toplevel) {
+ $entry = $doc->createElement("entry");
+ $title = sprintf("New note by %s", $owner["nick"]);
+ } else {
+ $entry = $doc->createElementNS(NAMESPACE_ATOM1, "entry");
+
+ $entry->setAttribute("xmlns:thr", NAMESPACE_THREAD);
+ $entry->setAttribute("xmlns:georss", NAMESPACE_GEORSS);
+ $entry->setAttribute("xmlns:activity", NAMESPACE_ACTIVITY);
+ $entry->setAttribute("xmlns:media", NAMESPACE_MEDIA);
+ $entry->setAttribute("xmlns:poco", NAMESPACE_POCO);
+ $entry->setAttribute("xmlns:ostatus", NAMESPACE_OSTATUS);
+ $entry->setAttribute("xmlns:statusnet", NAMESPACE_STATUSNET);
+ $entry->setAttribute("xmlns:mastodon", NAMESPACE_MASTODON);
+
+ $author = self::addAuthor($doc, $owner);
+ $entry->appendChild($author);
+
+ $title = sprintf("New comment by %s", $owner["nick"]);
+ }
+ return $title;
+ }
+
+ /**
+ * @brief Adds elements to the XML document
+ *
+ * @param object $doc XML document
+ * @param object $entry Entry element where the content is added
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param string $title Title for the post
+ * @param string $verb The activity verb
+ * @param bool $complete Add the "status_net" element?
+ * @return void
+ */
+ private static function entryContent($doc, $entry, $item, $owner, $title, $verb = "", $complete = true)
+ {
+ if ($verb == "") {
+ $verb = self::constructVerb($item);
+ }
+
+ XML::addElement($doc, $entry, "id", $item["uri"]);
+ XML::addElement($doc, $entry, "title", $title);
+
+ $body = self::formatPicturePost($item['body']);
+
+ if ($item['title'] != "") {
+ $body = "[b]".$item['title']."[/b]\n\n".$body;
+ }
+
+ $body = bbcode($body, false, false, 7);
+
+ XML::addElement($doc, $entry, "content", $body, array("type" => "html"));
+
+ XML::addElement($doc, $entry, "link", "", array("rel" => "alternate", "type" => "text/html",
+ "href" => System::baseUrl()."/display/".$item["guid"])
+ );
+
+ if ($complete && ($item["id"] > 0)) {
+ XML::addElement($doc, $entry, "status_net", "", array("notice_id" => $item["id"]));
+ }
+
+ XML::addElement($doc, $entry, "activity:verb", $verb);
+
+ XML::addElement($doc, $entry, "published", datetime_convert("UTC", "UTC", $item["created"]."+00:00", ATOM_TIME));
+ XML::addElement($doc, $entry, "updated", datetime_convert("UTC", "UTC", $item["edited"]."+00:00", ATOM_TIME));
+ }
+
+ /**
+ * @brief Adds the elements at the foot of an entry to the XML document
+ *
+ * @param object $doc XML document
+ * @param object $entry The entry element where the elements are added
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ * @param bool $complete default true
+ * @return void
+ */
+ private static function entryFooter($doc, $entry, $item, $owner, $complete = true)
+ {
+ $mentioned = array();
+
+ if (($item['parent'] != $item['id']) || ($item['parent-uri'] !== $item['uri']) || (($item['thr-parent'] !== '') && ($item['thr-parent'] !== $item['uri']))) {
+ $parent = q("SELECT `guid`, `author-link`, `owner-link` FROM `item` WHERE `id` = %d", intval($item["parent"]));
+ $parent_item = (($item['thr-parent']) ? $item['thr-parent'] : $item['parent-uri']);
+
+ $thrparent = q(
+ "SELECT `guid`, `author-link`, `owner-link`, `plink` FROM `item` WHERE `uid` = %d AND `uri` = '%s'",
+ intval($owner["uid"]),
+ dbesc($parent_item)
+ );
+ if ($thrparent) {
+ $mentioned[$thrparent[0]["author-link"]] = $thrparent[0]["author-link"];
+ $mentioned[$thrparent[0]["owner-link"]] = $thrparent[0]["owner-link"];
+ $parent_plink = $thrparent[0]["plink"];
+ } else {
+ $mentioned[$parent[0]["author-link"]] = $parent[0]["author-link"];
+ $mentioned[$parent[0]["owner-link"]] = $parent[0]["owner-link"];
+ $parent_plink = System::baseUrl()."/display/".$parent[0]["guid"];
+ }
+
+ $attributes = array(
+ "ref" => $parent_item,
+ "href" => $parent_plink);
+ XML::addElement($doc, $entry, "thr:in-reply-to", "", $attributes);
+
+ $attributes = array(
+ "rel" => "related",
+ "href" => $parent_plink);
+ XML::addElement($doc, $entry, "link", "", $attributes);
+ }
+
+ if (intval($item["parent"]) > 0) {
+ $conversation_href = System::baseUrl()."/display/".$owner["nick"]."/".$item["parent"];
+ $conversation_uri = $conversation_href;
+
+ if (isset($parent_item)) {
+ $r = dba::fetch_first("SELECT `conversation-uri`, `conversation-href` FROM `conversation` WHERE `item-uri` = ?", $parent_item);
+ if (DBM::is_result($r)) {
+ if ($r['conversation-uri'] != '') {
+ $conversation_uri = $r['conversation-uri'];
+ }
+ if ($r['conversation-href'] != '') {
+ $conversation_href = $r['conversation-href'];
+ }
+ }
+ }
+
+ XML::addElement($doc, $entry, "link", "", array("rel" => "ostatus:conversation", "href" => $conversation_href));
+
+ $attributes = array(
+ "href" => $conversation_href,
+ "local_id" => $item["parent"],
+ "ref" => $conversation_uri);
+
+ XML::addElement($doc, $entry, "ostatus:conversation", $conversation_uri, $attributes);
+ }
+
+ $tags = item_getfeedtags($item);
+
+ if (count($tags)) {
+ foreach ($tags as $t) {
+ if ($t[0] == "@") {
+ $mentioned[$t[1]] = $t[1];
+ }
+ }
+ }
+
+ // Make sure that mentions are accepted (GNU Social has problems with mixing HTTP and HTTPS)
+ $newmentions = array();
+ foreach ($mentioned as $mention) {
+ $newmentions[str_replace("http://", "https://", $mention)] = str_replace("http://", "https://", $mention);
+ $newmentions[str_replace("https://", "http://", $mention)] = str_replace("https://", "http://", $mention);
+ }
+ $mentioned = $newmentions;
+
+ foreach ($mentioned as $mention) {
+ $r = q(
+ "SELECT `forum`, `prv` FROM `contact` WHERE `uid` = %d AND `nurl` = '%s'",
+ intval($owner["uid"]),
+ dbesc(normalise_link($mention))
+ );
+ if ($r[0]["forum"] || $r[0]["prv"]) {
+ XML::addElement($doc, $entry, "link", "",
+ array(
+ "rel" => "mentioned",
+ "ostatus:object-type" => ACTIVITY_OBJ_GROUP,
+ "href" => $mention)
+ );
+ } else {
+ XML::addElement($doc, $entry, "link", "",
+ array(
+ "rel" => "mentioned",
+ "ostatus:object-type" => ACTIVITY_OBJ_PERSON,
+ "href" => $mention)
+ );
+ }
+ }
+
+ if (!$item["private"]) {
+ XML::addElement($doc, $entry, "link", "", array("rel" => "ostatus:attention",
+ "href" => "http://activityschema.org/collection/public"));
+ XML::addElement($doc, $entry, "link", "", array("rel" => "mentioned",
+ "ostatus:object-type" => "http://activitystrea.ms/schema/1.0/collection",
+ "href" => "http://activityschema.org/collection/public"));
+ XML::addElement($doc, $entry, "mastodon:scope", "public");
+ }
+
+ if (count($tags)) {
+ foreach ($tags as $t) {
+ if ($t[0] != "@") {
+ XML::addElement($doc, $entry, "category", "", array("term" => $t[2]));
+ }
+ }
+ }
+
+ self::getAttachment($doc, $entry, $item);
+
+ if ($complete && ($item["id"] > 0)) {
+ $app = $item["app"];
+ if ($app == "") {
+ $app = "web";
+ }
+
+ $attributes = array("local_id" => $item["id"], "source" => $app);
+
+ if (isset($parent["id"])) {
+ $attributes["repeat_of"] = $parent["id"];
+ }
+
+ if ($item["coord"] != "") {
+ XML::addElement($doc, $entry, "georss:point", $item["coord"]);
+ }
+
+ XML::addElement($doc, $entry, "statusnet:notice_info", "", $attributes);
+ }
+ }
+
+ /**
+ * @brief Creates the XML feed for a given nickname
+ *
+ * @param object $a The application class
+ * @param string $owner_nick Nickname of the feed owner
+ * @param string $last_update Date of the last update
+ * @param integer $max_items Number of maximum items to fetch
+ *
+ * @return string XML feed
+ */
+ public static function feed(App $a, $owner_nick, &$last_update, $max_items = 300)
+ {
+ $stamp = microtime(true);
+
+ $cachekey = "ostatus:feed:".$owner_nick.":".$last_update;
+
+ $previous_created = $last_update;
+
+ $result = Cache::get($cachekey);
+ if (!is_null($result)) {
+ logger('Feed duration: '.number_format(microtime(true) - $stamp, 3).' - '.$owner_nick.' - '.$previous_created.' (cached)', LOGGER_DEBUG);
+ $last_update = $result['last_update'];
+ return $result['feed'];
+ }
+
+ $r = q(
+ "SELECT `contact`.*, `user`.`nickname`, `user`.`timezone`, `user`.`page-flags`
+ FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
+ WHERE `contact`.`self` AND `user`.`nickname` = '%s' LIMIT 1",
+ dbesc($owner_nick)
+ );
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ $owner = $r[0];
+
+ if (!strlen($last_update)) {
+ $last_update = 'now -30 days';
+ }
+
+ $check_date = datetime_convert('UTC', 'UTC', $last_update, 'Y-m-d H:i:s');
+ $authorid = Contact::getIdForURL($owner["url"], 0);
+
+ $items = q(
+ "SELECT `item`.*, `item`.`id` AS `item_id` FROM `item` USE INDEX (`uid_contactid_created`)
+ STRAIGHT_JOIN `thread` ON `thread`.`iid` = `item`.`parent`
+ WHERE `item`.`uid` = %d AND `item`.`contact-id` = %d AND
+ `item`.`author-id` = %d AND `item`.`created` > '%s' AND
+ NOT `item`.`deleted` AND NOT `item`.`private` AND
+ `thread`.`network` IN ('%s', '%s')
+ ORDER BY `item`.`created` DESC LIMIT %d",
+ intval($owner["uid"]), intval($owner["id"]),
+ intval($authorid), dbesc($check_date),
+ dbesc(NETWORK_OSTATUS), dbesc(NETWORK_DFRN), intval($max_items)
+ );
+
+ $doc = new DOMDocument('1.0', 'utf-8');
+ $doc->formatOutput = true;
+
+ $root = self::addHeader($doc, $owner);
+
+ foreach ($items as $item) {
+ if (Config::get('system', 'ostatus_debug')) {
+ $item['body'] .= '🍼';
+ }
+ $entry = self::entry($doc, $item, $owner);
+ $root->appendChild($entry);
+
+ if ($last_update < $item['created']) {
+ $last_update = $item['created'];
+ }
+ }
+
+ $feeddata = trim($doc->saveXML());
+
+ $msg = array('feed' => $feeddata, 'last_update' => $last_update);
+ Cache::set($cachekey, $msg, CACHE_QUARTER_HOUR);
+
+ logger('Feed duration: '.number_format(microtime(true) - $stamp, 3).' - '.$owner_nick.' - '.$previous_created, LOGGER_DEBUG);
+
+ return $feeddata;
+ }
+
+ /**
+ * @brief Creates the XML for a salmon message
+ *
+ * @param array $item Data of the item that is to be posted
+ * @param array $owner Contact data of the poster
+ *
+ * @return string XML for the salmon
+ */
+ public static function salmon($item, $owner)
+ {
+ $doc = new DOMDocument('1.0', 'utf-8');
+ $doc->formatOutput = true;
+
+ if (Config::get('system', 'ostatus_debug')) {
+ $item['body'] .= '🐟';
+ }
+
+ $entry = self::entry($doc, $item, $owner, true);
+
+ $doc->appendChild($entry);
+
+ return trim($doc->saveXML());
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Protocol/PortableContact.php
+ *
+ * @todo Move GNU Social URL schemata (http://server.tld/user/number) to http://server.tld/username
+ * @todo Fetch profile data from profile page for Redmatrix users
+ * @todo Detect if it is a forum
+ */
+
+namespace Friendica\Protocol;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Network\Probe;
+use Friendica\Object\Profile;
+use dba;
+use DOMDocument;
+use DomXPath;
+use Exception;
+
+require_once 'include/datetime.php';
+require_once 'include/network.php';
+require_once 'include/html2bbcode.php';
+require_once 'include/Photo.php';
+
+class PortableContact
+{
+ /**
+ * @brief Fetch POCO data
+ *
+ * @param integer $cid Contact ID
+ * @param integer $uid User ID
+ * @param integer $zcid Global Contact ID
+ * @param integer $url POCO address that should be polled
+ *
+ * Given a contact-id (minimum), load the PortableContacts friend list for that contact,
+ * and add the entries to the gcontact (Global Contact) table, or update existing entries
+ * if anything (name or photo) has changed.
+ * We use normalised urls for comparison which ignore http vs https and www.domain vs domain
+ *
+ * Once the global contact is stored add (if necessary) the contact linkage which associates
+ * the given uid, cid to the global contact entry. There can be many uid/cid combinations
+ * pointing to the same global contact id.
+ *
+ */
+ public static function loadWorker($cid, $uid = 0, $zcid = 0, $url = null)
+ {
+ // Call the function "load" via the worker
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "load", (int)$cid, (int)$uid, (int)$zcid, $url);
+ }
+
+ /**
+ * @brief Fetch POCO data from the worker
+ *
+ * @param integer $cid Contact ID
+ * @param integer $uid User ID
+ * @param integer $zcid Global Contact ID
+ * @param integer $url POCO address that should be polled
+ *
+ */
+ public static function load($cid, $uid, $zcid, $url)
+ {
+ $a = get_app();
+
+ if ($cid) {
+ if ((! $url) || (! $uid)) {
+ $r = q(
+ "select `poco`, `uid` from `contact` where `id` = %d limit 1",
+ intval($cid)
+ );
+ if (DBM::is_result($r)) {
+ $url = $r[0]['poco'];
+ $uid = $r[0]['uid'];
+ }
+ }
+ if (! $uid) {
+ return;
+ }
+ }
+
+ if (! $url) {
+ return;
+ }
+
+ $url = $url . (($uid) ? '/@me/@all?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation' : '?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation') ;
+
+ logger('load: ' . $url, LOGGER_DEBUG);
+
+ $s = fetch_url($url);
+
+ logger('load: returns ' . $s, LOGGER_DATA);
+
+ logger('load: return code: ' . $a->get_curl_code(), LOGGER_DEBUG);
+
+ if (($a->get_curl_code() > 299) || (! $s)) {
+ return;
+ }
+
+ $j = json_decode($s);
+
+ logger('load: json: ' . print_r($j, true), LOGGER_DATA);
+
+ if (! isset($j->entry)) {
+ return;
+ }
+
+ $total = 0;
+ foreach ($j->entry as $entry) {
+ $total ++;
+ $profile_url = '';
+ $profile_photo = '';
+ $connect_url = '';
+ $name = '';
+ $network = '';
+ $updated = NULL_DATE;
+ $location = '';
+ $about = '';
+ $keywords = '';
+ $gender = '';
+ $contact_type = -1;
+ $generation = 0;
+
+ $name = $entry->displayName;
+
+ if (isset($entry->urls)) {
+ foreach ($entry->urls as $url) {
+ if ($url->type == 'profile') {
+ $profile_url = $url->value;
+ continue;
+ }
+ if ($url->type == 'webfinger') {
+ $connect_url = str_replace('acct:', '', $url->value);
+ continue;
+ }
+ }
+ }
+ if (isset($entry->photos)) {
+ foreach ($entry->photos as $photo) {
+ if ($photo->type == 'profile') {
+ $profile_photo = $photo->value;
+ continue;
+ }
+ }
+ }
+
+ if (isset($entry->updated)) {
+ $updated = date("Y-m-d H:i:s", strtotime($entry->updated));
+ }
+
+ if (isset($entry->network)) {
+ $network = $entry->network;
+ }
+
+ if (isset($entry->currentLocation)) {
+ $location = $entry->currentLocation;
+ }
+
+ if (isset($entry->aboutMe)) {
+ $about = html2bbcode($entry->aboutMe);
+ }
+
+ if (isset($entry->gender)) {
+ $gender = $entry->gender;
+ }
+
+ if (isset($entry->generation) && ($entry->generation > 0)) {
+ $generation = ++$entry->generation;
+ }
+
+ if (isset($entry->tags)) {
+ foreach ($entry->tags as $tag) {
+ $keywords = implode(", ", $tag);
+ }
+ }
+
+ if (isset($entry->contactType) && ($entry->contactType >= 0)) {
+ $contact_type = $entry->contactType;
+ }
+
+ $gcontact = array("url" => $profile_url,
+ "name" => $name,
+ "network" => $network,
+ "photo" => $profile_photo,
+ "about" => $about,
+ "location" => $location,
+ "gender" => $gender,
+ "keywords" => $keywords,
+ "connect" => $connect_url,
+ "updated" => $updated,
+ "contact-type" => $contact_type,
+ "generation" => $generation);
+
+ try {
+ $gcontact = GlobalContact::sanitize($gcontact);
+ $gcid = GlobalContact::update($gcontact);
+
+ GlobalContact::link($gcid, $uid, $cid, $zcid);
+ } catch (Exception $e) {
+ logger($e->getMessage(), LOGGER_DEBUG);
+ }
+ }
+ logger("load: loaded $total entries", LOGGER_DEBUG);
+
+ q(
+ "DELETE FROM `glink` WHERE `cid` = %d AND `uid` = %d AND `zcid` = %d AND `updated` < UTC_TIMESTAMP - INTERVAL 2 DAY",
+ intval($cid),
+ intval($uid),
+ intval($zcid)
+ );
+ }
+
+ public static function reachable($profile, $server = "", $network = "", $force = false)
+ {
+ if ($server == "") {
+ $server = self::detectServer($profile);
+ }
+
+ if ($server == "") {
+ return true;
+ }
+
+ return self::checkServer($server, $network, $force);
+ }
+
+ public static function detectServer($profile)
+ {
+ // Try to detect the server path based upon some known standard paths
+ $server_url = "";
+
+ if ($server_url == "") {
+ $friendica = preg_replace("=(https?://)(.*)/profile/(.*)=ism", "$1$2", $profile);
+ if ($friendica != $profile) {
+ $server_url = $friendica;
+ $network = NETWORK_DFRN;
+ }
+ }
+
+ if ($server_url == "") {
+ $diaspora = preg_replace("=(https?://)(.*)/u/(.*)=ism", "$1$2", $profile);
+ if ($diaspora != $profile) {
+ $server_url = $diaspora;
+ $network = NETWORK_DIASPORA;
+ }
+ }
+
+ if ($server_url == "") {
+ $red = preg_replace("=(https?://)(.*)/channel/(.*)=ism", "$1$2", $profile);
+ if ($red != $profile) {
+ $server_url = $red;
+ $network = NETWORK_DIASPORA;
+ }
+ }
+
+ // Mastodon
+ if ($server_url == "") {
+ $mastodon = preg_replace("=(https?://)(.*)/users/(.*)=ism", "$1$2", $profile);
+ if ($mastodon != $profile) {
+ $server_url = $mastodon;
+ $network = NETWORK_OSTATUS;
+ }
+ }
+
+ // Numeric OStatus variant
+ if ($server_url == "") {
+ $ostatus = preg_replace("=(https?://)(.*)/user/(.*)=ism", "$1$2", $profile);
+ if ($ostatus != $profile) {
+ $server_url = $ostatus;
+ $network = NETWORK_OSTATUS;
+ }
+ }
+
+ // Wild guess
+ if ($server_url == "") {
+ $base = preg_replace("=(https?://)(.*?)/(.*)=ism", "$1$2", $profile);
+ if ($base != $profile) {
+ $server_url = $base;
+ $network = NETWORK_PHANTOM;
+ }
+ }
+
+ if ($server_url == "") {
+ return "";
+ }
+
+ $r = q(
+ "SELECT `id` FROM `gserver` WHERE `nurl` = '%s' AND `last_contact` > `last_failure`",
+ dbesc(normalise_link($server_url))
+ );
+
+ if (DBM::is_result($r)) {
+ return $server_url;
+ }
+
+ // Fetch the host-meta to check if this really is a server
+ $serverret = z_fetch_url($server_url."/.well-known/host-meta");
+ if (!$serverret["success"]) {
+ return "";
+ }
+
+ return $server_url;
+ }
+
+ public static function alternateOStatusUrl($url)
+ {
+ return(preg_match("=https?://.+/user/\d+=ism", $url, $matches));
+ }
+
+ public static function lastUpdated($profile, $force = false)
+ {
+ $gcontacts = q(
+ "SELECT * FROM `gcontact` WHERE `nurl` = '%s'",
+ dbesc(normalise_link($profile))
+ );
+
+ if (!DBM::is_result($gcontacts)) {
+ return false;
+ }
+
+ $contact = array("url" => $profile);
+
+ if ($gcontacts[0]["created"] <= NULL_DATE) {
+ $contact['created'] = datetime_convert();
+ }
+
+ if ($force) {
+ $server_url = normalise_link(self::detectServer($profile));
+ }
+
+ if (($server_url == '') && ($gcontacts[0]["server_url"] != "")) {
+ $server_url = $gcontacts[0]["server_url"];
+ }
+
+ if (!$force && (($server_url == '') || ($gcontacts[0]["server_url"] == $gcontacts[0]["nurl"]))) {
+ $server_url = normalise_link(self::detectServer($profile));
+ }
+
+ if (!in_array($gcontacts[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_FEED, NETWORK_OSTATUS, ""))) {
+ logger("Profile ".$profile.": Network type ".$gcontacts[0]["network"]." can't be checked", LOGGER_DEBUG);
+ return false;
+ }
+
+ if ($server_url != "") {
+ if (!self::checkServer($server_url, $gcontacts[0]["network"], $force)) {
+ if ($force) {
+ q(
+ "UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()),
+ dbesc(normalise_link($profile))
+ );
+ }
+
+ logger("Profile ".$profile.": Server ".$server_url." wasn't reachable.", LOGGER_DEBUG);
+ return false;
+ }
+ $contact['server_url'] = $server_url;
+ }
+
+ if (in_array($gcontacts[0]["network"], array("", NETWORK_FEED))) {
+ $server = q(
+ "SELECT `network` FROM `gserver` WHERE `nurl` = '%s' AND `network` != ''",
+ dbesc(normalise_link($server_url))
+ );
+
+ if ($server) {
+ $contact['network'] = $server[0]["network"];
+ } else {
+ return false;
+ }
+ }
+
+ // noscrape is really fast so we don't cache the call.
+ if (($server_url != "") && ($gcontacts[0]["nick"] != "")) {
+ // Use noscrape if possible
+ $server = q("SELECT `noscrape`, `network` FROM `gserver` WHERE `nurl` = '%s' AND `noscrape` != ''", dbesc(normalise_link($server_url)));
+
+ if ($server) {
+ $noscraperet = z_fetch_url($server[0]["noscrape"]."/".$gcontacts[0]["nick"]);
+
+ if ($noscraperet["success"] && ($noscraperet["body"] != "")) {
+ $noscrape = json_decode($noscraperet["body"], true);
+
+ if (is_array($noscrape)) {
+ $contact["network"] = $server[0]["network"];
+
+ if (isset($noscrape["fn"])) {
+ $contact["name"] = $noscrape["fn"];
+ }
+ if (isset($noscrape["comm"])) {
+ $contact["community"] = $noscrape["comm"];
+ }
+ if (isset($noscrape["tags"])) {
+ $keywords = implode(" ", $noscrape["tags"]);
+ if ($keywords != "") {
+ $contact["keywords"] = $keywords;
+ }
+ }
+
+ $location = Profile::formatLocation($noscrape);
+ if ($location) {
+ $contact["location"] = $location;
+ }
+ if (isset($noscrape["dfrn-notify"])) {
+ $contact["notify"] = $noscrape["dfrn-notify"];
+ }
+ // Remove all fields that are not present in the gcontact table
+ unset($noscrape["fn"]);
+ unset($noscrape["key"]);
+ unset($noscrape["homepage"]);
+ unset($noscrape["comm"]);
+ unset($noscrape["tags"]);
+ unset($noscrape["locality"]);
+ unset($noscrape["region"]);
+ unset($noscrape["country-name"]);
+ unset($noscrape["contacts"]);
+ unset($noscrape["dfrn-request"]);
+ unset($noscrape["dfrn-confirm"]);
+ unset($noscrape["dfrn-notify"]);
+ unset($noscrape["dfrn-poll"]);
+
+ // Set the date of the last contact
+ /// @todo By now the function "update_gcontact" doesn't work with this field
+ //$contact["last_contact"] = datetime_convert();
+
+ $contact = array_merge($contact, $noscrape);
+
+ GlobalContact::update($contact);
+
+ if (trim($noscrape["updated"]) != "") {
+ q(
+ "UPDATE `gcontact` SET `last_contact` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()),
+ dbesc(normalise_link($profile))
+ );
+
+ logger("Profile ".$profile." was last updated at ".$noscrape["updated"]." (noscrape)", LOGGER_DEBUG);
+
+ return $noscrape["updated"];
+ }
+ }
+ }
+ }
+ }
+
+ // If we only can poll the feed, then we only do this once a while
+ if (!$force && !self::updateNeeded($gcontacts[0]["created"], $gcontacts[0]["updated"], $gcontacts[0]["last_failure"], $gcontacts[0]["last_contact"])) {
+ logger("Profile ".$profile." was last updated at ".$gcontacts[0]["updated"]." (cached)", LOGGER_DEBUG);
+
+ GlobalContact::update($contact);
+ return $gcontacts[0]["updated"];
+ }
+
+ $data = Probe::uri($profile);
+
+ // Is the profile link the alternate OStatus link notation? (http://domain.tld/user/4711)
+ // Then check the other link and delete this one
+ if (($data["network"] == NETWORK_OSTATUS) && self::alternateOStatusUrl($profile)
+ && (normalise_link($profile) == normalise_link($data["alias"]))
+ && (normalise_link($profile) != normalise_link($data["url"]))
+ ) {
+ // Delete the old entry
+ q("DELETE FROM `gcontact` WHERE `nurl` = '%s'", dbesc(normalise_link($profile)));
+ q("DELETE FROM `glink` WHERE `gcid` = %d", intval($gcontacts[0]["id"]));
+
+ $gcontact = array_merge($gcontacts[0], $data);
+
+ $gcontact["server_url"] = $data["baseurl"];
+
+ try {
+ $gcontact = GlobalContact::sanitize($gcontact);
+ GlobalContact::update($gcontact);
+
+ self::lastUpdated($data["url"], $force);
+ } catch (Exception $e) {
+ logger($e->getMessage(), LOGGER_DEBUG);
+ }
+
+ logger("Profile ".$profile." was deleted", LOGGER_DEBUG);
+ return false;
+ }
+
+ if (($data["poll"] == "") || (in_array($data["network"], array(NETWORK_FEED, NETWORK_PHANTOM)))) {
+ q(
+ "UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()),
+ dbesc(normalise_link($profile))
+ );
+
+ logger("Profile ".$profile." wasn't reachable (profile)", LOGGER_DEBUG);
+ return false;
+ }
+
+ $contact = array_merge($contact, $data);
+
+ $contact["server_url"] = $data["baseurl"];
+
+ GlobalContact::update($contact);
+
+ $feedret = z_fetch_url($data["poll"]);
+
+ if (!$feedret["success"]) {
+ q(
+ "UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()),
+ dbesc(normalise_link($profile))
+ );
+
+ logger("Profile ".$profile." wasn't reachable (no feed)", LOGGER_DEBUG);
+ return false;
+ }
+
+ $doc = new DOMDocument();
+ @$doc->loadXML($feedret["body"]);
+
+ $xpath = new DomXPath($doc);
+ $xpath->registerNamespace('atom', "http://www.w3.org/2005/Atom");
+
+ $entries = $xpath->query('/atom:feed/atom:entry');
+
+ $last_updated = "";
+
+ foreach ($entries as $entry) {
+ $published = $xpath->query('atom:published/text()', $entry)->item(0)->nodeValue;
+ $updated = $xpath->query('atom:updated/text()', $entry)->item(0)->nodeValue;
+
+ if ($last_updated < $published)
+ $last_updated = $published;
+
+ if ($last_updated < $updated)
+ $last_updated = $updated;
+ }
+
+ // Maybe there aren't any entries. Then check if it is a valid feed
+ if ($last_updated == "") {
+ if ($xpath->query('/atom:feed')->length > 0) {
+ $last_updated = NULL_DATE;
+ }
+ }
+ q(
+ "UPDATE `gcontact` SET `updated` = '%s', `last_contact` = '%s' WHERE `nurl` = '%s'",
+ dbesc(DBM::date($last_updated)),
+ dbesc(DBM::date()),
+ dbesc(normalise_link($profile))
+ );
+
+ if (($gcontacts[0]["generation"] == 0)) {
+ q(
+ "UPDATE `gcontact` SET `generation` = 9 WHERE `nurl` = '%s'",
+ dbesc(normalise_link($profile))
+ );
+ }
+
+ logger("Profile ".$profile." was last updated at ".$last_updated, LOGGER_DEBUG);
+
+ return($last_updated);
+ }
+
+ public static function updateNeeded($created, $updated, $last_failure, $last_contact)
+ {
+ $now = strtotime(datetime_convert());
+
+ if ($updated > $last_contact) {
+ $contact_time = strtotime($updated);
+ } else {
+ $contact_time = strtotime($last_contact);
+ }
+
+ $failure_time = strtotime($last_failure);
+ $created_time = strtotime($created);
+
+ // If there is no "created" time then use the current time
+ if ($created_time <= 0) {
+ $created_time = $now;
+ }
+
+ // If the last contact was less than 24 hours then don't update
+ if (($now - $contact_time) < (60 * 60 * 24)) {
+ return false;
+ }
+
+ // If the last failure was less than 24 hours then don't update
+ if (($now - $failure_time) < (60 * 60 * 24)) {
+ return false;
+ }
+
+ // If the last contact was less than a week ago and the last failure is older than a week then don't update
+ //if ((($now - $contact_time) < (60 * 60 * 24 * 7)) && ($contact_time > $failure_time))
+ // return false;
+
+ // If the last contact time was more than a week ago and the contact was created more than a week ago, then only try once a week
+ if ((($now - $contact_time) > (60 * 60 * 24 * 7)) && (($now - $created_time) > (60 * 60 * 24 * 7)) && (($now - $failure_time) < (60 * 60 * 24 * 7))) {
+ return false;
+ }
+
+ // If the last contact time was more than a month ago and the contact was created more than a month ago, then only try once a month
+ if ((($now - $contact_time) > (60 * 60 * 24 * 30)) && (($now - $created_time) > (60 * 60 * 24 * 30)) && (($now - $failure_time) < (60 * 60 * 24 * 30))) {
+ return false;
+ }
+
+ return true;
+ }
+
+ public static function toBoolean($val)
+ {
+ if (($val == "true") || ($val == 1)) {
+ return true;
+ } elseif (($val == "false") || ($val == 0)) {
+ return false;
+ }
+
+ return $val;
+ }
+
+ /**
+ * @brief Detect server type (Hubzilla or Friendica) via the poco data
+ *
+ * @param object $data POCO data
+ * @return array Server data
+ */
+ public static function detectPocoData($data)
+ {
+ $server = false;
+
+ if (!isset($data->entry)) {
+ return false;
+ }
+
+ if (count($data->entry) == 0) {
+ return false;
+ }
+
+ if (!isset($data->entry[0]->urls)) {
+ return false;
+ }
+
+ if (count($data->entry[0]->urls) == 0) {
+ return false;
+ }
+
+ foreach ($data->entry[0]->urls as $url) {
+ if ($url->type == 'zot') {
+ $server = array();
+ $server["platform"] = 'Hubzilla';
+ $server["network"] = NETWORK_DIASPORA;
+ return $server;
+ }
+ }
+ return false;
+ }
+
+ /**
+ * @brief Detect server type by using the nodeinfo data
+ *
+ * @param string $server_url address of the server
+ * @return array Server data
+ */
+ public static function fetchNodeinfo($server_url)
+ {
+ $serverret = z_fetch_url($server_url."/.well-known/nodeinfo");
+ if (!$serverret["success"]) {
+ return false;
+ }
+
+ $nodeinfo = json_decode($serverret['body']);
+
+ if (!is_object($nodeinfo)) {
+ return false;
+ }
+
+ if (!is_array($nodeinfo->links)) {
+ return false;
+ }
+
+ $nodeinfo_url = '';
+
+ foreach ($nodeinfo->links as $link) {
+ if ($link->rel == 'http://nodeinfo.diaspora.software/ns/schema/1.0') {
+ $nodeinfo_url = $link->href;
+ }
+ }
+
+ if ($nodeinfo_url == '') {
+ return false;
+ }
+
+ $serverret = z_fetch_url($nodeinfo_url);
+ if (!$serverret["success"]) {
+ return false;
+ }
+
+ $nodeinfo = json_decode($serverret['body']);
+
+ if (!is_object($nodeinfo)) {
+ return false;
+ }
+
+ $server = array();
+
+ $server['register_policy'] = REGISTER_CLOSED;
+
+ if (is_bool($nodeinfo->openRegistrations) && $nodeinfo->openRegistrations) {
+ $server['register_policy'] = REGISTER_OPEN;
+ }
+
+ if (is_object($nodeinfo->software)) {
+ if (isset($nodeinfo->software->name)) {
+ $server['platform'] = $nodeinfo->software->name;
+ }
+
+ if (isset($nodeinfo->software->version)) {
+ $server['version'] = $nodeinfo->software->version;
+ // Version numbers on Nodeinfo are presented with additional info, e.g.:
+ // 0.6.3.0-p1702cc1c, 0.6.99.0-p1b9ab160 or 3.4.3-2-1191.
+ $server['version'] = preg_replace("=(.+)-(.{4,})=ism", "$1", $server['version']);
+ }
+ }
+
+ if (is_object($nodeinfo->metadata)) {
+ if (isset($nodeinfo->metadata->nodeName)) {
+ $server['site_name'] = $nodeinfo->metadata->nodeName;
+ }
+ }
+
+ $diaspora = false;
+ $friendica = false;
+ $gnusocial = false;
+
+ if (is_array($nodeinfo->protocols->inbound)) {
+ foreach ($nodeinfo->protocols->inbound as $inbound) {
+ if ($inbound == 'diaspora') {
+ $diaspora = true;
+ }
+ if ($inbound == 'friendica') {
+ $friendica = true;
+ }
+ if ($inbound == 'gnusocial') {
+ $gnusocial = true;
+ }
+ }
+ }
+
+ if ($gnusocial) {
+ $server['network'] = NETWORK_OSTATUS;
+ }
+ if ($diaspora) {
+ $server['network'] = NETWORK_DIASPORA;
+ }
+ if ($friendica) {
+ $server['network'] = NETWORK_DFRN;
+ }
+
+ if (!$server) {
+ return false;
+ }
+
+ return $server;
+ }
+
+ /**
+ * @brief Detect server type (Hubzilla or Friendica) via the front page body
+ *
+ * @param string $body Front page of the server
+ * @return array Server data
+ */
+ public static function detectServerType($body)
+ {
+ $server = false;
+
+ $doc = new DOMDocument();
+ @$doc->loadHTML($body);
+ $xpath = new DomXPath($doc);
+
+ $list = $xpath->query("//meta[@name]");
+
+ foreach ($list as $node) {
+ $attr = array();
+ if ($node->attributes->length) {
+ foreach ($node->attributes as $attribute) {
+ $attr[$attribute->name] = $attribute->value;
+ }
+ }
+ if ($attr['name'] == 'generator') {
+ $version_part = explode(" ", $attr['content']);
+ if (count($version_part) == 2) {
+ if (in_array($version_part[0], array("Friendika", "Friendica"))) {
+ $server = array();
+ $server["platform"] = $version_part[0];
+ $server["version"] = $version_part[1];
+ $server["network"] = NETWORK_DFRN;
+ }
+ }
+ }
+ }
+
+ if (!$server) {
+ $list = $xpath->query("//meta[@property]");
+
+ foreach ($list as $node) {
+ $attr = array();
+ if ($node->attributes->length) {
+ foreach ($node->attributes as $attribute) {
+ $attr[$attribute->name] = $attribute->value;
+ }
+ }
+ if ($attr['property'] == 'generator' && in_array($attr['content'], array("hubzilla", "BlaBlaNet"))) {
+ $server = array();
+ $server["platform"] = $attr['content'];
+ $server["version"] = "";
+ $server["network"] = NETWORK_DIASPORA;
+ }
+ }
+ }
+
+ if (!$server) {
+ return false;
+ }
+
+ $server["site_name"] = $xpath->evaluate($element."//head/title/text()", $context)->item(0)->nodeValue;
+ return $server;
+ }
+
+ public static function checkServer($server_url, $network = "", $force = false)
+ {
+ // Unify the server address
+ $server_url = trim($server_url, "/");
+ $server_url = str_replace("/index.php", "", $server_url);
+
+ if ($server_url == "") {
+ return false;
+ }
+
+ $servers = q("SELECT * FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
+ if (DBM::is_result($servers)) {
+ if ($servers[0]["created"] <= NULL_DATE) {
+ q(
+ "UPDATE `gserver` SET `created` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()),
+ dbesc(normalise_link($server_url))
+ );
+ }
+ $poco = $servers[0]["poco"];
+ $noscrape = $servers[0]["noscrape"];
+
+ if ($network == "") {
+ $network = $servers[0]["network"];
+ }
+
+ $last_contact = $servers[0]["last_contact"];
+ $last_failure = $servers[0]["last_failure"];
+ $version = $servers[0]["version"];
+ $platform = $servers[0]["platform"];
+ $site_name = $servers[0]["site_name"];
+ $info = $servers[0]["info"];
+ $register_policy = $servers[0]["register_policy"];
+
+ if (!$force && !self::updateNeeded($servers[0]["created"], "", $last_failure, $last_contact)) {
+ logger("Use cached data for server ".$server_url, LOGGER_DEBUG);
+ return ($last_contact >= $last_failure);
+ }
+ } else {
+ $poco = "";
+ $noscrape = "";
+ $version = "";
+ $platform = "";
+ $site_name = "";
+ $info = "";
+ $register_policy = -1;
+
+ $last_contact = NULL_DATE;
+ $last_failure = NULL_DATE;
+ }
+ logger("Server ".$server_url." is outdated or unknown. Start discovery. Force: ".$force." Created: ".$servers[0]["created"]." Failure: ".$last_failure." Contact: ".$last_contact, LOGGER_DEBUG);
+
+ $failure = false;
+ $possible_failure = false;
+ $orig_last_failure = $last_failure;
+ $orig_last_contact = $last_contact;
+
+ // Check if the page is accessible via SSL.
+ $orig_server_url = $server_url;
+ $server_url = str_replace("http://", "https://", $server_url);
+
+ // We set the timeout to 20 seconds since this operation should be done in no time if the server was vital
+ $serverret = z_fetch_url($server_url."/.well-known/host-meta", false, $redirects, array('timeout' => 20));
+
+ // Quit if there is a timeout.
+ // But we want to make sure to only quit if we are mostly sure that this server url fits.
+ if (DBM::is_result($servers) && ($orig_server_url == $server_url) &&
+ ($serverret['errno'] == CURLE_OPERATION_TIMEDOUT)) {
+ logger("Connection to server ".$server_url." timed out.", LOGGER_DEBUG);
+ dba::update('gserver', array('last_failure' => datetime_convert()), array('nurl' => normalise_link($server_url)));
+ return false;
+ }
+
+ // Maybe the page is unencrypted only?
+ $xmlobj = @simplexml_load_string($serverret["body"], 'SimpleXMLElement', 0, "http://docs.oasis-open.org/ns/xri/xrd-1.0");
+ if (!$serverret["success"] || ($serverret["body"] == "") || (@sizeof($xmlobj) == 0) || !is_object($xmlobj)) {
+ $server_url = str_replace("https://", "http://", $server_url);
+
+ // We set the timeout to 20 seconds since this operation should be done in no time if the server was vital
+ $serverret = z_fetch_url($server_url."/.well-known/host-meta", false, $redirects, array('timeout' => 20));
+
+ // Quit if there is a timeout
+ if ($serverret['errno'] == CURLE_OPERATION_TIMEDOUT) {
+ logger("Connection to server ".$server_url." timed out.", LOGGER_DEBUG);
+ dba::update('gserver', array('last_failure' => datetime_convert()), array('nurl' => normalise_link($server_url)));
+ return false;
+ }
+
+ $xmlobj = @simplexml_load_string($serverret["body"], 'SimpleXMLElement', 0, "http://docs.oasis-open.org/ns/xri/xrd-1.0");
+ }
+
+ if (!$serverret["success"] || ($serverret["body"] == "") || (sizeof($xmlobj) == 0) || !is_object($xmlobj)) {
+ // Workaround for bad configured servers (known nginx problem)
+ if (!in_array($serverret["debug"]["http_code"], array("403", "404"))) {
+ $failure = true;
+ }
+ $possible_failure = true;
+ }
+
+ // If the server has no possible failure we reset the cached data
+ if (!$possible_failure) {
+ $version = "";
+ $platform = "";
+ $site_name = "";
+ $info = "";
+ $register_policy = -1;
+ }
+
+ // Look for poco
+ if (!$failure) {
+ $serverret = z_fetch_url($server_url."/poco");
+ if ($serverret["success"]) {
+ $data = json_decode($serverret["body"]);
+ if (isset($data->totalResults)) {
+ $poco = $server_url."/poco";
+ $server = self::detectPocoData($data);
+ if ($server) {
+ $platform = $server['platform'];
+ $network = $server['network'];
+ $version = '';
+ $site_name = '';
+ }
+ }
+ }
+ }
+
+ if (!$failure) {
+ // Test for Diaspora, Hubzilla, Mastodon or older Friendica servers
+ $serverret = z_fetch_url($server_url);
+
+ if (!$serverret["success"] || ($serverret["body"] == "")) {
+ $failure = true;
+ } else {
+ $server = self::detectServerType($serverret["body"]);
+ if ($server) {
+ $platform = $server['platform'];
+ $network = $server['network'];
+ $version = $server['version'];
+ $site_name = $server['site_name'];
+ }
+
+ $lines = explode("\n", $serverret["header"]);
+ if (count($lines)) {
+ foreach ($lines as $line) {
+ $line = trim($line);
+ if (stristr($line, 'X-Diaspora-Version:')) {
+ $platform = "Diaspora";
+ $version = trim(str_replace("X-Diaspora-Version:", "", $line));
+ $version = trim(str_replace("x-diaspora-version:", "", $version));
+ $network = NETWORK_DIASPORA;
+ $versionparts = explode("-", $version);
+ $version = $versionparts[0];
+ }
+
+ if (stristr($line, 'Server: Mastodon')) {
+ $platform = "Mastodon";
+ $network = NETWORK_OSTATUS;
+ }
+ }
+ }
+ }
+ }
+
+ if (!$failure && ($poco == "")) {
+ // Test for Statusnet
+ // Will also return data for Friendica and GNU Social - but it will be overwritten later
+ // The "not implemented" is a special treatment for really, really old Friendica versions
+ $serverret = z_fetch_url($server_url."/api/statusnet/version.json");
+ if ($serverret["success"] && ($serverret["body"] != '{"error":"not implemented"}') &&
+ ($serverret["body"] != '') && (strlen($serverret["body"]) < 30)) {
+ $platform = "StatusNet";
+ // Remove junk that some GNU Social servers return
+ $version = str_replace(chr(239).chr(187).chr(191), "", $serverret["body"]);
+ $version = trim($version, '"');
+ $network = NETWORK_OSTATUS;
+ }
+
+ // Test for GNU Social
+ $serverret = z_fetch_url($server_url."/api/gnusocial/version.json");
+ if ($serverret["success"] && ($serverret["body"] != '{"error":"not implemented"}') &&
+ ($serverret["body"] != '') && (strlen($serverret["body"]) < 30)) {
+ $platform = "GNU Social";
+ // Remove junk that some GNU Social servers return
+ $version = str_replace(chr(239).chr(187).chr(191), "", $serverret["body"]);
+ $version = trim($version, '"');
+ $network = NETWORK_OSTATUS;
+ }
+
+ // Test for Mastodon
+ $orig_version = $version;
+ $serverret = z_fetch_url($server_url."/api/v1/instance");
+ if ($serverret["success"] && ($serverret["body"] != '')) {
+ $data = json_decode($serverret["body"]);
+ if (isset($data->version)) {
+ $platform = "Mastodon";
+ $version = $data->version;
+ $site_name = $data->title;
+ $info = $data->description;
+ $network = NETWORK_OSTATUS;
+ }
+ }
+ if (strstr($orig_version.$version, 'Pleroma')) {
+ $platform = 'Pleroma';
+ $version = trim(str_replace('Pleroma', '', $version));
+ }
+ }
+
+ if (!$failure) {
+ // Test for Hubzilla and Red
+ $serverret = z_fetch_url($server_url."/siteinfo.json");
+ if ($serverret["success"]) {
+ $data = json_decode($serverret["body"]);
+ if (isset($data->url)) {
+ $platform = $data->platform;
+ $version = $data->version;
+ $network = NETWORK_DIASPORA;
+ }
+ if (!empty($data->site_name)) {
+ $site_name = $data->site_name;
+ }
+ switch ($data->register_policy) {
+ case "REGISTER_OPEN":
+ $register_policy = REGISTER_OPEN;
+ break;
+ case "REGISTER_APPROVE":
+ $register_policy = REGISTER_APPROVE;
+ break;
+ case "REGISTER_CLOSED":
+ default:
+ $register_policy = REGISTER_CLOSED;
+ break;
+ }
+ } else {
+ // Test for Hubzilla, Redmatrix or Friendica
+ $serverret = z_fetch_url($server_url."/api/statusnet/config.json");
+ if ($serverret["success"]) {
+ $data = json_decode($serverret["body"]);
+ if (isset($data->site->server)) {
+ if (isset($data->site->platform)) {
+ $platform = $data->site->platform->PLATFORM_NAME;
+ $version = $data->site->platform->STD_VERSION;
+ $network = NETWORK_DIASPORA;
+ }
+ if (isset($data->site->BlaBlaNet)) {
+ $platform = $data->site->BlaBlaNet->PLATFORM_NAME;
+ $version = $data->site->BlaBlaNet->STD_VERSION;
+ $network = NETWORK_DIASPORA;
+ }
+ if (isset($data->site->hubzilla)) {
+ $platform = $data->site->hubzilla->PLATFORM_NAME;
+ $version = $data->site->hubzilla->RED_VERSION;
+ $network = NETWORK_DIASPORA;
+ }
+ if (isset($data->site->redmatrix)) {
+ if (isset($data->site->redmatrix->PLATFORM_NAME)) {
+ $platform = $data->site->redmatrix->PLATFORM_NAME;
+ } elseif (isset($data->site->redmatrix->RED_PLATFORM)) {
+ $platform = $data->site->redmatrix->RED_PLATFORM;
+ }
+
+ $version = $data->site->redmatrix->RED_VERSION;
+ $network = NETWORK_DIASPORA;
+ }
+ if (isset($data->site->friendica)) {
+ $platform = $data->site->friendica->FRIENDICA_PLATFORM;
+ $version = $data->site->friendica->FRIENDICA_VERSION;
+ $network = NETWORK_DFRN;
+ }
+
+ $site_name = $data->site->name;
+
+ $data->site->closed = self::toBoolean($data->site->closed);
+ $data->site->private = self::toBoolean($data->site->private);
+ $data->site->inviteonly = self::toBoolean($data->site->inviteonly);
+
+ if (!$data->site->closed && !$data->site->private and $data->site->inviteonly) {
+ $register_policy = REGISTER_APPROVE;
+ } elseif (!$data->site->closed && !$data->site->private) {
+ $register_policy = REGISTER_OPEN;
+ } else {
+ $register_policy = REGISTER_CLOSED;
+ }
+ }
+ }
+ }
+ }
+
+ // Query statistics.json. Optional package for Diaspora, Friendica and Redmatrix
+ if (!$failure) {
+ $serverret = z_fetch_url($server_url."/statistics.json");
+ if ($serverret["success"]) {
+ $data = json_decode($serverret["body"]);
+ if (isset($data->version)) {
+ $version = $data->version;
+ // Version numbers on statistics.json are presented with additional info, e.g.:
+ // 0.6.3.0-p1702cc1c, 0.6.99.0-p1b9ab160 or 3.4.3-2-1191.
+ $version = preg_replace("=(.+)-(.{4,})=ism", "$1", $version);
+ }
+
+ if (!empty($data->name)) {
+ $site_name = $data->name;
+ }
+
+ if (!empty($data->network)) {
+ $platform = $data->network;
+ }
+
+ if ($platform == "Diaspora") {
+ $network = NETWORK_DIASPORA;
+ }
+
+ if ($data->registrations_open) {
+ $register_policy = REGISTER_OPEN;
+ } else {
+ $register_policy = REGISTER_CLOSED;
+ }
+ }
+ }
+
+ // Query nodeinfo. Working for (at least) Diaspora and Friendica.
+ if (!$failure) {
+ $server = self::fetchNodeinfo($server_url);
+ if ($server) {
+ $register_policy = $server['register_policy'];
+
+ if (isset($server['platform'])) {
+ $platform = $server['platform'];
+ }
+
+ if (isset($server['network'])) {
+ $network = $server['network'];
+ }
+
+ if (isset($server['version'])) {
+ $version = $server['version'];
+ }
+
+ if (isset($server['site_name'])) {
+ $site_name = $server['site_name'];
+ }
+ }
+ }
+
+ // Check for noscrape
+ // Friendica servers could be detected as OStatus servers
+ if (!$failure && in_array($network, array(NETWORK_DFRN, NETWORK_OSTATUS))) {
+ $serverret = z_fetch_url($server_url."/friendica/json");
+
+ if (!$serverret["success"]) {
+ $serverret = z_fetch_url($server_url."/friendika/json");
+ }
+
+ if ($serverret["success"]) {
+ $data = json_decode($serverret["body"]);
+
+ if (isset($data->version)) {
+ $network = NETWORK_DFRN;
+
+ $noscrape = $data->no_scrape_url;
+ $version = $data->version;
+ $site_name = $data->site_name;
+ $info = $data->info;
+ $register_policy_str = $data->register_policy;
+ $platform = $data->platform;
+
+ switch ($register_policy_str) {
+ case "REGISTER_CLOSED":
+ $register_policy = REGISTER_CLOSED;
+ break;
+ case "REGISTER_APPROVE":
+ $register_policy = REGISTER_APPROVE;
+ break;
+ case "REGISTER_OPEN":
+ $register_policy = REGISTER_OPEN;
+ break;
+ }
+ }
+ }
+ }
+
+ if ($possible_failure && !$failure) {
+ $failure = true;
+ }
+
+ if ($failure) {
+ $last_contact = $orig_last_contact;
+ $last_failure = datetime_convert();
+ } else {
+ $last_contact = datetime_convert();
+ $last_failure = $orig_last_failure;
+ }
+
+ if (($last_contact <= $last_failure) && !$failure) {
+ logger("Server ".$server_url." seems to be alive, but last contact wasn't set - could be a bug", LOGGER_DEBUG);
+ } elseif (($last_contact >= $last_failure) && $failure) {
+ logger("Server ".$server_url." seems to be dead, but last failure wasn't set - could be a bug", LOGGER_DEBUG);
+ }
+
+ // Check again if the server exists
+ $servers = q("SELECT `nurl` FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
+
+ $version = strip_tags($version);
+ $site_name = strip_tags($site_name);
+ $info = strip_tags($info);
+ $platform = strip_tags($platform);
+
+ if ($servers) {
+ q(
+ "UPDATE `gserver` SET `url` = '%s', `version` = '%s', `site_name` = '%s', `info` = '%s', `register_policy` = %d, `poco` = '%s', `noscrape` = '%s',
+ `network` = '%s', `platform` = '%s', `last_contact` = '%s', `last_failure` = '%s' WHERE `nurl` = '%s'",
+ dbesc($server_url),
+ dbesc($version),
+ dbesc($site_name),
+ dbesc($info),
+ intval($register_policy),
+ dbesc($poco),
+ dbesc($noscrape),
+ dbesc($network),
+ dbesc($platform),
+ dbesc($last_contact),
+ dbesc($last_failure),
+ dbesc(normalise_link($server_url))
+ );
+ } elseif (!$failure) {
+ q(
+ "INSERT INTO `gserver` (`url`, `nurl`, `version`, `site_name`, `info`, `register_policy`, `poco`, `noscrape`, `network`, `platform`, `created`, `last_contact`, `last_failure`)
+ VALUES ('%s', '%s', '%s', '%s', '%s', %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s')",
+ dbesc($server_url),
+ dbesc(normalise_link($server_url)),
+ dbesc($version),
+ dbesc($site_name),
+ dbesc($info),
+ intval($register_policy),
+ dbesc($poco),
+ dbesc($noscrape),
+ dbesc($network),
+ dbesc($platform),
+ dbesc(datetime_convert()),
+ dbesc($last_contact),
+ dbesc($last_failure),
+ dbesc(datetime_convert())
+ );
+ }
+ logger("End discovery for server " . $server_url, LOGGER_DEBUG);
+
+ return !$failure;
+ }
+
+ /**
+ * @brief Returns a list of all known servers
+ * @return array List of server urls
+ */
+ public static function serverlist()
+ {
+ $r = q(
+ "SELECT `url`, `site_name` AS `displayName`, `network`, `platform`, `version` FROM `gserver`
+ WHERE `network` IN ('%s', '%s', '%s') AND `last_contact` > `last_failure`
+ ORDER BY `last_contact`
+ LIMIT 1000",
+ dbesc(NETWORK_DFRN),
+ dbesc(NETWORK_DIASPORA),
+ dbesc(NETWORK_OSTATUS)
+ );
+
+ if (!DBM::is_result($r)) {
+ return false;
+ }
+
+ return $r;
+ }
+
+ /**
+ * @brief Fetch server list from remote servers and adds them when they are new.
+ *
+ * @param string $poco URL to the POCO endpoint
+ */
+ public static function fetchServerlist($poco)
+ {
+ $serverret = z_fetch_url($poco."/@server");
+ if (!$serverret["success"]) {
+ return;
+ }
+ $serverlist = json_decode($serverret['body']);
+
+ if (!is_array($serverlist)) {
+ return;
+ }
+
+ foreach ($serverlist as $server) {
+ $server_url = str_replace("/index.php", "", $server->url);
+
+ $r = q("SELECT `nurl` FROM `gserver` WHERE `nurl` = '%s'", dbesc(normalise_link($server_url)));
+ if (!DBM::is_result($r)) {
+ logger("Call server check for server ".$server_url, LOGGER_DEBUG);
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "server", $server_url);
+ }
+ }
+ }
+
+ public static function discoverFederation()
+ {
+ $last = Config::get('poco', 'last_federation_discovery');
+
+ if ($last) {
+ $next = $last + (24 * 60 * 60);
+ if ($next > time()) {
+ return;
+ }
+ }
+
+ // Discover Friendica, Hubzilla and Diaspora servers
+ $serverdata = fetch_url("http://the-federation.info/pods.json");
+
+ if ($serverdata) {
+ $servers = json_decode($serverdata);
+
+ foreach ($servers->pods as $server) {
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "server", "https://".$server->host);
+ }
+ }
+
+ // Disvover Mastodon servers
+ if (!Config::get('system', 'ostatus_disabled')) {
+ $serverdata = fetch_url("https://instances.mastodon.xyz/instances.json");
+
+ if ($serverdata) {
+ $servers = json_decode($serverdata);
+
+ foreach ($servers as $server) {
+ $url = (is_null($server->https_score) ? 'http' : 'https').'://'.$server->name;
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "server", $url);
+ }
+ }
+ }
+
+ // Currently disabled, since the service isn't available anymore.
+ // It is not removed since I hope that there will be a successor.
+ // Discover GNU Social Servers.
+ //if (!Config::get('system','ostatus_disabled')) {
+ // $serverdata = "http://gstools.org/api/get_open_instances/";
+
+ // $result = z_fetch_url($serverdata);
+ // if ($result["success"]) {
+ // $servers = json_decode($result["body"]);
+
+ // foreach($servers->data as $server)
+ // self::checkServer($server->instance_address);
+ // }
+ //}
+
+ Config::set('poco', 'last_federation_discovery', time());
+ }
+
+ public static function discoverSingleServer($id)
+ {
+ $r = q("SELECT `poco`, `nurl`, `url`, `network` FROM `gserver` WHERE `id` = %d", intval($id));
+ if (!DBM::is_result($r)) {
+ return false;
+ }
+
+ $server = $r[0];
+
+ // Discover new servers out there (Works from Friendica version 3.5.2)
+ self::fetchServerlist($server["poco"]);
+
+ // Fetch all users from the other server
+ $url = $server["poco"]."/?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
+
+ logger("Fetch all users from the server ".$server["url"], LOGGER_DEBUG);
+
+ $retdata = z_fetch_url($url);
+ if ($retdata["success"]) {
+ $data = json_decode($retdata["body"]);
+
+ self::discoverServer($data, 2);
+
+ if (Config::get('system', 'poco_discovery') > 1) {
+ $timeframe = Config::get('system', 'poco_discovery_since');
+ if ($timeframe == 0) {
+ $timeframe = 30;
+ }
+
+ $updatedSince = date("Y-m-d H:i:s", time() - $timeframe * 86400);
+
+ // Fetch all global contacts from the other server (Not working with Redmatrix and Friendica versions before 3.3)
+ $url = $server["poco"]."/@global?updatedSince=".$updatedSince."&fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
+
+ $success = false;
+
+ $retdata = z_fetch_url($url);
+ if ($retdata["success"]) {
+ logger("Fetch all global contacts from the server ".$server["nurl"], LOGGER_DEBUG);
+ $success = self::discoverServer(json_decode($retdata["body"]));
+ }
+
+ if (!$success && (Config::get('system', 'poco_discovery') > 2)) {
+ logger("Fetch contacts from users of the server ".$server["nurl"], LOGGER_DEBUG);
+ self::discoverServerUsers($data, $server);
+ }
+ }
+
+ q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
+
+ return true;
+ } else {
+ // If the server hadn't replied correctly, then force a sanity check
+ self::checkServer($server["url"], $server["network"], true);
+
+ // If we couldn't reach the server, we will try it some time later
+ q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
+
+ return false;
+ }
+ }
+
+ public static function discover($complete = false)
+ {
+ // Update the server list
+ self::discoverFederation();
+
+ $no_of_queries = 5;
+
+ $requery_days = intval(Config::get("system", "poco_requery_days"));
+
+ if ($requery_days == 0) {
+ $requery_days = 7;
+ }
+ $last_update = date("c", time() - (60 * 60 * 24 * $requery_days));
+
+ $r = q("SELECT `id`, `url`, `network` FROM `gserver` WHERE `last_contact` >= `last_failure` AND `poco` != '' AND `last_poco_query` < '%s' ORDER BY RAND()", dbesc($last_update));
+ if (DBM::is_result($r)) {
+ foreach ($r as $server) {
+ if (!self::checkServer($server["url"], $server["network"])) {
+ // The server is not reachable? Okay, then we will try it later
+ q("UPDATE `gserver` SET `last_poco_query` = '%s' WHERE `nurl` = '%s'", dbesc(datetime_convert()), dbesc($server["nurl"]));
+ continue;
+ }
+
+ logger('Update directory from server '.$server['url'].' with ID '.$server['id'], LOGGER_DEBUG);
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "update_server_directory", (int)$server['id']);
+
+ if (!$complete && (--$no_of_queries == 0)) {
+ break;
+ }
+ }
+ }
+ }
+
+ public static function discoverServerUsers($data, $server)
+ {
+ if (!isset($data->entry)) {
+ return;
+ }
+
+ foreach ($data->entry as $entry) {
+ $username = "";
+ if (isset($entry->urls)) {
+ foreach ($entry->urls as $url) {
+ if ($url->type == 'profile') {
+ $profile_url = $url->value;
+ $urlparts = parse_url($profile_url);
+ $username = end(explode("/", $urlparts["path"]));
+ }
+ }
+ }
+ if ($username != "") {
+ logger("Fetch contacts for the user ".$username." from the server ".$server["nurl"], LOGGER_DEBUG);
+
+ // Fetch all contacts from a given user from the other server
+ $url = $server["poco"]."/".$username."/?fields=displayName,urls,photos,updated,network,aboutMe,currentLocation,tags,gender,contactType,generation";
+
+ $retdata = z_fetch_url($url);
+ if ($retdata["success"]) {
+ self::discoverServer(json_decode($retdata["body"]), 3);
+ }
+ }
+ }
+ }
+
+ public static function discoverServer($data, $default_generation = 0)
+ {
+ if (!isset($data->entry) || !count($data->entry)) {
+ return false;
+ }
+
+ $success = false;
+
+ foreach ($data->entry as $entry) {
+ $profile_url = '';
+ $profile_photo = '';
+ $connect_url = '';
+ $name = '';
+ $network = '';
+ $updated = NULL_DATE;
+ $location = '';
+ $about = '';
+ $keywords = '';
+ $gender = '';
+ $contact_type = -1;
+ $generation = $default_generation;
+
+ $name = $entry->displayName;
+
+ if (isset($entry->urls)) {
+ foreach ($entry->urls as $url) {
+ if ($url->type == 'profile') {
+ $profile_url = $url->value;
+ continue;
+ }
+ if ($url->type == 'webfinger') {
+ $connect_url = str_replace('acct:' , '', $url->value);
+ continue;
+ }
+ }
+ }
+
+ if (isset($entry->photos)) {
+ foreach ($entry->photos as $photo) {
+ if ($photo->type == 'profile') {
+ $profile_photo = $photo->value;
+ continue;
+ }
+ }
+ }
+
+ if (isset($entry->updated)) {
+ $updated = date("Y-m-d H:i:s", strtotime($entry->updated));
+ }
+
+ if (isset($entry->network)) {
+ $network = $entry->network;
+ }
+
+ if (isset($entry->currentLocation)) {
+ $location = $entry->currentLocation;
+ }
+
+ if (isset($entry->aboutMe)) {
+ $about = html2bbcode($entry->aboutMe);
+ }
+
+ if (isset($entry->gender)) {
+ $gender = $entry->gender;
+ }
+
+ if (isset($entry->generation) && ($entry->generation > 0)) {
+ $generation = ++$entry->generation;
+ }
+
+ if (isset($entry->contactType) && ($entry->contactType >= 0)) {
+ $contact_type = $entry->contactType;
+ }
+
+ if (isset($entry->tags)) {
+ foreach ($entry->tags as $tag) {
+ $keywords = implode(", ", $tag);
+ }
+ }
+
+ if ($generation > 0) {
+ $success = true;
+
+ logger("Store profile ".$profile_url, LOGGER_DEBUG);
+
+ $gcontact = array("url" => $profile_url,
+ "name" => $name,
+ "network" => $network,
+ "photo" => $profile_photo,
+ "about" => $about,
+ "location" => $location,
+ "gender" => $gender,
+ "keywords" => $keywords,
+ "connect" => $connect_url,
+ "updated" => $updated,
+ "contact-type" => $contact_type,
+ "generation" => $generation);
+
+ try {
+ $gcontact = GlobalContact::sanitize($gcontact);
+ GlobalContact::update($gcontact);
+ } catch (Exception $e) {
+ logger($e->getMessage(), LOGGER_DEBUG);
+ }
+
+ logger("Done for profile ".$profile_url, LOGGER_DEBUG);
+ }
+ }
+ return $success;
+ }
+
+}
--- /dev/null
+<?php\r
+/**\r
+ * @file src/Render/ITemplateEngine.php\r
+ */\r
+\r
+namespace Friendica\Render;\r
+\r
+/**\r
+ * Interface for template engines\r
+ */\r
+interface ITemplateEngine\r
+{\r
+ public function replaceMacros($s, $v);\r
+ public function getTemplateFile($file, $root = '');\r
+}\r
--- /dev/null
+<?php
+/**
+ * @file src/Util/Emailer.php
+ */
+namespace Friendica\Util;
+
+use Friendica\Core\PConfig;
+
+require_once 'include/email.php';
+
+/**
+ * @breif class to handle emailing
+ */
+class Emailer
+{
+ /**
+ * Send a multipart/alternative message with Text and HTML versions
+ *
+ * @param array $params parameters
+ * fromName name of the sender
+ * fromEmail email fo the sender
+ * replyTo replyTo address to direct responses
+ * toEmail destination email address
+ * messageSubject subject of the message
+ * htmlVersion html version of the message
+ * textVersion text only version of the message
+ * additionalMailHeader additions to the smtp mail header
+ * optional uid user id of the destination user
+ *
+ * @return object
+ */
+ public static function send($params)
+ {
+ call_hooks('emailer_send_prepare', $params);
+
+ $email_textonly = false;
+ if (x($params, "uid")) {
+ $email_textonly = PConfig::get($params['uid'], "system", "email_textonly");
+ }
+
+ $fromName = email_header_encode(html_entity_decode($params['fromName'], ENT_QUOTES, 'UTF-8'), 'UTF-8');
+ $messageSubject = email_header_encode(html_entity_decode($params['messageSubject'], ENT_QUOTES, 'UTF-8'), 'UTF-8');
+
+ // generate a mime boundary
+ $mimeBoundary =rand(0, 9)."-"
+ .rand(100000000, 999999999)."-"
+ .rand(100000000, 999999999)."=:"
+ .rand(10000, 99999);
+
+ // generate a multipart/alternative message header
+ $messageHeader = $params['additionalMailHeader'] .
+ "From: $fromName <{$params['fromEmail']}>\n" .
+ "Reply-To: $fromName <{$params['replyTo']}>\n" .
+ "MIME-Version: 1.0\n" .
+ "Content-Type: multipart/alternative; boundary=\"{$mimeBoundary}\"";
+
+ // assemble the final multipart message body with the text and html types included
+ $textBody = chunk_split(base64_encode($params['textVersion']));
+ $htmlBody = chunk_split(base64_encode($params['htmlVersion']));
+ $multipartMessageBody = "--" . $mimeBoundary . "\n" . // plain text section
+ "Content-Type: text/plain; charset=UTF-8\n" .
+ "Content-Transfer-Encoding: base64\n\n" .
+ $textBody . "\n";
+
+ if (!$email_textonly && !is_null($params['htmlVersion'])) {
+ $multipartMessageBody .=
+ "--" . $mimeBoundary . "\n" . // text/html section
+ "Content-Type: text/html; charset=UTF-8\n" .
+ "Content-Transfer-Encoding: base64\n\n" .
+ $htmlBody . "\n";
+ }
+ $multipartMessageBody .=
+ "--" . $mimeBoundary . "--\n"; // message ending
+
+ // send the message
+ $hookdata = array(
+ 'to' => $params['toEmail'],
+ 'subject' => $messageSubject,
+ 'body' => $multipartMessageBody,
+ 'headers' => $messageHeader
+ );
+ //echo "<pre>"; var_dump($hookdata); killme();
+ call_hooks("emailer_send", $hookdata);
+ $res = mail(
+ $hookdata['to'], // send to address
+ $hookdata['subject'], // subject
+ $hookdata['body'], // message body
+ $hookdata['headers'] // message headers
+ );
+ logger("header " . 'To: ' . $params['toEmail'] . "\n" . $messageHeader, LOGGER_DEBUG);
+ logger("return value " . (($res)?"true":"false"), LOGGER_DEBUG);
+ return $res;
+ }
+}
--- /dev/null
+<?php\r
+\r
+/*\r
+ * ejabberd extauth script for the integration with friendica\r
+ *\r
+ * Originally written for joomla by Dalibor Karlovic <dado@krizevci.info>\r
+ * modified for Friendica by Michael Vogel <icarus@dabo.de>\r
+ * published under GPL\r
+ *\r
+ * Latest version of the original script for joomla is available at:\r
+ * http://87.230.15.86/~dado/ejabberd/joomla-login\r
+ *\r
+ * Installation:\r
+ *\r
+ * - Change it's owner to whichever user is running the server, ie. ejabberd\r
+ * $ chown ejabberd:ejabberd /path/to/friendica/scripts/auth_ejabberd.php\r
+ *\r
+ * - Change the access mode so it is readable only to the user ejabberd and has exec\r
+ * $ chmod 700 /path/to/friendica/scripts/auth_ejabberd.php\r
+ *\r
+ * - Edit your ejabberd.cfg file, comment out your auth_method and add:\r
+ * {auth_method, external}.\r
+ * {extauth_program, "/path/to/friendica/script/auth_ejabberd.php"}.\r
+ *\r
+ * - Restart your ejabberd service, you should be able to login with your friendica auth info\r
+ *\r
+ * Other hints:\r
+ * - if your users have a space or a @ in their nickname, they'll run into trouble\r
+ * registering with any client so they should be instructed to replace these chars\r
+ * " " (space) is replaced with "%20"\r
+ * "@" is replaced with "(a)"\r
+ *\r
+ */\r
+\r
+namespace Friendica\Util;\r
+\r
+use Friendica\Core\Config;\r
+use Friendica\Core\PConfig;\r
+use Friendica\Database\DBM;\r
+use Friendica\Model\User;\r
+use dba;\r
+\r
+require_once 'include/dba.php';\r
+\r
+class ExAuth\r
+{\r
+ private $bDebug;\r
+\r
+ /**\r
+ * @brief Create the class\r
+ *\r
+ * @param boolean $bDebug Debug mode\r
+ */\r
+ public function __construct()\r
+ {\r
+ $this->bDebug = (int) Config::get('jabber', 'debug');\r
+\r
+ openlog('auth_ejabberd', LOG_PID, LOG_USER);\r
+\r
+ $this->writeLog(LOG_NOTICE, 'start');\r
+ }\r
+\r
+ /**\r
+ * @brief Standard input reading function, executes the auth with the provided\r
+ * parameters\r
+ *\r
+ * @return null\r
+ */\r
+ public function readStdin()\r
+ {\r
+ while (!feof(STDIN)) {\r
+ // Quit if the database connection went down\r
+ if (!dba::connected()) {\r
+ $this->writeLog(LOG_ERR, 'the database connection went down');\r
+ return;\r
+ }\r
+\r
+ $iHeader = fgets(STDIN, 3);\r
+ $aLength = unpack('n', $iHeader);\r
+ $iLength = $aLength['1'];\r
+\r
+ // No data? Then quit\r
+ if ($iLength == 0) {\r
+ $this->writeLog(LOG_ERR, 'we got no data, quitting');\r
+ return;\r
+ }\r
+\r
+ // Fetching the data\r
+ $sData = fgets(STDIN, $iLength + 1);\r
+ $this->writeLog(LOG_DEBUG, 'received data: ' . $sData);\r
+ $aCommand = explode(':', $sData);\r
+ if (is_array($aCommand)) {\r
+ switch ($aCommand[0]) {\r
+ case 'isuser':\r
+ // Check the existance of a given username\r
+ $this->isUser($aCommand);\r
+ break;\r
+ case 'auth':\r
+ // Check if the givven password is correct\r
+ $this->auth($aCommand);\r
+ break;\r
+ case 'setpass':\r
+ // We don't accept the setting of passwords here\r
+ $this->writeLog(LOG_NOTICE, 'setpass command disabled');\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ break;\r
+ default:\r
+ // We don't know the given command\r
+ $this->writeLog(LOG_NOTICE, 'unknown command ' . $aCommand[0]);\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ break;\r
+ }\r
+ } else {\r
+ $this->writeLog(LOG_NOTICE, 'invalid command string ' . $sData);\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ }\r
+ }\r
+ }\r
+\r
+ /**\r
+ * @brief Check if the given username exists\r
+ *\r
+ * @param array $aCommand The command array\r
+ */\r
+ private function isUser(array $aCommand)\r
+ {\r
+ $a = get_app();\r
+\r
+ // Check if there is a username\r
+ if (!isset($aCommand[1])) {\r
+ $this->writeLog(LOG_NOTICE, 'invalid isuser command, no username given');\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ return;\r
+ }\r
+\r
+ // Now we check if the given user is valid\r
+ $sUser = str_replace(array('%20', '(a)'), array(' ', '@'), $aCommand[1]);\r
+\r
+ // Does the hostname match? So we try directly\r
+ if ($a->get_hostname() == $aCommand[2]) {\r
+ $this->writeLog(LOG_INFO, 'internal user check for ' . $sUser . '@' . $aCommand[2]);\r
+ $found = dba::exists('user', ['nickname' => $sUser]);\r
+ } else {\r
+ $found = false;\r
+ }\r
+\r
+ // If the hostnames doesn't match or there is some failure, we try to check remotely\r
+ if (!$found) {\r
+ $found = $this->checkUser($aCommand[2], $aCommand[1], true);\r
+ }\r
+\r
+ if ($found) {\r
+ // The user is okay\r
+ $this->writeLog(LOG_NOTICE, 'valid user: ' . $sUser);\r
+ fwrite(STDOUT, pack('nn', 2, 1));\r
+ } else {\r
+ // The user isn't okay\r
+ $this->writeLog(LOG_WARNING, 'invalid user: ' . $sUser);\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ }\r
+ }\r
+\r
+ /**\r
+ * @brief Check remote user existance via HTTP(S)\r
+ *\r
+ * @param string $host The hostname\r
+ * @param string $user Username\r
+ * @param boolean $ssl Should the check be done via SSL?\r
+ *\r
+ * @return boolean Was the user found?\r
+ */\r
+ private function checkUser($host, $user, $ssl)\r
+ {\r
+ $this->writeLog(LOG_INFO, 'external user check for ' . $user . '@' . $host);\r
+\r
+ $url = ($ssl ? 'https' : 'http') . '://' . $host . '/noscrape/' . $user;\r
+\r
+ $data = z_fetch_url($url);\r
+\r
+ if (!is_array($data)) {\r
+ return false;\r
+ }\r
+\r
+ if ($data['return_code'] != '200') {\r
+ return false;\r
+ }\r
+\r
+ $json = @json_decode($data['body']);\r
+ if (!is_object($json)) {\r
+ return false;\r
+ }\r
+\r
+ return $json->nick == $user;\r
+ }\r
+\r
+ /**\r
+ * @brief Authenticate the given user and password\r
+ *\r
+ * @param array $aCommand The command array\r
+ */\r
+ private function auth(array $aCommand)\r
+ {\r
+ $a = get_app();\r
+\r
+ // check user authentication\r
+ if (sizeof($aCommand) != 4) {\r
+ $this->writeLog(LOG_NOTICE, 'invalid auth command, data missing');\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ return;\r
+ }\r
+\r
+ // We now check if the password match\r
+ $sUser = str_replace(array('%20', '(a)'), array(' ', '@'), $aCommand[1]);\r
+\r
+ // Does the hostname match? So we try directly\r
+ if ($a->get_hostname() == $aCommand[2]) {\r
+ $this->writeLog(LOG_INFO, 'internal auth for ' . $sUser . '@' . $aCommand[2]);\r
+\r
+ $aUser = dba::select('user', ['uid', 'password'], ['nickname' => $sUser], ['limit' => 1]);\r
+ if (DBM::is_result($aUser)) {\r
+ $uid = User::authenticate($aUser, $aCommand[3]);\r
+ $Error = $uid === false;\r
+ } else {\r
+ $this->writeLog(LOG_WARNING, 'user not found: ' . $sUser);\r
+ $Error = true;\r
+ $uid = -1;\r
+ }\r
+ if ($Error) {\r
+ $this->writeLog(LOG_INFO, 'check against alternate password for ' . $sUser . '@' . $aCommand[2]);\r
+ $sPassword = PConfig::get($uid, 'xmpp', 'password', null, true);\r
+ $Error = ($aCommand[3] != $sPassword);\r
+ }\r
+ } else {\r
+ $Error = true;\r
+ }\r
+\r
+ // If the hostnames doesn't match or there is some failure, we try to check remotely\r
+ if ($Error) {\r
+ $Error = !$this->checkCredentials($aCommand[2], $aCommand[1], $aCommand[3], true);\r
+ }\r
+\r
+ if ($Error) {\r
+ $this->writeLog(LOG_WARNING, 'authentification failed for user ' . $sUser . '@' . $aCommand[2]);\r
+ fwrite(STDOUT, pack('nn', 2, 0));\r
+ } else {\r
+ $this->writeLog(LOG_NOTICE, 'authentificated user ' . $sUser . '@' . $aCommand[2]);\r
+ fwrite(STDOUT, pack('nn', 2, 1));\r
+ }\r
+ }\r
+\r
+ /**\r
+ * @brief Check remote credentials via HTTP(S)\r
+ *\r
+ * @param string $host The hostname\r
+ * @param string $user Username\r
+ * @param string $password Password\r
+ * @param boolean $ssl Should the check be done via SSL?\r
+ *\r
+ * @return boolean Are the credentials okay?\r
+ */\r
+ private function checkCredentials($host, $user, $password, $ssl)\r
+ {\r
+ $url = ($ssl ? 'https' : 'http') . '://' . $host . '/api/account/verify_credentials.json';\r
+\r
+ $ch = curl_init();\r
+ curl_setopt($ch, CURLOPT_URL, $url);\r
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\r
+ curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5);\r
+ curl_setopt($ch, CURLOPT_HEADER, true);\r
+ curl_setopt($ch, CURLOPT_NOBODY, true);\r
+ curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);\r
+ curl_setopt($ch, CURLOPT_USERPWD, $user . ':' . $password);\r
+\r
+ curl_exec($ch);\r
+ $curl_info = @curl_getinfo($ch);\r
+ $http_code = $curl_info['http_code'];\r
+ curl_close($ch);\r
+\r
+ $this->writeLog(LOG_INFO, 'external auth for ' . $user . '@' . $host . ' returned ' . $http_code);\r
+\r
+ return $http_code == 200;\r
+ }\r
+\r
+ /**\r
+ * @brief write data to the syslog\r
+ *\r
+ * @param integer $loglevel The syslog loglevel\r
+ * @param string $sMessage The syslog message\r
+ */\r
+ private function writeLog($loglevel, $sMessage)\r
+ {\r
+ if (!$this->bDebug && ($loglevel >= LOG_DEBUG)) {\r
+ return;\r
+ }\r
+ syslog($loglevel, $sMessage);\r
+ }\r
+\r
+ /**\r
+ * @brief destroy the class, close the syslog connection.\r
+ */\r
+ public function __destruct()\r
+ {\r
+ $this->writeLog(LOG_NOTICE, 'stop');\r
+ closelog();\r
+ }\r
+}\r
<?php
-
+/**
+ * @file src/Util/Lock.php
+ */
namespace Friendica\Util;
/**
* @file src/Util/Lock.php
* @brief Functions for preventing parallel execution of functions
- *
*/
use Friendica\Core\Config;
/**
* @brief This class contain Functions for preventing parallel execution of functions
*/
-class Lock {
+class Lock
+{
private static $semaphore = array();
/**
*
* @return object|boolean The memcache object - or "false" if not successful
*/
- private static function connectMemcache() {
+ private static function connectMemcache()
+ {
if (!function_exists('memcache_connect')) {
return false;
}
*
* @return ressource the semaphore key
*/
- private static function semaphoreKey($fn_name) {
+ private static function semaphoreKey($fn_name)
+ {
$temp = get_temppath();
$file = $temp.'/'.$fn_name.'.sem';
/**
* @brief Sets a lock for a given name
*
- * @param string $fn_name Name of the lock
+ * @param string $fn_name Name of the lock
* @param integer $timeout Seconds until we give up
*
* @return boolean Was the lock successful?
*/
- public static function set($fn_name, $timeout = 120) {
+ public static function set($fn_name, $timeout = 120)
+ {
$got_lock = false;
$start = time();
* @brief Removes a lock if it was set by us
*
* @param string $fn_name Name of the lock
+ * @return mixed
*/
- public static function remove($fn_name) {
+ public static function remove($fn_name)
+ {
if (function_exists('sem_get') && version_compare(PHP_VERSION, '5.6.1', '>=')) {
if (empty(self::$semaphore[$fn_name])) {
return false;
/**
* @brief Removes all lock that were set by us
+ * @return void
*/
- public static function removeAll() {
+ public static function removeAll()
+ {
$memcache = self::connectMemcache();
if (is_object($memcache)) {
// We cannot delete all cache entries, but this doesn't matter with memcache
<?php
-
/**
* @file src/Util/XML.php
*/
*
* @return string The created XML
*/
- public static function from_array($array, &$xml, $remove_header = false, $namespaces = array(), $root = true)
+ public static function fromArray($array, &$xml, $remove_header = false, $namespaces = array(), $root = true)
{
if ($root) {
foreach ($array as $key => $value) {
if (is_array($value)) {
$root = new SimpleXMLElement("<".$key."/>");
- self::from_array($value, $root, $remove_header, $namespaces, false);
+ self::fromArray($value, $root, $remove_header, $namespaces, false);
} else {
$root = new SimpleXMLElement("<".$key.">".xmlify($value)."</".$key.">");
}
$element = $xml->addChild($key, xmlify($value), $namespace);
} elseif (is_array($value)) {
$element = $xml->addChild($key, null, $namespace);
- self::from_array($value, $element, $remove_header, $namespaces, false);
+ self::fromArray($value, $element, $remove_header, $namespaces, false);
}
}
}
* @param object $source The XML source
* @param object $target The XML target
* @param string $elementname Name of the XML element of the target
+ * @return void
*/
public static function copy(&$source, &$target, $elementname)
{
*
* @return object XML element object
*/
- public static function create_element($doc, $element, $value = "", $attributes = array())
+ public static function createElement($doc, $element, $value = "", $attributes = array())
{
$element = $doc->createElement($element, xmlify($value));
* @param string $element XML element name
* @param string $value XML value
* @param array $attributes array containing the attributes
+ * @return void
*/
- public static function add_element($doc, $parent, $element, $value = "", $attributes = array())
+ public static function addElement($doc, $parent, $element, $value = "", $attributes = array())
{
- $element = self::create_element($doc, $element, $value, $attributes);
+ $element = self::createElement($doc, $element, $value, $attributes);
$parent->appendChild($element);
}
*
* @return array | sring The array from the xml element or the string
*/
- public static function element_to_array($xml_element, &$recursion_depth=0)
+ public static function elementToArray($xml_element, &$recursion_depth = 0)
{
// If we're getting too deep, bail out
if ($recursion_depth > 512) {
foreach ($xml_element as $key => $value) {
$recursion_depth++;
- $result_array[strtolower($key)] = self::element_to_array($value, $recursion_depth);
+ $result_array[strtolower($key)] = self::elementToArray($value, $recursion_depth);
$recursion_depth--;
}
/**
* @brief Convert the given XML text to an array in the XML structure.
*
- * Xml::to_array() will convert the given XML text to an array in the XML structure.
+ * Xml::toArray() will convert the given XML text to an array in the XML structure.
* Link: http://www.bin-co.com/php/scripts/xml2array/
* Portions significantly re-written by mike@macgirvin.com for Friendica
* (namespaces, lowercase tags, get_attribute default changed, more...)
*
- * Examples: $array = Xml::to_array(file_get_contents('feed.xml'));
- * $array = Xml::to_array(file_get_contents('feed.xml', true, 1, 'attribute'));
+ * Examples: $array = Xml::toArray(file_get_contents('feed.xml'));
+ * $array = Xml::toArray(file_get_contents('feed.xml', true, 1, 'attribute'));
*
* @param object $contents The XML text
* @param boolean $namespaces True or false include namespace information
*
* @return array The parsed XML in an array form. Use print_r() to see the resulting array structure.
*/
- public static function to_array($contents, $namespaces = true, $get_attributes = 1, $priority = 'attribute')
+ public static function toArray($contents, $namespaces = true, $get_attributes = 1, $priority = 'attribute')
{
if (!$contents) {
return array();
}
if (!function_exists('xml_parser_create')) {
- logger('Xml::to_array: parser function missing');
+ logger('Xml::toArray: parser function missing');
return array();
}
}
if (! $parser) {
- logger('Xml::to_array: xml_parser_create: no resource');
+ logger('Xml::toArray: xml_parser_create: no resource');
return array();
}
@xml_parser_free($parser);
if (! $xml_values) {
- logger('Xml::to_array: libxml: parse error: ' . $contents, LOGGER_DATA);
+ logger('Xml::toArray: libxml: parse error: ' . $contents, LOGGER_DATA);
foreach (libxml_get_errors() as $err) {
logger('libxml: parse: ' . $err->code . " at " . $err->line . ":" . $err->column . " : " . $err->message, LOGGER_DATA);
}
*
* @param object $doc XML document
* @param string $node Node name
+ * @return void
*/
public static function deleteNode(&$doc, $node)
{
--- /dev/null
+<?php
+
+/**
+ * @file src/Worker/CheckVersion.php
+ *
+ * @brief save Friendica upstream version to the DB
+ **/
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+
+/**
+ * @brief check the git repository VERSION file and save the version to the DB
+ *
+ * Checking the upstream version is optional (opt-in) and can be done to either
+ * the master or the develop branch in the repository.
+ */
+class CheckVersion {
+ public static function execute() {
+ global $a;
+
+ logger('checkversion: start');
+
+ $checkurl = Config::get('system', 'check_new_version_url', 'none');
+
+ switch ($checkurl) {
+ case 'master':
+ $checked_url = 'https://raw.githubusercontent.com/friendica/friendica/master/VERSION';
+ break;
+ case 'develop':
+ $checked_url = 'https://raw.githubusercontent.com/friendica/friendica/develop/VERSION';
+ break;
+ default:
+ // don't check
+ return;
+ }
+ logger("Checking VERSION from: ".$checked_url, LOGGER_DEBUG);
+
+ // fetch the VERSION file
+ $gitversion = dbesc(trim(fetch_url($checked_url)));
+ logger("Upstream VERSION is: ".$gitversion, LOGGER_DEBUG);
+
+ Config::set('system', 'git_friendica_version', $gitversion);
+
+ logger('checkversion: end');
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/CreateShadowEntry.php
+ * @brief This script creates posts with UID = 0 for a given public post.
+ *
+ * This script is started from mod/item.php to save some time when doing a post.
+ */
+
+namespace Friendica\Worker;
+
+require_once("include/threads.php");
+
+class CreateShadowEntry {
+ public static function execute($message_id = 0) {
+ if (empty($message_id)) {
+ return;
+ }
+
+ add_shadow_entry($message_id);
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/Cron.php
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use dba;
+
+Class Cron {
+ public static function execute($parameter = '', $generation = 0) {
+ global $a;
+
+ require_once 'include/datetime.php';
+
+ // Poll contacts with specific parameters
+ if (!empty($parameter)) {
+ self::pollContacts($parameter, $generation);
+ return;
+ }
+
+ $last = Config::get('system', 'last_cron');
+
+ $poll_interval = intval(Config::get('system', 'cron_interval'));
+ if (! $poll_interval) {
+ $poll_interval = 10;
+ }
+
+ if ($last) {
+ $next = $last + ($poll_interval * 60);
+ if ($next > time()) {
+ logger('cron intervall not reached');
+ return;
+ }
+ }
+
+ logger('cron: start');
+
+ // run queue delivery process in the background
+ Worker::add(PRIORITY_NEGLIGIBLE, "Queue");
+
+ // run the process to discover global contacts in the background
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo");
+
+ // run the process to update locally stored global contacts in the background
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "checkcontact");
+
+ // Expire and remove user entries
+ Worker::add(PRIORITY_MEDIUM, "CronJobs", "expire_and_remove_users");
+
+ // Call possible post update functions
+ Worker::add(PRIORITY_LOW, "CronJobs", "post_update");
+
+ // update nodeinfo data
+ Worker::add(PRIORITY_LOW, "CronJobs", "nodeinfo");
+
+ // Clear cache entries
+ Worker::add(PRIORITY_LOW, "CronJobs", "clear_cache");
+
+ // Repair missing Diaspora values in contacts
+ Worker::add(PRIORITY_LOW, "CronJobs", "repair_diaspora");
+
+ // Repair entries in the database
+ Worker::add(PRIORITY_LOW, "CronJobs", "repair_database");
+
+ // once daily run birthday_updates and then expire in background
+ $d1 = Config::get('system', 'last_expire_day');
+ $d2 = intval(datetime_convert('UTC', 'UTC', 'now', 'd'));
+
+ if ($d2 != intval($d1)) {
+
+ Worker::add(PRIORITY_LOW, "CronJobs", "update_contact_birthdays");
+
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "update_server");
+
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "suggestions");
+
+ Config::set('system', 'last_expire_day', $d2);
+
+ Worker::add(PRIORITY_LOW, 'Expire');
+
+ Worker::add(PRIORITY_MEDIUM, 'DBClean');
+
+ Worker::add(PRIORITY_LOW, "CronJobs", "update_photo_albums");
+
+ // Delete all done workerqueue entries
+ dba::delete('workerqueue', array('`done` AND `executed` < UTC_TIMESTAMP() - INTERVAL 12 HOUR'));
+
+ // check upstream version?
+ Worker::add(PRIORITY_LOW, 'CheckVersion');
+ }
+
+ // Poll contacts
+ self::pollContacts($parameter, $generation);
+
+ logger('cron: end');
+
+ Config::set('system', 'last_cron', time());
+
+ return;
+ }
+
+ /**
+ * @brief Poll contacts for unreceived messages
+ *
+ * @todo Currently it seems as if the following parameter aren't used at all ...
+ *
+ * @param string $parameter Parameter (force, restart, ...) for the contact polling
+ * @param integer $generation
+ */
+ private static function pollContacts($parameter, $generation) {
+ $manual_id = 0;
+ $generation = 0;
+ $force = false;
+ $restart = false;
+
+ if ($parameter == 'force') {
+ $force = true;
+ }
+ if ($parameter == 'restart') {
+ $restart = true;
+ $generation = intval($generation);
+ if (!$generation) {
+ killme();
+ }
+ }
+
+ if (intval($parameter)) {
+ $manual_id = intval($parameter);
+ $force = true;
+ }
+
+ $min_poll_interval = Config::get('system', 'min_poll_interval', 1);
+
+ $sql_extra = (($manual_id) ? " AND `id` = $manual_id " : "");
+
+ reload_plugins();
+
+ $d = datetime_convert();
+
+ // Only poll from those with suitable relationships,
+ // and which have a polling address and ignore Diaspora since
+ // we are unable to match those posts with a Diaspora GUID and prevent duplicates.
+
+ $abandon_days = intval(Config::get('system', 'account_abandon_days'));
+ if ($abandon_days < 1) {
+ $abandon_days = 0;
+ }
+ $abandon_sql = (($abandon_days)
+ ? sprintf(" AND `user`.`login_date` > UTC_TIMESTAMP() - INTERVAL %d DAY ", intval($abandon_days))
+ : ''
+ );
+
+ $contacts = q("SELECT `contact`.`id` FROM `user`
+ STRAIGHT_JOIN `contact`
+ ON `contact`.`uid` = `user`.`uid` AND `contact`.`rel` IN (%d, %d) AND `contact`.`poll` != ''
+ AND `contact`.`network` IN ('%s', '%s', '%s', '%s', '%s', '%s') $sql_extra
+ AND NOT `contact`.`self` AND NOT `contact`.`blocked` AND NOT `contact`.`readonly`
+ AND NOT `contact`.`archive`
+ WHERE NOT `user`.`account_expired` AND NOT `user`.`account_removed` $abandon_sql ORDER BY RAND()",
+ intval(CONTACT_IS_SHARING),
+ intval(CONTACT_IS_FRIEND),
+ dbesc(NETWORK_DFRN),
+ dbesc(NETWORK_ZOT),
+ dbesc(NETWORK_OSTATUS),
+ dbesc(NETWORK_FEED),
+ dbesc(NETWORK_MAIL),
+ dbesc(NETWORK_MAIL2)
+ );
+
+ if (!DBM::is_result($contacts)) {
+ return;
+ }
+
+ foreach ($contacts as $c) {
+
+ $res = q("SELECT * FROM `contact` WHERE `id` = %d LIMIT 1",
+ intval($c['id'])
+ );
+
+ if (!DBM::is_result($res)) {
+ continue;
+ }
+
+ foreach ($res as $contact) {
+
+ $xml = false;
+
+ if ($manual_id) {
+ $contact['last-update'] = NULL_DATE;
+ }
+
+ if (in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
+ $contact['priority'] = 2;
+ }
+
+ if ($contact['subhub'] && in_array($contact['network'], array(NETWORK_DFRN, NETWORK_ZOT, NETWORK_OSTATUS))) {
+ /*
+ * We should be getting everything via a hub. But just to be sure, let's check once a day.
+ * (You can make this more or less frequent if desired by setting 'pushpoll_frequency' appropriately)
+ * This also lets us update our subscription to the hub, and add or replace hubs in case it
+ * changed. We will only update hubs once a day, regardless of 'pushpoll_frequency'.
+ */
+ $poll_interval = Config::get('system', 'pushpoll_frequency');
+ $contact['priority'] = (($poll_interval !== false) ? intval($poll_interval) : 3);
+ }
+
+ if (($contact['priority'] >= 0) && !$force) {
+ $update = false;
+
+ $t = $contact['last-update'];
+
+ /*
+ * Based on $contact['priority'], should we poll this site now? Or later?
+ */
+ switch ($contact['priority']) {
+ case 5:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 month")) {
+ $update = true;
+ }
+ break;
+ case 4:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 week")) {
+ $update = true;
+ }
+ break;
+ case 3:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day")) {
+ $update = true;
+ }
+ break;
+ case 2:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 12 hour")) {
+ $update = true;
+ }
+ break;
+ case 1:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 hour")) {
+ $update = true;
+ }
+ break;
+ case 0:
+ default:
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + ".$min_poll_interval." minute")) {
+ $update = true;
+ }
+ break;
+ }
+ if (!$update) {
+ continue;
+ }
+ }
+
+ logger("Polling " . $contact["network"] . " " . $contact["id"] . " " . $contact["nick"] . " " . $contact["name"]);
+
+ if (($contact['network'] == NETWORK_FEED) && ($contact['priority'] <= 3)) {
+ $priority = PRIORITY_MEDIUM;
+ } else {
+ $priority = PRIORITY_LOW;
+ }
+ Worker::add(array('priority' => $priority, 'dont_fork' => true), 'OnePoll', (int)$contact['id']);
+ }
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/CronHooks.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+
+Class CronHooks {
+ public static function execute($hook = '') {
+ global $a;
+
+ require_once 'include/datetime.php';
+
+ if (($hook != '') && is_array($a->hooks) && array_key_exists("cron", $a->hooks)) {
+ foreach ($a->hooks["cron"] as $single_hook) {
+ if ($single_hook[1] == $hook) {
+ logger("Calling cron hook '" . $hook . "'", LOGGER_DEBUG);
+ call_single_hook($a, $name, $single_hook, $data);
+ }
+ }
+ return;
+ }
+
+ $last = Config::get('system', 'last_cronhook');
+
+ $poll_interval = intval(Config::get('system', 'cronhook_interval'));
+ if (!$poll_interval) {
+ $poll_interval = 9;
+ }
+
+ if ($last) {
+ $next = $last + ($poll_interval * 60);
+ if ($next > time()) {
+ logger('cronhook intervall not reached');
+ return;
+ }
+ }
+
+ $a->set_baseurl(Config::get('system', 'url'));
+
+ logger('cronhooks: start');
+
+ $d = datetime_convert();
+
+ if (is_array($a->hooks) && array_key_exists("cron", $a->hooks)) {
+ foreach ($a->hooks["cron"] as $hook) {
+ logger("Calling cronhooks for '" . $hook[1] . "'", LOGGER_DEBUG);
+ Worker::add(PRIORITY_MEDIUM, "CronHooks", $hook[1]);
+ }
+ }
+
+ logger('cronhooks: end');
+
+ Config::set('system', 'last_cronhook', time());
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/worker/CronJobs.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\App;
+use Friendica\Core\Cache;
+use Friendica\Core\Config;
+use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Network\Probe;
+use Friendica\Protocol\PortableContact;
+use dba;
+
+class CronJobs {
+ public static function execute($command = ''){
+ global $a;
+
+ require_once 'include/datetime.php';
+ require_once 'include/post_update.php';
+ require_once 'mod/nodeinfo.php';
+ require_once 'include/photos.php';
+ require_once 'include/user.php';
+
+ // No parameter set? So return
+ if ($command == '') {
+ return;
+ }
+
+ logger("Starting cronjob ".$command, LOGGER_DEBUG);
+
+ // Call possible post update functions
+ // see include/post_update.php for more details
+ if ($command == 'post_update') {
+ post_update();
+ return;
+ }
+
+ // update nodeinfo data
+ if ($command == 'nodeinfo') {
+ nodeinfo_cron();
+ return;
+ }
+
+ // Expire and remove user entries
+ if ($command == 'expire_and_remove_users') {
+ self::expireAndRemoveUsers();
+ return;
+ }
+
+ if ($command == 'update_contact_birthdays') {
+ update_contact_birthdays();
+ return;
+ }
+
+ if ($command == 'update_photo_albums') {
+ self::updatePhotoAlbums();
+ return;
+ }
+
+ // Clear cache entries
+ if ($command == 'clear_cache') {
+ self::clearCache($a);
+ return;
+ }
+
+ // Repair missing Diaspora values in contacts
+ if ($command == 'repair_diaspora') {
+ self::repairDiaspora($a);
+ return;
+ }
+
+ // Repair entries in the database
+ if ($command == 'repair_database') {
+ self::repairDatabase();
+ return;
+ }
+
+ logger("Xronjob ".$command." is unknown.", LOGGER_DEBUG);
+
+ return;
+ }
+
+ /**
+ * @brief Update the cached values for the number of photo albums per user
+ */
+ private static function updatePhotoAlbums() {
+ $r = q("SELECT `uid` FROM `user` WHERE NOT `account_expired` AND NOT `account_removed`");
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ foreach ($r AS $user) {
+ photo_albums($user['uid'], true);
+ }
+ }
+
+ /**
+ * @brief Expire and remove user entries
+ */
+ private static function expireAndRemoveUsers() {
+ // expire any expired accounts
+ q("UPDATE user SET `account_expired` = 1 where `account_expired` = 0
+ AND `account_expires_on` > '%s'
+ AND `account_expires_on` < UTC_TIMESTAMP()", dbesc(NULL_DATE));
+
+ // delete user records for recently removed accounts
+ $r = q("SELECT * FROM `user` WHERE `account_removed` AND `account_expires_on` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
+ if (DBM::is_result($r)) {
+ foreach ($r as $user) {
+ dba::delete('user', array('uid' => $user['uid']));
+ }
+ }
+ }
+
+ /**
+ * @brief Clear cache entries
+ *
+ * @param App $a
+ */
+ private static function clearCache(App $a) {
+
+ $last = Config::get('system','cache_last_cleared');
+
+ if ($last) {
+ $next = $last + (3600); // Once per hour
+ $clear_cache = ($next <= time());
+ } else {
+ $clear_cache = true;
+ }
+
+ if (!$clear_cache) {
+ return;
+ }
+
+ // clear old cache
+ Cache::clear();
+
+ // clear old item cache files
+ clear_cache();
+
+ // clear cache for photos
+ clear_cache($a->get_basepath(), $a->get_basepath()."/photo");
+
+ // clear smarty cache
+ clear_cache($a->get_basepath()."/view/smarty3/compiled", $a->get_basepath()."/view/smarty3/compiled");
+
+ // clear cache for image proxy
+ if (!Config::get("system", "proxy_disabled")) {
+ clear_cache($a->get_basepath(), $a->get_basepath()."/proxy");
+
+ $cachetime = Config::get('system','proxy_cache_time');
+ if (!$cachetime) {
+ $cachetime = PROXY_DEFAULT_TIME;
+ }
+ $condition = array('`uid` = 0 AND `resource-id` LIKE "pic:%" AND `created` < NOW() - INTERVAL ? SECOND', $cachetime);
+ dba::delete('photo', $condition);
+ }
+
+ // Delete the cached OEmbed entries that are older than three month
+ dba::delete('oembed', array("`created` < NOW() - INTERVAL 3 MONTH"));
+
+ // Delete the cached "parse_url" entries that are older than three month
+ dba::delete('parsed_url', array("`created` < NOW() - INTERVAL 3 MONTH"));
+
+ // Maximum table size in megabyte
+ $max_tablesize = intval(Config::get('system','optimize_max_tablesize')) * 1000000;
+ if ($max_tablesize == 0) {
+ $max_tablesize = 100 * 1000000; // Default are 100 MB
+ }
+ if ($max_tablesize > 0) {
+ // Minimum fragmentation level in percent
+ $fragmentation_level = intval(Config::get('system','optimize_fragmentation')) / 100;
+ if ($fragmentation_level == 0) {
+ $fragmentation_level = 0.3; // Default value is 30%
+ }
+
+ // Optimize some tables that need to be optimized
+ $r = q("SHOW TABLE STATUS");
+ foreach ($r as $table) {
+
+ // Don't optimize tables that are too large
+ if ($table["Data_length"] > $max_tablesize) {
+ continue;
+ }
+
+ // Don't optimize empty tables
+ if ($table["Data_length"] == 0) {
+ continue;
+ }
+
+ // Calculate fragmentation
+ $fragmentation = $table["Data_free"] / ($table["Data_length"] + $table["Index_length"]);
+
+ logger("Table ".$table["Name"]." - Fragmentation level: ".round($fragmentation * 100, 2), LOGGER_DEBUG);
+
+ // Don't optimize tables that needn't to be optimized
+ if ($fragmentation < $fragmentation_level) {
+ continue;
+ }
+
+ // So optimize it
+ logger("Optimize Table ".$table["Name"], LOGGER_DEBUG);
+ q("OPTIMIZE TABLE `%s`", dbesc($table["Name"]));
+ }
+ }
+
+ Config::set('system','cache_last_cleared', time());
+ }
+
+ /**
+ * @brief Repair missing values in Diaspora contacts
+ *
+ * @param App $a
+ */
+ private static function repairDiaspora(App $a) {
+
+ $starttime = time();
+
+ $r = q("SELECT `id`, `url` FROM `contact`
+ WHERE `network` = '%s' AND (`batch` = '' OR `notify` = '' OR `poll` = '' OR pubkey = '')
+ ORDER BY RAND() LIMIT 50", dbesc(NETWORK_DIASPORA));
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ foreach ($r AS $contact) {
+ // Quit the loop after 3 minutes
+ if (time() > ($starttime + 180)) {
+ return;
+ }
+
+ if (!PortableContact::reachable($contact["url"])) {
+ continue;
+ }
+
+ $data = Probe::uri($contact["url"]);
+ if ($data["network"] != NETWORK_DIASPORA) {
+ continue;
+ }
+
+ logger("Repair contact ".$contact["id"]." ".$contact["url"], LOGGER_DEBUG);
+ q("UPDATE `contact` SET `batch` = '%s', `notify` = '%s', `poll` = '%s', pubkey = '%s' WHERE `id` = %d",
+ dbesc($data["batch"]), dbesc($data["notify"]), dbesc($data["poll"]), dbesc($data["pubkey"]),
+ intval($contact["id"]));
+ }
+ }
+
+ /**
+ * @brief Do some repairs in database entries
+ *
+ */
+ private static function repairDatabase() {
+
+ // Sometimes there seem to be issues where the "self" contact vanishes.
+ // We haven't found the origin of the problem by now.
+ $r = q("SELECT `uid` FROM `user` WHERE NOT EXISTS (SELECT `uid` FROM `contact` WHERE `contact`.`uid` = `user`.`uid` AND `contact`.`self`)");
+ if (DBM::is_result($r)) {
+ foreach ($r AS $user) {
+ logger('Create missing self contact for user '.$user['uid']);
+ user_create_self_contact($user['uid']);
+ }
+ }
+
+ // Set the parent if it wasn't set. (Shouldn't happen - but does sometimes)
+ // This call is very "cheap" so we can do it at any time without a problem
+ q("UPDATE `item` INNER JOIN `item` AS `parent` ON `parent`.`uri` = `item`.`parent-uri` AND `parent`.`uid` = `item`.`uid` SET `item`.`parent` = `parent`.`id` WHERE `item`.`parent` = 0");
+
+ // There was an issue where the nick vanishes from the contact table
+ q("UPDATE `contact` INNER JOIN `user` ON `contact`.`uid` = `user`.`uid` SET `nick` = `nickname` WHERE `self` AND `nick`=''");
+
+ // Update the global contacts for local users
+ $r = q("SELECT `uid` FROM `user` WHERE `verified` AND NOT `blocked` AND NOT `account_removed` AND NOT `account_expired`");
+ if (DBM::is_result($r)) {
+ foreach ($r AS $user) {
+ GlobalContact::updateForUser($user["uid"]);
+ }
+ }
+
+ /// @todo
+ /// - remove thread entries without item
+ /// - remove sign entries without item
+ /// - remove children when parent got lost
+ /// - set contact-id in item when not present
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/DBClean.php
+ * @brief The script is called from time to time to clean the database entries and remove orphaned data.
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use dba;
+
+class DBClean {
+ public static function execute($stage = 0) {
+
+ if (!Config::get('system', 'dbclean', false)) {
+ return;
+ }
+
+ // Get the expire days for step 8 and 9
+ $days = Config::get('system', 'dbclean-expire-days', 0);
+
+ if ($stage == 0) {
+ for ($i = 1; $i <= 9; $i++) {
+ // Execute the background script for a step when it isn't finished.
+ // Execute step 8 and 9 only when $days is defined.
+ if (!Config::get('system', 'finished-dbclean-'.$i, false) && (($i < 8) || ($days > 0))) {
+ Worker::add(PRIORITY_LOW, 'DBClean', $i);
+ }
+ }
+ } else {
+ self::removeOrphans($stage);
+ }
+ }
+
+ /**
+ * @brief Remove orphaned database entries
+ * @param integer $stage What should be deleted?
+ *
+ * Values for $stage:
+ * ------------------
+ * 1: Old global item entries from item table without user copy.
+ * 2: Items without parents.
+ * 3: Orphaned data from thread table.
+ * 4: Orphaned data from notify table.
+ * 5: Orphaned data from notify-threads table.
+ * 6: Orphaned data from sign table.
+ * 7: Orphaned data from term table.
+ * 8: Expired threads.
+ * 9: Old global item entries from expired threads
+ */
+ private static function removeOrphans($stage = 0) {
+ global $db;
+
+ $count = 0;
+
+ // We split the deletion in many small tasks
+ $limit = 1000;
+
+ // Get the expire days for step 8 and 9
+ $days = Config::get('system', 'dbclean-expire-days', 0);
+
+ if ($stage == 1) {
+ $last_id = Config::get('system', 'dbclean-last-id-1', 0);
+
+ logger("Deleting old global item entries from item table without user copy. Last ID: ".$last_id);
+ $r = dba::p("SELECT `id` FROM `item` WHERE `uid` = 0 AND
+ NOT EXISTS (SELECT `guid` FROM `item` AS `i` WHERE `item`.`guid` = `i`.`guid` AND `i`.`uid` != 0) AND
+ `received` < UTC_TIMESTAMP() - INTERVAL 90 DAY AND `id` >= ?
+ ORDER BY `id` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found global item orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('item', array('id' => $orphan["id"]));
+ }
+ } else {
+ logger("No global item orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." old global item entries from item table without user copy. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-1', $last_id);
+ } elseif ($stage == 2) {
+ $last_id = Config::get('system', 'dbclean-last-id-2', 0);
+
+ logger("Deleting items without parents. Last ID: ".$last_id);
+ $r = dba::p("SELECT `id` FROM `item`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` AS `i` WHERE `item`.`parent` = `i`.`id`)
+ AND `id` >= ? ORDER BY `id` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found item orphans without parents: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('item', array('id' => $orphan["id"]));
+ }
+ } else {
+ logger("No item orphans without parents found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." items without parents. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-2', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-2', true);
+ }
+ } elseif ($stage == 3) {
+ $last_id = Config::get('system', 'dbclean-last-id-3', 0);
+
+ logger("Deleting orphaned data from thread table. Last ID: ".$last_id);
+ $r = dba::p("SELECT `iid` FROM `thread`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`parent` = `thread`.`iid`) AND `iid` >= ?
+ ORDER BY `iid` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found thread orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["iid"];
+ dba::delete('thread', array('iid' => $orphan["iid"]));
+ }
+ } else {
+ logger("No thread orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." orphaned data from thread table. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-3', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-3', true);
+ }
+ } elseif ($stage == 4) {
+ $last_id = Config::get('system', 'dbclean-last-id-4', 0);
+
+ logger("Deleting orphaned data from notify table. Last ID: ".$last_id);
+ $r = dba::p("SELECT `iid`, `id` FROM `notify`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `notify`.`iid`) AND `id` >= ?
+ ORDER BY `id` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found notify orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('notify', array('iid' => $orphan["iid"]));
+ }
+ } else {
+ logger("No notify orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." orphaned data from notify table. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-4', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-4', true);
+ }
+ } elseif ($stage == 5) {
+ $last_id = Config::get('system', 'dbclean-last-id-5', 0);
+
+ logger("Deleting orphaned data from notify-threads table. Last ID: ".$last_id);
+ $r = dba::p("SELECT `id` FROM `notify-threads`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`parent` = `notify-threads`.`master-parent-item`) AND `id` >= ?
+ ORDER BY `id` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found notify-threads orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('notify-threads', array('id' => $orphan["id"]));
+ }
+ } else {
+ logger("No notify-threads orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." orphaned data from notify-threads table. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-5', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-5', true);
+ }
+ } elseif ($stage == 6) {
+ $last_id = Config::get('system', 'dbclean-last-id-6', 0);
+
+ logger("Deleting orphaned data from sign table. Last ID: ".$last_id);
+ $r = dba::p("SELECT `iid`, `id` FROM `sign`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `sign`.`iid`) AND `id` >= ?
+ ORDER BY `id` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found sign orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('sign', array('iid' => $orphan["iid"]));
+ }
+ } else {
+ logger("No sign orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." orphaned data from sign table. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-6', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-6', true);
+ }
+ } elseif ($stage == 7) {
+ $last_id = Config::get('system', 'dbclean-last-id-7', 0);
+
+ logger("Deleting orphaned data from term table. Last ID: ".$last_id);
+ $r = dba::p("SELECT `oid`, `tid` FROM `term`
+ WHERE NOT EXISTS (SELECT `id` FROM `item` WHERE `item`.`id` = `term`.`oid`) AND `tid` >= ?
+ ORDER BY `tid` LIMIT ".intval($limit), $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found term orphans: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["tid"];
+ dba::delete('term', array('oid' => $orphan["oid"]));
+ }
+ } else {
+ logger("No term orphans found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." orphaned data from term table. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-7', $last_id);
+
+ if ($count < $limit) {
+ Config::set('system', 'finished-dbclean-7', true);
+ }
+ } elseif ($stage == 8) {
+ if ($days <= 0) {
+ return;
+ }
+
+ $last_id = Config::get('system', 'dbclean-last-id-8', 0);
+
+ logger("Deleting expired threads. Last ID: ".$last_id);
+ $r = dba::p("SELECT `thread`.`iid` FROM `thread`
+ INNER JOIN `contact` ON `thread`.`contact-id` = `contact`.`id` AND NOT `notify_new_posts`
+ WHERE `thread`.`received` < UTC_TIMESTAMP() - INTERVAL ? DAY
+ AND NOT `thread`.`mention` AND NOT `thread`.`starred`
+ AND NOT `thread`.`wall` AND NOT `thread`.`origin`
+ AND `thread`.`uid` != 0 AND `thread`.`iid` >= ?
+ AND NOT `thread`.`iid` IN (SELECT `parent` FROM `item`
+ WHERE (`item`.`starred` OR (`item`.`resource-id` != '')
+ OR (`item`.`file` != '') OR (`item`.`event-id` != '')
+ OR (`item`.`attach` != '') OR `item`.`wall` OR `item`.`origin`)
+ AND `item`.`parent` = `thread`.`iid`)
+ ORDER BY `thread`.`iid` LIMIT 1000", $days, $last_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found expired threads: ".$count);
+ while ($thread = dba::fetch($r)) {
+ $last_id = $thread["iid"];
+ dba::delete('thread', array('iid' => $thread["iid"]));
+ }
+ } else {
+ logger("No expired threads found");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." expired threads. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-8', $last_id);
+ } elseif ($stage == 9) {
+ if ($days <= 0) {
+ return;
+ }
+
+ $last_id = Config::get('system', 'dbclean-last-id-9', 0);
+ $till_id = Config::get('system', 'dbclean-last-id-8', 0);
+
+ logger("Deleting old global item entries from expired threads from ID ".$last_id." to ID ".$till_id);
+ $r = dba::p("SELECT `id` FROM `item` WHERE `uid` = 0 AND
+ NOT EXISTS (SELECT `guid` FROM `item` AS `i` WHERE `item`.`guid` = `i`.`guid` AND `i`.`uid` != 0) AND
+ `received` < UTC_TIMESTAMP() - INTERVAL 90 DAY AND `id` >= ? AND `id` <= ?
+ ORDER BY `id` LIMIT ".intval($limit), $last_id, $till_id);
+ $count = dba::num_rows($r);
+ if ($count > 0) {
+ logger("found global item entries from expired threads: ".$count);
+ while ($orphan = dba::fetch($r)) {
+ $last_id = $orphan["id"];
+ dba::delete('item', array('id' => $orphan["id"]));
+ }
+ } else {
+ logger("No global item entries from expired threads");
+ }
+ dba::close($r);
+ logger("Done deleting ".$count." old global item entries from expired threads. Last ID: ".$last_id);
+
+ Config::set('system', 'dbclean-last-id-9', $last_id);
+ }
+
+ // Call it again if not all entries were purged
+ if (($stage != 0) && ($count > 0)) {
+ Worker::add(PRIORITY_MEDIUM, 'dbclean');
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/DBUpdate.php
+ * @brief This file is called when the database structure needs to be updated
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+
+class DBUpdate {
+ public static function execute() {
+ $a = get_app();
+
+ // We are deleting the latest dbupdate entry.
+ // This is done to avoid endless loops because the update was interupted.
+ Config::delete('database', 'dbupdate_'.DB_UPDATE_VERSION);
+
+ update_db($a);
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/Delivery.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\App;
+use Friendica\Core\System;
+use Friendica\Core\Config;
+use Friendica\Database\DBM;
+use Friendica\Object\Contact;
+use Friendica\Protocol\Diaspora;
+use Friendica\Protocol\DFRN;
+
+require_once 'include/queue_fn.php';
+require_once 'include/html2plain.php';
+require_once 'include/datetime.php';
+require_once 'include/items.php';
+require_once 'include/bbcode.php';
+require_once 'include/email.php';
+
+/// @todo This is some ugly code that needs to be split into several methods
+
+class Delivery {
+ public static function execute($cmd, $item_id, $contact_id) {
+ global $a;
+
+ logger('delivery: invoked: '.$cmd.': '.$item_id.' to '.$contact_id, LOGGER_DEBUG);
+
+ $expire = false;
+ $mail = false;
+ $fsuggest = false;
+ $relocate = false;
+ $top_level = false;
+ $recipients = array();
+ $url_recipients = array();
+ $followup = false;
+
+ $normal_mode = true;
+
+ $recipients[] = $contact_id;
+
+ if ($cmd === 'mail') {
+ $normal_mode = false;
+ $mail = true;
+ $message = q("SELECT * FROM `mail` WHERE `id` = %d LIMIT 1",
+ intval($item_id)
+ );
+ if (!count($message)) {
+ return;
+ }
+ $uid = $message[0]['uid'];
+ $recipients[] = $message[0]['contact-id'];
+ $item = $message[0];
+ } elseif ($cmd === 'expire') {
+ $normal_mode = false;
+ $expire = true;
+ $items = q("SELECT * FROM `item` WHERE `uid` = %d AND `wall` = 1
+ AND `deleted` = 1 AND `changed` > UTC_TIMESTAMP() - INTERVAL 30 MINUTE",
+ intval($item_id)
+ );
+ $uid = $item_id;
+ $item_id = 0;
+ if (!count($items)) {
+ return;
+ }
+ } elseif ($cmd === 'suggest') {
+ $normal_mode = false;
+ $fsuggest = true;
+
+ $suggest = q("SELECT * FROM `fsuggest` WHERE `id` = %d LIMIT 1",
+ intval($item_id)
+ );
+ if (!count($suggest)) {
+ return;
+ }
+ $uid = $suggest[0]['uid'];
+ $recipients[] = $suggest[0]['cid'];
+ $item = $suggest[0];
+ } elseif ($cmd === 'relocate') {
+ $normal_mode = false;
+ $relocate = true;
+ $uid = $item_id;
+ } else {
+ // find ancestors
+ $r = q("SELECT * FROM `item` WHERE `id` = %d AND visible = 1 AND moderated = 0 LIMIT 1",
+ intval($item_id)
+ );
+
+ if (!DBM::is_result($r) || !intval($r[0]['parent'])) {
+ return;
+ }
+
+ $target_item = $r[0];
+ $parent_id = intval($r[0]['parent']);
+ $uid = $r[0]['uid'];
+ $updated = $r[0]['edited'];
+
+ $items = q("SELECT `item`.*, `sign`.`signed_text`,`sign`.`signature`,`sign`.`signer`
+ FROM `item` LEFT JOIN `sign` ON `sign`.`iid` = `item`.`id` WHERE `parent` = %d AND visible = 1 AND moderated = 0 ORDER BY `id` ASC",
+ intval($parent_id)
+ );
+
+ if (!count($items)) {
+ return;
+ }
+
+ $icontacts = null;
+ $contacts_arr = array();
+ foreach ($items as $item) {
+ if (!in_array($item['contact-id'],$contacts_arr)) {
+ $contacts_arr[] = intval($item['contact-id']);
+ }
+ }
+ if (count($contacts_arr)) {
+ $str_contacts = implode(',',$contacts_arr);
+ $icontacts = q("SELECT * FROM `contact`
+ WHERE `id` IN ( $str_contacts ) "
+ );
+ }
+ if ( !($icontacts && count($icontacts))) {
+ return;
+ }
+
+ // avoid race condition with deleting entries
+
+ if ($items[0]['deleted']) {
+ foreach ($items as $item) {
+ $item['deleted'] = 1;
+ }
+ }
+
+ // When commenting too fast after delivery, a post wasn't recognized as top level post.
+ // The count then showed more than one entry. The additional check should help.
+ // The check for the "count" should be superfluous, but I'm not totally sure by now, so we keep it.
+ if ((($items[0]['id'] == $item_id) || (count($items) == 1)) && ($items[0]['uri'] === $items[0]['parent-uri'])) {
+ logger('delivery: top level post');
+ $top_level = true;
+ }
+ }
+
+ $r = q("SELECT `contact`.*, `user`.`prvkey` AS `uprvkey`,
+ `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
+ `user`.`page-flags`, `user`.`account-type`, `user`.`prvnets`
+ FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
+ WHERE `contact`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
+ intval($uid)
+ );
+
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ $owner = $r[0];
+
+ $walltowall = (($top_level && ($owner['id'] != $items[0]['contact-id'])) ? true : false);
+
+ $public_message = true;
+
+ if (!($mail || $fsuggest || $relocate)) {
+ require_once 'include/group.php';
+
+ $parent = $items[0];
+
+ // This is IMPORTANT!!!!
+
+ // We will only send a "notify owner to relay" or followup message if the referenced post
+ // originated on our system by virtue of having our hostname somewhere
+ // in the URI, AND it was a comment (not top_level) AND the parent originated elsewhere.
+ // if $parent['wall'] == 1 we will already have the parent message in our array
+ // and we will relay the whole lot.
+
+ // expire sends an entire group of expire messages and cannot be forwarded.
+ // However the conversation owner will be a part of the conversation and will
+ // be notified during this run.
+ // Other DFRN conversation members will be alerted during polled updates.
+
+ // Diaspora members currently are not notified of expirations, and other networks have
+ // either limited or no ability to process deletions. We should at least fix Diaspora
+ // by stringing togther an array of retractions and sending them onward.
+
+
+ $localhost = $a->get_hostname();
+ if (strpos($localhost,':')) {
+ $localhost = substr($localhost,0,strpos($localhost,':'));
+ }
+ /**
+ *
+ * Be VERY CAREFUL if you make any changes to the following line. Seemingly innocuous changes
+ * have been known to cause runaway conditions which affected several servers, along with
+ * permissions issues.
+ *
+ */
+
+ $relay_to_owner = false;
+
+ if (!$top_level && ($parent['wall'] == 0) && !$expire && stristr($target_item['uri'],$localhost)) {
+ $relay_to_owner = true;
+ }
+
+ if ($relay_to_owner) {
+ logger('followup '.$target_item["guid"], LOGGER_DEBUG);
+ // local followup to remote post
+ $followup = true;
+ }
+
+ if ((strlen($parent['allow_cid']))
+ || (strlen($parent['allow_gid']))
+ || (strlen($parent['deny_cid']))
+ || (strlen($parent['deny_gid']))
+ || $parent["private"]) {
+ $public_message = false; // private recipients, not public
+ }
+
+ }
+
+ $r = q("SELECT * FROM `contact` WHERE `id` = %d AND `blocked` = 0 AND `pending` = 0",
+ intval($contact_id)
+ );
+
+ if (DBM::is_result($r)) {
+ $contact = $r[0];
+ }
+ if ($contact['self']) {
+ return;
+ }
+ $deliver_status = 0;
+
+ logger("main delivery by delivery: followup=$followup mail=$mail fsuggest=$fsuggest relocate=$relocate - network ".$contact['network']);
+
+ switch($contact['network']) {
+
+ case NETWORK_DFRN:
+ logger('notifier: '.$target_item["guid"].' dfrndelivery: '.$contact['name']);
+
+ if ($mail) {
+ $item['body'] = fix_private_photos($item['body'],$owner['uid'],null,$message[0]['contact-id']);
+ $atom = DFRN::mail($item, $owner);
+ } elseif ($fsuggest) {
+ $atom = DFRN::fsuggest($item, $owner);
+ q("DELETE FROM `fsuggest` WHERE `id` = %d LIMIT 1", intval($item['id']));
+ } elseif ($relocate) {
+ $atom = DFRN::relocate($owner, $uid);
+ } elseif ($followup) {
+ $msgitems = array();
+ foreach ($items as $item) { // there is only one item
+ if (!$item['parent']) {
+ return;
+ }
+ if ($item['id'] == $item_id) {
+ logger('followup: item: '. print_r($item,true), LOGGER_DATA);
+ $msgitems[] = $item;
+ }
+ }
+ $atom = DFRN::entries($msgitems,$owner);
+ } else {
+ $msgitems = array();
+ foreach ($items as $item) {
+ if (!$item['parent']) {
+ return;
+ }
+
+ // private emails may be in included in public conversations. Filter them.
+ if ($public_message && $item['private']) {
+ return;
+ }
+
+ $item_contact = get_item_contact($item,$icontacts);
+ if (!$item_contact) {
+ return;
+ }
+
+ if ($normal_mode) {
+ if ($item_id == $item['id'] || $item['id'] == $item['parent']) {
+ $item["entry:comment-allow"] = true;
+ $item["entry:cid"] = (($top_level) ? $contact['id'] : 0);
+ $msgitems[] = $item;
+ }
+ } else {
+ $item["entry:comment-allow"] = true;
+ $msgitems[] = $item;
+ }
+ }
+ $atom = DFRN::entries($msgitems,$owner);
+ }
+
+ logger('notifier entry: '.$contact["url"].' '.$target_item["guid"].' entry: '.$atom, LOGGER_DEBUG);
+
+ logger('notifier: '.$atom, LOGGER_DATA);
+ $basepath = implode('/', array_slice(explode('/',$contact['url']),0,3));
+
+ // perform local delivery if we are on the same site
+
+ if (link_compare($basepath,System::baseUrl())) {
+
+ $nickname = basename($contact['url']);
+ if ($contact['issued-id']) {
+ $sql_extra = sprintf(" AND `dfrn-id` = '%s' ", dbesc($contact['issued-id']));
+ } else {
+ $sql_extra = sprintf(" AND `issued-id` = '%s' ", dbesc($contact['dfrn-id']));
+ }
+
+ $x = q("SELECT `contact`.*, `contact`.`uid` AS `importer_uid`,
+ `contact`.`pubkey` AS `cpubkey`,
+ `contact`.`prvkey` AS `cprvkey`,
+ `contact`.`thumb` AS `thumb`,
+ `contact`.`url` as `url`,
+ `contact`.`name` as `senderName`,
+ `user`.*
+ FROM `contact`
+ INNER JOIN `user` ON `contact`.`uid` = `user`.`uid`
+ WHERE `contact`.`blocked` = 0 AND `contact`.`pending` = 0
+ AND `contact`.`network` = '%s' AND `user`.`nickname` = '%s'
+ $sql_extra
+ AND `user`.`account_expired` = 0 AND `user`.`account_removed` = 0 LIMIT 1",
+ dbesc(NETWORK_DFRN),
+ dbesc($nickname)
+ );
+
+ if ($x && count($x)) {
+ $write_flag = ((($x[0]['rel']) && ($x[0]['rel'] != CONTACT_IS_SHARING)) ? true : false);
+ if ((($owner['page-flags'] == PAGE_COMMUNITY) || $write_flag) && !$x[0]['writable']) {
+ q("UPDATE `contact` SET `writable` = 1 WHERE `id` = %d",
+ intval($x[0]['id'])
+ );
+ $x[0]['writable'] = 1;
+ }
+
+ $ssl_policy = Config::get('system','ssl_policy');
+ fix_contact_ssl_policy($x[0],$ssl_policy);
+
+ // If we are setup as a soapbox we aren't accepting top level posts from this person
+
+ if (($x[0]['page-flags'] == PAGE_SOAPBOX) && $top_level) {
+ break;
+ }
+ logger('mod-delivery: local delivery');
+ DFRN::import($atom, $x[0]);
+ break;
+ }
+ }
+
+ if (!was_recently_delayed($contact['id'])) {
+ $deliver_status = DFRN::deliver($owner,$contact,$atom);
+ } else {
+ $deliver_status = (-1);
+ }
+
+ logger('notifier: dfrn_delivery to '.$contact["url"].' with guid '.$target_item["guid"].' returns '.$deliver_status);
+
+ if ($deliver_status < 0) {
+ logger('notifier: delivery failed: queuing message');
+ add_to_queue($contact['id'],NETWORK_DFRN,$atom);
+
+ // The message could not be delivered. We mark the contact as "dead"
+ Contact::markForArchival($contact);
+ } else {
+ // We successfully delivered a message, the contact is alive
+ Contact::unmarkForArchival($contact);
+ }
+
+ break;
+
+ case NETWORK_OSTATUS:
+ // Do not send to otatus if we are not configured to send to public networks
+ if ($owner['prvnets']) {
+ break;
+ }
+ if (Config::get('system','ostatus_disabled') || Config::get('system','dfrn_only')) {
+ break;
+ }
+
+ // There is currently no code here to distribute anything to OStatus.
+ // This is done in "notifier.php" (See "url_recipients" and "push_notify")
+ break;
+
+ case NETWORK_MAIL:
+ case NETWORK_MAIL2:
+
+ if (Config::get('system','dfrn_only')) {
+ break;
+ }
+ // WARNING: does not currently convert to RFC2047 header encodings, etc.
+
+ $addr = $contact['addr'];
+ if (!strlen($addr)) {
+ break;
+ }
+
+ if ($cmd === 'wall-new' || $cmd === 'comment-new') {
+
+ $it = null;
+ if ($cmd === 'wall-new') {
+ $it = $items[0];
+ } else {
+ $r = q("SELECT * FROM `item` WHERE `id` = %d AND `uid` = %d LIMIT 1",
+ intval($item_id),
+ intval($uid)
+ );
+ if (DBM::is_result($r))
+ $it = $r[0];
+ }
+ if (!$it)
+ break;
+
+
+ $local_user = q("SELECT * FROM `user` WHERE `uid` = %d LIMIT 1",
+ intval($uid)
+ );
+ if (!count($local_user))
+ break;
+
+ $reply_to = '';
+ $r1 = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1",
+ intval($uid)
+ );
+ if ($r1 && $r1[0]['reply_to'])
+ $reply_to = $r1[0]['reply_to'];
+
+ $subject = (($it['title']) ? email_header_encode($it['title'],'UTF-8') : t("\x28no subject\x29")) ;
+
+ // only expose our real email address to true friends
+
+ if (($contact['rel'] == CONTACT_IS_FRIEND) && !$contact['blocked']) {
+ if ($reply_to) {
+ $headers = 'From: '.email_header_encode($local_user[0]['username'],'UTF-8').' <'.$reply_to.'>'."\n";
+ $headers .= 'Sender: '.$local_user[0]['email']."\n";
+ } else {
+ $headers = 'From: '.email_header_encode($local_user[0]['username'],'UTF-8').' <'.$local_user[0]['email'].'>'."\n";
+ }
+ } else {
+ $headers = 'From: '. email_header_encode($local_user[0]['username'],'UTF-8') .' <'. t('noreply') .'@'.$a->get_hostname() .'>'. "\n";
+ }
+
+ //if ($reply_to)
+ // $headers .= 'Reply-to: '.$reply_to . "\n";
+
+ $headers .= 'Message-Id: <'. iri2msgid($it['uri']).'>'. "\n";
+
+ //logger("Mail: uri: ".$it['uri']." parent-uri ".$it['parent-uri'], LOGGER_DEBUG);
+ //logger("Mail: Data: ".print_r($it, true), LOGGER_DEBUG);
+ //logger("Mail: Data: ".print_r($it, true), LOGGER_DATA);
+
+ if ($it['uri'] !== $it['parent-uri']) {
+ $headers .= "References: <".iri2msgid($it["parent-uri"]).">";
+
+ // If Threading is enabled, write down the correct parent
+ if (($it["thr-parent"] != "") && ($it["thr-parent"] != $it["parent-uri"]))
+ $headers .= " <".iri2msgid($it["thr-parent"]).">";
+ $headers .= "\n";
+
+ if (!$it['title']) {
+ $r = q("SELECT `title` FROM `item` WHERE `uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($it['parent-uri']),
+ intval($uid));
+
+ if (DBM::is_result($r) && ($r[0]['title'] != '')) {
+ $subject = $r[0]['title'];
+ } else {
+ $r = q("SELECT `title` FROM `item` WHERE `parent-uri` = '%s' AND `uid` = %d LIMIT 1",
+ dbesc($it['parent-uri']),
+ intval($uid));
+
+ if (DBM::is_result($r) && ($r[0]['title'] != ''))
+ $subject = $r[0]['title'];
+ }
+ }
+ if (strncasecmp($subject,'RE:',3))
+ $subject = 'Re: '.$subject;
+ }
+ email_send($addr, $subject, $headers, $it);
+ }
+ break;
+
+ case NETWORK_DIASPORA:
+ if ($public_message)
+ $loc = 'public batch '.$contact['batch'];
+ else
+ $loc = $contact['name'];
+
+ logger('delivery: diaspora batch deliver: '.$loc);
+
+ if (Config::get('system','dfrn_only') || !Config::get('system','diaspora_enabled'))
+ break;
+
+ if ($mail) {
+ Diaspora::sendMail($item,$owner,$contact);
+ break;
+ }
+
+ if (!$normal_mode)
+ break;
+
+ if (!$contact['pubkey'] && !$public_message)
+ break;
+
+ if (($target_item['deleted']) && (($target_item['uri'] === $target_item['parent-uri']) || $followup)) {
+ // top-level retraction
+ logger('diaspora retract: '.$loc);
+ Diaspora::sendRetraction($target_item,$owner,$contact,$public_message);
+ break;
+ } elseif ($relocate) {
+ Diaspora::sendAccountMigration($owner, $contact, $uid);
+ break;
+ } elseif ($followup) {
+ // send comments and likes to owner to relay
+ logger('diaspora followup: '.$loc);
+ Diaspora::sendFollowup($target_item,$owner,$contact,$public_message);
+ break;
+ } elseif ($target_item['uri'] !== $target_item['parent-uri']) {
+ // we are the relay - send comments, likes and relayable_retractions to our conversants
+ logger('diaspora relay: '.$loc);
+ Diaspora::sendRelay($target_item,$owner,$contact,$public_message);
+ break;
+ } elseif ($top_level && !$walltowall) {
+ // currently no workable solution for sending walltowall
+ logger('diaspora status: '.$loc);
+ Diaspora::sendStatus($target_item,$owner,$contact,$public_message);
+ break;
+ }
+
+ logger('delivery: diaspora unknown mode: '.$contact['name']);
+
+ break;
+
+ default:
+ break;
+ }
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/Directory.php
+ * @brief Sends updated profile data to the directory
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+
+class Directory {
+ public static function execute($url = '') {
+ $dir = Config::get('system', 'directory');
+
+ if (!strlen($dir)) {
+ return;
+ }
+
+ if ($url == '') {
+ self::updateAll();
+ return;
+ }
+
+ $dir .= "/submit";
+
+ $arr = array('url' => $argv[1]);
+
+ call_hooks('globaldir_update', $arr);
+
+ logger('Updating directory: ' . $arr['url'], LOGGER_DEBUG);
+ if (strlen($arr['url'])) {
+ fetch_url($dir . '?url=' . bin2hex($arr['url']));
+ }
+
+ return;
+ }
+
+ private static function updateAll() {
+ $r = q("SELECT `url` FROM `contact`
+ INNER JOIN `profile` ON `profile`.`uid` = `contact`.`uid`
+ INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
+ WHERE `contact`.`self` AND `profile`.`net-publish` AND `profile`.`is-default` AND
+ NOT `user`.`account_expired` AND `user`.`verified`");
+
+ if (DBM::is_result($r)) {
+ foreach ($r AS $user) {
+ Worker::add(PRIORITY_LOW, 'Directory', $user['url']);
+ }
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/DiscoverPoCo.php
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Cache;
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Network\Probe;
+use Friendica\Protocol\PortableContact;
+
+require_once 'include/datetime.php';
+
+class DiscoverPoCo {
+ /// @todo Clean up this mess of a parameter hell and split it in several classes
+ public static function execute($command = '', $param1 = '', $param2 = '', $param3 = '', $param4 = '')
+ {
+ /*
+ This function can be called in these ways:
+ - dirsearch <search pattern>: Searches for "search pattern" in the directory. "search pattern" is url encoded.
+ - checkcontact: Updates gcontact entries
+ - suggestions: Discover other servers for their contacts.
+ - server <poco url>: Searches for the poco server list. "poco url" is base64 encoded.
+ - update_server: Frequently check the first 250 servers for vitality.
+ - update_server_directory: Discover the given server id for their contacts
+ - PortableContact::load: Load POCO data from a given POCO address
+ - check_profile: Update remote profile data
+ */
+
+ if ($command == "dirsearch") {
+ $search = urldecode($param1);
+ $mode = 1;
+ } elseif ($command == "checkcontact") {
+ $mode = 2;
+ } elseif ($command == "suggestions") {
+ $mode = 3;
+ } elseif ($command == "server") {
+ $mode = 4;
+ } elseif ($command == "update_server") {
+ $mode = 5;
+ } elseif ($command == "update_server_directory") {
+ $mode = 6;
+ } elseif ($command == "load") {
+ $mode = 7;
+ } elseif ($command == "check_profile") {
+ $mode = 8;
+ } elseif ($command == '') {
+ $search = "";
+ $mode = 0;
+ } else {
+ logger("Unknown or missing parameter ".$command."\n");
+ return;
+ }
+
+ logger('start '.$search);
+
+ if ($mode == 8) {
+ if ($param1 != "") {
+ PortableContact::lastUpdated($param1, true);
+ }
+ } elseif ($mode == 7) {
+ if (!empty($param4)) {
+ $url = $param4;
+ } else {
+ $url = '';
+ }
+ PortableContact::load(intval($param1), intval($param2), intval($param3), $url);
+ } elseif ($mode == 6) {
+ PortableContact::discoverSingleServer(intval($param1));
+ } elseif ($mode == 5) {
+ self::updateServer();
+ } elseif ($mode == 4) {
+ $server_url = $param1;
+ if ($server_url == "") {
+ return;
+ }
+ $server_url = filter_var($server_url, FILTER_SANITIZE_URL);
+ if (substr(normalise_link($server_url), 0, 7) != "http://") {
+ return;
+ }
+ $result = "Checking server ".$server_url." - ";
+ $ret = PortableContact::checkServer($server_url);
+ if ($ret) {
+ $result .= "success";
+ } else {
+ $result .= "failed";
+ }
+ logger($result, LOGGER_DEBUG);
+ } elseif ($mode == 3) {
+ GlobalContact::updateSuggestions();
+ } elseif (($mode == 2) && Config::get('system', 'poco_completion')) {
+ self::discoverUsers();
+ } elseif (($mode == 1) && ($search != "") && Config::get('system', 'poco_local_search')) {
+ self::discoverDirectory($search);
+ self::gsSearchUser($search);
+ } elseif (($mode == 0) && ($search == "") && (Config::get('system', 'poco_discovery') > 0)) {
+ // Query Friendica and Hubzilla servers for their users
+ PortableContact::discover();
+
+ // Query GNU Social servers for their users ("statistics" addon has to be enabled on the GS server)
+ if (!Config::get('system', 'ostatus_disabled')) {
+ GlobalContact::discoverGsUsers();
+ }
+ }
+
+ logger('end '.$search);
+
+ return;
+ }
+
+ /**
+ * @brief Updates the first 250 servers
+ *
+ */
+ private static function updateServer() {
+ $r = q("SELECT `url`, `created`, `last_failure`, `last_contact` FROM `gserver` ORDER BY rand()");
+
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ $updated = 0;
+
+ foreach ($r AS $server) {
+ if (!PortableContact::updateNeeded($server["created"], "", $server["last_failure"], $server["last_contact"])) {
+ continue;
+ }
+ logger('Update server status for server '.$server["url"], LOGGER_DEBUG);
+
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "server", $server["url"]);
+
+ if (++$updated > 250) {
+ return;
+ }
+ }
+ }
+
+ private static function discoverUsers() {
+ logger("Discover users", LOGGER_DEBUG);
+
+ $starttime = time();
+
+ $users = q("SELECT `url`, `created`, `updated`, `last_failure`, `last_contact`, `server_url`, `network` FROM `gcontact`
+ WHERE `last_contact` < UTC_TIMESTAMP - INTERVAL 1 MONTH AND
+ `last_failure` < UTC_TIMESTAMP - INTERVAL 1 MONTH AND
+ `network` IN ('%s', '%s', '%s', '%s', '') ORDER BY rand()",
+ dbesc(NETWORK_DFRN), dbesc(NETWORK_DIASPORA),
+ dbesc(NETWORK_OSTATUS), dbesc(NETWORK_FEED));
+
+ if (!$users) {
+ return;
+ }
+ $checked = 0;
+
+ foreach ($users AS $user) {
+
+ $urlparts = parse_url($user["url"]);
+ if (!isset($urlparts["scheme"])) {
+ q("UPDATE `gcontact` SET `network` = '%s' WHERE `nurl` = '%s'",
+ dbesc(NETWORK_PHANTOM), dbesc(normalise_link($user["url"])));
+ continue;
+ }
+
+ if (in_array($urlparts["host"], array("www.facebook.com", "facebook.com", "twitter.com",
+ "identi.ca", "alpha.app.net"))) {
+ $networks = array("www.facebook.com" => NETWORK_FACEBOOK,
+ "facebook.com" => NETWORK_FACEBOOK,
+ "twitter.com" => NETWORK_TWITTER,
+ "identi.ca" => NETWORK_PUMPIO,
+ "alpha.app.net" => NETWORK_APPNET);
+
+ q("UPDATE `gcontact` SET `network` = '%s' WHERE `nurl` = '%s'",
+ dbesc($networks[$urlparts["host"]]), dbesc(normalise_link($user["url"])));
+ continue;
+ }
+
+ $server_url = PortableContact::detectServer($user["url"]);
+ $force_update = false;
+
+ if ($user["server_url"] != "") {
+
+ $force_update = (normalise_link($user["server_url"]) != normalise_link($server_url));
+
+ $server_url = $user["server_url"];
+ }
+
+ if ((($server_url == "") && ($user["network"] == NETWORK_FEED)) || $force_update || PortableContact::checkServer($server_url, $user["network"])) {
+ logger('Check profile '.$user["url"]);
+ Worker::add(PRIORITY_LOW, "DiscoverPoCo", "check_profile", $user["url"]);
+
+ if (++$checked > 100) {
+ return;
+ }
+ } else {
+ q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `nurl` = '%s'",
+ dbesc(datetime_convert()), dbesc(normalise_link($user["url"])));
+ }
+
+ // Quit the loop after 3 minutes
+ if (time() > ($starttime + 180)) {
+ return;
+ }
+ }
+ }
+
+ private static function discoverDirectory($search) {
+
+ $data = Cache::get("dirsearch:".$search);
+ if (!is_null($data)) {
+ // Only search for the same item every 24 hours
+ if (time() < $data + (60 * 60 * 24)) {
+ logger("Already searched for ".$search." in the last 24 hours", LOGGER_DEBUG);
+ return;
+ }
+ }
+
+ $x = fetch_url(get_server()."/lsearch?p=1&n=500&search=".urlencode($search));
+ $j = json_decode($x);
+
+ if (count($j->results)) {
+ foreach ($j->results as $jj) {
+ // Check if the contact already exists
+ $exists = q("SELECT `id`, `last_contact`, `last_failure`, `updated` FROM `gcontact` WHERE `nurl` = '%s'", normalise_link($jj->url));
+ if (DBM::is_result($exists)) {
+ logger("Profile ".$jj->url." already exists (".$search.")", LOGGER_DEBUG);
+
+ if (($exists[0]["last_contact"] < $exists[0]["last_failure"]) &&
+ ($exists[0]["updated"] < $exists[0]["last_failure"])) {
+ continue;
+ }
+ // Update the contact
+ PortableContact::lastUpdated($jj->url);
+ continue;
+ }
+
+ $server_url = PortableContact::detectServer($jj->url);
+ if ($server_url != '') {
+ if (!PortableContact::checkServer($server_url)) {
+ logger("Friendica server ".$server_url." doesn't answer.", LOGGER_DEBUG);
+ continue;
+ }
+ logger("Friendica server ".$server_url." seems to be okay.", LOGGER_DEBUG);
+ }
+
+ $data = Probe::uri($jj->url);
+ if ($data["network"] == NETWORK_DFRN) {
+ logger("Profile ".$jj->url." is reachable (".$search.")", LOGGER_DEBUG);
+ logger("Add profile ".$jj->url." to local directory (".$search.")", LOGGER_DEBUG);
+
+ if ($jj->tags != "") {
+ $data["keywords"] = $jj->tags;
+ }
+
+ $data["server_url"] = $data["baseurl"];
+
+ GlobalContact::update($data);
+ } else {
+ logger("Profile ".$jj->url." is not responding or no Friendica contact - but network ".$data["network"], LOGGER_DEBUG);
+ }
+ }
+ }
+ Cache::set("dirsearch:".$search, time(), CACHE_DAY);
+ }
+
+ /**
+ * @brief Search for GNU Social user with gstools.org
+ *
+ * @param str $search User name
+ */
+ private static function gsSearchUser($search) {
+
+ // Currently disabled, since the service isn't available anymore.
+ // It is not removed since I hope that there will be a successor.
+ return false;
+
+ $a = get_app();
+
+ $url = "http://gstools.org/api/users_search/".urlencode($search);
+
+ $result = z_fetch_url($url);
+ if (!$result["success"]) {
+ return false;
+ }
+
+ $contacts = json_decode($result["body"]);
+
+ if ($contacts->status == 'ERROR') {
+ return false;
+ }
+
+ /// @TODO AS is considered as a notation for constants (as they usually being written all upper-case)
+ /// @TODO find all those and convert to all lower-case which is a keyword then
+ foreach ($contacts->data AS $user) {
+ $contact = Probe::uri($user->site_address."/".$user->name);
+ if ($contact["network"] != NETWORK_PHANTOM) {
+ $contact["about"] = $user->description;
+ GlobalContact::update($contact);
+ }
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/Expire.php
+ * @brief Expires old item entries
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use dba;
+
+class Expire {
+ public static function execute($param = '', $hook_name = '') {
+ global $a;
+
+ require_once 'include/datetime.php';
+ require_once 'include/items.php';
+
+ load_hooks();
+
+ if ($param == 'delete') {
+ logger('Delete expired items', LOGGER_DEBUG);
+ // physically remove anything that has been deleted for more than two months
+ $r = dba::p("SELECT `id` FROM `item` WHERE `deleted` AND `changed` < UTC_TIMESTAMP() - INTERVAL 60 DAY");
+ while ($row = dba::fetch($r)) {
+ dba::delete('item', array('id' => $row['id']));
+ }
+ dba::close($r);
+
+ logger('Delete expired items - done', LOGGER_DEBUG);
+
+ // make this optional as it could have a performance impact on large sites
+ if (intval(Config::get('system', 'optimize_items'))) {
+ dba::e("OPTIMIZE TABLE `item`");
+ }
+ return;
+ } elseif (intval($param) > 0) {
+ $user = dba::select('user', array('uid', 'username', 'expire'), array('uid' => $param), array('limit' => 1));
+ if (DBM::is_result($user)) {
+ logger('Expire items for user '.$user['uid'].' ('.$user['username'].') - interval: '.$user['expire'], LOGGER_DEBUG);
+ item_expire($user['uid'], $user['expire']);
+ logger('Expire items for user '.$user['uid'].' ('.$user['username'].') - done ', LOGGER_DEBUG);
+ }
+ return;
+ } elseif (!empty($hook_name) && ($param == 'hook') && is_array($a->hooks) && array_key_exists("expire", $a->hooks)) {
+ foreach ($a->hooks["expire"] as $hook) {
+ if ($hook[1] == $hook_name) {
+ logger("Calling expire hook '" . $hook[1] . "'", LOGGER_DEBUG);
+ call_single_hook($a, $name, $hook, $data);
+ }
+ }
+ return;
+ }
+
+ logger('expire: start');
+
+ Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'Expire', 'delete');
+
+ $r = dba::p("SELECT `uid`, `username` FROM `user` WHERE `expire` != 0");
+ while ($row = dba::fetch($r)) {
+ logger('Calling expiry for user '.$row['uid'].' ('.$row['username'].')', LOGGER_DEBUG);
+ Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'Expire', (int)$row['uid']);
+ }
+ dba::close($r);
+
+ logger('expire: calling hooks');
+
+ if (is_array($a->hooks) && array_key_exists('expire', $a->hooks)) {
+ foreach ($a->hooks['expire'] as $hook) {
+ logger("Calling expire hook for '" . $hook[1] . "'", LOGGER_DEBUG);
+ Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'Expire', 'hook', $hook[1]);
+ }
+ }
+
+ logger('expire: end');
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/GProbe.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Cache;
+use Friendica\Core\Config;
+use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
+use Friendica\Network\Probe;
+use Friendica\Protocol\PortableContact;
+
+require_once 'include/datetime.php';
+
+class GProbe {
+ public static function execute($url = '')
+ {
+ if (empty($url)) {
+ return;
+ }
+
+ $r = q(
+ "SELECT `id`, `url`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 1",
+ dbesc(normalise_link($url))
+ );
+
+ logger("gprobe start for ".normalise_link($url), LOGGER_DEBUG);
+
+ if (!DBM::is_result($r)) {
+ // Is it a DDoS attempt?
+ $urlparts = parse_url($url);
+
+ $result = Cache::get("gprobe:".$urlparts["host"]);
+ if (!is_null($result)) {
+ if (in_array($result["network"], array(NETWORK_FEED, NETWORK_PHANTOM))) {
+ logger("DDoS attempt detected for ".$urlparts["host"]." by ".$_SERVER["REMOTE_ADDR"].". server data: ".print_r($_SERVER, true), LOGGER_DEBUG);
+ return;
+ }
+ }
+
+ $arr = Probe::uri($url);
+
+ if (is_null($result)) {
+ Cache::set("gprobe:".$urlparts["host"], $arr);
+ }
+
+ if (!in_array($arr["network"], array(NETWORK_FEED, NETWORK_PHANTOM))) {
+ GlobalContact::update($arr);
+ }
+
+ $r = q(
+ "SELECT `id`, `url`, `network` FROM `gcontact` WHERE `nurl` = '%s' ORDER BY `id` LIMIT 1",
+ dbesc(normalise_link($url))
+ );
+ }
+ if (DBM::is_result($r)) {
+ // Check for accessibility and do a poco discovery
+ if (PortableContact::lastUpdated($r[0]['url'], true) && ($r[0]["network"] == NETWORK_DFRN)) {
+ PortableContact::loadWorker(0, 0, $r[0]['id'], str_replace('/profile/', '/poco/', $r[0]['url']));
+ }
+ }
+
+ logger("gprobe end for ".normalise_link($url), LOGGER_DEBUG);
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/Notifier.php
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+use Friendica\Object\Contact;
+use Friendica\Protocol\Diaspora;
+use Friendica\Protocol\OStatus;
+use dba;
+
+require_once 'include/queue_fn.php';
+require_once 'include/html2plain.php';
+require_once 'include/salmon.php';
+require_once 'include/datetime.php';
+require_once 'include/items.php';
+require_once 'include/bbcode.php';
+require_once 'include/email.php';
+
+/*
+ * This file was at one time responsible for doing all deliveries, but this caused
+ * big problems when the process was killed or stalled during the delivery process.
+ * It now invokes separate queues that are delivering via delivery.php and pubsubpublish.php.
+ */
+
+/*
+ * The notifier is typically called with:
+ *
+ * Worker::add(PRIORITY_HIGH, "Notifier", COMMAND, ITEM_ID);
+ *
+ * where COMMAND is one of the following:
+ *
+ * activity (in diaspora.php, dfrn_confirm.php, profiles.php)
+ * comment-import (in diaspora.php, items.php)
+ * comment-new (in item.php)
+ * drop (in diaspora.php, items.php, photos.php)
+ * edit_post (in item.php)
+ * event (in events.php)
+ * expire (in items.php)
+ * like (in like.php, poke.php)
+ * mail (in message.php)
+ * suggest (in fsuggest.php)
+ * tag (in photos.php, poke.php, tagger.php)
+ * tgroup (in items.php)
+ * wall-new (in photos.php, item.php)
+ * removeme (in Contact.php)
+ * relocate (in uimport.php)
+ *
+ * and ITEM_ID is the id of the item in the database that needs to be sent to others.
+ */
+
+class Notifier {
+ public static function execute($cmd, $item_id) {
+ global $a;
+
+ logger('notifier: invoked: '.$cmd.': '.$item_id, LOGGER_DEBUG);
+
+ $expire = false;
+ $mail = false;
+ $fsuggest = false;
+ $relocate = false;
+ $top_level = false;
+ $recipients = array();
+ $url_recipients = array();
+
+ $normal_mode = true;
+
+ if ($cmd === 'mail') {
+ $normal_mode = false;
+ $mail = true;
+ $message = q("SELECT * FROM `mail` WHERE `id` = %d LIMIT 1",
+ intval($item_id)
+ );
+ if (! count($message)) {
+ return;
+ }
+ $uid = $message[0]['uid'];
+ $recipients[] = $message[0]['contact-id'];
+ $item = $message[0];
+
+ } elseif ($cmd === 'expire') {
+ $normal_mode = false;
+ $expire = true;
+ $items = q("SELECT * FROM `item` WHERE `uid` = %d AND `wall` = 1
+ AND `deleted` = 1 AND `changed` > UTC_TIMESTAMP() - INTERVAL 10 MINUTE",
+ intval($item_id)
+ );
+ $uid = $item_id;
+ $item_id = 0;
+ if (! count($items)) {
+ return;
+ }
+ } elseif ($cmd === 'suggest') {
+ $normal_mode = false;
+ $fsuggest = true;
+
+ $suggest = q("SELECT * FROM `fsuggest` WHERE `id` = %d LIMIT 1",
+ intval($item_id)
+ );
+ if (! count($suggest)) {
+ return;
+ }
+ $uid = $suggest[0]['uid'];
+ $recipients[] = $suggest[0]['cid'];
+ $item = $suggest[0];
+ } elseif ($cmd === 'removeme') {
+ $r = q("SELECT `contact`.*, `user`.`prvkey` AS `uprvkey`,
+ `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
+ `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`, `user`.`guid`
+ FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
+ WHERE `contact`.`uid` = %d AND `contact`.`self` LIMIT 1",
+ intval($item_id));
+ if (!$r)
+ return;
+
+ $user = $r[0];
+
+ $r = q("SELECT * FROM `contact` WHERE NOT `self` AND `uid` = %d", intval($item_id));
+ if (!$r) {
+ return;
+ }
+ foreach ($r as $contact) {
+ Contact::terminateFriendship($user, $contact);
+ }
+ return;
+ } elseif ($cmd === 'relocate') {
+ $normal_mode = false;
+ $relocate = true;
+ $uid = $item_id;
+
+ $recipients_relocate = q("SELECT * FROM `contact` WHERE `uid` = %d AND NOT `self` AND `network` IN ('%s', '%s')",
+ intval($uid), NETWORK_DFRN, NETWORK_DIASPORA);
+ } else {
+ // find ancestors
+ $r = q("SELECT * FROM `item` WHERE `id` = %d AND visible = 1 AND moderated = 0 LIMIT 1",
+ intval($item_id)
+ );
+
+ if ((! DBM::is_result($r)) || (! intval($r[0]['parent']))) {
+ return;
+ }
+
+ $target_item = $r[0];
+ $parent_id = intval($r[0]['parent']);
+ $uid = $r[0]['uid'];
+ $updated = $r[0]['edited'];
+
+ $items = q("SELECT `item`.*, `sign`.`signed_text`,`sign`.`signature`,`sign`.`signer`
+ FROM `item` LEFT JOIN `sign` ON `sign`.`iid` = `item`.`id` WHERE `parent` = %d AND visible = 1 AND moderated = 0 ORDER BY `id` ASC",
+ intval($parent_id)
+ );
+
+ if (! count($items)) {
+ return;
+ }
+
+ // avoid race condition with deleting entries
+
+ if ($items[0]['deleted']) {
+ foreach ($items as $item) {
+ $item['deleted'] = 1;
+ }
+ }
+
+ if ((count($items) == 1) && ($items[0]['id'] === $target_item['id']) && ($items[0]['uri'] === $items[0]['parent-uri'])) {
+ logger('notifier: top level post');
+ $top_level = true;
+ }
+
+ }
+
+ $r = q("SELECT `contact`.*, `user`.`prvkey` AS `uprvkey`,
+ `user`.`timezone`, `user`.`nickname`, `user`.`sprvkey`, `user`.`spubkey`,
+ `user`.`page-flags`, `user`.`prvnets`, `user`.`account-type`
+ FROM `contact` INNER JOIN `user` ON `user`.`uid` = `contact`.`uid`
+ WHERE `contact`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
+ intval($uid)
+ );
+
+ if (! DBM::is_result($r)) {
+ return;
+ }
+
+ $owner = $r[0];
+
+ $walltowall = ((($top_level) && ($owner['id'] != $items[0]['contact-id'])) ? true : false);
+
+ // Should the post be transmitted to Diaspora?
+ $diaspora_delivery = true;
+
+ // If this is a public conversation, notify the feed hub
+ $public_message = true;
+
+ // Do a PuSH
+ $push_notify = false;
+
+ // Deliver directly to a forum, don't PuSH
+ $direct_forum_delivery = false;
+
+ // fill this in with a single salmon slap if applicable
+ $slap = '';
+
+ if (! ($mail || $fsuggest || $relocate)) {
+
+ $slap = OStatus::salmon($target_item, $owner);
+
+ require_once 'include/group.php';
+
+ $parent = $items[0];
+
+ $thr_parent = q("SELECT `network`, `author-link`, `owner-link` FROM `item` WHERE `uri` = '%s' AND `uid` = %d",
+ dbesc($target_item["thr-parent"]), intval($target_item["uid"]));
+
+ logger('GUID: '.$target_item["guid"].': Parent is '.$parent['network'].'. Thread parent is '.$thr_parent[0]['network'], LOGGER_DEBUG);
+
+ // This is IMPORTANT!!!!
+
+ // We will only send a "notify owner to relay" or followup message if the referenced post
+ // originated on our system by virtue of having our hostname somewhere
+ // in the URI, AND it was a comment (not top_level) AND the parent originated elsewhere.
+
+ // if $parent['wall'] == 1 we will already have the parent message in our array
+ // and we will relay the whole lot.
+
+ // expire sends an entire group of expire messages and cannot be forwarded.
+ // However the conversation owner will be a part of the conversation and will
+ // be notified during this run.
+ // Other DFRN conversation members will be alerted during polled updates.
+
+
+
+ // Diaspora members currently are not notified of expirations, and other networks have
+ // either limited or no ability to process deletions. We should at least fix Diaspora
+ // by stringing togther an array of retractions and sending them onward.
+
+
+ $localhost = str_replace('www.','',$a->get_hostname());
+ if (strpos($localhost,':')) {
+ $localhost = substr($localhost,0,strpos($localhost,':'));
+ }
+ /**
+ *
+ * Be VERY CAREFUL if you make any changes to the following several lines. Seemingly innocuous changes
+ * have been known to cause runaway conditions which affected several servers, along with
+ * permissions issues.
+ *
+ */
+
+ $relay_to_owner = false;
+
+ if (!$top_level && ($parent['wall'] == 0) && !$expire && (stristr($target_item['uri'],$localhost))) {
+ $relay_to_owner = true;
+ }
+
+
+ if (($cmd === 'uplink') && (intval($parent['forum_mode']) == 1) && !$top_level) {
+ $relay_to_owner = true;
+ }
+
+ // until the 'origin' flag has been in use for several months
+ // we will just use it as a fallback test
+ // later we will be able to use it as the primary test of whether or not to relay.
+
+ if (! $target_item['origin']) {
+ $relay_to_owner = false;
+ }
+ if ($parent['origin']) {
+ $relay_to_owner = false;
+ }
+
+ // Special treatment for forum posts
+ if (($target_item['author-link'] != $target_item['owner-link']) &&
+ ($owner['id'] != $target_item['contact-id']) &&
+ ($target_item['uri'] === $target_item['parent-uri'])) {
+
+ $fields = array('forum', 'prv');
+ $condition = array('id' => $target_item['contact-id']);
+ $contact = dba::select('contact', $fields, $condition, array('limit' => 1));
+ if (!DBM::is_result($contact)) {
+ // Should never happen
+ return false;
+ }
+
+ // Is the post from a forum?
+ if ($contact['forum'] || $contact['prv']) {
+ $relay_to_owner = true;
+ $direct_forum_delivery = true;
+ }
+ }
+ if ($relay_to_owner) {
+ logger('notifier: followup '.$target_item["guid"], LOGGER_DEBUG);
+ // local followup to remote post
+ $followup = true;
+ $public_message = false; // not public
+ $conversant_str = dbesc($parent['contact-id']);
+ $recipients = array($parent['contact-id']);
+ $recipients_followup = array($parent['contact-id']);
+
+ //if (!$target_item['private'] && $target_item['wall'] &&
+ if (!$target_item['private'] &&
+ (strlen($target_item['allow_cid'].$target_item['allow_gid'].
+ $target_item['deny_cid'].$target_item['deny_gid']) == 0))
+ $push_notify = true;
+
+ if (($thr_parent && ($thr_parent[0]['network'] == NETWORK_OSTATUS)) || ($parent['network'] == NETWORK_OSTATUS)) {
+
+ $push_notify = true;
+
+ if ($parent["network"] == NETWORK_OSTATUS) {
+ // Distribute the message to the DFRN contacts as if this wasn't a followup since OStatus can't relay comments
+ // Currently it is work at progress
+ $r = q("SELECT `id` FROM `contact` WHERE `uid` = %d AND `network` = '%s' AND NOT `blocked` AND NOT `pending` AND NOT `archive`",
+ intval($uid),
+ dbesc(NETWORK_DFRN)
+ );
+ if (DBM::is_result($r)) {
+ foreach ($r as $rr) {
+ $recipients_followup[] = $rr['id'];
+ }
+ }
+ }
+ }
+
+ if ($direct_forum_delivery) {
+ $push_notify = false;
+ }
+
+ logger("Notify ".$target_item["guid"]." via PuSH: ".($push_notify?"Yes":"No"), LOGGER_DEBUG);
+ } else {
+ $followup = false;
+
+ logger('Distributing directly '.$target_item["guid"], LOGGER_DEBUG);
+
+ // don't send deletions onward for other people's stuff
+
+ if ($target_item['deleted'] && (! intval($target_item['wall']))) {
+ logger('notifier: ignoring delete notification for non-wall item');
+ return;
+ }
+
+ if ((strlen($parent['allow_cid']))
+ || (strlen($parent['allow_gid']))
+ || (strlen($parent['deny_cid']))
+ || (strlen($parent['deny_gid']))) {
+ $public_message = false; // private recipients, not public
+ }
+
+ $allow_people = expand_acl($parent['allow_cid']);
+ $allow_groups = expand_groups(expand_acl($parent['allow_gid']),true);
+ $deny_people = expand_acl($parent['deny_cid']);
+ $deny_groups = expand_groups(expand_acl($parent['deny_gid']));
+
+ // if our parent is a public forum (forum_mode == 1), uplink to the origional author causing
+ // a delivery fork. private groups (forum_mode == 2) do not uplink
+
+ if ((intval($parent['forum_mode']) == 1) && (! $top_level) && ($cmd !== 'uplink')) {
+ Worker::add($a->queue['priority'], 'Notifier', 'uplink', $item_id);
+ }
+
+ $conversants = array();
+
+ foreach ($items as $item) {
+ $recipients[] = $item['contact-id'];
+ $conversants[] = $item['contact-id'];
+ // pull out additional tagged people to notify (if public message)
+ if ($public_message && strlen($item['inform'])) {
+ $people = explode(',',$item['inform']);
+ foreach ($people as $person) {
+ if (substr($person,0,4) === 'cid:') {
+ $recipients[] = intval(substr($person,4));
+ $conversants[] = intval(substr($person,4));
+ } else {
+ $url_recipients[] = substr($person,4);
+ }
+ }
+ }
+ }
+
+ if (count($url_recipients))
+ logger('notifier: '.$target_item["guid"].' url_recipients ' . print_r($url_recipients,true));
+
+ $conversants = array_unique($conversants);
+
+
+ $recipients = array_unique(array_merge($recipients,$allow_people,$allow_groups));
+ $deny = array_unique(array_merge($deny_people,$deny_groups));
+ $recipients = array_diff($recipients,$deny);
+
+ $conversant_str = dbesc(implode(', ',$conversants));
+ }
+
+ // If the thread parent is OStatus then do some magic to distribute the messages.
+ // We have not only to look at the parent, since it could be a Friendica thread.
+ if (($thr_parent && ($thr_parent[0]['network'] == NETWORK_OSTATUS)) || ($parent['network'] == NETWORK_OSTATUS)) {
+
+ $diaspora_delivery = false;
+
+ logger('Some parent is OStatus for '.$target_item["guid"]." - Author: ".$thr_parent[0]['author-link']." - Owner: ".$thr_parent[0]['owner-link'], LOGGER_DEBUG);
+
+ // Send a salmon to the parent author
+ $r = q("SELECT `url`, `notify` FROM `contact` WHERE `nurl`='%s' AND `uid` IN (0, %d) AND `notify` != ''",
+ dbesc(normalise_link($thr_parent[0]['author-link'])),
+ intval($uid));
+ if (DBM::is_result($r)) {
+ $probed_contact = $r[0];
+ } else {
+ $probed_contact = Probe::uri($thr_parent[0]['author-link']);
+ }
+
+ if ($probed_contact["notify"] != "") {
+ logger('Notify parent author '.$probed_contact["url"].': '.$probed_contact["notify"]);
+ $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
+ }
+
+ // Send a salmon to the parent owner
+ $r = q("SELECT `url`, `notify` FROM `contact` WHERE `nurl`='%s' AND `uid` IN (0, %d) AND `notify` != ''",
+ dbesc(normalise_link($thr_parent[0]['owner-link'])),
+ intval($uid));
+ if (DBM::is_result($r)) {
+ $probed_contact = $r[0];
+ } else {
+ $probed_contact = Probe::uri($thr_parent[0]['owner-link']);
+ }
+
+ if ($probed_contact["notify"] != "") {
+ logger('Notify parent owner '.$probed_contact["url"].': '.$probed_contact["notify"]);
+ $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
+ }
+
+ // Send a salmon notification to every person we mentioned in the post
+ $arr = explode(',',$target_item['tag']);
+ foreach ($arr as $x) {
+ //logger('Checking tag '.$x, LOGGER_DEBUG);
+ $matches = null;
+ if (preg_match('/@\[url=([^\]]*)\]/',$x,$matches)) {
+ $probed_contact = Probe::uri($matches[1]);
+ if ($probed_contact["notify"] != "") {
+ logger('Notify mentioned user '.$probed_contact["url"].': '.$probed_contact["notify"]);
+ $url_recipients[$probed_contact["notify"]] = $probed_contact["notify"];
+ }
+ }
+ }
+
+ // It only makes sense to distribute answers to OStatus messages to Friendica and OStatus - but not Diaspora
+ $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."')";
+ } else {
+ $sql_extra = " AND `network` IN ('".NETWORK_OSTATUS."', '".NETWORK_DFRN."', '".NETWORK_DIASPORA."', '".NETWORK_MAIL."', '".NETWORK_MAIL2."')";
+ }
+ } else {
+ $public_message = false;
+ }
+
+ // If this is a public message and pubmail is set on the parent, include all your email contacts
+
+ $mail_disabled = ((function_exists('imap_open') && (!Config::get('system','imap_disabled'))) ? 0 : 1);
+
+ if (! $mail_disabled) {
+ if ((! strlen($target_item['allow_cid'])) && (! strlen($target_item['allow_gid']))
+ && (! strlen($target_item['deny_cid'])) && (! strlen($target_item['deny_gid']))
+ && (intval($target_item['pubmail']))) {
+ $r = q("SELECT `id` FROM `contact` WHERE `uid` = %d AND `network` = '%s'",
+ intval($uid),
+ dbesc(NETWORK_MAIL)
+ );
+ if (DBM::is_result($r)) {
+ foreach ($r as $rr) {
+ $recipients[] = $rr['id'];
+ }
+ }
+ }
+ }
+
+ if ($followup) {
+ $recip_str = implode(', ', $recipients_followup);
+ } else {
+ $recip_str = implode(', ', $recipients);
+ }
+ if ($relocate) {
+ $r = $recipients_relocate;
+ } else {
+ $r = q("SELECT `id`, `url`, `network`, `self` FROM `contact`
+ WHERE `id` IN (%s) AND NOT `blocked` AND NOT `pending` AND NOT `archive`".$sql_extra,
+ dbesc($recip_str)
+ );
+ }
+
+ // delivery loop
+
+ if (DBM::is_result($r)) {
+ foreach ($r as $contact) {
+ if ($contact['self']) {
+ continue;
+ }
+ logger("Deliver ".$target_item["guid"]." to ".$contact['url']." via network ".$contact['network'], LOGGER_DEBUG);
+
+ Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'Delivery', $cmd, $item_id, (int)$contact['id']);
+ }
+ }
+
+ // send salmon slaps to mentioned remote tags (@foo@example.com) in OStatus posts
+ // They are especially used for notifications to OStatus users that don't follow us.
+
+ if ($slap && count($url_recipients) && ($public_message || $push_notify) && $normal_mode) {
+ if (!Config::get('system','dfrn_only')) {
+ foreach ($url_recipients as $url) {
+ if ($url) {
+ logger('notifier: urldelivery: ' . $url);
+ $deliver_status = slapper($owner,$url,$slap);
+ /// @TODO Redeliver/queue these items on failure, though there is no contact record
+ }
+ }
+ }
+ }
+
+
+ if ($public_message) {
+
+ $r0 = array();
+ $r1 = array();
+
+ if ($diaspora_delivery) {
+ if (!$followup) {
+ $r0 = Diaspora::relayList();
+ }
+
+ $r1 = q("SELECT `batch`, ANY_VALUE(`id`) AS `id`, ANY_VALUE(`name`) AS `name`, ANY_VALUE(`network`) AS `network`
+ FROM `contact` WHERE `network` = '%s' AND `batch` != ''
+ AND `uid` = %d AND `rel` != %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` GROUP BY `batch`",
+ dbesc(NETWORK_DIASPORA),
+ intval($owner['uid']),
+ intval(CONTACT_IS_SHARING)
+ );
+ }
+
+ $r2 = q("SELECT `id`, `name`,`network` FROM `contact`
+ WHERE `network` in ('%s', '%s') AND `uid` = %d AND NOT `blocked` AND NOT `pending` AND NOT `archive` AND `rel` != %d",
+ dbesc(NETWORK_DFRN),
+ dbesc(NETWORK_MAIL2),
+ intval($owner['uid']),
+ intval(CONTACT_IS_SHARING)
+ );
+
+ $r = array_merge($r2,$r1,$r0);
+
+ if (DBM::is_result($r)) {
+ logger('pubdeliver '.$target_item["guid"].': '.print_r($r,true), LOGGER_DEBUG);
+
+ foreach ($r as $rr) {
+
+ // except for Diaspora batch jobs
+ // Don't deliver to folks who have already been delivered to
+
+ if (($rr['network'] !== NETWORK_DIASPORA) && (in_array($rr['id'],$conversants))) {
+ logger('notifier: already delivered id=' . $rr['id']);
+ continue;
+ }
+
+ if ((! $mail) && (! $fsuggest) && (! $followup)) {
+ logger('notifier: delivery agent: '.$rr['name'].' '.$rr['id'].' '.$rr['network'].' '.$target_item["guid"]);
+ Worker::add(array('priority' => $a->queue['priority'], 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'Delivery', $cmd, $item_id, (int)$rr['id']);
+ }
+ }
+ }
+
+ $push_notify = true;
+
+ }
+
+ // Notify PuSH subscribers (Used for OStatus distribution of regular posts)
+ if ($push_notify) {
+ // Set push flag for PuSH subscribers to this topic,
+ // they will be notified in queue.php
+ q("UPDATE `push_subscriber` SET `push` = 1 ".
+ "WHERE `nickname` = '%s' AND `push` = 0", dbesc($owner['nickname']));
+
+ logger('Activating internal PuSH for item '.$item_id, LOGGER_DEBUG);
+
+ // Handling the pubsubhubbub requests
+ Worker::add(array('priority' => PRIORITY_HIGH, 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'PubSubPublish');
+ }
+
+ logger('notifier: calling hooks', LOGGER_DEBUG);
+
+ if ($normal_mode) {
+ call_hooks('notifier_normal',$target_item);
+ }
+
+ call_hooks('notifier_end',$target_item);
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/OnePoll.php
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Core\PConfig;
+use Friendica\Database\DBM;
+use Friendica\Object\Contact;
+use Friendica\Protocol\PortableContact;
+use dba;
+
+require_once 'include/follow.php';
+
+Class OnePoll
+{
+ public static function execute($contact_id = 0, $command = '') {
+ global $a;
+
+ require_once 'include/datetime.php';
+ require_once 'include/items.php';
+ require_once 'include/email.php';
+ require_once 'include/queue_fn.php';
+
+ logger('onepoll: start');
+
+ $manual_id = 0;
+ $generation = 0;
+ $hub_update = false;
+ $force = false;
+ $restart = false;
+
+ if ($command == "force") {
+ $force = true;
+ }
+
+ if (!$contact_id) {
+ logger('onepoll: no contact');
+ return;
+ }
+
+ $d = datetime_convert();
+
+ // Only poll from those with suitable relationships,
+ // and which have a polling address and ignore Diaspora since
+ // we are unable to match those posts with a Diaspora GUID and prevent duplicates.
+
+ $contacts = q("SELECT `contact`.* FROM `contact`
+ WHERE (`rel` = %d OR `rel` = %d) AND `poll` != ''
+ AND NOT `network` IN ('%s', '%s')
+ AND `contact`.`id` = %d
+ AND `self` = 0 AND `contact`.`blocked` = 0 AND `contact`.`readonly` = 0
+ AND `contact`.`archive` = 0 LIMIT 1",
+ intval(CONTACT_IS_SHARING),
+ intval(CONTACT_IS_FRIEND),
+ dbesc(NETWORK_FACEBOOK),
+ dbesc(NETWORK_PUMPIO),
+ intval($contact_id)
+ );
+
+ if (!count($contacts)) {
+ logger('Contact not found or cannot be used.');
+ return;
+ }
+
+ $contact = $contacts[0];
+
+ $importer_uid = $contact['uid'];
+
+ // load current friends if possible.
+ if (($contact['poco'] != "") && ($contact['success_update'] > $contact['failure_update'])) {
+ $r = q("SELECT count(*) AS total FROM glink
+ WHERE `cid` = %d AND updated > UTC_TIMESTAMP() - INTERVAL 1 DAY",
+ intval($contact['id'])
+ );
+ if (DBM::is_result($r)) {
+ if (!$r[0]['total']) {
+ PortableContact::loadWorker($contact['id'], $importer_uid, 0, $contact['poco']);
+ }
+ }
+ }
+
+ /// @TODO Check why we don't poll the Diaspora feed at the moment (some guid problem in the items?)
+ /// @TODO Check whether this is possible with Redmatrix
+ if ($contact["network"] == NETWORK_DIASPORA) {
+ if (PortableContact::updateNeeded($contact["created"], $contact["last-item"], $contact["failure_update"], $contact["success_update"])) {
+ $last_updated = PortableContact::lastUpdated($contact["url"]);
+ $updated = datetime_convert();
+ if ($last_updated) {
+ $fields = array('last-item' => $last_updated, 'last-update' => $updated, 'success_update' => $updated);
+ dba::update('contact', $fields, array('id' => $contact['id']));
+ } else {
+ dba::update('contact', array('last-update' => $updated, 'failure_update' => $updated), array('id' => $contact['id']));
+ }
+ }
+ return;
+ }
+
+ $xml = false;
+
+ $t = $contact['last-update'];
+
+ if ($contact['subhub']) {
+ $poll_interval = Config::get('system', 'pushpoll_frequency');
+ $contact['priority'] = (($poll_interval !== false) ? intval($poll_interval) : 3);
+ $hub_update = false;
+
+ if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day")) {
+ $hub_update = true;
+ }
+ } else {
+ $hub_update = false;
+ }
+
+ $last_update = (($contact['last-update'] <= NULL_DATE)
+ ? datetime_convert('UTC', 'UTC', 'now - 7 days', ATOM_TIME)
+ : datetime_convert('UTC', 'UTC', $contact['last-update'], ATOM_TIME)
+ );
+
+ // Update the contact entry
+ if (($contact['network'] === NETWORK_OSTATUS) || ($contact['network'] === NETWORK_DIASPORA) || ($contact['network'] === NETWORK_DFRN)) {
+ if (!PortableContact::reachable($contact['url'])) {
+ logger("Skipping probably dead contact ".$contact['url']);
+ return;
+ }
+
+ if (!update_contact($contact["id"])) {
+ Contact::markForArchival($contact);
+ logger('Contact is marked dead');
+ return;
+ } else {
+ Contact::unmarkForArchival($contact);
+ }
+ }
+
+ if ($importer_uid == 0) {
+ logger('Ignore public contacts');
+ return;
+ }
+
+ $r = q("SELECT `contact`.*, `user`.`page-flags` FROM `contact` INNER JOIN `user` on `contact`.`uid` = `user`.`uid` WHERE `user`.`uid` = %d AND `contact`.`self` = 1 LIMIT 1",
+ intval($importer_uid)
+ );
+
+ if (!DBM::is_result($r)) {
+ logger('No self contact for user '.$importer_uid);
+ return;
+ }
+
+ $importer = $r[0];
+
+ logger("onepoll: poll: ({$contact['id']}) IMPORTER: {$importer['name']}, CONTACT: {$contact['name']}");
+
+ if ($contact['network'] === NETWORK_DFRN) {
+ $idtosend = $orig_id = (($contact['dfrn-id']) ? $contact['dfrn-id'] : $contact['issued-id']);
+ if (intval($contact['duplex']) && $contact['dfrn-id']) {
+ $idtosend = '0:' . $orig_id;
+ }
+ if (intval($contact['duplex']) && $contact['issued-id']) {
+ $idtosend = '1:' . $orig_id;
+ }
+
+ // they have permission to write to us. We already filtered this in the contact query.
+ $perm = 'rw';
+
+ // But this may be our first communication, so set the writable flag if it isn't set already.
+
+ if (!intval($contact['writable'])) {
+ $fields = array('writable' => true);
+ dba::update('contact', $fields, array('id' => $contact['id']));
+ }
+
+ $url = $contact['poll'] . '?dfrn_id=' . $idtosend
+ . '&dfrn_version=' . DFRN_PROTOCOL_VERSION
+ . '&type=data&last_update=' . $last_update
+ . '&perm=' . $perm ;
+
+ $ret = z_fetch_url($url);
+
+ if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
+ return;
+ }
+
+ $handshake_xml = $ret['body'];
+
+ $html_code = $a->get_curl_code();
+
+ logger('onepoll: handshake with url ' . $url . ' returns xml: ' . $handshake_xml, LOGGER_DATA);
+
+
+ if (!strlen($handshake_xml) || ($html_code >= 400) || !$html_code) {
+ logger("$url appears to be dead - marking for death ");
+
+ // dead connection - might be a transient event, or this might
+ // mean the software was uninstalled or the domain expired.
+ // Will keep trying for one month.
+
+ Contact::markForArchival($contact);
+
+ // set the last-update so we don't keep polling
+ $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
+ dba::update('contact', $fields, array('id' => $contact['id']));
+
+ return;
+ }
+
+ if (!strstr($handshake_xml, '<')) {
+ logger('response from ' . $url . ' did not contain XML.');
+
+ Contact::markForArchival($contact);
+
+ $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
+ dba::update('contact', $fields, array('id' => $contact['id']));
+
+ return;
+ }
+
+
+ $res = parse_xml_string($handshake_xml);
+
+ if (intval($res->status) == 1) {
+ logger("$url replied status 1 - marking for death ");
+
+ // we may not be friends anymore. Will keep trying for one month.
+ // set the last-update so we don't keep polling
+ $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
+ dba::update('contact', $fields, array('id' => $contact['id']));
+
+ Contact::markForArchival($contact);
+ } elseif ($contact['term-date'] > NULL_DATE) {
+ logger("$url back from the dead - removing mark for death");
+ Contact::unmarkForArchival($contact);
+ }
+
+ if ((intval($res->status) != 0) || !strlen($res->challenge) || !strlen($res->dfrn_id)) {
+ return;
+ }
+
+ if (((float)$res->dfrn_version > 2.21) && ($contact['poco'] == '')) {
+ $fields = array('poco' => str_replace('/profile/', '/poco/', $contact['url']));
+ dba::update('contact', $fields, array('id' => $contact['id']));
+ }
+
+ $postvars = array();
+
+ $sent_dfrn_id = hex2bin((string) $res->dfrn_id);
+ $challenge = hex2bin((string) $res->challenge);
+
+ $final_dfrn_id = '';
+
+ if ($contact['duplex'] && strlen($contact['prvkey'])) {
+ openssl_private_decrypt($sent_dfrn_id, $final_dfrn_id, $contact['prvkey']);
+ openssl_private_decrypt($challenge, $postvars['challenge'], $contact['prvkey']);
+ } else {
+ openssl_public_decrypt($sent_dfrn_id, $final_dfrn_id, $contact['pubkey']);
+ openssl_public_decrypt($challenge, $postvars['challenge'], $contact['pubkey']);
+ }
+
+ $final_dfrn_id = substr($final_dfrn_id, 0, strpos($final_dfrn_id, '.'));
+
+ if (strpos($final_dfrn_id, ':') == 1) {
+ $final_dfrn_id = substr($final_dfrn_id, 2);
+ }
+
+ if ($final_dfrn_id != $orig_id) {
+ logger('ID did not decode: ' . $contact['id'] . ' orig: ' . $orig_id . ' final: ' . $final_dfrn_id);
+ // did not decode properly - cannot trust this site
+ return;
+ }
+
+ $postvars['dfrn_id'] = $idtosend;
+ $postvars['dfrn_version'] = DFRN_PROTOCOL_VERSION;
+ $postvars['perm'] = 'rw';
+
+ $xml = post_url($contact['poll'], $postvars);
+
+ } elseif (($contact['network'] === NETWORK_OSTATUS)
+ || ($contact['network'] === NETWORK_DIASPORA)
+ || ($contact['network'] === NETWORK_FEED)) {
+
+ // Upgrading DB fields from an older Friendica version
+ // Will only do this once per notify-enabled OStatus contact
+ // or if relationship changes
+
+ $stat_writeable = ((($contact['notify']) && ($contact['rel'] == CONTACT_IS_FOLLOWER || $contact['rel'] == CONTACT_IS_FRIEND)) ? 1 : 0);
+
+ // Contacts from OStatus are always writable
+ if ($contact['network'] === NETWORK_OSTATUS) {
+ $stat_writeable = 1;
+ }
+
+ if ($stat_writeable != $contact['writable']) {
+ $fields = array('writable' => $stat_writeable);
+ dba::update('contact', $fields, array('id' => $contact['id']));
+ }
+
+ // Are we allowed to import from this person?
+
+ if ($contact['rel'] == CONTACT_IS_FOLLOWER || $contact['blocked'] || $contact['readonly']) {
+ return;
+ }
+
+ $cookiejar = tempnam(get_temppath(), 'cookiejar-onepoll-');
+ $ret = z_fetch_url($contact['poll'], false, $redirects, array('cookiejar' => $cookiejar));
+
+ if ($ret['errno'] == CURLE_OPERATION_TIMEDOUT) {
+ return;
+ }
+
+ $xml = $ret['body'];
+
+ unlink($cookiejar);
+ } elseif ($contact['network'] === NETWORK_MAIL || $contact['network'] === NETWORK_MAIL2) {
+
+ logger("Mail: Fetching for ".$contact['addr'], LOGGER_DEBUG);
+
+ $mail_disabled = ((function_exists('imap_open') && (! Config::get('system', 'imap_disabled'))) ? 0 : 1);
+ if ($mail_disabled) {
+ return;
+ }
+
+ logger("Mail: Enabled", LOGGER_DEBUG);
+
+ $mbox = null;
+ $x = dba::select('user', array('prvkey'), array('uid' => $importer_uid), array('limit' => 1));
+
+ $condition = array("`server` != '' AND `uid` = ?", $importer_uid);
+ $mailconf = dba::select('mailacct', array(), $condition, array('limit' => 1));
+ if (DBM::is_result($x) && DBM::is_result($mailconf)) {
+ $mailbox = construct_mailbox_name($mailconf);
+ $password = '';
+ openssl_private_decrypt(hex2bin($mailconf['pass']), $password, $x['prvkey']);
+ $mbox = email_connect($mailbox, $mailconf['user'], $password);
+ unset($password);
+ logger("Mail: Connect to " . $mailconf['user']);
+ if ($mbox) {
+ $fields = array('last_check' => datetime_convert());
+ dba::update('mailacct', $fields, array('id' => $mailconf['id']));
+ logger("Mail: Connected to " . $mailconf['user']);
+ } else {
+ logger("Mail: Connection error ".$mailconf['user']." ".print_r(imap_errors(), true));
+ }
+ }
+
+ if ($mbox) {
+ $msgs = email_poll($mbox, $contact['addr']);
+
+ if (count($msgs)) {
+ logger("Mail: Parsing ".count($msgs)." mails from ".$contact['addr']." for ".$mailconf['user'], LOGGER_DEBUG);
+
+ $metas = email_msg_meta($mbox,implode(',', $msgs));
+ if (count($metas) != count($msgs)) {
+ logger("onepoll: for " . $mailconf['user'] . " there are ". count($msgs) . " messages but received " . count($metas) . " metas", LOGGER_DEBUG);
+ } else {
+ $msgs = array_combine($msgs, $metas);
+
+ foreach ($msgs as $msg_uid => $meta) {
+ logger("Mail: Parsing mail ".$msg_uid, LOGGER_DATA);
+
+ $datarray = array();
+ $datarray['verb'] = ACTIVITY_POST;
+ $datarray['object-type'] = ACTIVITY_OBJ_NOTE;
+ // $meta = email_msg_meta($mbox, $msg_uid);
+ // $headers = email_msg_headers($mbox, $msg_uid);
+
+ $datarray['uri'] = msgid2iri(trim($meta->message_id, '<>'));
+
+ // Have we seen it before?
+ $fields = array('deleted', 'id');
+ $condition = array('uid' => $importer_uid, 'uri' => $datarray['uri']);
+ $r = dba::select('item', $fields, $condition, array('limit' => 1));
+
+ if (DBM::is_result($r)) {
+ logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user']." UID: ".$importer_uid." URI: ".$datarray['uri'],LOGGER_DEBUG);
+
+ // Only delete when mails aren't automatically moved or deleted
+ if (($mailconf['action'] != 1) && ($mailconf['action'] != 3))
+ if ($meta->deleted && ! $r['deleted']) {
+ $fields = array('deleted' => true, 'changed' => datetime_convert());
+ dba::update('item', $fields, array('id' => $r['id']));
+ }
+
+ switch ($mailconf['action']) {
+ case 0:
+ logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user'].". Doing nothing.", LOGGER_DEBUG);
+ break;
+ case 1:
+ logger("Mail: Deleting ".$msg_uid." for ".$mailconf['user']);
+ imap_delete($mbox, $msg_uid, FT_UID);
+ break;
+ case 2:
+ logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf['user']);
+ imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
+ break;
+ case 3:
+ logger("Mail: Moving ".$msg_uid." to ".$mailconf['movetofolder']." for ".$mailconf['user']);
+ imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
+ if ($mailconf['movetofolder'] != "") {
+ imap_mail_move($mbox, $msg_uid, $mailconf['movetofolder'], FT_UID);
+ }
+ break;
+ }
+ continue;
+ }
+
+
+ // look for a 'references' or an 'in-reply-to' header and try to match with a parent item we have locally.
+ $raw_refs = ((property_exists($meta, 'references')) ? str_replace("\t", '', $meta->references) : '');
+ if (!trim($raw_refs)) {
+ $raw_refs = ((property_exists($meta, 'in_reply_to')) ? str_replace("\t", '', $meta->in_reply_to) : '');
+ }
+ $raw_refs = trim($raw_refs); // Don't allow a blank reference in $refs_arr
+
+ if ($raw_refs) {
+ $refs_arr = explode(' ', $raw_refs);
+ if (count($refs_arr)) {
+ for ($x = 0; $x < count($refs_arr); $x ++) {
+ $refs_arr[$x] = "'" . msgid2iri(str_replace(array('<', '>', ' '),array('', '', ''),dbesc($refs_arr[$x]))) . "'";
+ }
+ }
+ $qstr = implode(',', $refs_arr);
+ $r = q("SELECT `parent-uri` FROM `item` USE INDEX (`uid_uri`) WHERE `uri` IN ($qstr) AND `uid` = %d LIMIT 1",
+ intval($importer_uid)
+ );
+ if (DBM::is_result($r)) {
+ $datarray['parent-uri'] = $r[0]['parent-uri']; // Set the parent as the top-level item
+ }
+ }
+
+ // Decoding the header
+ $subject = imap_mime_header_decode($meta->subject);
+ $datarray['title'] = "";
+ foreach ($subject as $subpart) {
+ if ($subpart->charset != "default") {
+ $datarray['title'] .= iconv($subpart->charset, 'UTF-8//IGNORE', $subpart->text);
+ } else {
+ $datarray['title'] .= $subpart->text;
+ }
+ }
+ $datarray['title'] = notags(trim($datarray['title']));
+
+ //$datarray['title'] = notags(trim($meta->subject));
+ $datarray['created'] = datetime_convert('UTC', 'UTC', $meta->date);
+
+ // Is it a reply?
+ $reply = ((substr(strtolower($datarray['title']), 0, 3) == "re:") ||
+ (substr(strtolower($datarray['title']), 0, 3) == "re-") ||
+ ($raw_refs != ""));
+
+ // Remove Reply-signs in the subject
+ $datarray['title'] = self::RemoveReply($datarray['title']);
+
+ // If it seems to be a reply but a header couldn't be found take the last message with matching subject
+ if (empty($datarray['parent-uri']) && $reply) {
+ $r = q("SELECT `parent-uri` FROM `item` WHERE `title` = \"%s\" AND `uid` = %d AND `network` = '%s' ORDER BY `created` DESC LIMIT 1",
+ dbesc(protect_sprintf($datarray['title'])),
+ intval($importer_uid),
+ dbesc(NETWORK_MAIL));
+ if (DBM::is_result($r)) {
+ $datarray['parent-uri'] = $r[0]['parent-uri'];
+ }
+ }
+
+ if (empty($datarray['parent-uri'])) {
+ $datarray['parent-uri'] = $datarray['uri'];
+ }
+
+ $r = email_get_msg($mbox, $msg_uid, $reply);
+ if (!$r) {
+ logger("Mail: can't fetch msg ".$msg_uid." for ".$mailconf['user']);
+ continue;
+ }
+ $datarray['body'] = escape_tags($r['body']);
+ $datarray['body'] = limit_body_size($datarray['body']);
+
+ logger("Mail: Importing ".$msg_uid." for ".$mailconf['user']);
+
+ /// @TODO Adding a gravatar for the original author would be cool
+
+ $from = imap_mime_header_decode($meta->from);
+ $fromdecoded = "";
+ foreach ($from as $frompart) {
+ if ($frompart->charset != "default") {
+ $fromdecoded .= iconv($frompart->charset, 'UTF-8//IGNORE', $frompart->text);
+ } else {
+ $fromdecoded .= $frompart->text;
+ }
+ }
+
+ $fromarr = imap_rfc822_parse_adrlist($fromdecoded, $a->get_hostname());
+
+ $frommail = $fromarr[0]->mailbox."@".$fromarr[0]->host;
+
+ if (isset($fromarr[0]->personal)) {
+ $fromname = $fromarr[0]->personal;
+ } else {
+ $fromname = $frommail;
+ }
+
+ $datarray['author-name'] = $fromname;
+ $datarray['author-link'] = "mailto:".$frommail;
+ $datarray['author-avatar'] = $contact['photo'];
+
+ $datarray['owner-name'] = $contact['name'];
+ $datarray['owner-link'] = "mailto:".$contact['addr'];
+ $datarray['owner-avatar'] = $contact['photo'];
+
+ $datarray['uid'] = $importer_uid;
+ $datarray['contact-id'] = $contact['id'];
+ if ($datarray['parent-uri'] === $datarray['uri']) {
+ $datarray['private'] = 1;
+ }
+ if (($contact['network'] === NETWORK_MAIL) && (!PConfig::get($importer_uid, 'system', 'allow_public_email_replies'))) {
+ $datarray['private'] = 1;
+ $datarray['allow_cid'] = '<' . $contact['id'] . '>';
+ }
+
+ $stored_item = item_store($datarray);
+
+ $condition = array('parent-uri' => $datarray['parent-uri'], 'uid' => $importer_uid);
+ dba::update('item', array('last-child' => false), $condition);
+
+ dba::update('item', array('last-child' => true), array('id' => $stored_item));
+
+ switch ($mailconf['action']) {
+ case 0:
+ logger("Mail: Seen before ".$msg_uid." for ".$mailconf['user'].". Doing nothing.", LOGGER_DEBUG);
+ break;
+ case 1:
+ logger("Mail: Deleting ".$msg_uid." for ".$mailconf['user']);
+ imap_delete($mbox, $msg_uid, FT_UID);
+ break;
+ case 2:
+ logger("Mail: Mark as seen ".$msg_uid." for ".$mailconf['user']);
+ imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
+ break;
+ case 3:
+ logger("Mail: Moving ".$msg_uid." to ".$mailconf['movetofolder']." for ".$mailconf['user']);
+ imap_setflag_full($mbox, $msg_uid, "\\Seen", ST_UID);
+ if ($mailconf['movetofolder'] != "") {
+ imap_mail_move($mbox, $msg_uid, $mailconf['movetofolder'], FT_UID);
+ }
+ break;
+ }
+ }
+ }
+ } else {
+ logger("Mail: no mails for ".$mailconf['user']);
+ }
+
+ logger("Mail: closing connection for ".$mailconf['user']);
+ imap_close($mbox);
+ }
+ }
+
+ if ($xml) {
+ logger('received xml : ' . $xml, LOGGER_DATA);
+ if (!strstr($xml, '<')) {
+ logger('post_handshake: response from ' . $url . ' did not contain XML.');
+
+ $fields = array('last-update' => datetime_convert(), 'failure_update' => datetime_convert());
+ dba::update('contact', $fields, array('id' => $contact['id']));
+
+ return;
+ }
+
+
+ logger("Consume feed of contact ".$contact['id']);
+
+ consume_feed($xml, $importer, $contact, $hub, 1, 1);
+
+ // do it twice. Ensures that children of parents which may be later in the stream aren't tossed
+
+ consume_feed($xml, $importer, $contact, $hub, 1, 2);
+
+ $hubmode = 'subscribe';
+ if ($contact['network'] === NETWORK_DFRN || $contact['blocked'] || $contact['readonly']) {
+ $hubmode = 'unsubscribe';
+ }
+
+ if (($contact['network'] === NETWORK_OSTATUS || $contact['network'] == NETWORK_FEED) && (! $contact['hub-verify'])) {
+ $hub_update = true;
+ }
+
+ if ($force) {
+ $hub_update = true;
+ }
+
+ logger("Contact ".$contact['id']." returned hub: ".$hub." Network: ".$contact['network']." Relation: ".$contact['rel']." Update: ".$hub_update);
+
+ if (strlen($hub) && $hub_update && (($contact['rel'] != CONTACT_IS_FOLLOWER) || $contact['network'] == NETWORK_FEED)) {
+ logger('hub ' . $hubmode . ' : ' . $hub . ' contact name : ' . $contact['name'] . ' local user : ' . $importer['name']);
+ $hubs = explode(',', $hub);
+ if (count($hubs)) {
+ foreach ($hubs as $h) {
+ $h = trim($h);
+ if (!strlen($h)) {
+ continue;
+ }
+ subscribe_to_hub($h, $importer, $contact, $hubmode);
+ }
+ }
+ }
+
+ $updated = datetime_convert();
+
+ dba::update('contact', array('last-update' => $updated, 'success_update' => $updated), array('id' => $contact['id']));
+ dba::update('gcontact', array('last_contact' => $updated), array('nurl' => $contact['nurl']));
+ } elseif (in_array($contact["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS, NETWORK_FEED))) {
+ $updated = datetime_convert();
+
+ dba::update('contact', array('last-update' => $updated, 'failure_update' => $updated), array('id' => $contact['id']));
+ dba::update('gcontact', array('last_failure' => $updated), array('nurl' => $contact['nurl']));
+ } else {
+ dba::update('contact', array('last-update' => $updated), array('id' => $contact['id']));
+ }
+
+ return;
+ }
+
+ private static function RemoveReply($subject) {
+ while (in_array(strtolower(substr($subject, 0, 3)), array("re:", "aw:"))) {
+ $subject = trim(substr($subject, 4));
+ }
+
+ return $subject;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/ProfileUpdate.php
+ * @brief Send updated profile data to Diaspora
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Protocol\Diaspora;
+
+class ProfileUpdate {
+ public static function execute($uid = 0) {
+ if (empty($uid)) {
+ return;
+ }
+
+ Diaspora::sendProfile($uid);
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/PubSubPublish.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\App;
+use Friendica\Core\System;
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Protocol\OStatus;
+
+require_once 'include/items.php';
+
+class PubSubPublish {
+ public static function execute($pubsubpublish_id = 0)
+ {
+ global $a;
+
+ if ($pubsubpublish_id == 0) {
+ // We'll push to each subscriber that has push > 0,
+ // i.e. there has been an update (set in notifier.php).
+ $r = q("SELECT `id`, `callback_url` FROM `push_subscriber` WHERE `push` > 0 ORDER BY `last_update` DESC");
+
+ foreach ($r as $rr) {
+ logger("Publish feed to ".$rr["callback_url"], LOGGER_DEBUG);
+ Worker::add(array('priority' => PRIORITY_HIGH, 'created' => $a->queue['created'], 'dont_fork' => true),
+ 'PubSubPublish', (int)$rr["id"]);
+ }
+ }
+
+ self::publish($pubsubpublish_id);
+
+ return;
+ }
+
+ private static function publish($id) {
+ global $a;
+
+ $r = q("SELECT * FROM `push_subscriber` WHERE `id` = %d", intval($id));
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ $rr = $r[0];
+
+ /// @todo Check server status with PortableContact::checkServer()
+ // Before this can be done we need a way to safely detect the server url.
+
+ logger("Generate feed of user ".$rr['nickname']." to ".$rr['callback_url']." - last updated ".$rr['last_update'], LOGGER_DEBUG);
+
+ $last_update = $rr['last_update'];
+ $params = OStatus::feed($a, $rr['nickname'], $last_update);
+
+ if (!$params) {
+ return;
+ }
+
+ $hmac_sig = hash_hmac("sha1", $params, $rr['secret']);
+
+ $headers = array("Content-type: application/atom+xml",
+ sprintf("Link: <%s>;rel=hub,<%s>;rel=self",
+ System::baseUrl().'/pubsubhubbub/'.$rr['nickname'],
+ $rr['topic']),
+ "X-Hub-Signature: sha1=".$hmac_sig);
+
+ logger('POST '.print_r($headers, true)."\n".$params, LOGGER_DEBUG);
+
+ post_url($rr['callback_url'], $params, $headers);
+ $ret = $a->get_curl_code();
+
+ if ($ret >= 200 && $ret <= 299) {
+ logger('successfully pushed to '.$rr['callback_url']);
+
+ // set last_update to the "created" date of the last item, and reset push=0
+ q("UPDATE `push_subscriber` SET `push` = 0, last_update = '%s' WHERE id = %d",
+ dbesc($last_update),
+ intval($rr['id']));
+
+ } else {
+ logger('error when pushing to '.$rr['callback_url'].' HTTP: '.$ret);
+
+ // we use the push variable also as a counter, if we failed we
+ // increment this until some upper limit where we give up
+ $new_push = intval($rr['push']) + 1;
+
+ if ($new_push > 30) // OK, let's give up
+ $new_push = 0;
+
+ q("UPDATE `push_subscriber` SET `push` = %d WHERE id = %d",
+ $new_push,
+ intval($rr['id']));
+ }
+ }
+}
--- /dev/null
+<?php
+
+/**
+ * @file src/Worker/Queue.php
+ */
+
+namespace Friendica\Worker;
+
+use Friendica\Core\Cache;
+use Friendica\Core\Config;
+use Friendica\Core\Worker;
+use Friendica\Database\DBM;
+use Friendica\Protocol\Diaspora;
+use Friendica\Protocol\DFRN;
+use Friendica\Protocol\PortableContact;
+use dba;
+
+require_once 'include/queue_fn.php';
+require_once 'include/datetime.php';
+require_once 'include/items.php';
+require_once 'include/bbcode.php';
+require_once 'include/salmon.php';
+
+class Queue
+{
+ public static function execute($queue_id = 0)
+ {
+ global $a;
+
+ $cachekey_deadguy = 'queue_run:deadguy:';
+ $cachekey_server = 'queue_run:server:';
+
+ if (!$queue_id) {
+ logger('queue: start');
+
+ // Handling the pubsubhubbub requests
+ Worker::add(array('priority' => PRIORITY_HIGH, 'dont_fork' => true), 'PubSubPublish');
+
+ $r = q(
+ "SELECT `queue`.*, `contact`.`name`, `contact`.`uid` FROM `queue`
+ INNER JOIN `contact` ON `queue`.`cid` = `contact`.`id`
+ WHERE `queue`.`created` < UTC_TIMESTAMP() - INTERVAL 3 DAY"
+ );
+
+ if (DBM::is_result($r)) {
+ foreach ($r as $rr) {
+ logger('Removing expired queue item for ' . $rr['name'] . ', uid=' . $rr['uid']);
+ logger('Expired queue data: ' . $rr['content'], LOGGER_DATA);
+ }
+ q("DELETE FROM `queue` WHERE `created` < UTC_TIMESTAMP() - INTERVAL 3 DAY");
+ }
+
+ /*
+ * For the first 12 hours we'll try to deliver every 15 minutes
+ * After that, we'll only attempt delivery once per hour.
+ */
+ $r = q("SELECT `id` FROM `queue` WHERE ((`created` > UTC_TIMESTAMP() - INTERVAL 12 HOUR AND `last` < UTC_TIMESTAMP() - INTERVAL 15 MINUTE) OR (`last` < UTC_TIMESTAMP() - INTERVAL 1 HOUR)) ORDER BY `cid`, `created`");
+
+ call_hooks('queue_predeliver', $a, $r);
+
+ if (DBM::is_result($r)) {
+ foreach ($r as $q_item) {
+ logger('Call queue for id ' . $q_item['id']);
+ Worker::add(array('priority' => PRIORITY_LOW, 'dont_fork' => true), "Queue", (int) $q_item['id']);
+ }
+ }
+ return;
+ }
+
+
+ // delivering
+
+ $r = q(
+ "SELECT * FROM `queue` WHERE `id` = %d LIMIT 1",
+ intval($queue_id)
+ );
+
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ $q_item = $r[0];
+
+ $contact = dba::select('contact', [], ['id' => $q_item['cid']], ['limit' => 1]);
+ if (!DBM::is_result($contact)) {
+ remove_queue_item($q_item['id']);
+ return;
+ }
+
+ $dead = Cache::get($cachekey_deadguy . $contact['notify']);
+
+ if (!is_null($dead) && $dead) {
+ logger('queue: skipping known dead url: ' . $contact['notify']);
+ update_queue_time($q_item['id']);
+ return;
+ }
+
+ $server = PortableContact::detectServer($contact['url']);
+
+ if ($server != "") {
+ $vital = Cache::get($cachekey_server . $server);
+
+ if (is_null($vital)) {
+ logger("Check server " . $server . " (" . $contact["network"] . ")");
+
+ $vital = PortableContact::checkServer($server, $contact["network"], true);
+ Cache::set($cachekey_server . $server, $vital, CACHE_QUARTER_HOUR);
+ }
+
+ if (!is_null($vital) && !$vital) {
+ logger('queue: skipping dead server: ' . $server);
+ update_queue_time($q_item['id']);
+ return;
+ }
+ }
+
+ $user = dba::select('user', [], ['uid' => $contact['uid']], ['limit' => 1]);
+ if (!DBM::is_result($user)) {
+ remove_queue_item($q_item['id']);
+ return;
+ }
+
+ $data = $q_item['content'];
+ $public = $q_item['batch'];
+ $owner = $user;
+
+ $deliver_status = 0;
+
+ switch ($contact['network']) {
+ case NETWORK_DFRN:
+ logger('queue: dfrndelivery: item ' . $q_item['id'] . ' for ' . $contact['name'] . ' <' . $contact['url'] . '>');
+ $deliver_status = DFRN::deliver($owner, $contact, $data);
+
+ if ($deliver_status == (-1)) {
+ update_queue_time($q_item['id']);
+ Cache::set($cachekey_deadguy . $contact['notify'], true, CACHE_QUARTER_HOUR);
+ } else {
+ remove_queue_item($q_item['id']);
+ }
+ break;
+ case NETWORK_OSTATUS:
+ if ($contact['notify']) {
+ logger('queue: slapdelivery: item ' . $q_item['id'] . ' for ' . $contact['name'] . ' <' . $contact['url'] . '>');
+ $deliver_status = slapper($owner, $contact['notify'], $data);
+
+ if ($deliver_status == (-1)) {
+ update_queue_time($q_item['id']);
+ Cache::set($cachekey_deadguy . $contact['notify'], true, CACHE_QUARTER_HOUR);
+ } else {
+ remove_queue_item($q_item['id']);
+ }
+ }
+ break;
+ case NETWORK_DIASPORA:
+ if ($contact['notify']) {
+ logger('queue: diaspora_delivery: item ' . $q_item['id'] . ' for ' . $contact['name'] . ' <' . $contact['url'] . '>');
+ $deliver_status = Diaspora::transmit($owner, $contact, $data, $public, true);
+
+ if ($deliver_status == (-1)) {
+ update_queue_time($q_item['id']);
+ Cache::set($cachekey_deadguy . $contact['notify'], true, CACHE_QUARTER_HOUR);
+ } else {
+ remove_queue_item($q_item['id']);
+ }
+ }
+ break;
+
+ default:
+ $params = array('owner' => $owner, 'contact' => $contact, 'queue' => $q_item, 'result' => false);
+ call_hooks('queue_deliver', $a, $params);
+
+ if ($params['result']) {
+ remove_queue_item($q_item['id']);
+ } else {
+ update_queue_time($q_item['id']);
+ }
+ break;
+ }
+ logger('Deliver status ' . (int) $deliver_status . ' for item ' . $q_item['id'] . ' to ' . $contact['name'] . ' <' . $contact['url'] . '>');
+
+ return;
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/RemoveContact.php
+ * @brief Removes orphaned data from deleted contacts
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use dba;
+
+class RemoveContact {
+ public static function execute($id) {
+
+ // Only delete if the contact doesn't exist (anymore)
+ $r = dba::exists('contact', array('id' => $id));
+ if ($r) {
+ return;
+ }
+
+ // Now we delete all the depending table entries
+ dba::delete('contact', array('id' => $id));
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/SpoolPost.php
+ * @brief Posts items that wer spooled because they couldn't be posted.
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+
+require_once("include/items.php");
+
+class SpoolPost {
+ public static function execute() {
+ $path = get_spoolpath();
+
+ if (($path != '') && is_writable($path)){
+ if ($dh = opendir($path)) {
+ while (($file = readdir($dh)) !== false) {
+
+ // It is not named like a spool file, so we don't care.
+ if (substr($file, 0, 5) != "item-") {
+ continue;
+ }
+
+ $fullfile = $path."/".$file;
+
+ // We don't care about directories either
+ if (filetype($fullfile) != "file") {
+ continue;
+ }
+
+ // We can't read or write the file? So we don't care about it.
+ if (!is_writable($fullfile) || !is_readable($fullfile)) {
+ continue;
+ }
+
+ $arr = json_decode(file_get_contents($fullfile), true);
+
+ // If it isn't an array then it is no spool file
+ if (!is_array($arr)) {
+ continue;
+ }
+
+ // Skip if it doesn't seem to be an item array
+ if (!isset($arr['uid']) && !isset($arr['uri']) && !isset($arr['network'])) {
+ continue;
+ }
+
+ $result = item_store($arr);
+
+ logger("Spool file ".$file." stored: ".$result, LOGGER_DEBUG);
+ unlink($fullfile);
+ }
+ closedir($dh);
+ }
+ }
+ }
+}
--- /dev/null
+<?php
+namespace Friendica\Worker;
+
+require_once("include/tags.php");
+
+class TagUpdate {
+ public static function execute() {
+ update_items();
+ }
+}
--- /dev/null
+<?php
+namespace Friendica\Worker;
+
+require_once("include/threads.php");
+
+class ThreadUpdate {
+ public static function execute() {
+ update_threads();
+ update_threads_mention();
+ }
+}
--- /dev/null
+<?php
+/**
+ * @file src/Worker/UpdateGcontact.php
+ */
+namespace Friendica\Worker;
+
+use Friendica\Core\Config;
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+use Friendica\Protocol\PortableContact;
+
+class UpdateGContact {
+ public static function execute($contact_id) {
+ global $a;
+
+ logger('update_gcontact: start');
+
+ if (empty($contact_id)) {
+ logger('update_gcontact: no contact');
+ return;
+ }
+
+ $r = q("SELECT * FROM `gcontact` WHERE `id` = %d", intval($contact_id));
+
+ if (!DBM::is_result($r)) {
+ return;
+ }
+
+ if (!in_array($r[0]["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
+ return;
+ }
+
+ $data = Probe::uri($r[0]["url"]);
+
+ if (!in_array($data["network"], array(NETWORK_DFRN, NETWORK_DIASPORA, NETWORK_OSTATUS))) {
+ if ($r[0]["server_url"] != "")
+ PortableContact::checkServer($r[0]["server_url"], $r[0]["network"]);
+
+ q("UPDATE `gcontact` SET `last_failure` = '%s' WHERE `id` = %d",
+ dbesc(datetime_convert()), intval($contact_id));
+ return;
+ }
+
+ if (($data["name"] == "") && ($r[0]['name'] != ""))
+ $data["name"] = $r[0]['name'];
+
+ if (($data["nick"] == "") && ($r[0]['nick'] != ""))
+ $data["nick"] = $r[0]['nick'];
+
+ if (($data["addr"] == "") && ($r[0]['addr'] != ""))
+ $data["addr"] = $r[0]['addr'];
+
+ if (($data["photo"] == "") && ($r[0]['photo'] != ""))
+ $data["photo"] = $r[0]['photo'];
+
+
+ q("UPDATE `gcontact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `photo` = '%s'
+ WHERE `id` = %d",
+ dbesc($data["name"]),
+ dbesc($data["nick"]),
+ dbesc($data["addr"]),
+ dbesc($data["photo"]),
+ intval($contact_id)
+ );
+
+ q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `photo` = '%s'
+ WHERE `uid` = 0 AND `addr` = '' AND `nurl` = '%s'",
+ dbesc($data["name"]),
+ dbesc($data["nick"]),
+ dbesc($data["addr"]),
+ dbesc($data["photo"]),
+ dbesc(normalise_link($data["url"]))
+ );
+
+ q("UPDATE `contact` SET `addr` = '%s'
+ WHERE `uid` != 0 AND `addr` = '' AND `nurl` = '%s'",
+ dbesc($data["addr"]),
+ dbesc(normalise_link($data["url"]))
+ );
+ }
+}
foreach ($r as $rr) {
$found = true;
do {
- $guid = substr(random_string(),0,16);
+ $guid = random_string(16);
$x = q("SELECT `uid` FROM `user` WHERE `guid` = '%s' LIMIT 1",
dbesc($guid)
);
if (!$r)
return UPDATE_FAILED;
- Worker::add(PRIORITY_LOW, "threadupdate");
+ Worker::add(PRIORITY_LOW, "ThreadUpdate");
return UPDATE_SUCCESS;
}
function update_1180() {
// Fill the new fields in the term table.
- Worker::add(PRIORITY_LOW, "tagupdate");
+ Worker::add(PRIORITY_LOW, "TagUpdate");
return UPDATE_SUCCESS;
}
--- /dev/null
+# Bookmarklet-share2friendica
+
+Javascript bookmarklet to share websites with your friendica account
+
+## Getting Started
+
+### Installing
+
+Open the file bookmarklet-share2friendica.js and change 'YourFriendicaDoomain.tld" with your friendica domain
+
+If you friendica is at https://myfriend.myfami.ly/ , the original ...
+```javascript
+javascript:(function(){f='https://YourFriendicaDomain.tld/bookmarklet/?url='+encodeURIC....
+```
+... has to be changed to ...
+
+```javascript
+javascript:(function(){f='https://myfriend.myfami.ly/bookmarklet/?url='+encodeURIC....
+```
+
+*Please copy the whole script, not only the part mentioned here!*
+
+Then create a new bookmark, give it a name like "share2Friendica" and paste the script in the address field. Save it. Now you can click on that bookmarklet every time you want to share a website, you are currently reading. A new small window will open where title is prefilled and the website you want to share is put as attachement in the body of the new post.
+
+## Additional notes if it doesn't work
+
+* Make sure the site you want to share is allowed to run javascript. (enable it in your script blocker)
+* Check the apostrophes that are used. Sometimes it is changed by the copy and paste process depending on the editor you are using, or if you copy it from a website. Correct it and it will work again.
+
+
+
+## Authors
+
+* **diaspora** - *Initial work* - [Share all teh internetz!](https://share.diasporafoundation.org/about.html)
+* **hoergen** - *Adaptation to Friendica (2017)* - [hoergen.org](https://hoergen.org)
+
+## License
+
+This project is licensed under the same license like friendica
+
+## Acknowledgments
+
+* Hat tip to anyone who's code was used
+* Hat tip to everyone who does everyday a little something ot make this world better
+* Had tip but spent it
+
+
--- /dev/null
+javascript:(function(){f='https://YourFriendicaDomain.tld/bookmarklet/?url='+encodeURIComponent(window.location.href)+'&title='+encodeURIComponent(document.title);a=function(){if(!window.open(f+'&jump=doclose','friendica','location=yes,links=no,scrollbars=no,toolbar=no,width=620,height=250'))location.href=f+'jump=yes'};if(/Firefox/.test(navigator.userAgent)){setTimeout(a,0)}else{a()}})()
#!/usr/bin/env php
<?php
-// Red config utility
+/**
+ * @brief tool to access the system config from the CLI
+ *
+ * With this script you can access the system configuration of your node from
+ * the CLI. You can do both, reading current values stored in the database and
+ * set new values to config variables.
+ *
+ * Usage:
+ * If you specify no parameters at the CLI, the script will list all config
+ * variables defined.
+ *
+ * If you specify one parameter, the scipt will list all config variables
+ * defined in this section of the configuration (e.g. "system").
+ *
+ * If you specify two parameters, the scipt will show you the current value
+ * of the named configuration setting. (e.g. "system loglevel")
+ *
+ * If you specify three parameters, the named configuration setting will be
+ * set to the value of the last parameter. (e.g. "system loglevel 0" will
+ * disable logging)
+ **/
use Friendica\Core\Config;
-require_once('include/cli_startup.php');
+require_once 'boot.php';
+require_once 'include/dba.php';
+require_once 'include/text.php';
+$a = get_app();
+require_once '.htconfig.php';
-cli_startup();
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
if($argc > 3) {
Config::set($argv[1],$argv[2],$argv[3]);
}
if($argc == 2) {
- load_config($argv[1]);
- foreach($a->config[$argv[1]] as $k => $x) {
- echo "config[{$argv[1]}][{$k}] = " . $x . "\n";
+ Config::load($argv[1]);
+ if (!is_null($a->config[$argv[1]])) {
+ foreach($a->config[$argv[1]] as $k => $x) {
+ echo "config[{$argv[1]}][{$k}] = " . $x . "\n";
+ }
+ } else {
+ echo "config section '$argv[1]' returned nothing.\n";
}
}
Abinoam P. Marques Jr.
Abrax
Adam Jurkiewicz
+Adam Magness
Albert
Alberto Díaz Tormo
Alex
+Alexander Fortin
Alexander Kampmann
Alexandre Alapetite
AlfredSK
hauke
Hauke Altmann
Hauke Zühl
+Herbert Thielen
+hoergen
Hubert Kościański
Hypolite Petovan
irhen
Matthew Exon
Matthias
Matthias Moritz
+Mauro Batini
Max Weller
mhnxo
Michael Johnston
Rafael Garau
Rainulf Pineda
Ralph
+Ratten
rcmaniac
rebeka-catalina
repat
RJ Madsen
Roland Häder
Rui Andrada
+S.Krumbholz
Sakałoŭ Alaksiej
Sam
Sandro Santilli
+++ /dev/null
-<?php
-/**
- * @file util/daemon.php
- * @brief Run the poller from a daemon.
- *
- * This script was taken from http://php.net/manual/en/function.pcntl-fork.php
- */
-function shutdown() {
- posix_kill(posix_getpid(), SIGHUP);
-}
-
-if (in_array("start", $_SERVER["argv"])) {
- $mode = "start";
-}
-
-if (in_array("stop", $_SERVER["argv"])) {
- $mode = "stop";
-}
-
-if (in_array("status", $_SERVER["argv"])) {
- $mode = "status";
-}
-
-if (!isset($mode)) {
- die("Please use either 'start', 'stop' or 'status'.\n");
-}
-
-@include(".htconfig.php");
-
-if (!isset($pidfile)) {
- die('Please specify a pid file in the variable $pidfile in the .htconfig.php. For example:'."\n".
- '$pidfile = "/path/to/daemon.pid";'."\n");
-}
-
-if (in_array($mode, array("stop", "status"))) {
- $pid = @file_get_contents($pidfile);
-
- if (!$pid) {
- die("Pidfile wasn't found. Is the daemon running?\n");
- }
-}
-
-if ($mode == "status") {
- if (posix_kill($pid, 0)) {
- die("Daemon process $pid is running.\n");
- }
-
- unlink($pidfile);
-
- die("Daemon process $pid isn't running.\n");
-}
-
-if ($mode == "stop") {
- posix_kill($pid, SIGTERM);
-
- unlink($pidfile);
-
- die("Worker daemon process $pid was killed.\n");
-}
-
-echo "Starting worker daemon.\n";
-
-if (isset($a->config['php_path'])) {
- $php = $a->config['php_path'];
-} else {
- $php = "php";
-}
-
-// Switch over to daemon mode.
-if ($pid = pcntl_fork())
- return; // Parent
-
-fclose(STDIN); // Close all of the standard
-fclose(STDOUT); // file descriptors as we
-fclose(STDERR); // are running as a daemon.
-
-register_shutdown_function('shutdown');
-
-if (posix_setsid() < 0)
- return;
-
-if ($pid = pcntl_fork())
- return; // Parent
-
-$pid = getmypid();
-file_put_contents($pidfile, $pid);
-
-// Now running as a daemon.
-while (true) {
- // Just to be sure that this script really runs endlessly
- set_time_limit(0);
-
- // Call the poller
- $cmdline = $php.' include/poller.php';
-
- exec($cmdline);
-
- // Now sleep for 5 minutes
- sleep(300);
-}
+++ /dev/null
-<?php
-
-/**
- * @package util
- */
-
-use Friendica\App;
-use Friendica\Core\Config;
-
-/*
- * require boot.php
- */
-require_once("boot.php");
-
-if (empty($a)) {
- $a = new App(dirname(__DIR__));
-}
-@include(".htconfig.php");
-
-$lang = get_browser_language();
-load_translation_table($lang);
-
-require_once("include/dba.php");
-dba::connect($db_host, $db_user, $db_pass, $db_data, false);
-unset($db_host, $db_user, $db_pass, $db_data);
-
-$build = Config::get('system', 'build');
-
-echo "Old DB VERSION: " . $build . "\n";
-echo "New DB VERSION: " . DB_UPDATE_VERSION . "\n";
-
-
-if ($build != DB_UPDATE_VERSION) {
- echo "Updating database...";
- update_db($a);
- echo "Done\n";
-}
--- /dev/null
+#!/usr/bin/env php
+<?php
+
+/**
+ * @brief tool to block an account from the node
+ *
+ * With this tool, you can block an account in such a way, that no postings
+ * or comments this account writes are accepted to the node.
+ *
+ * Usage: pass the URL of the to be blocked account as only parameter
+ * at the command line when running this tool. E.g.
+ *
+ * $> util/global_community_block.php http://example.com/profile/bob
+ *
+ * will block bob@example.com.
+ *
+ * Author: Tobias Diekershoff
+ *
+ * License: AGPLv3 or later, same as Friendica
+ **/
+
+if ($argc != 2 || $argv[1] == "-h" || $argv[1] == "--help" || $argv[1] == "-?") {
+ echo "Usage: ".$argv[0]." [-h|profile_url]\r\n";
+ echo " -h, -?, --help ... show this help\r\n";
+ echo " profile_url ...... The URL of the profile you want to silence\r\n";
+ echo "\r\n";
+ echo "Example: block bob@example.com\r\n";
+ echo "$> ".$argv[0]." https://example.com/profiles/bob\r\n";
+ echo "\r\n";
+ exit(0);
+}
+
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+
+require_once 'boot.php';
+require_once 'include/dba.php';
+require_once 'include/text.php';
+$a = get_app();
+require_once '.htconfig.php';
+
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
+
+/**
+ * 1. make nurl from last parameter
+ * 2. check DB (contact) if there is a contact with uid=0 and that nurl, get the ID
+ * 3. set the flag hidden=1 for the contact entry with the found ID
+ **/
+$net = Probe::uri($argv[1]);
+if (in_array($net['network'], array(NETWORK_PHANTOM, NETWORK_MAIL))) {
+ echo 'This account seems not to exist.';
+ echo "\r\n";
+ exit(1);
+}
+$nurl = normalise_link($net['url']);
+$r = dba::select('contact', array('id'), array('nurl' => $nurl, 'uid' => 0), array('limit' => 1));
+if (DBM::is_result($r)) {
+ dba::update('contact', array('blocked' => true), array('id' => $r['id']));
+ echo "NOTICE: The account should be blocked from the node now\r\n";
+} else {
+ echo "NOTICE: Could not find any entry for this URL (".$nurl.")\r\n";
+}
+
+?>
--- /dev/null
+#!/usr/bin/env php
+<?php
+
+/**
+ * @brief tool to silence accounts on the global community page
+ *
+ * With this tool, you can silence an account on the global community page.
+ * Postings from silenced accounts will not be displayed on the community
+ * page. This silencing does only affect the display on the community page,
+ * accounts following the silenced accounts will still get their postings.
+ *
+ * Usage: pass the URL of the profile to be silenced account as only parameter
+ * at the command line when running this tool. E.g.
+ *
+ * $> util/global_community_silence.php http://example.com/profile/bob
+ *
+ * will silence bob@example.com so that his postings won't appear at
+ * the global community page.
+ *
+ * Author: Tobias Diekershoff
+ *
+ * License: AGPLv3 or later, same as Friendica
+ **/
+
+if ($argc != 2 || $argv[1] == "-h" || $argv[1] == "--help" || $argv[1] == "-?") {
+ echo "Usage: ".$argv[0]." [-h|profile_url]\r\n";
+ echo " -h, -?, --help ... show this help\r\n";
+ echo " profile_url ...... The URL of the profile you want to silence\r\n";
+ echo "\r\n";
+ echo "Example: Silence bob@example.com\r\n";
+ echo "$> ".$argv[0]." https://example.com/profiles/bob\r\n";
+ echo "\r\n";
+ exit(0);
+}
+
+use Friendica\Database\DBM;
+use Friendica\Network\Probe;
+
+require_once 'boot.php';
+require_once 'include/dba.php';
+require_once 'include/text.php';
+$a = get_app();
+require_once '.htconfig.php';
+
+dba::connect($db_host, $db_user, $db_pass, $db_data);
+unset($db_host, $db_user, $db_pass, $db_data);
+
+/**
+ * 1. make nurl from last parameter
+ * 2. check DB (contact) if there is a contact with uid=0 and that nurl, get the ID
+ * 3. set the flag hidden=1 for the contact entry with the found ID
+ **/
+$net = Probe::uri($argv[1]);
+if (in_array($net['network'], array(NETWORK_PHANTOM, NETWORK_MAIL))) {
+ echo "This account seems not to exist.";
+ echo "\r\n";
+ exit(1);
+}
+$nurl = normalise_link($net['url']);
+$r = dba::select("contact", array("id"), array("nurl" => $nurl, "uid" => 0), array("limit" => 1));
+if (DBM::is_result($r)) {
+ dba::update("contact", array("hidden" => true), array("id" => $r["id"]));
+ echo "NOTICE: The account should be silenced from the global community page\r\n";
+} else {
+ echo "NOTICE: Could not find any entry for this URL (".$nurl.")\r\n";
+}
+
+?>
path = os.path.abspath(argv[0].split('util/make_credits.py')[0])
print('> base directory is assumed to be: '+path)
# a place to store contributors
-contributors = ["Andi Stadler", "Vít Šesták 'v6ak'"]
+contributors = ["Andi Stadler", "Ratten", "Vít Šesták 'v6ak'"]
# get the contributors
print('> getting contributors to the friendica core repository')
p = subprocess.Popen(['git', 'shortlog', '--no-merges', '-s'],
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2017-11-07 07:03+0100\n"
+"POT-Creation-Date: 2017-11-27 09:19+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Content-Transfer-Encoding: 8bit\n"
-#: include/features.php:65
-msgid "General Features"
-msgstr ""
-
-#: include/features.php:67
-msgid "Multiple Profiles"
-msgstr ""
-
-#: include/features.php:67
-msgid "Ability to create multiple profiles"
-msgstr ""
-
-#: include/features.php:68
-msgid "Photo Location"
-msgstr ""
-
-#: include/features.php:68
-msgid ""
-"Photo metadata is normally stripped. This extracts the location (if present) "
-"prior to stripping metadata and links it to a map."
-msgstr ""
-
-#: include/features.php:69
-msgid "Export Public Calendar"
-msgstr ""
-
-#: include/features.php:69
-msgid "Ability for visitors to download the public calendar"
-msgstr ""
-
-#: include/features.php:74
-msgid "Post Composition Features"
-msgstr ""
-
-#: include/features.php:75
-msgid "Post Preview"
-msgstr ""
-
-#: include/features.php:75
-msgid "Allow previewing posts and comments before publishing them"
-msgstr ""
-
-#: include/features.php:76
-msgid "Auto-mention Forums"
-msgstr ""
-
-#: include/features.php:76
-msgid ""
-"Add/remove mention when a forum page is selected/deselected in ACL window."
-msgstr ""
-
-#: include/features.php:81
-msgid "Network Sidebar Widgets"
-msgstr ""
-
-#: include/features.php:82
-msgid "Search by Date"
-msgstr ""
-
-#: include/features.php:82
-msgid "Ability to select posts by date ranges"
-msgstr ""
-
-#: include/features.php:83 include/features.php:113
-msgid "List Forums"
-msgstr ""
-
-#: include/features.php:83
-msgid "Enable widget to display the forums your are connected with"
-msgstr ""
-
-#: include/features.php:84
-msgid "Group Filter"
-msgstr ""
-
-#: include/features.php:84
-msgid "Enable widget to display Network posts only from selected group"
-msgstr ""
-
-#: include/features.php:85
-msgid "Network Filter"
-msgstr ""
-
-#: include/features.php:85
-msgid "Enable widget to display Network posts only from selected network"
-msgstr ""
-
-#: include/features.php:86 mod/search.php:37 mod/network.php:196
-msgid "Saved Searches"
-msgstr ""
-
-#: include/features.php:86
-msgid "Save search terms for re-use"
-msgstr ""
-
-#: include/features.php:91
-msgid "Network Tabs"
-msgstr ""
-
-#: include/features.php:92
-msgid "Network Personal Tab"
-msgstr ""
-
-#: include/features.php:92
-msgid "Enable tab to display only Network posts that you've interacted on"
-msgstr ""
-
-#: include/features.php:93
-msgid "Network New Tab"
-msgstr ""
-
-#: include/features.php:93
-msgid "Enable tab to display only new Network posts (from the last 12 hours)"
-msgstr ""
-
-#: include/features.php:94
-msgid "Network Shared Links Tab"
-msgstr ""
-
-#: include/features.php:94
-msgid "Enable tab to display only Network posts with links in them"
-msgstr ""
-
-#: include/features.php:99
-msgid "Post/Comment Tools"
-msgstr ""
-
-#: include/features.php:100
-msgid "Multiple Deletion"
-msgstr ""
-
-#: include/features.php:100
-msgid "Select and delete multiple posts/comments at once"
-msgstr ""
-
-#: include/features.php:101
-msgid "Edit Sent Posts"
-msgstr ""
-
-#: include/features.php:101
-msgid "Edit and correct posts and comments after sending"
-msgstr ""
-
-#: include/features.php:102
-msgid "Tagging"
-msgstr ""
-
-#: include/features.php:102
-msgid "Ability to tag existing posts"
-msgstr ""
-
-#: include/features.php:103
-msgid "Post Categories"
-msgstr ""
-
-#: include/features.php:103
-msgid "Add categories to your posts"
-msgstr ""
-
-#: include/features.php:104 include/contact_widgets.php:167
-msgid "Saved Folders"
-msgstr ""
-
-#: include/features.php:104
-msgid "Ability to file posts under folders"
-msgstr ""
-
-#: include/features.php:105
-msgid "Dislike Posts"
-msgstr ""
-
-#: include/features.php:105
-msgid "Ability to dislike posts/comments"
-msgstr ""
-
-#: include/features.php:106
-msgid "Star Posts"
-msgstr ""
-
-#: include/features.php:106
-msgid "Ability to mark special posts with a star indicator"
-msgstr ""
-
-#: include/features.php:107
-msgid "Mute Post Notifications"
-msgstr ""
-
-#: include/features.php:107
-msgid "Ability to mute notifications for a thread"
-msgstr ""
-
-#: include/features.php:112
-msgid "Advanced Profile Settings"
-msgstr ""
-
-#: include/features.php:113
-msgid "Show visitors public community forums at the Advanced Profile Page"
-msgstr ""
-
-#: include/datetime.php:66 include/datetime.php:68 mod/profiles.php:697
-msgid "Miscellaneous"
-msgstr ""
-
-#: include/datetime.php:196 include/identity.php:655
-msgid "Birthday:"
-msgstr ""
-
-#: include/datetime.php:198 mod/profiles.php:720
-msgid "Age: "
-msgstr ""
-
-#: include/datetime.php:200
-msgid "YYYY-MM-DD or MM-DD"
-msgstr ""
-
-#: include/datetime.php:370
-msgid "never"
-msgstr ""
-
-#: include/datetime.php:376
-msgid "less than a second ago"
-msgstr ""
-
-#: include/datetime.php:379
-msgid "year"
-msgstr ""
-
-#: include/datetime.php:379
-msgid "years"
-msgstr ""
-
-#: include/datetime.php:380 include/event.php:490 mod/cal.php:282
-#: mod/events.php:393
-msgid "month"
-msgstr ""
-
-#: include/datetime.php:380
-msgid "months"
-msgstr ""
-
-#: include/datetime.php:381 include/event.php:491 mod/cal.php:283
-#: mod/events.php:394
-msgid "week"
-msgstr ""
-
-#: include/datetime.php:381
-msgid "weeks"
-msgstr ""
-
-#: include/datetime.php:382 include/event.php:492 mod/cal.php:284
-#: mod/events.php:395
-msgid "day"
-msgstr ""
-
-#: include/datetime.php:382
-msgid "days"
-msgstr ""
-
-#: include/datetime.php:383
-msgid "hour"
-msgstr ""
-
-#: include/datetime.php:383
-msgid "hours"
-msgstr ""
-
-#: include/datetime.php:384
-msgid "minute"
-msgstr ""
-
-#: include/datetime.php:384
-msgid "minutes"
-msgstr ""
-
-#: include/datetime.php:385
-msgid "second"
-msgstr ""
-
-#: include/datetime.php:385
-msgid "seconds"
-msgstr ""
-
-#: include/datetime.php:394
-#, php-format
-msgid "%1$d %2$s ago"
-msgstr ""
-
-#: include/datetime.php:620
-#, php-format
-msgid "%s's birthday"
-msgstr ""
-
-#: include/datetime.php:621 include/dfrn.php:1361
-#, php-format
-msgid "Happy Birthday %s"
-msgstr ""
-
#: include/profile_selectors.php:6
msgid "Male"
msgstr ""
msgid "Other"
msgstr ""
-#: include/profile_selectors.php:6 include/conversation.php:1565
+#: include/profile_selectors.php:6 include/conversation.php:1645
msgid "Undecided"
msgid_plural "Undecided"
msgstr[0] ""
msgid "Sex Addict"
msgstr ""
-#: include/profile_selectors.php:42 include/user.php:256 include/user.php:260
+#: include/profile_selectors.php:42 include/user.php:257 include/user.php:261
msgid "Friends"
msgstr ""
msgid "Ask me"
msgstr ""
-#: include/group.php:25
-msgid ""
-"A deleted group with this name was revived. Existing item permissions "
-"<strong>may</strong> apply to this group and any future members. If this is "
-"not what you intended, please create another group with a different name."
+#: include/Photo.php:998 include/Photo.php:1014 include/Photo.php:1022
+#: include/Photo.php:1047 include/message.php:140 mod/item.php:582
+#: mod/wall_upload.php:228
+msgid "Wall Photos"
msgstr ""
-#: include/group.php:201
-msgid "Default privacy group for new contacts"
+#: include/acl_selectors.php:357
+msgid "Post to Email"
msgstr ""
-#: include/group.php:234
-msgid "Everybody"
+#: include/acl_selectors.php:362
+#, php-format
+msgid "Connectors disabled, since \"%s\" is enabled."
msgstr ""
-#: include/group.php:257
-msgid "edit"
+#: include/acl_selectors.php:363 mod/settings.php:1172
+msgid "Hide your profile details from unknown viewers?"
msgstr ""
-#: include/group.php:278 mod/newmember.php:39
-msgid "Groups"
+#: include/acl_selectors.php:369
+msgid "Visible to everybody"
msgstr ""
-#: include/group.php:280
-msgid "Edit groups"
+#: include/acl_selectors.php:370 view/theme/vier/config.php:113
+msgid "show"
msgstr ""
-#: include/group.php:282
-msgid "Edit group"
+#: include/acl_selectors.php:371 view/theme/vier/config.php:113
+msgid "don't show"
msgstr ""
-#: include/group.php:283
-msgid "Create a new group"
+#: include/acl_selectors.php:377 mod/editpost.php:128
+msgid "CC: email addresses"
msgstr ""
-#: include/group.php:284 mod/group.php:101 mod/group.php:198
-msgid "Group Name: "
+#: include/acl_selectors.php:378 mod/editpost.php:135
+msgid "Example: bob@example.com, mary@example.com"
msgstr ""
-#: include/group.php:286
-msgid "Contacts not in any group"
+#: include/acl_selectors.php:380 mod/events.php:534 mod/photos.php:1170
+#: mod/photos.php:1552
+msgid "Permissions"
msgstr ""
-#: include/group.php:288 mod/network.php:197
-msgid "add"
+#: include/acl_selectors.php:381
+msgid "Close"
msgstr ""
-#: include/ForumManager.php:119 include/nav.php:134 include/text.php:1100
-#: view/theme/vier/theme.php:249
-msgid "Forums"
+#: include/api.php:1130
+#, php-format
+msgid "Daily posting limit of %d posts reached. The post was rejected."
msgstr ""
-#: include/ForumManager.php:121 view/theme/vier/theme.php:251
-msgid "External link to forum"
+#: include/api.php:1154
+#, php-format
+msgid "Weekly posting limit of %d posts reached. The post was rejected."
msgstr ""
-#: include/ForumManager.php:124 include/contact_widgets.php:272
-#: include/items.php:2413 object/Item.php:417 view/theme/vier/theme.php:254
-#: src/App.php:523
-msgid "show more"
+#: include/api.php:1178
+#, php-format
+msgid "Monthly posting limit of %d posts reached. The post was rejected."
msgstr ""
-#: include/NotificationsManager.php:157
-msgid "System"
+#: include/api.php:3823 include/user.php:303 include/user.php:311
+#: include/user.php:319 mod/photos.php:77 mod/photos.php:193 mod/photos.php:780
+#: mod/photos.php:1230 mod/photos.php:1247 mod/photos.php:1809
+#: mod/profile_photo.php:78 mod/profile_photo.php:86 mod/profile_photo.php:94
+#: mod/profile_photo.php:218 mod/profile_photo.php:313
+#: mod/profile_photo.php:323
+msgid "Profile Photos"
msgstr ""
-#: include/NotificationsManager.php:164 include/nav.php:161 mod/admin.php:590
-#: view/theme/frio/theme.php:260
-msgid "Network"
+#: include/auth.php:54
+msgid "Logged out."
msgstr ""
-#: include/NotificationsManager.php:171 mod/network.php:914
-#: mod/profiles.php:695
-msgid "Personal"
+#: include/auth.php:125 include/auth.php:187 mod/openid.php:113
+msgid "Login failed."
msgstr ""
-#: include/NotificationsManager.php:178 include/nav.php:108 include/nav.php:164
-msgid "Home"
+#: include/auth.php:141 include/user.php:78
+msgid ""
+"We encountered a problem while logging in with the OpenID you provided. "
+"Please check the correct spelling of the ID."
msgstr ""
-#: include/NotificationsManager.php:185 include/nav.php:169
-msgid "Introductions"
+#: include/auth.php:141 include/user.php:78
+msgid "The error message was:"
msgstr ""
-#: include/NotificationsManager.php:243 include/NotificationsManager.php:255
-#, php-format
-msgid "%s commented on %s's post"
+#: include/bb2diaspora.php:235 include/event.php:21 include/event.php:932
+#: mod/localtime.php:14
+msgid "l F d, Y \\@ g:i A"
msgstr ""
-#: include/NotificationsManager.php:254
-#, php-format
-msgid "%s created a new post"
+#: include/bb2diaspora.php:241 include/event.php:38 include/event.php:55
+#: include/event.php:495 include/event.php:984
+msgid "Starts:"
msgstr ""
-#: include/NotificationsManager.php:269
-#, php-format
-msgid "%s liked %s's post"
+#: include/bb2diaspora.php:249 include/event.php:41 include/event.php:61
+#: include/event.php:496 include/event.php:988
+msgid "Finishes:"
msgstr ""
-#: include/NotificationsManager.php:282
-#, php-format
-msgid "%s disliked %s's post"
+#: include/bb2diaspora.php:258 include/event.php:45 include/event.php:70
+#: include/event.php:497 include/event.php:1002 include/identity.php:358
+#: mod/contacts.php:666 mod/directory.php:136 mod/events.php:519
+#: mod/notifications.php:248
+msgid "Location:"
msgstr ""
-#: include/NotificationsManager.php:295
-#, php-format
-msgid "%s is attending %s's event"
+#: include/bbcode.php:433 include/bbcode.php:1196 include/bbcode.php:1197
+msgid "Image/photo"
msgstr ""
-#: include/NotificationsManager.php:308
+#: include/bbcode.php:549
#, php-format
-msgid "%s is not attending %s's event"
+msgid "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
msgstr ""
-#: include/NotificationsManager.php:321
-#, php-format
-msgid "%s may attend %s's event"
+#: include/bbcode.php:1153 include/bbcode.php:1175
+msgid "$1 wrote:"
msgstr ""
-#: include/NotificationsManager.php:338
-#, php-format
-msgid "%s is now friends with %s"
+#: include/bbcode.php:1205 include/bbcode.php:1206
+msgid "Encrypted content"
msgstr ""
-#: include/NotificationsManager.php:776
-msgid "Friend Suggestion"
+#: include/bbcode.php:1325
+msgid "Invalid source protocol"
msgstr ""
-#: include/NotificationsManager.php:805
-msgid "Friend/Connect Request"
+#: include/bbcode.php:1336
+msgid "Invalid link protocol"
msgstr ""
-#: include/NotificationsManager.php:805
-msgid "New Follower"
+#: include/contact_selectors.php:34
+msgid "Unknown | Not categorised"
msgstr ""
-#: include/auth.php:53
-msgid "Logged out."
+#: include/contact_selectors.php:35
+msgid "Block immediately"
msgstr ""
-#: include/auth.php:124 include/auth.php:186 mod/openid.php:111
-msgid "Login failed."
+#: include/contact_selectors.php:36
+msgid "Shady, spammer, self-marketer"
msgstr ""
-#: include/auth.php:140 include/user.php:77
-msgid ""
-"We encountered a problem while logging in with the OpenID you provided. "
-"Please check the correct spelling of the ID."
+#: include/contact_selectors.php:37
+msgid "Known to me, but no opinion"
msgstr ""
-#: include/auth.php:140 include/user.php:77
-msgid "The error message was:"
+#: include/contact_selectors.php:38
+msgid "OK, probably harmless"
msgstr ""
-#: include/bb2diaspora.php:234 include/event.php:19 include/event.php:933
-#: mod/localtime.php:14
-msgid "l F d, Y \\@ g:i A"
+#: include/contact_selectors.php:39
+msgid "Reputable, has my trust"
msgstr ""
-#: include/bb2diaspora.php:240 include/event.php:36 include/event.php:53
-#: include/event.php:496 include/event.php:985
-msgid "Starts:"
+#: include/contact_selectors.php:58 mod/admin.php:1097
+msgid "Frequently"
msgstr ""
-#: include/bb2diaspora.php:248 include/event.php:39 include/event.php:59
-#: include/event.php:497 include/event.php:989
-msgid "Finishes:"
+#: include/contact_selectors.php:59 mod/admin.php:1098
+msgid "Hourly"
msgstr ""
-#: include/bb2diaspora.php:257 include/event.php:43 include/event.php:68
-#: include/event.php:498 include/event.php:1003 include/identity.php:340
-#: mod/notifications.php:247 mod/directory.php:133 mod/contacts.php:658
-#: mod/events.php:517
-msgid "Location:"
+#: include/contact_selectors.php:60 mod/admin.php:1099
+msgid "Twice daily"
+msgstr ""
+
+#: include/contact_selectors.php:61 mod/admin.php:1100
+msgid "Daily"
+msgstr ""
+
+#: include/contact_selectors.php:62
+msgid "Weekly"
+msgstr ""
+
+#: include/contact_selectors.php:63
+msgid "Monthly"
+msgstr ""
+
+#: include/contact_selectors.php:78 mod/dfrn_request.php:889
+msgid "Friendica"
+msgstr ""
+
+#: include/contact_selectors.php:79
+msgid "OStatus"
+msgstr ""
+
+#: include/contact_selectors.php:80
+msgid "RSS/Atom"
+msgstr ""
+
+#: include/contact_selectors.php:81 include/contact_selectors.php:88
+#: mod/admin.php:1612 mod/admin.php:1625 mod/admin.php:1638 mod/admin.php:1656
+msgid "Email"
+msgstr ""
+
+#: include/contact_selectors.php:82 mod/dfrn_request.php:891
+#: mod/settings.php:863
+msgid "Diaspora"
+msgstr ""
+
+#: include/contact_selectors.php:83
+msgid "Facebook"
+msgstr ""
+
+#: include/contact_selectors.php:84
+msgid "Zot!"
+msgstr ""
+
+#: include/contact_selectors.php:85
+msgid "LinkedIn"
+msgstr ""
+
+#: include/contact_selectors.php:86
+msgid "XMPP/IM"
+msgstr ""
+
+#: include/contact_selectors.php:87
+msgid "MySpace"
+msgstr ""
+
+#: include/contact_selectors.php:89
+msgid "Google+"
+msgstr ""
+
+#: include/contact_selectors.php:90
+msgid "pump.io"
+msgstr ""
+
+#: include/contact_selectors.php:91
+msgid "Twitter"
+msgstr ""
+
+#: include/contact_selectors.php:92
+msgid "Diaspora Connector"
+msgstr ""
+
+#: include/contact_selectors.php:93
+msgid "GNU Social Connector"
+msgstr ""
+
+#: include/contact_selectors.php:94
+msgid "pnut"
msgstr ""
-#: include/contact_widgets.php:12
+#: include/contact_selectors.php:95
+msgid "App.net"
+msgstr ""
+
+#: include/contact_widgets.php:14
msgid "Add New Contact"
msgstr ""
-#: include/contact_widgets.php:13
+#: include/contact_widgets.php:15
msgid "Enter address or web location"
msgstr ""
-#: include/contact_widgets.php:14
+#: include/contact_widgets.php:16
msgid "Example: bob@example.com, http://example.com/barbara"
msgstr ""
-#: include/contact_widgets.php:16 include/identity.php:230
-#: mod/allfriends.php:88 mod/match.php:93 mod/suggest.php:101
-#: mod/dirfind.php:211
+#: include/contact_widgets.php:18 include/identity.php:245
+#: mod/allfriends.php:91 mod/dirfind.php:215 mod/match.php:102
+#: mod/suggest.php:105
msgid "Connect"
msgstr ""
msgid "Enter name or interest"
msgstr ""
-#: include/contact_widgets.php:39 include/Contact.php:411
-#: include/conversation.php:1035 mod/allfriends.php:72 mod/follow.php:143
-#: mod/match.php:78 mod/suggest.php:83 mod/contacts.php:590 mod/dirfind.php:214
+#: include/contact_widgets.php:39 include/conversation.php:1028
+#: mod/allfriends.php:75 mod/contacts.php:597 mod/dirfind.php:218
+#: mod/follow.php:144 mod/match.php:87 mod/suggest.php:87
+#: src/Object/Contact.php:392
msgid "Connect/Follow"
msgstr ""
msgid "Examples: Robert Morgenstein, Fishing"
msgstr ""
-#: include/contact_widgets.php:41 mod/directory.php:200 mod/contacts.php:828
+#: include/contact_widgets.php:41 mod/contacts.php:836 mod/directory.php:198
msgid "Find"
msgstr ""
-#: include/contact_widgets.php:42 mod/suggest.php:114
-#: view/theme/vier/theme.php:196
+#: include/contact_widgets.php:42 mod/suggest.php:118
+#: view/theme/vier/theme.php:199
msgid "Friend Suggestions"
msgstr ""
-#: include/contact_widgets.php:43 view/theme/vier/theme.php:195
+#: include/contact_widgets.php:43 view/theme/vier/theme.php:198
msgid "Similar Interests"
msgstr ""
msgid "Random Profile"
msgstr ""
-#: include/contact_widgets.php:45 view/theme/vier/theme.php:197
+#: include/contact_widgets.php:45 view/theme/vier/theme.php:200
msgid "Invite Friends"
msgstr ""
msgid "All Networks"
msgstr ""
+#: include/contact_widgets.php:167 include/features.php:107
+msgid "Saved Folders"
+msgstr ""
+
#: include/contact_widgets.php:170 include/contact_widgets.php:205
msgid "Everything"
msgstr ""
msgid "Categories"
msgstr ""
-#: include/contact_widgets.php:267
+#: include/contact_widgets.php:265
#, php-format
msgid "%d contact in common"
msgid_plural "%d contacts in common"
msgstr[0] ""
msgstr[1] ""
-#: include/enotify.php:28
-msgid "Friendica Notification"
-msgstr ""
-
-#: include/enotify.php:31
-msgid "Thank You,"
+#: include/contact_widgets.php:270 include/items.php:2395
+#: view/theme/vier/theme.php:254 src/App.php:523
+#: src/Content/ForumManager.php:126 src/Object/Item.php:422
+msgid "show more"
msgstr ""
-#: include/enotify.php:34
-#, php-format
-msgid "%s Administrator"
+#: include/conversation.php:143 include/conversation.php:295
+#: include/like.php:184 include/text.php:1783
+msgid "event"
msgstr ""
-#: include/enotify.php:36
-#, php-format
-msgid "%1$s, %2$s Administrator"
+#: include/conversation.php:146 include/conversation.php:156
+#: include/conversation.php:298 include/conversation.php:307
+#: include/like.php:182 mod/subthread.php:91 mod/tagger.php:66
+#: src/Protocol/Diaspora.php:1893
+msgid "status"
msgstr ""
-#: include/enotify.php:47 include/delivery.php:441
-msgid "noreply"
+#: include/conversation.php:151 include/conversation.php:303
+#: include/like.php:182 include/text.php:1785 mod/subthread.php:91
+#: mod/tagger.php:66
+msgid "photo"
msgstr ""
-#: include/enotify.php:81
+#: include/conversation.php:163 include/like.php:33
+#: src/Protocol/Diaspora.php:1889
#, php-format
-msgid "%s <!item_type!>"
+msgid "%1$s likes %2$s's %3$s"
msgstr ""
-#: include/enotify.php:94
+#: include/conversation.php:166 include/like.php:37 include/like.php:42
#, php-format
-msgid "[Friendica:Notify] New mail received at %s"
+msgid "%1$s doesn't like %2$s's %3$s"
msgstr ""
-#: include/enotify.php:96
+#: include/conversation.php:169
#, php-format
-msgid "%1$s sent you a new private message at %2$s."
+msgid "%1$s attends %2$s's %3$s"
msgstr ""
-#: include/enotify.php:97
+#: include/conversation.php:172
#, php-format
-msgid "%1$s sent you %2$s."
-msgstr ""
-
-#: include/enotify.php:97
-msgid "a private message"
+msgid "%1$s doesn't attend %2$s's %3$s"
msgstr ""
-#: include/enotify.php:99
+#: include/conversation.php:175
#, php-format
-msgid "Please visit %s to view and/or reply to your private messages."
+msgid "%1$s attends maybe %2$s's %3$s"
msgstr ""
-#: include/enotify.php:145
+#: include/conversation.php:208 mod/dfrn_confirm.php:484
#, php-format
-msgid "%1$s commented on [url=%2$s]a %3$s[/url]"
+msgid "%1$s is now friends with %2$s"
msgstr ""
-#: include/enotify.php:152
+#: include/conversation.php:249
#, php-format
-msgid "%1$s commented on [url=%2$s]%3$s's %4$s[/url]"
+msgid "%1$s poked %2$s"
msgstr ""
-#: include/enotify.php:160
+#: include/conversation.php:270 mod/mood.php:67
#, php-format
-msgid "%1$s commented on [url=%2$s]your %3$s[/url]"
+msgid "%1$s is currently %2$s"
msgstr ""
-#: include/enotify.php:170
+#: include/conversation.php:317 mod/tagger.php:99
#, php-format
-msgid "[Friendica:Notify] Comment to conversation #%1$d by %2$s"
+msgid "%1$s tagged %2$s's %3$s with %4$s"
msgstr ""
-#: include/enotify.php:172
-#, php-format
-msgid "%s commented on an item/conversation you have been following."
+#: include/conversation.php:344
+msgid "post/item"
msgstr ""
-#: include/enotify.php:175 include/enotify.php:189 include/enotify.php:203
-#: include/enotify.php:217 include/enotify.php:235 include/enotify.php:249
+#: include/conversation.php:345
#, php-format
-msgid "Please visit %s to view and/or reply to the conversation."
+msgid "%1$s marked %2$s's %3$s as favorite"
msgstr ""
-#: include/enotify.php:182
-#, php-format
-msgid "[Friendica:Notify] %s posted to your profile wall"
+#: include/conversation.php:630 mod/photos.php:1621 mod/profiles.php:344
+msgid "Likes"
msgstr ""
-#: include/enotify.php:184
-#, php-format
-msgid "%1$s posted to your profile wall at %2$s"
+#: include/conversation.php:630 mod/photos.php:1621 mod/profiles.php:348
+msgid "Dislikes"
msgstr ""
-#: include/enotify.php:185
-#, php-format
-msgid "%1$s posted to [url=%2$s]your wall[/url]"
+#: include/conversation.php:631 include/conversation.php:1639
+#: mod/photos.php:1622
+msgid "Attending"
+msgid_plural "Attending"
+msgstr[0] ""
+msgstr[1] ""
+
+#: include/conversation.php:631 mod/photos.php:1622
+msgid "Not attending"
msgstr ""
-#: include/enotify.php:196
-#, php-format
-msgid "[Friendica:Notify] %s tagged you"
+#: include/conversation.php:631 mod/photos.php:1622
+msgid "Might attend"
msgstr ""
-#: include/enotify.php:198
-#, php-format
-msgid "%1$s tagged you at %2$s"
+#: include/conversation.php:768 mod/photos.php:1687 src/Object/Item.php:164
+msgid "Select"
msgstr ""
-#: include/enotify.php:199
-#, php-format
-msgid "%1$s [url=%2$s]tagged you[/url]."
+#: include/conversation.php:769 mod/admin.php:1630 mod/contacts.php:846
+#: mod/contacts.php:1045 mod/photos.php:1688 mod/settings.php:759
+#: src/Object/Item.php:165
+msgid "Delete"
msgstr ""
-#: include/enotify.php:210
+#: include/conversation.php:802 src/Object/Item.php:355 src/Object/Item.php:356
#, php-format
-msgid "[Friendica:Notify] %s shared a new post"
+msgid "View %s's profile @ %s"
msgstr ""
-#: include/enotify.php:212
-#, php-format
-msgid "%1$s shared a new post at %2$s"
+#: include/conversation.php:814 src/Object/Item.php:343
+msgid "Categories:"
msgstr ""
-#: include/enotify.php:213
-#, php-format
-msgid "%1$s [url=%2$s]shared a post[/url]."
+#: include/conversation.php:815 src/Object/Item.php:344
+msgid "Filed under:"
msgstr ""
-#: include/enotify.php:224
+#: include/conversation.php:822 src/Object/Item.php:369
#, php-format
-msgid "[Friendica:Notify] %1$s poked you"
+msgid "%s from %s"
msgstr ""
-#: include/enotify.php:226
-#, php-format
-msgid "%1$s poked you at %2$s"
+#: include/conversation.php:838
+msgid "View in context"
msgstr ""
-#: include/enotify.php:227
-#, php-format
-msgid "%1$s [url=%2$s]poked you[/url]."
+#: include/conversation.php:840 include/conversation.php:1309
+#: mod/editpost.php:119 mod/message.php:339 mod/message.php:513
+#: mod/photos.php:1586 mod/wallmessage.php:144 src/Object/Item.php:394
+msgid "Please wait"
msgstr ""
-#: include/enotify.php:242
-#, php-format
-msgid "[Friendica:Notify] %s tagged your post"
-msgstr ""
-
-#: include/enotify.php:244
-#, php-format
-msgid "%1$s tagged your post at %2$s"
+#: include/conversation.php:914
+msgid "remove"
msgstr ""
-#: include/enotify.php:245
-#, php-format
-msgid "%1$s tagged [url=%2$s]your post[/url]"
+#: include/conversation.php:918
+msgid "Delete Selected Items"
msgstr ""
-#: include/enotify.php:256
-msgid "[Friendica:Notify] Introduction received"
+#: include/conversation.php:1013 view/theme/frio/theme.php:350
+msgid "Follow Thread"
msgstr ""
-#: include/enotify.php:258
-#, php-format
-msgid "You've received an introduction from '%1$s' at %2$s"
+#: include/conversation.php:1014 src/Object/Contact.php:435
+msgid "View Status"
msgstr ""
-#: include/enotify.php:259
-#, php-format
-msgid "You've received [url=%1$s]an introduction[/url] from %2$s."
+#: include/conversation.php:1015 include/conversation.php:1031
+#: mod/allfriends.php:74 mod/directory.php:149 mod/dirfind.php:217
+#: mod/match.php:86 mod/suggest.php:86 src/Object/Contact.php:379
+#: src/Object/Contact.php:391 src/Object/Contact.php:436
+msgid "View Profile"
msgstr ""
-#: include/enotify.php:263 include/enotify.php:306
-#, php-format
-msgid "You may visit their profile at %s"
+#: include/conversation.php:1016 src/Object/Contact.php:437
+msgid "View Photos"
msgstr ""
-#: include/enotify.php:265
-#, php-format
-msgid "Please visit %s to approve or reject the introduction."
+#: include/conversation.php:1017 src/Object/Contact.php:438
+msgid "Network Posts"
msgstr ""
-#: include/enotify.php:273
-msgid "[Friendica:Notify] A new person is sharing with you"
+#: include/conversation.php:1018 src/Object/Contact.php:439
+msgid "View Contact"
msgstr ""
-#: include/enotify.php:275 include/enotify.php:276
-#, php-format
-msgid "%1$s is sharing with you at %2$s"
+#: include/conversation.php:1019 src/Object/Contact.php:441
+msgid "Send PM"
msgstr ""
-#: include/enotify.php:282
-msgid "[Friendica:Notify] You have a new follower"
+#: include/conversation.php:1023 src/Object/Contact.php:442
+msgid "Poke"
msgstr ""
-#: include/enotify.php:284 include/enotify.php:285
+#: include/conversation.php:1150
#, php-format
-msgid "You have a new follower at %2$s : %1$s"
-msgstr ""
-
-#: include/enotify.php:296
-msgid "[Friendica:Notify] Friend suggestion received"
+msgid "%s likes this."
msgstr ""
-#: include/enotify.php:298
+#: include/conversation.php:1153
#, php-format
-msgid "You've received a friend suggestion from '%1$s' at %2$s"
+msgid "%s doesn't like this."
msgstr ""
-#: include/enotify.php:299
+#: include/conversation.php:1156
#, php-format
-msgid "You've received [url=%1$s]a friend suggestion[/url] for %2$s from %3$s."
-msgstr ""
-
-#: include/enotify.php:304
-msgid "Name:"
+msgid "%s attends."
msgstr ""
-#: include/enotify.php:305
-msgid "Photo:"
+#: include/conversation.php:1159
+#, php-format
+msgid "%s doesn't attend."
msgstr ""
-#: include/enotify.php:308
+#: include/conversation.php:1162
#, php-format
-msgid "Please visit %s to approve or reject the suggestion."
+msgid "%s attends maybe."
msgstr ""
-#: include/enotify.php:316 include/enotify.php:330
-msgid "[Friendica:Notify] Connection accepted"
+#: include/conversation.php:1173
+msgid "and"
msgstr ""
-#: include/enotify.php:318 include/enotify.php:332
+#: include/conversation.php:1179
#, php-format
-msgid "'%1$s' has accepted your connection request at %2$s"
+msgid ", and %d other people"
msgstr ""
-#: include/enotify.php:319 include/enotify.php:333
+#: include/conversation.php:1188
#, php-format
-msgid "%2$s has accepted your [url=%1$s]connection request[/url]."
-msgstr ""
-
-#: include/enotify.php:323
-msgid ""
-"You are now mutual friends and may exchange status updates, photos, and "
-"email without restriction."
+msgid "<span %1$s>%2$d people</span> like this"
msgstr ""
-#: include/enotify.php:325
+#: include/conversation.php:1189
#, php-format
-msgid "Please visit %s if you wish to make any changes to this relationship."
+msgid "%s like this."
msgstr ""
-#: include/enotify.php:337
+#: include/conversation.php:1192
#, php-format
-msgid ""
-"'%1$s' has chosen to accept you a \"fan\", which restricts some forms of "
-"communication - such as private messaging and some profile interactions. If "
-"this is a celebrity or community page, these settings were applied "
-"automatically."
+msgid "<span %1$s>%2$d people</span> don't like this"
msgstr ""
-#: include/enotify.php:339
+#: include/conversation.php:1193
#, php-format
-msgid ""
-"'%1$s' may choose to extend this into a two-way or more permissive "
-"relationship in the future."
+msgid "%s don't like this."
msgstr ""
-#: include/enotify.php:341
+#: include/conversation.php:1196
#, php-format
-msgid "Please visit %s if you wish to make any changes to this relationship."
-msgstr ""
-
-#: include/enotify.php:351
-msgid "[Friendica System:Notify] registration request"
+msgid "<span %1$s>%2$d people</span> attend"
msgstr ""
-#: include/enotify.php:353
+#: include/conversation.php:1197
#, php-format
-msgid "You've received a registration request from '%1$s' at %2$s"
+msgid "%s attend."
msgstr ""
-#: include/enotify.php:354
+#: include/conversation.php:1200
#, php-format
-msgid "You've received a [url=%1$s]registration request[/url] from %2$s."
+msgid "<span %1$s>%2$d people</span> don't attend"
msgstr ""
-#: include/enotify.php:358
+#: include/conversation.php:1201
#, php-format
-msgid "Full Name:\t%1$s\\nSite Location:\t%2$s\\nLogin Name:\t%3$s (%4$s)"
+msgid "%s don't attend."
msgstr ""
-#: include/enotify.php:361
+#: include/conversation.php:1204
#, php-format
-msgid "Please visit %s to approve or reject the request."
+msgid "<span %1$s>%2$d people</span> attend maybe"
msgstr ""
-#: include/oembed.php:254
-msgid "Embedded content"
+#: include/conversation.php:1205
+#, php-format
+msgid "%s anttend maybe."
msgstr ""
-#: include/oembed.php:262
-msgid "Embedding disabled"
+#: include/conversation.php:1234 include/conversation.php:1250
+msgid "Visible to <strong>everybody</strong>"
msgstr ""
-#: include/security.php:64
-msgid "Welcome "
+#: include/conversation.php:1235 include/conversation.php:1251
+#: mod/message.php:273 mod/message.php:280 mod/message.php:420
+#: mod/message.php:427 mod/wallmessage.php:118 mod/wallmessage.php:125
+msgid "Please enter a link URL:"
msgstr ""
-#: include/security.php:65
-msgid "Please upload a profile photo."
+#: include/conversation.php:1236 include/conversation.php:1252
+msgid "Please enter a video link/URL:"
msgstr ""
-#: include/security.php:67
-msgid "Welcome back "
+#: include/conversation.php:1237 include/conversation.php:1253
+msgid "Please enter an audio link/URL:"
msgstr ""
-#: include/security.php:424
-msgid ""
-"The form security token was not correct. This probably happened because the "
-"form has been opened for too long (>3 hours) before submitting it."
+#: include/conversation.php:1238 include/conversation.php:1254
+msgid "Tag term:"
msgstr ""
-#: include/photos.php:57 include/photos.php:66 mod/fbrowser.php:43
-#: mod/fbrowser.php:65 mod/photos.php:191 mod/photos.php:1109
-#: mod/photos.php:1233 mod/photos.php:1254 mod/photos.php:1816
-#: mod/photos.php:1830
-msgid "Contact Photos"
+#: include/conversation.php:1239 include/conversation.php:1255 mod/filer.php:32
+msgid "Save to Folder:"
msgstr ""
-#: include/nav.php:38 mod/navigation.php:22
-msgid "Nothing new here"
+#: include/conversation.php:1240 include/conversation.php:1256
+msgid "Where are you right now?"
msgstr ""
-#: include/nav.php:42 mod/navigation.php:26
-msgid "Clear notifications"
+#: include/conversation.php:1241
+msgid "Delete item(s)?"
msgstr ""
-#: include/nav.php:43 include/text.php:1090
-msgid "@name, !forum, #tags, content"
+#: include/conversation.php:1290
+msgid "Share"
msgstr ""
-#: include/nav.php:81 view/theme/frio/theme.php:250 boot.php:874
-msgid "Logout"
+#: include/conversation.php:1291 mod/editpost.php:105 mod/message.php:337
+#: mod/message.php:510 mod/wallmessage.php:142
+msgid "Upload photo"
msgstr ""
-#: include/nav.php:81 view/theme/frio/theme.php:250
-msgid "End this session"
+#: include/conversation.php:1292 mod/editpost.php:106
+msgid "upload photo"
msgstr ""
-#: include/nav.php:84 include/identity.php:785 mod/contacts.php:667
-#: mod/contacts.php:863 view/theme/frio/theme.php:253
-msgid "Status"
+#: include/conversation.php:1293 mod/editpost.php:107
+msgid "Attach file"
msgstr ""
-#: include/nav.php:84 include/nav.php:164 view/theme/frio/theme.php:253
-msgid "Your posts and conversations"
+#: include/conversation.php:1294 mod/editpost.php:108
+msgid "attach file"
msgstr ""
-#: include/nav.php:85 include/identity.php:631 include/identity.php:760
-#: include/identity.php:793 mod/newmember.php:20 mod/profperm.php:107
-#: mod/contacts.php:669 mod/contacts.php:871 view/theme/frio/theme.php:254
-msgid "Profile"
+#: include/conversation.php:1295 mod/editpost.php:109 mod/message.php:338
+#: mod/message.php:511 mod/wallmessage.php:143
+msgid "Insert web link"
msgstr ""
-#: include/nav.php:85 view/theme/frio/theme.php:254
-msgid "Your profile page"
+#: include/conversation.php:1296 mod/editpost.php:110
+msgid "web link"
msgstr ""
-#: include/nav.php:86 include/identity.php:801 mod/fbrowser.php:34
-#: view/theme/frio/theme.php:255
-msgid "Photos"
+#: include/conversation.php:1297 mod/editpost.php:111
+msgid "Insert video link"
msgstr ""
-#: include/nav.php:86 view/theme/frio/theme.php:255
-msgid "Your photos"
+#: include/conversation.php:1298 mod/editpost.php:112
+msgid "video link"
msgstr ""
-#: include/nav.php:87 include/identity.php:809 include/identity.php:812
-#: view/theme/frio/theme.php:256
-msgid "Videos"
+#: include/conversation.php:1299 mod/editpost.php:113
+msgid "Insert audio link"
msgstr ""
-#: include/nav.php:87 view/theme/frio/theme.php:256
-msgid "Your videos"
+#: include/conversation.php:1300 mod/editpost.php:114
+msgid "audio link"
msgstr ""
-#: include/nav.php:88 include/nav.php:152 include/identity.php:821
-#: include/identity.php:832 mod/cal.php:273 mod/events.php:383
-#: view/theme/frio/theme.php:257 view/theme/frio/theme.php:261
-msgid "Events"
+#: include/conversation.php:1301 mod/editpost.php:115
+msgid "Set your location"
msgstr ""
-#: include/nav.php:88 view/theme/frio/theme.php:257
-msgid "Your events"
+#: include/conversation.php:1302 mod/editpost.php:116
+msgid "set location"
msgstr ""
-#: include/nav.php:89
-msgid "Personal notes"
+#: include/conversation.php:1303 mod/editpost.php:117
+msgid "Clear browser location"
msgstr ""
-#: include/nav.php:89
-msgid "Your personal notes"
+#: include/conversation.php:1304 mod/editpost.php:118
+msgid "clear location"
msgstr ""
-#: include/nav.php:98 mod/bookmarklet.php:15 boot.php:875
-msgid "Login"
+#: include/conversation.php:1306 mod/editpost.php:132
+msgid "Set title"
msgstr ""
-#: include/nav.php:98
-msgid "Sign in"
+#: include/conversation.php:1308 mod/editpost.php:134
+msgid "Categories (comma-separated list)"
msgstr ""
-#: include/nav.php:108
-msgid "Home Page"
+#: include/conversation.php:1310 mod/editpost.php:120
+msgid "Permission settings"
msgstr ""
-#: include/nav.php:112 mod/register.php:294 boot.php:851
-msgid "Register"
+#: include/conversation.php:1311 mod/editpost.php:149
+msgid "permissions"
msgstr ""
-#: include/nav.php:112
-msgid "Create an account"
+#: include/conversation.php:1319 mod/editpost.php:129
+msgid "Public post"
msgstr ""
-#: include/nav.php:118 mod/help.php:51 view/theme/vier/theme.php:292
-msgid "Help"
+#: include/conversation.php:1324 mod/editpost.php:140 mod/events.php:529
+#: mod/photos.php:1606 mod/photos.php:1648 mod/photos.php:1722
+#: src/Object/Item.php:796
+msgid "Preview"
msgstr ""
-#: include/nav.php:118
-msgid "Help and documentation"
+#: include/conversation.php:1328 include/items.php:2148 mod/contacts.php:470
+#: mod/dfrn_request.php:897 mod/editpost.php:143 mod/fbrowser.php:98
+#: mod/fbrowser.php:128 mod/follow.php:162 mod/message.php:212
+#: mod/photos.php:251 mod/photos.php:343 mod/settings.php:697
+#: mod/settings.php:723 mod/suggest.php:39 mod/tagrm.php:15 mod/tagrm.php:100
+#: mod/unfollow.php:116 mod/videos.php:139
+msgid "Cancel"
msgstr ""
-#: include/nav.php:122
-msgid "Apps"
+#: include/conversation.php:1334
+msgid "Post to Groups"
msgstr ""
-#: include/nav.php:122
-msgid "Addon applications, utilities, games"
+#: include/conversation.php:1335
+msgid "Post to Contacts"
msgstr ""
-#: include/nav.php:126 include/text.php:1087 mod/search.php:145
-msgid "Search"
+#: include/conversation.php:1336
+msgid "Private post"
msgstr ""
-#: include/nav.php:126
-msgid "Search site content"
+#: include/conversation.php:1341 include/identity.php:283 mod/editpost.php:147
+msgid "Message"
msgstr ""
-#: include/nav.php:129 include/text.php:1095
-msgid "Full Text"
+#: include/conversation.php:1342 mod/editpost.php:148
+msgid "Browser"
msgstr ""
-#: include/nav.php:130 include/text.php:1096
-msgid "Tags"
+#: include/conversation.php:1611
+msgid "View all"
msgstr ""
-#: include/nav.php:131 include/nav.php:195 include/identity.php:854
-#: include/identity.php:857 include/text.php:1097 mod/viewcontacts.php:124
-#: mod/contacts.php:822 mod/contacts.php:883 view/theme/frio/theme.php:264
-msgid "Contacts"
-msgstr ""
+#: include/conversation.php:1633
+msgid "Like"
+msgid_plural "Likes"
+msgstr[0] ""
+msgstr[1] ""
-#: include/nav.php:146 include/nav.php:148 mod/community.php:31
-msgid "Community"
-msgstr ""
+#: include/conversation.php:1636
+msgid "Dislike"
+msgid_plural "Dislikes"
+msgstr[0] ""
+msgstr[1] ""
-#: include/nav.php:146
-msgid "Conversations on this site"
-msgstr ""
+#: include/conversation.php:1642
+msgid "Not Attending"
+msgid_plural "Not Attending"
+msgstr[0] ""
+msgstr[1] ""
-#: include/nav.php:148
-msgid "Conversations on the network"
+#: include/datetime.php:68 include/datetime.php:70 mod/profiles.php:701
+msgid "Miscellaneous"
msgstr ""
-#: include/nav.php:152 include/identity.php:824 include/identity.php:835
-#: view/theme/frio/theme.php:261
-msgid "Events and Calendar"
+#: include/datetime.php:198 include/identity.php:698
+msgid "Birthday:"
msgstr ""
-#: include/nav.php:155
-msgid "Directory"
+#: include/datetime.php:200 mod/profiles.php:724
+msgid "Age: "
msgstr ""
-#: include/nav.php:155
-msgid "People directory"
+#: include/datetime.php:202
+msgid "YYYY-MM-DD or MM-DD"
msgstr ""
-#: include/nav.php:157
-msgid "Information"
+#: include/datetime.php:369
+msgid "never"
msgstr ""
-#: include/nav.php:157
-msgid "Information about this friendica instance"
+#: include/datetime.php:375
+msgid "less than a second ago"
msgstr ""
-#: include/nav.php:161 view/theme/frio/theme.php:260
-msgid "Conversations from your friends"
+#: include/datetime.php:378
+msgid "year"
msgstr ""
-#: include/nav.php:162
-msgid "Network Reset"
+#: include/datetime.php:378
+msgid "years"
msgstr ""
-#: include/nav.php:162
-msgid "Load Network page with no filters"
+#: include/datetime.php:379 include/event.php:489 mod/cal.php:285
+#: mod/events.php:395
+msgid "month"
msgstr ""
-#: include/nav.php:169
-msgid "Friend Requests"
+#: include/datetime.php:379
+msgid "months"
msgstr ""
-#: include/nav.php:172 mod/notifications.php:99
-msgid "Notifications"
+#: include/datetime.php:380 include/event.php:490 mod/cal.php:286
+#: mod/events.php:396
+msgid "week"
msgstr ""
-#: include/nav.php:173
-msgid "See all notifications"
+#: include/datetime.php:380
+msgid "weeks"
msgstr ""
-#: include/nav.php:174 mod/settings.php:911
-msgid "Mark as seen"
+#: include/datetime.php:381 include/event.php:491 mod/cal.php:287
+#: mod/events.php:397
+msgid "day"
msgstr ""
-#: include/nav.php:174
-msgid "Mark all system notifications seen"
+#: include/datetime.php:381
+msgid "days"
msgstr ""
-#: include/nav.php:178 mod/message.php:180 view/theme/frio/theme.php:262
-msgid "Messages"
+#: include/datetime.php:382
+msgid "hour"
msgstr ""
-#: include/nav.php:178 view/theme/frio/theme.php:262
-msgid "Private mail"
+#: include/datetime.php:382
+msgid "hours"
msgstr ""
-#: include/nav.php:179
-msgid "Inbox"
+#: include/datetime.php:383
+msgid "minute"
msgstr ""
-#: include/nav.php:180
-msgid "Outbox"
+#: include/datetime.php:383
+msgid "minutes"
msgstr ""
-#: include/nav.php:181 mod/message.php:19
-msgid "New Message"
+#: include/datetime.php:384
+msgid "second"
msgstr ""
-#: include/nav.php:184
-msgid "Manage"
+#: include/datetime.php:384
+msgid "seconds"
msgstr ""
-#: include/nav.php:184
-msgid "Manage other pages"
+#: include/datetime.php:393
+#, php-format
+msgid "%1$d %2$s ago"
msgstr ""
-#: include/nav.php:187 mod/settings.php:81
-msgid "Delegations"
+#: include/datetime.php:619
+#, php-format
+msgid "%s's birthday"
msgstr ""
-#: include/nav.php:187 mod/delegate.php:130
-msgid "Delegate Page Management"
+#: include/datetime.php:620 src/Protocol/DFRN.php:1417
+#, php-format
+msgid "Happy Birthday %s"
msgstr ""
-#: include/nav.php:189 mod/newmember.php:15 mod/admin.php:1740
-#: mod/admin.php:2016 mod/settings.php:111 view/theme/frio/theme.php:263
-msgid "Settings"
+#: include/dba.php:57
+#, php-format
+msgid "Cannot locate DNS info for database server '%s'"
msgstr ""
-#: include/nav.php:189 view/theme/frio/theme.php:263
-msgid "Account settings"
+#: include/dbstructure.php:25
+msgid "There are no tables on MyISAM."
msgstr ""
-#: include/nav.php:192 include/identity.php:294
-msgid "Profiles"
+#: include/dbstructure.php:66
+#, php-format
+msgid ""
+"\n"
+"\t\t\tThe friendica developers released update %s recently,\n"
+"\t\t\tbut when I tried to install it, something went terribly wrong.\n"
+"\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n"
+"\t\t\tfriendica developer if you can not help me on your own. My database "
+"might be invalid."
msgstr ""
-#: include/nav.php:192
-msgid "Manage/Edit Profiles"
+#: include/dbstructure.php:71
+#, php-format
+msgid ""
+"The error message is\n"
+"[pre]%s[/pre]"
msgstr ""
-#: include/nav.php:195 view/theme/frio/theme.php:264
-msgid "Manage/edit friends and contacts"
+#: include/dbstructure.php:193
+#, php-format
+msgid ""
+"\n"
+"Error %d occurred during database update:\n"
+"%s\n"
msgstr ""
-#: include/nav.php:200 mod/admin.php:204
-msgid "Admin"
+#: include/dbstructure.php:196
+msgid "Errors encountered performing database changes: "
msgstr ""
-#: include/nav.php:200
-msgid "Site setup and configuration"
+#: include/dbstructure.php:204
+msgid ": Database update"
msgstr ""
-#: include/nav.php:203
-msgid "Navigation"
+#: include/dbstructure.php:437
+#, php-format
+msgid "%s: updating %s table."
msgstr ""
-#: include/nav.php:203
-msgid "Site map"
+#: include/enotify.php:32
+msgid "Friendica Notification"
msgstr ""
-#: include/Contact.php:397 include/Contact.php:410 include/Contact.php:455
-#: include/conversation.php:1022 include/conversation.php:1038
-#: mod/allfriends.php:71 mod/match.php:77 mod/suggest.php:82
-#: mod/directory.php:151 mod/dirfind.php:213
-msgid "View Profile"
+#: include/enotify.php:35
+msgid "Thank You,"
msgstr ""
-#: include/Contact.php:454 include/conversation.php:1021
-msgid "View Status"
+#: include/enotify.php:38
+#, php-format
+msgid "%s Administrator"
msgstr ""
-#: include/Contact.php:456 include/conversation.php:1023
-msgid "View Photos"
+#: include/enotify.php:40
+#, php-format
+msgid "%1$s, %2$s Administrator"
msgstr ""
-#: include/Contact.php:457 include/conversation.php:1024
-msgid "Network Posts"
+#: include/enotify.php:51 src/Worker/Delivery.php:433
+msgid "noreply"
msgstr ""
-#: include/Contact.php:458 include/conversation.php:1025
-msgid "View Contact"
+#: include/enotify.php:85
+#, php-format
+msgid "%s <!item_type!>"
msgstr ""
-#: include/Contact.php:459
-msgid "Drop Contact"
+#: include/enotify.php:98
+#, php-format
+msgid "[Friendica:Notify] New mail received at %s"
msgstr ""
-#: include/Contact.php:460 include/conversation.php:1026
-msgid "Send PM"
+#: include/enotify.php:100
+#, php-format
+msgid "%1$s sent you a new private message at %2$s."
msgstr ""
-#: include/Contact.php:461 include/conversation.php:1030
-msgid "Poke"
+#: include/enotify.php:101
+#, php-format
+msgid "%1$s sent you %2$s."
msgstr ""
-#: include/Contact.php:884
-msgid "Organisation"
+#: include/enotify.php:101
+msgid "a private message"
msgstr ""
-#: include/Contact.php:887
-msgid "News"
+#: include/enotify.php:103
+#, php-format
+msgid "Please visit %s to view and/or reply to your private messages."
msgstr ""
-#: include/Contact.php:890
-msgid "Forum"
+#: include/enotify.php:149
+#, php-format
+msgid "%1$s commented on [url=%2$s]a %3$s[/url]"
msgstr ""
-#: include/Photo.php:995 include/Photo.php:1011 include/Photo.php:1019
-#: include/Photo.php:1044 include/message.php:139 mod/item.php:470
-#: mod/wall_upload.php:227
-msgid "Wall Photos"
+#: include/enotify.php:156
+#, php-format
+msgid "%1$s commented on [url=%2$s]%3$s's %4$s[/url]"
msgstr ""
-#: include/acl_selectors.php:355
-msgid "Post to Email"
+#: include/enotify.php:164
+#, php-format
+msgid "%1$s commented on [url=%2$s]your %3$s[/url]"
msgstr ""
-#: include/acl_selectors.php:360
+#: include/enotify.php:174
#, php-format
-msgid "Connectors disabled, since \"%s\" is enabled."
+msgid "[Friendica:Notify] Comment to conversation #%1$d by %2$s"
msgstr ""
-#: include/acl_selectors.php:361 mod/settings.php:1175
-msgid "Hide your profile details from unknown viewers?"
+#: include/enotify.php:176
+#, php-format
+msgid "%s commented on an item/conversation you have been following."
msgstr ""
-#: include/acl_selectors.php:367
-msgid "Visible to everybody"
+#: include/enotify.php:179 include/enotify.php:193 include/enotify.php:207
+#: include/enotify.php:221 include/enotify.php:239 include/enotify.php:253
+#, php-format
+msgid "Please visit %s to view and/or reply to the conversation."
msgstr ""
-#: include/acl_selectors.php:368 view/theme/vier/config.php:110
-msgid "show"
+#: include/enotify.php:186
+#, php-format
+msgid "[Friendica:Notify] %s posted to your profile wall"
msgstr ""
-#: include/acl_selectors.php:369 view/theme/vier/config.php:110
-msgid "don't show"
+#: include/enotify.php:188
+#, php-format
+msgid "%1$s posted to your profile wall at %2$s"
msgstr ""
-#: include/acl_selectors.php:375 mod/editpost.php:126
-msgid "CC: email addresses"
+#: include/enotify.php:189
+#, php-format
+msgid "%1$s posted to [url=%2$s]your wall[/url]"
msgstr ""
-#: include/acl_selectors.php:376 mod/editpost.php:133
-msgid "Example: bob@example.com, mary@example.com"
+#: include/enotify.php:200
+#, php-format
+msgid "[Friendica:Notify] %s tagged you"
msgstr ""
-#: include/acl_selectors.php:378 mod/events.php:532 mod/photos.php:1173
-#: mod/photos.php:1570
-msgid "Permissions"
+#: include/enotify.php:202
+#, php-format
+msgid "%1$s tagged you at %2$s"
msgstr ""
-#: include/acl_selectors.php:379
-msgid "Close"
+#: include/enotify.php:203
+#, php-format
+msgid "%1$s [url=%2$s]tagged you[/url]."
msgstr ""
-#: include/api.php:1104
+#: include/enotify.php:214
#, php-format
-msgid "Daily posting limit of %d posts reached. The post was rejected."
+msgid "[Friendica:Notify] %s shared a new post"
msgstr ""
-#: include/api.php:1125
+#: include/enotify.php:216
#, php-format
-msgid "Weekly posting limit of %d posts reached. The post was rejected."
+msgid "%1$s shared a new post at %2$s"
msgstr ""
-#: include/api.php:1146
+#: include/enotify.php:217
#, php-format
-msgid "Monthly posting limit of %d posts reached. The post was rejected."
+msgid "%1$s [url=%2$s]shared a post[/url]."
msgstr ""
-#: include/api.php:3718 include/user.php:302 include/user.php:310
-#: include/user.php:318 mod/photos.php:75 mod/photos.php:191 mod/photos.php:778
-#: mod/photos.php:1233 mod/photos.php:1254 mod/photos.php:1840
-#: mod/profile_photo.php:76 mod/profile_photo.php:84 mod/profile_photo.php:92
-#: mod/profile_photo.php:216 mod/profile_photo.php:311
-#: mod/profile_photo.php:321
-msgid "Profile Photos"
+#: include/enotify.php:228
+#, php-format
+msgid "[Friendica:Notify] %1$s poked you"
msgstr ""
-#: include/bbcode.php:429 include/bbcode.php:1192 include/bbcode.php:1193
-msgid "Image/photo"
+#: include/enotify.php:230
+#, php-format
+msgid "%1$s poked you at %2$s"
msgstr ""
-#: include/bbcode.php:545
+#: include/enotify.php:231
#, php-format
-msgid "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
+msgid "%1$s [url=%2$s]poked you[/url]."
msgstr ""
-#: include/bbcode.php:1149 include/bbcode.php:1171
-msgid "$1 wrote:"
+#: include/enotify.php:246
+#, php-format
+msgid "[Friendica:Notify] %s tagged your post"
msgstr ""
-#: include/bbcode.php:1201 include/bbcode.php:1202
-msgid "Encrypted content"
+#: include/enotify.php:248
+#, php-format
+msgid "%1$s tagged your post at %2$s"
msgstr ""
-#: include/bbcode.php:1321
-msgid "Invalid source protocol"
+#: include/enotify.php:249
+#, php-format
+msgid "%1$s tagged [url=%2$s]your post[/url]"
msgstr ""
-#: include/bbcode.php:1332
-msgid "Invalid link protocol"
+#: include/enotify.php:260
+msgid "[Friendica:Notify] Introduction received"
msgstr ""
-#: include/contact_selectors.php:32
-msgid "Unknown | Not categorised"
+#: include/enotify.php:262
+#, php-format
+msgid "You've received an introduction from '%1$s' at %2$s"
msgstr ""
-#: include/contact_selectors.php:33
-msgid "Block immediately"
+#: include/enotify.php:263
+#, php-format
+msgid "You've received [url=%1$s]an introduction[/url] from %2$s."
msgstr ""
-#: include/contact_selectors.php:34
-msgid "Shady, spammer, self-marketer"
+#: include/enotify.php:267 include/enotify.php:310
+#, php-format
+msgid "You may visit their profile at %s"
msgstr ""
-#: include/contact_selectors.php:35
-msgid "Known to me, but no opinion"
+#: include/enotify.php:269
+#, php-format
+msgid "Please visit %s to approve or reject the introduction."
msgstr ""
-#: include/contact_selectors.php:36
-msgid "OK, probably harmless"
+#: include/enotify.php:277
+msgid "[Friendica:Notify] A new person is sharing with you"
msgstr ""
-#: include/contact_selectors.php:37
-msgid "Reputable, has my trust"
+#: include/enotify.php:279 include/enotify.php:280
+#, php-format
+msgid "%1$s is sharing with you at %2$s"
msgstr ""
-#: include/contact_selectors.php:56 mod/admin.php:1095
-msgid "Frequently"
+#: include/enotify.php:286
+msgid "[Friendica:Notify] You have a new follower"
msgstr ""
-#: include/contact_selectors.php:57 mod/admin.php:1096
-msgid "Hourly"
+#: include/enotify.php:288 include/enotify.php:289
+#, php-format
+msgid "You have a new follower at %2$s : %1$s"
msgstr ""
-#: include/contact_selectors.php:58 mod/admin.php:1097
-msgid "Twice daily"
+#: include/enotify.php:300
+msgid "[Friendica:Notify] Friend suggestion received"
msgstr ""
-#: include/contact_selectors.php:59 mod/admin.php:1098
-msgid "Daily"
+#: include/enotify.php:302
+#, php-format
+msgid "You've received a friend suggestion from '%1$s' at %2$s"
msgstr ""
-#: include/contact_selectors.php:60
-msgid "Weekly"
+#: include/enotify.php:303
+#, php-format
+msgid "You've received [url=%1$s]a friend suggestion[/url] for %2$s from %3$s."
msgstr ""
-#: include/contact_selectors.php:61
-msgid "Monthly"
+#: include/enotify.php:308
+msgid "Name:"
msgstr ""
-#: include/contact_selectors.php:76 mod/dfrn_request.php:887
-msgid "Friendica"
+#: include/enotify.php:309
+msgid "Photo:"
msgstr ""
-#: include/contact_selectors.php:77
-msgid "OStatus"
+#: include/enotify.php:312
+#, php-format
+msgid "Please visit %s to approve or reject the suggestion."
msgstr ""
-#: include/contact_selectors.php:78
-msgid "RSS/Atom"
+#: include/enotify.php:320 include/enotify.php:334
+msgid "[Friendica:Notify] Connection accepted"
msgstr ""
-#: include/contact_selectors.php:79 include/contact_selectors.php:86
-#: mod/admin.php:1612 mod/admin.php:1625 mod/admin.php:1638 mod/admin.php:1656
-msgid "Email"
+#: include/enotify.php:322 include/enotify.php:336
+#, php-format
+msgid "'%1$s' has accepted your connection request at %2$s"
msgstr ""
-#: include/contact_selectors.php:80 mod/dfrn_request.php:889
-#: mod/settings.php:858
-msgid "Diaspora"
+#: include/enotify.php:323 include/enotify.php:337
+#, php-format
+msgid "%2$s has accepted your [url=%1$s]connection request[/url]."
msgstr ""
-#: include/contact_selectors.php:81
-msgid "Facebook"
+#: include/enotify.php:327
+msgid ""
+"You are now mutual friends and may exchange status updates, photos, and "
+"email without restriction."
msgstr ""
-#: include/contact_selectors.php:82
-msgid "Zot!"
+#: include/enotify.php:329
+#, php-format
+msgid "Please visit %s if you wish to make any changes to this relationship."
msgstr ""
-#: include/contact_selectors.php:83
-msgid "LinkedIn"
+#: include/enotify.php:341
+#, php-format
+msgid ""
+"'%1$s' has chosen to accept you a \"fan\", which restricts some forms of "
+"communication - such as private messaging and some profile interactions. If "
+"this is a celebrity or community page, these settings were applied "
+"automatically."
msgstr ""
-#: include/contact_selectors.php:84
-msgid "XMPP/IM"
+#: include/enotify.php:343
+#, php-format
+msgid ""
+"'%1$s' may choose to extend this into a two-way or more permissive "
+"relationship in the future."
msgstr ""
-#: include/contact_selectors.php:85
-msgid "MySpace"
+#: include/enotify.php:345
+#, php-format
+msgid "Please visit %s if you wish to make any changes to this relationship."
msgstr ""
-#: include/contact_selectors.php:87
-msgid "Google+"
+#: include/enotify.php:355
+msgid "[Friendica System:Notify] registration request"
msgstr ""
-#: include/contact_selectors.php:88
-msgid "pump.io"
+#: include/enotify.php:357
+#, php-format
+msgid "You've received a registration request from '%1$s' at %2$s"
msgstr ""
-#: include/contact_selectors.php:89
-msgid "Twitter"
+#: include/enotify.php:358
+#, php-format
+msgid "You've received a [url=%1$s]registration request[/url] from %2$s."
msgstr ""
-#: include/contact_selectors.php:90
-msgid "Diaspora Connector"
+#: include/enotify.php:362
+#, php-format
+msgid "Full Name:\t%1$s\\nSite Location:\t%2$s\\nLogin Name:\t%3$s (%4$s)"
msgstr ""
-#: include/contact_selectors.php:91
-msgid "GNU Social Connector"
+#: include/enotify.php:365
+#, php-format
+msgid "Please visit %s to approve or reject the request."
msgstr ""
-#: include/contact_selectors.php:92
-msgid "pnut"
+#: include/event.php:444
+msgid "all-day"
msgstr ""
-#: include/contact_selectors.php:93
-msgid "App.net"
+#: include/event.php:446
+msgid "Sun"
msgstr ""
-#: include/conversation.php:135 include/conversation.php:287
-#: include/like.php:185 include/text.php:1894
-msgid "event"
+#: include/event.php:447 include/text.php:1177
+msgid "Mon"
msgstr ""
-#: include/conversation.php:138 include/conversation.php:148
-#: include/conversation.php:290 include/conversation.php:299
-#: include/diaspora.php:1787 include/like.php:183 mod/subthread.php:90
-#: mod/tagger.php:65
-msgid "status"
+#: include/event.php:448 include/text.php:1177
+msgid "Tue"
msgstr ""
-#: include/conversation.php:143 include/conversation.php:295
-#: include/like.php:183 include/text.php:1896 mod/subthread.php:90
-#: mod/tagger.php:65
-msgid "photo"
+#: include/event.php:449 include/text.php:1177
+msgid "Wed"
msgstr ""
-#: include/conversation.php:155 include/diaspora.php:1783 include/like.php:32
-#, php-format
-msgid "%1$s likes %2$s's %3$s"
+#: include/event.php:450 include/text.php:1177
+msgid "Thu"
msgstr ""
-#: include/conversation.php:158 include/like.php:36 include/like.php:41
-#, php-format
-msgid "%1$s doesn't like %2$s's %3$s"
+#: include/event.php:451 include/text.php:1177
+msgid "Fri"
msgstr ""
-#: include/conversation.php:161
-#, php-format
-msgid "%1$s attends %2$s's %3$s"
+#: include/event.php:452 include/text.php:1177
+msgid "Sat"
msgstr ""
-#: include/conversation.php:164
-#, php-format
-msgid "%1$s doesn't attend %2$s's %3$s"
+#: include/event.php:454 include/text.php:1159 mod/settings.php:988
+msgid "Sunday"
msgstr ""
-#: include/conversation.php:167
-#, php-format
-msgid "%1$s attends maybe %2$s's %3$s"
+#: include/event.php:455 include/text.php:1159 mod/settings.php:988
+msgid "Monday"
msgstr ""
-#: include/conversation.php:200 mod/dfrn_confirm.php:481
-#, php-format
-msgid "%1$s is now friends with %2$s"
+#: include/event.php:456 include/text.php:1159
+msgid "Tuesday"
msgstr ""
-#: include/conversation.php:241
-#, php-format
-msgid "%1$s poked %2$s"
+#: include/event.php:457 include/text.php:1159
+msgid "Wednesday"
msgstr ""
-#: include/conversation.php:262 mod/mood.php:66
-#, php-format
-msgid "%1$s is currently %2$s"
+#: include/event.php:458 include/text.php:1159
+msgid "Thursday"
msgstr ""
-#: include/conversation.php:309 mod/tagger.php:98
-#, php-format
-msgid "%1$s tagged %2$s's %3$s with %4$s"
+#: include/event.php:459 include/text.php:1159
+msgid "Friday"
msgstr ""
-#: include/conversation.php:336
-msgid "post/item"
+#: include/event.php:460 include/text.php:1159
+msgid "Saturday"
msgstr ""
-#: include/conversation.php:337
-#, php-format
-msgid "%1$s marked %2$s's %3$s as favorite"
+#: include/event.php:462 include/text.php:1180
+msgid "Jan"
msgstr ""
-#: include/conversation.php:623 mod/photos.php:1639 mod/profiles.php:340
-msgid "Likes"
+#: include/event.php:463 include/text.php:1180
+msgid "Feb"
msgstr ""
-#: include/conversation.php:623 mod/photos.php:1639 mod/profiles.php:344
-msgid "Dislikes"
+#: include/event.php:464 include/text.php:1180
+msgid "Mar"
msgstr ""
-#: include/conversation.php:624 include/conversation.php:1559
-#: mod/photos.php:1640
-msgid "Attending"
-msgid_plural "Attending"
-msgstr[0] ""
-msgstr[1] ""
-
-#: include/conversation.php:624 mod/photos.php:1640
-msgid "Not attending"
+#: include/event.php:465 include/text.php:1180
+msgid "Apr"
msgstr ""
-#: include/conversation.php:624 mod/photos.php:1640
-msgid "Might attend"
+#: include/event.php:466 include/event.php:479 include/text.php:1163
+#: include/text.php:1180
+msgid "May"
msgstr ""
-#: include/conversation.php:761 mod/photos.php:1705 object/Item.php:147
-msgid "Select"
+#: include/event.php:467
+msgid "Jun"
msgstr ""
-#: include/conversation.php:762 mod/admin.php:1630 mod/contacts.php:838
-#: mod/contacts.php:1037 mod/photos.php:1706 mod/settings.php:754
-#: object/Item.php:148
-msgid "Delete"
+#: include/event.php:468 include/text.php:1180
+msgid "Jul"
msgstr ""
-#: include/conversation.php:806 object/Item.php:350 object/Item.php:351
-#, php-format
-msgid "View %s's profile @ %s"
+#: include/event.php:469 include/text.php:1180
+msgid "Aug"
msgstr ""
-#: include/conversation.php:818 object/Item.php:338
-msgid "Categories:"
+#: include/event.php:470
+msgid "Sept"
msgstr ""
-#: include/conversation.php:819 object/Item.php:339
-msgid "Filed under:"
+#: include/event.php:471 include/text.php:1180
+msgid "Oct"
msgstr ""
-#: include/conversation.php:826 object/Item.php:364
-#, php-format
-msgid "%s from %s"
+#: include/event.php:472 include/text.php:1180
+msgid "Nov"
msgstr ""
-#: include/conversation.php:842
-msgid "View in context"
+#: include/event.php:473 include/text.php:1180
+msgid "Dec"
msgstr ""
-#: include/conversation.php:844 include/conversation.php:1316
-#: mod/editpost.php:117 mod/message.php:337 mod/message.php:522
-#: mod/wallmessage.php:143 mod/photos.php:1604 object/Item.php:389
-msgid "Please wait"
+#: include/event.php:475 include/text.php:1163
+msgid "January"
msgstr ""
-#: include/conversation.php:921
-msgid "remove"
+#: include/event.php:476 include/text.php:1163
+msgid "February"
msgstr ""
-#: include/conversation.php:925
-msgid "Delete Selected Items"
+#: include/event.php:477 include/text.php:1163
+msgid "March"
msgstr ""
-#: include/conversation.php:1020 view/theme/frio/theme.php:347
-msgid "Follow Thread"
+#: include/event.php:478 include/text.php:1163
+msgid "April"
msgstr ""
-#: include/conversation.php:1157
-#, php-format
-msgid "%s likes this."
+#: include/event.php:480 include/text.php:1163
+msgid "June"
msgstr ""
-#: include/conversation.php:1160
-#, php-format
-msgid "%s doesn't like this."
+#: include/event.php:481 include/text.php:1163
+msgid "July"
msgstr ""
-#: include/conversation.php:1163
-#, php-format
-msgid "%s attends."
+#: include/event.php:482 include/text.php:1163
+msgid "August"
msgstr ""
-#: include/conversation.php:1166
-#, php-format
-msgid "%s doesn't attend."
+#: include/event.php:483 include/text.php:1163
+msgid "September"
msgstr ""
-#: include/conversation.php:1169
-#, php-format
-msgid "%s attends maybe."
+#: include/event.php:484 include/text.php:1163
+msgid "October"
msgstr ""
-#: include/conversation.php:1180
-msgid "and"
+#: include/event.php:485 include/text.php:1163
+msgid "November"
msgstr ""
-#: include/conversation.php:1186
-#, php-format
-msgid ", and %d other people"
+#: include/event.php:486 include/text.php:1163
+msgid "December"
msgstr ""
-#: include/conversation.php:1195
-#, php-format
-msgid "<span %1$s>%2$d people</span> like this"
+#: include/event.php:488 mod/cal.php:284 mod/events.php:394
+msgid "today"
msgstr ""
-#: include/conversation.php:1196
-#, php-format
-msgid "%s like this."
+#: include/event.php:493
+msgid "No events to display"
msgstr ""
-#: include/conversation.php:1199
-#, php-format
-msgid "<span %1$s>%2$d people</span> don't like this"
+#: include/event.php:607
+msgid "l, F j"
msgstr ""
-#: include/conversation.php:1200
-#, php-format
-msgid "%s don't like this."
+#: include/event.php:628
+msgid "Edit event"
msgstr ""
-#: include/conversation.php:1203
-#, php-format
-msgid "<span %1$s>%2$d people</span> attend"
+#: include/event.php:629
+msgid "Duplicate event"
msgstr ""
-#: include/conversation.php:1204
-#, php-format
-msgid "%s attend."
+#: include/event.php:630
+msgid "Delete event"
msgstr ""
-#: include/conversation.php:1207
-#, php-format
-msgid "<span %1$s>%2$d people</span> don't attend"
+#: include/event.php:657 include/text.php:1574 include/text.php:1581
+msgid "link to source"
msgstr ""
-#: include/conversation.php:1208
-#, php-format
-msgid "%s don't attend."
+#: include/event.php:914
+msgid "Export"
msgstr ""
-#: include/conversation.php:1211
-#, php-format
-msgid "<span %1$s>%2$d people</span> attend maybe"
+#: include/event.php:915
+msgid "Export calendar as ical"
msgstr ""
-#: include/conversation.php:1212
-#, php-format
-msgid "%s anttend maybe."
+#: include/event.php:916
+msgid "Export calendar as csv"
msgstr ""
-#: include/conversation.php:1241 include/conversation.php:1257
-msgid "Visible to <strong>everybody</strong>"
+#: include/event.php:933
+msgid "D g:i A"
msgstr ""
-#: include/conversation.php:1242 include/conversation.php:1258
-#: mod/message.php:271 mod/message.php:278 mod/message.php:418
-#: mod/message.php:425 mod/wallmessage.php:117 mod/wallmessage.php:124
-msgid "Please enter a link URL:"
+#: include/event.php:934
+msgid "g:i A"
msgstr ""
-#: include/conversation.php:1243 include/conversation.php:1259
-msgid "Please enter a video link/URL:"
+#: include/event.php:1003 include/event.php:1005
+msgid "Show map"
msgstr ""
-#: include/conversation.php:1244 include/conversation.php:1260
-msgid "Please enter an audio link/URL:"
+#: include/event.php:1004
+msgid "Hide map"
msgstr ""
-#: include/conversation.php:1245 include/conversation.php:1261
-msgid "Tag term:"
+#: include/features.php:68
+msgid "General Features"
msgstr ""
-#: include/conversation.php:1246 include/conversation.php:1262 mod/filer.php:31
-msgid "Save to Folder:"
+#: include/features.php:70
+msgid "Multiple Profiles"
msgstr ""
-#: include/conversation.php:1247 include/conversation.php:1263
-msgid "Where are you right now?"
+#: include/features.php:70
+msgid "Ability to create multiple profiles"
msgstr ""
-#: include/conversation.php:1248
-msgid "Delete item(s)?"
+#: include/features.php:71
+msgid "Photo Location"
msgstr ""
-#: include/conversation.php:1297
-msgid "Share"
+#: include/features.php:71
+msgid ""
+"Photo metadata is normally stripped. This extracts the location (if present) "
+"prior to stripping metadata and links it to a map."
msgstr ""
-#: include/conversation.php:1298 mod/editpost.php:103 mod/message.php:335
-#: mod/message.php:519 mod/wallmessage.php:141
-msgid "Upload photo"
+#: include/features.php:72
+msgid "Export Public Calendar"
msgstr ""
-#: include/conversation.php:1299 mod/editpost.php:104
-msgid "upload photo"
+#: include/features.php:72
+msgid "Ability for visitors to download the public calendar"
msgstr ""
-#: include/conversation.php:1300 mod/editpost.php:105
-msgid "Attach file"
+#: include/features.php:77
+msgid "Post Composition Features"
msgstr ""
-#: include/conversation.php:1301 mod/editpost.php:106
-msgid "attach file"
+#: include/features.php:78
+msgid "Post Preview"
msgstr ""
-#: include/conversation.php:1302 mod/editpost.php:107 mod/message.php:336
-#: mod/message.php:520 mod/wallmessage.php:142
-msgid "Insert web link"
+#: include/features.php:78
+msgid "Allow previewing posts and comments before publishing them"
msgstr ""
-#: include/conversation.php:1303 mod/editpost.php:108
-msgid "web link"
+#: include/features.php:79
+msgid "Auto-mention Forums"
msgstr ""
-#: include/conversation.php:1304 mod/editpost.php:109
-msgid "Insert video link"
+#: include/features.php:79
+msgid ""
+"Add/remove mention when a forum page is selected/deselected in ACL window."
msgstr ""
-#: include/conversation.php:1305 mod/editpost.php:110
-msgid "video link"
+#: include/features.php:84
+msgid "Network Sidebar Widgets"
msgstr ""
-#: include/conversation.php:1306 mod/editpost.php:111
-msgid "Insert audio link"
+#: include/features.php:85
+msgid "Search by Date"
msgstr ""
-#: include/conversation.php:1307 mod/editpost.php:112
-msgid "audio link"
+#: include/features.php:85
+msgid "Ability to select posts by date ranges"
msgstr ""
-#: include/conversation.php:1308 mod/editpost.php:113
-msgid "Set your location"
+#: include/features.php:86 include/features.php:116
+msgid "List Forums"
msgstr ""
-#: include/conversation.php:1309 mod/editpost.php:114
-msgid "set location"
+#: include/features.php:86
+msgid "Enable widget to display the forums your are connected with"
msgstr ""
-#: include/conversation.php:1310 mod/editpost.php:115
-msgid "Clear browser location"
+#: include/features.php:87
+msgid "Group Filter"
msgstr ""
-#: include/conversation.php:1311 mod/editpost.php:116
-msgid "clear location"
+#: include/features.php:87
+msgid "Enable widget to display Network posts only from selected group"
msgstr ""
-#: include/conversation.php:1313 mod/editpost.php:130
-msgid "Set title"
+#: include/features.php:88
+msgid "Network Filter"
msgstr ""
-#: include/conversation.php:1315 mod/editpost.php:132
-msgid "Categories (comma-separated list)"
+#: include/features.php:88
+msgid "Enable widget to display Network posts only from selected network"
msgstr ""
-#: include/conversation.php:1317 mod/editpost.php:118
-msgid "Permission settings"
+#: include/features.php:89 mod/network.php:202 mod/search.php:40
+msgid "Saved Searches"
msgstr ""
-#: include/conversation.php:1318 mod/editpost.php:147
-msgid "permissions"
+#: include/features.php:89
+msgid "Save search terms for re-use"
msgstr ""
-#: include/conversation.php:1326 mod/editpost.php:127
-msgid "Public post"
+#: include/features.php:94
+msgid "Network Tabs"
msgstr ""
-#: include/conversation.php:1331 mod/editpost.php:138 mod/events.php:527
-#: mod/photos.php:1624 mod/photos.php:1666 mod/photos.php:1746
-#: object/Item.php:711
-msgid "Preview"
+#: include/features.php:95
+msgid "Network Personal Tab"
msgstr ""
-#: include/conversation.php:1335 include/items.php:2154
-#: mod/dfrn_request.php:895 mod/editpost.php:141 mod/follow.php:161
-#: mod/message.php:210 mod/tagrm.php:14 mod/tagrm.php:99 mod/suggest.php:35
-#: mod/fbrowser.php:104 mod/fbrowser.php:139 mod/unfollow.php:117
-#: mod/contacts.php:469 mod/photos.php:249 mod/photos.php:341
-#: mod/settings.php:692 mod/settings.php:718 mod/videos.php:136
-msgid "Cancel"
+#: include/features.php:95
+msgid "Enable tab to display only Network posts that you've interacted on"
msgstr ""
-#: include/conversation.php:1341
-msgid "Post to Groups"
+#: include/features.php:96
+msgid "Network New Tab"
msgstr ""
-#: include/conversation.php:1342
-msgid "Post to Contacts"
+#: include/features.php:96
+msgid "Enable tab to display only new Network posts (from the last 12 hours)"
msgstr ""
-#: include/conversation.php:1343
-msgid "Private post"
+#: include/features.php:97
+msgid "Network Shared Links Tab"
msgstr ""
-#: include/conversation.php:1348 include/identity.php:268 mod/editpost.php:145
-msgid "Message"
+#: include/features.php:97
+msgid "Enable tab to display only Network posts with links in them"
msgstr ""
-#: include/conversation.php:1349 mod/editpost.php:146
-msgid "Browser"
+#: include/features.php:102
+msgid "Post/Comment Tools"
msgstr ""
-#: include/conversation.php:1531
-msgid "View all"
+#: include/features.php:103
+msgid "Multiple Deletion"
msgstr ""
-#: include/conversation.php:1553
-msgid "Like"
-msgid_plural "Likes"
-msgstr[0] ""
-msgstr[1] ""
-
-#: include/conversation.php:1556
-msgid "Dislike"
-msgid_plural "Dislikes"
-msgstr[0] ""
-msgstr[1] ""
-
-#: include/conversation.php:1562
-msgid "Not Attending"
-msgid_plural "Not Attending"
-msgstr[0] ""
-msgstr[1] ""
-
-#: include/dba.php:57
-#, php-format
-msgid "Cannot locate DNS info for database server '%s'"
+#: include/features.php:103
+msgid "Select and delete multiple posts/comments at once"
msgstr ""
-#: include/dbstructure.php:24
-msgid "There are no tables on MyISAM."
+#: include/features.php:104
+msgid "Edit Sent Posts"
msgstr ""
-#: include/dbstructure.php:65
-#, php-format
-msgid ""
-"\n"
-"\t\t\tThe friendica developers released update %s recently,\n"
-"\t\t\tbut when I tried to install it, something went terribly wrong.\n"
-"\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n"
-"\t\t\tfriendica developer if you can not help me on your own. My database "
-"might be invalid."
+#: include/features.php:104
+msgid "Edit and correct posts and comments after sending"
msgstr ""
-#: include/dbstructure.php:70
-#, php-format
-msgid ""
-"The error message is\n"
-"[pre]%s[/pre]"
+#: include/features.php:105
+msgid "Tagging"
msgstr ""
-#: include/dbstructure.php:192
-#, php-format
-msgid ""
-"\n"
-"Error %d occurred during database update:\n"
-"%s\n"
+#: include/features.php:105
+msgid "Ability to tag existing posts"
msgstr ""
-#: include/dbstructure.php:195
-msgid "Errors encountered performing database changes: "
+#: include/features.php:106
+msgid "Post Categories"
msgstr ""
-#: include/dbstructure.php:203
-msgid ": Database update"
+#: include/features.php:106
+msgid "Add categories to your posts"
msgstr ""
-#: include/dbstructure.php:436
-#, php-format
-msgid "%s: updating %s table."
+#: include/features.php:107
+msgid "Ability to file posts under folders"
msgstr ""
-#: include/delivery.php:429
-msgid "(no subject)"
+#: include/features.php:108
+msgid "Dislike Posts"
msgstr ""
-#: include/dfrn.php:1360
-#, php-format
-msgid "%s\\'s birthday"
+#: include/features.php:108
+msgid "Ability to dislike posts/comments"
msgstr ""
-#: include/diaspora.php:2351
-msgid "Sharing notification from Diaspora network"
+#: include/features.php:109
+msgid "Star Posts"
msgstr ""
-#: include/diaspora.php:3344
-msgid "Attachments:"
+#: include/features.php:109
+msgid "Ability to mark special posts with a star indicator"
msgstr ""
-#: include/event.php:445
-msgid "all-day"
+#: include/features.php:110
+msgid "Mute Post Notifications"
msgstr ""
-#: include/event.php:447
-msgid "Sun"
+#: include/features.php:110
+msgid "Ability to mute notifications for a thread"
msgstr ""
-#: include/event.php:448 include/text.php:1220
-msgid "Mon"
+#: include/features.php:115
+msgid "Advanced Profile Settings"
msgstr ""
-#: include/event.php:449 include/text.php:1220
-msgid "Tue"
+#: include/features.php:116
+msgid "Show visitors public community forums at the Advanced Profile Page"
msgstr ""
-#: include/event.php:450 include/text.php:1220
-msgid "Wed"
+#: include/features.php:117
+msgid "Tag Cloud"
msgstr ""
-#: include/event.php:451 include/text.php:1220
-msgid "Thu"
+#: include/features.php:117
+msgid "Provide a personal tag cloud on your profile page"
msgstr ""
-#: include/event.php:452 include/text.php:1220
-msgid "Fri"
-msgstr ""
-
-#: include/event.php:453 include/text.php:1220
-msgid "Sat"
-msgstr ""
-
-#: include/event.php:455 include/text.php:1202 mod/settings.php:986
-msgid "Sunday"
-msgstr ""
-
-#: include/event.php:456 include/text.php:1202 mod/settings.php:986
-msgid "Monday"
-msgstr ""
-
-#: include/event.php:457 include/text.php:1202
-msgid "Tuesday"
-msgstr ""
-
-#: include/event.php:458 include/text.php:1202
-msgid "Wednesday"
-msgstr ""
-
-#: include/event.php:459 include/text.php:1202
-msgid "Thursday"
-msgstr ""
-
-#: include/event.php:460 include/text.php:1202
-msgid "Friday"
-msgstr ""
-
-#: include/event.php:461 include/text.php:1202
-msgid "Saturday"
-msgstr ""
-
-#: include/event.php:463 include/text.php:1223
-msgid "Jan"
-msgstr ""
-
-#: include/event.php:464 include/text.php:1223
-msgid "Feb"
-msgstr ""
-
-#: include/event.php:465 include/text.php:1223
-msgid "Mar"
-msgstr ""
-
-#: include/event.php:466 include/text.php:1223
-msgid "Apr"
-msgstr ""
-
-#: include/event.php:467 include/event.php:480 include/text.php:1206
-#: include/text.php:1223
-msgid "May"
-msgstr ""
-
-#: include/event.php:468
-msgid "Jun"
-msgstr ""
-
-#: include/event.php:469 include/text.php:1223
-msgid "Jul"
-msgstr ""
-
-#: include/event.php:470 include/text.php:1223
-msgid "Aug"
-msgstr ""
-
-#: include/event.php:471
-msgid "Sept"
-msgstr ""
-
-#: include/event.php:472 include/text.php:1223
-msgid "Oct"
-msgstr ""
-
-#: include/event.php:473 include/text.php:1223
-msgid "Nov"
-msgstr ""
-
-#: include/event.php:474 include/text.php:1223
-msgid "Dec"
-msgstr ""
-
-#: include/event.php:476 include/text.php:1206
-msgid "January"
-msgstr ""
-
-#: include/event.php:477 include/text.php:1206
-msgid "February"
-msgstr ""
-
-#: include/event.php:478 include/text.php:1206
-msgid "March"
-msgstr ""
-
-#: include/event.php:479 include/text.php:1206
-msgid "April"
-msgstr ""
-
-#: include/event.php:481 include/text.php:1206
-msgid "June"
-msgstr ""
-
-#: include/event.php:482 include/text.php:1206
-msgid "July"
-msgstr ""
-
-#: include/event.php:483 include/text.php:1206
-msgid "August"
-msgstr ""
-
-#: include/event.php:484 include/text.php:1206
-msgid "September"
-msgstr ""
-
-#: include/event.php:485 include/text.php:1206
-msgid "October"
-msgstr ""
-
-#: include/event.php:486 include/text.php:1206
-msgid "November"
-msgstr ""
-
-#: include/event.php:487 include/text.php:1206
-msgid "December"
-msgstr ""
-
-#: include/event.php:489 mod/cal.php:281 mod/events.php:392
-msgid "today"
-msgstr ""
-
-#: include/event.php:494
-msgid "No events to display"
-msgstr ""
-
-#: include/event.php:608
-msgid "l, F j"
-msgstr ""
-
-#: include/event.php:629
-msgid "Edit event"
+#: include/follow.php:90 mod/dfrn_request.php:517
+msgid "Disallowed profile URL."
msgstr ""
-#: include/event.php:630
-msgid "Duplicate event"
+#: include/follow.php:95 mod/admin.php:292 mod/admin.php:310
+#: mod/dfrn_request.php:523 mod/friendica.php:117
+msgid "Blocked domain"
msgstr ""
-#: include/event.php:631
-msgid "Delete event"
+#: include/follow.php:100
+msgid "Connect URL missing."
msgstr ""
-#: include/event.php:658 include/text.php:1618 include/text.php:1625
-msgid "link to source"
+#: include/follow.php:132
+msgid ""
+"This site is not configured to allow communications with other networks."
msgstr ""
-#: include/event.php:915
-msgid "Export"
+#: include/follow.php:133 include/follow.php:147
+msgid "No compatible communication protocols or feeds were discovered."
msgstr ""
-#: include/event.php:916
-msgid "Export calendar as ical"
+#: include/follow.php:145
+msgid "The profile address specified does not provide adequate information."
msgstr ""
-#: include/event.php:917
-msgid "Export calendar as csv"
+#: include/follow.php:150
+msgid "An author or name was not found."
msgstr ""
-#: include/event.php:934
-msgid "D g:i A"
+#: include/follow.php:153
+msgid "No browser URL could be matched to this address."
msgstr ""
-#: include/event.php:935
-msgid "g:i A"
+#: include/follow.php:156
+msgid ""
+"Unable to match @-style Identity Address with a known protocol or email "
+"contact."
msgstr ""
-#: include/event.php:1004 include/event.php:1006
-msgid "Show map"
+#: include/follow.php:157
+msgid "Use mailto: in front of address to force email check."
msgstr ""
-#: include/event.php:1005
-msgid "Hide map"
+#: include/follow.php:163
+msgid ""
+"The profile address specified belongs to a network which has been disabled "
+"on this site."
msgstr ""
-#: include/follow.php:87 mod/dfrn_request.php:515
-msgid "Disallowed profile URL."
+#: include/follow.php:168
+msgid ""
+"Limited profile. This person will be unable to receive direct/personal "
+"notifications from you."
msgstr ""
-#: include/follow.php:92 mod/dfrn_request.php:521 mod/friendica.php:116
-#: mod/admin.php:290 mod/admin.php:308
-msgid "Blocked domain"
+#: include/follow.php:239
+msgid "Unable to retrieve contact information."
msgstr ""
-#: include/follow.php:97
-msgid "Connect URL missing."
+#: include/group.php:27
+msgid ""
+"A deleted group with this name was revived. Existing item permissions "
+"<strong>may</strong> apply to this group and any future members. If this is "
+"not what you intended, please create another group with a different name."
msgstr ""
-#: include/follow.php:129
-msgid ""
-"This site is not configured to allow communications with other networks."
+#: include/group.php:199
+msgid "Default privacy group for new contacts"
msgstr ""
-#: include/follow.php:130 include/follow.php:144
-msgid "No compatible communication protocols or feeds were discovered."
+#: include/group.php:232
+msgid "Everybody"
msgstr ""
-#: include/follow.php:142
-msgid "The profile address specified does not provide adequate information."
+#: include/group.php:255
+msgid "edit"
msgstr ""
-#: include/follow.php:147
-msgid "An author or name was not found."
+#: include/group.php:276 mod/newmember.php:40
+msgid "Groups"
msgstr ""
-#: include/follow.php:150
-msgid "No browser URL could be matched to this address."
+#: include/group.php:278
+msgid "Edit groups"
msgstr ""
-#: include/follow.php:153
-msgid ""
-"Unable to match @-style Identity Address with a known protocol or email "
-"contact."
+#: include/group.php:280
+msgid "Edit group"
msgstr ""
-#: include/follow.php:154
-msgid "Use mailto: in front of address to force email check."
+#: include/group.php:281
+msgid "Create a new group"
msgstr ""
-#: include/follow.php:160
-msgid ""
-"The profile address specified belongs to a network which has been disabled "
-"on this site."
+#: include/group.php:282 mod/group.php:101 mod/group.php:198
+msgid "Group Name: "
msgstr ""
-#: include/follow.php:165
-msgid ""
-"Limited profile. This person will be unable to receive direct/personal "
-"notifications from you."
+#: include/group.php:284
+msgid "Contacts not in any group"
msgstr ""
-#: include/follow.php:236
-msgid "Unable to retrieve contact information."
+#: include/group.php:286 mod/network.php:203
+msgid "add"
msgstr ""
-#: include/identity.php:47
+#: include/identity.php:52
msgid "Requested account is not available."
msgstr ""
-#: include/identity.php:56 mod/profile.php:23
+#: include/identity.php:61 mod/profile.php:26
msgid "Requested profile is not available."
msgstr ""
-#: include/identity.php:100 include/identity.php:323 include/identity.php:756
+#: include/identity.php:110 include/identity.php:340 include/identity.php:798
msgid "Edit profile"
msgstr ""
-#: include/identity.php:263
+#: include/identity.php:278
msgid "Atom feed"
msgstr ""
-#: include/identity.php:294
+#: include/identity.php:313 include/nav.php:194
+msgid "Profiles"
+msgstr ""
+
+#: include/identity.php:313
msgid "Manage/edit profiles"
msgstr ""
-#: include/identity.php:299 include/identity.php:325 mod/profiles.php:786
+#: include/identity.php:320 include/identity.php:342 mod/profiles.php:789
msgid "Change profile photo"
msgstr ""
-#: include/identity.php:300 mod/profiles.php:787
+#: include/identity.php:321 mod/profiles.php:790
msgid "Create New Profile"
msgstr ""
-#: include/identity.php:310 mod/profiles.php:776
+#: include/identity.php:330 mod/profiles.php:779
msgid "Profile Image"
msgstr ""
-#: include/identity.php:313 mod/profiles.php:778
+#: include/identity.php:333 mod/profiles.php:781
msgid "visible to everybody"
msgstr ""
-#: include/identity.php:314 mod/profiles.php:683 mod/profiles.php:779
+#: include/identity.php:334 mod/profiles.php:687 mod/profiles.php:782
msgid "Edit visibility"
msgstr ""
-#: include/identity.php:342 include/identity.php:643 mod/notifications.php:253
-#: mod/directory.php:135
+#: include/identity.php:361 include/identity.php:686 mod/directory.php:138
+#: mod/notifications.php:254
msgid "Gender:"
msgstr ""
-#: include/identity.php:345 include/identity.php:666 mod/directory.php:137
+#: include/identity.php:364 include/identity.php:708 mod/directory.php:140
msgid "Status:"
msgstr ""
-#: include/identity.php:347 include/identity.php:683 mod/directory.php:139
+#: include/identity.php:366 include/identity.php:725 mod/directory.php:142
msgid "Homepage:"
msgstr ""
-#: include/identity.php:349 include/identity.php:703 mod/notifications.php:249
-#: mod/directory.php:141 mod/contacts.php:662
+#: include/identity.php:368 include/identity.php:745 mod/contacts.php:670
+#: mod/directory.php:144 mod/notifications.php:250
msgid "About:"
msgstr ""
-#: include/identity.php:351 mod/contacts.php:660
+#: include/identity.php:370 mod/contacts.php:668
msgid "XMPP:"
msgstr ""
-#: include/identity.php:437 mod/notifications.php:261 mod/contacts.php:60
+#: include/identity.php:464 mod/contacts.php:60 mod/notifications.php:262
msgid "Network:"
msgstr ""
-#: include/identity.php:466 include/identity.php:557
+#: include/identity.php:496 include/identity.php:594
msgid "g A l F d"
msgstr ""
-#: include/identity.php:467 include/identity.php:558
+#: include/identity.php:497 include/identity.php:595
msgid "F d"
msgstr ""
-#: include/identity.php:519 include/identity.php:605
+#: include/identity.php:554 include/identity.php:643
msgid "[today]"
msgstr ""
-#: include/identity.php:531
+#: include/identity.php:567
msgid "Birthday Reminders"
msgstr ""
-#: include/identity.php:532
+#: include/identity.php:568
msgid "Birthdays this week:"
msgstr ""
-#: include/identity.php:592
+#: include/identity.php:630
msgid "[No description]"
msgstr ""
-#: include/identity.php:619
+#: include/identity.php:659
msgid "Event Reminders"
msgstr ""
-#: include/identity.php:620
+#: include/identity.php:660
msgid "Events this week:"
msgstr ""
-#: include/identity.php:640 mod/settings.php:1273
+#: include/identity.php:674 include/identity.php:804 include/identity.php:839
+#: include/nav.php:87 mod/contacts.php:677 mod/contacts.php:879
+#: mod/newmember.php:21 mod/profperm.php:108 view/theme/frio/theme.php:257
+msgid "Profile"
+msgstr ""
+
+#: include/identity.php:683 mod/settings.php:1270
msgid "Full Name:"
msgstr ""
-#: include/identity.php:647
+#: include/identity.php:690
msgid "j F, Y"
msgstr ""
-#: include/identity.php:648
+#: include/identity.php:691
msgid "j F"
msgstr ""
-#: include/identity.php:662
+#: include/identity.php:704
msgid "Age:"
msgstr ""
-#: include/identity.php:675
+#: include/identity.php:717
#, php-format
msgid "for %1$d %2$s"
msgstr ""
-#: include/identity.php:679 mod/profiles.php:702
+#: include/identity.php:721 mod/profiles.php:706
msgid "Sexual Preference:"
msgstr ""
-#: include/identity.php:687 mod/profiles.php:729
+#: include/identity.php:729 mod/profiles.php:733
msgid "Hometown:"
msgstr ""
-#: include/identity.php:691 mod/follow.php:174 mod/notifications.php:251
-#: mod/contacts.php:664
+#: include/identity.php:733 mod/contacts.php:672 mod/follow.php:175
+#: mod/notifications.php:252
msgid "Tags:"
msgstr ""
-#: include/identity.php:695 mod/profiles.php:730
+#: include/identity.php:737 mod/profiles.php:734
msgid "Political Views:"
msgstr ""
-#: include/identity.php:699
+#: include/identity.php:741
msgid "Religion:"
msgstr ""
-#: include/identity.php:707
+#: include/identity.php:749
msgid "Hobbies/Interests:"
msgstr ""
-#: include/identity.php:711 mod/profiles.php:734
+#: include/identity.php:753 mod/profiles.php:738
msgid "Likes:"
msgstr ""
-#: include/identity.php:715 mod/profiles.php:735
+#: include/identity.php:757 mod/profiles.php:739
msgid "Dislikes:"
msgstr ""
-#: include/identity.php:719
+#: include/identity.php:761
msgid "Contact information and Social Networks:"
msgstr ""
-#: include/identity.php:723
+#: include/identity.php:765
msgid "Musical interests:"
msgstr ""
-#: include/identity.php:727
+#: include/identity.php:769
msgid "Books, literature:"
msgstr ""
-#: include/identity.php:731
+#: include/identity.php:773
msgid "Television:"
msgstr ""
-#: include/identity.php:735
+#: include/identity.php:777
msgid "Film/dance/culture/entertainment:"
msgstr ""
-#: include/identity.php:739
+#: include/identity.php:781
msgid "Love/Romance:"
msgstr ""
-#: include/identity.php:743
+#: include/identity.php:785
msgid "Work/employment:"
msgstr ""
-#: include/identity.php:747
+#: include/identity.php:789
msgid "School/education:"
msgstr ""
-#: include/identity.php:752
+#: include/identity.php:794
msgid "Forums:"
msgstr ""
-#: include/identity.php:761 mod/events.php:530
+#: include/identity.php:805 mod/events.php:532
msgid "Basic"
msgstr ""
-#: include/identity.php:762 mod/admin.php:1181 mod/contacts.php:900
-#: mod/events.php:531
+#: include/identity.php:806 mod/admin.php:1183 mod/contacts.php:908
+#: mod/events.php:533
msgid "Advanced"
msgstr ""
-#: include/identity.php:788 mod/follow.php:182 mod/unfollow.php:133
-#: mod/contacts.php:866
+#: include/identity.php:831 include/nav.php:86 mod/contacts.php:675
+#: mod/contacts.php:871 view/theme/frio/theme.php:256
+msgid "Status"
+msgstr ""
+
+#: include/identity.php:834 mod/contacts.php:874 mod/follow.php:183
+#: mod/unfollow.php:132
msgid "Status Messages and Posts"
msgstr ""
-#: include/identity.php:796 mod/contacts.php:874
+#: include/identity.php:842 mod/contacts.php:882
msgid "Profile Details"
msgstr ""
-#: include/identity.php:804 mod/photos.php:97
+#: include/identity.php:847 include/nav.php:88 mod/fbrowser.php:34
+#: view/theme/frio/theme.php:258
+msgid "Photos"
+msgstr ""
+
+#: include/identity.php:850 mod/photos.php:99
msgid "Photo Albums"
msgstr ""
-#: include/identity.php:843 mod/notes.php:49
+#: include/identity.php:855 include/identity.php:858 include/nav.php:89
+#: view/theme/frio/theme.php:259
+msgid "Videos"
+msgstr ""
+
+#: include/identity.php:867 include/identity.php:878 include/nav.php:90
+#: include/nav.php:154 mod/cal.php:276 mod/events.php:385
+#: view/theme/frio/theme.php:260 view/theme/frio/theme.php:264
+msgid "Events"
+msgstr ""
+
+#: include/identity.php:870 include/identity.php:881 include/nav.php:154
+#: view/theme/frio/theme.php:264
+msgid "Events and Calendar"
+msgstr ""
+
+#: include/identity.php:889 mod/notes.php:50
msgid "Personal Notes"
msgstr ""
-#: include/identity.php:846
+#: include/identity.php:892
msgid "Only You Can See This"
msgstr ""
-#: include/items.php:1731 mod/dfrn_request.php:760 mod/dfrn_confirm.php:739
+#: include/identity.php:900 include/identity.php:903 include/nav.php:133
+#: include/nav.php:197 include/text.php:1056 mod/contacts.php:830
+#: mod/contacts.php:891 mod/viewcontacts.php:126 view/theme/frio/theme.php:267
+msgid "Contacts"
+msgstr ""
+
+#: include/items.php:1731 mod/dfrn_confirm.php:742 mod/dfrn_request.php:762
msgid "[Name Withheld]"
msgstr ""
-#: include/items.php:2106 mod/viewsrc.php:16 mod/notice.php:18
-#: mod/admin.php:258 mod/admin.php:1687 mod/admin.php:1938 mod/display.php:106
-#: mod/display.php:279 mod/display.php:487
+#: include/items.php:2100 mod/admin.php:260 mod/admin.php:1687
+#: mod/admin.php:1938 mod/display.php:108 mod/display.php:279
+#: mod/display.php:487 mod/notice.php:19 mod/viewsrc.php:17
msgid "Item not found."
msgstr ""
-#: include/items.php:2149
+#: include/items.php:2143
msgid "Do you really want to delete this item?"
msgstr ""
-#: include/items.php:2151 mod/api.php:107 mod/dfrn_request.php:881
-#: mod/follow.php:150 mod/message.php:207 mod/suggest.php:32
-#: mod/contacts.php:466 mod/profiles.php:639 mod/profiles.php:642
-#: mod/profiles.php:669 mod/register.php:250 mod/settings.php:1158
-#: mod/settings.php:1164 mod/settings.php:1171 mod/settings.php:1175
-#: mod/settings.php:1180 mod/settings.php:1185 mod/settings.php:1190
-#: mod/settings.php:1195 mod/settings.php:1221 mod/settings.php:1222
-#: mod/settings.php:1223 mod/settings.php:1224 mod/settings.php:1225
+#: include/items.php:2145 mod/api.php:109 mod/contacts.php:467
+#: mod/dfrn_request.php:883 mod/follow.php:151 mod/message.php:209
+#: mod/profiles.php:643 mod/profiles.php:646 mod/profiles.php:673
+#: mod/register.php:252 mod/settings.php:1155 mod/settings.php:1161
+#: mod/settings.php:1168 mod/settings.php:1172 mod/settings.php:1177
+#: mod/settings.php:1182 mod/settings.php:1187 mod/settings.php:1192
+#: mod/settings.php:1218 mod/settings.php:1219 mod/settings.php:1220
+#: mod/settings.php:1221 mod/settings.php:1222 mod/suggest.php:36
msgid "Yes"
msgstr ""
-#: include/items.php:2290 mod/api.php:28 mod/api.php:33 mod/attach.php:35
-#: mod/common.php:20 mod/crepair.php:105 mod/nogroup.php:29
-#: mod/viewcontacts.php:49 mod/uimport.php:26 mod/allfriends.php:15
-#: mod/cal.php:302 mod/editpost.php:13 mod/follow.php:14 mod/follow.php:55
-#: mod/follow.php:118 mod/group.php:21 mod/invite.php:18 mod/invite.php:106
-#: mod/manage.php:104 mod/message.php:49 mod/message.php:172
-#: mod/notifications.php:74 mod/repair_ostatus.php:12 mod/wallmessage.php:12
-#: mod/wallmessage.php:36 mod/wallmessage.php:76 mod/wallmessage.php:100
-#: mod/delegate.php:15 mod/suggest.php:58 mod/unfollow.php:14
-#: mod/unfollow.php:57 mod/unfollow.php:90 mod/contacts.php:374
-#: mod/dfrn_confirm.php:65 mod/dirfind.php:17 mod/display.php:484
-#: mod/events.php:190 mod/fsuggest.php:81 mod/item.php:199 mod/item.php:211
-#: mod/mood.php:118 mod/network.php:17 mod/notes.php:25
-#: mod/ostatus_subscribe.php:12 mod/photos.php:170 mod/photos.php:1095
-#: mod/poke.php:157 mod/profile_photo.php:21 mod/profile_photo.php:181
-#: mod/profile_photo.php:192 mod/profile_photo.php:205 mod/profiles.php:168
-#: mod/profiles.php:606 mod/register.php:47 mod/regmod.php:108
-#: mod/settings.php:28 mod/settings.php:130 mod/settings.php:678
-#: mod/wall_attach.php:69 mod/wall_attach.php:72 mod/wall_upload.php:102
-#: mod/wall_upload.php:105 index.php:412
+#: include/items.php:2272 mod/allfriends.php:18 mod/api.php:30 mod/api.php:35
+#: mod/attach.php:36 mod/cal.php:305 mod/common.php:23 mod/contacts.php:375
+#: mod/crepair.php:108 mod/delegate.php:16 mod/dfrn_confirm.php:69
+#: mod/dirfind.php:21 mod/display.php:484 mod/editpost.php:15
+#: mod/events.php:192 mod/follow.php:15 mod/follow.php:56 mod/follow.php:119
+#: mod/fsuggest.php:82 mod/group.php:24 mod/invite.php:20 mod/invite.php:108
+#: mod/item.php:203 mod/item.php:215 mod/manage.php:105 mod/message.php:51
+#: mod/message.php:174 mod/mood.php:119 mod/network.php:21 mod/nogroup.php:30
+#: mod/notes.php:26 mod/notifications.php:75 mod/ostatus_subscribe.php:13
+#: mod/photos.php:172 mod/photos.php:1097 mod/poke.php:158
+#: mod/profile_photo.php:23 mod/profile_photo.php:183 mod/profile_photo.php:194
+#: mod/profile_photo.php:207 mod/profiles.php:172 mod/profiles.php:610
+#: mod/register.php:49 mod/regmod.php:110 mod/repair_ostatus.php:11
+#: mod/settings.php:31 mod/settings.php:133 mod/settings.php:683
+#: mod/suggest.php:62 mod/uimport.php:27 mod/unfollow.php:14
+#: mod/unfollow.php:56 mod/unfollow.php:89 mod/viewcontacts.php:51
+#: mod/wall_attach.php:71 mod/wall_attach.php:74 mod/wall_upload.php:103
+#: mod/wall_upload.php:106 mod/wallmessage.php:13 mod/wallmessage.php:37
+#: mod/wallmessage.php:77 mod/wallmessage.php:101 index.php:399
msgid "Permission denied."
msgstr ""
-#: include/items.php:2407
+#: include/items.php:2389
msgid "Archives"
msgstr ""
-#: include/like.php:46
+#: include/like.php:47
#, php-format
msgid "%1$s is attending %2$s's %3$s"
msgstr ""
-#: include/like.php:51
+#: include/like.php:52
#, php-format
msgid "%1$s is not attending %2$s's %3$s"
msgstr ""
-#: include/like.php:56
+#: include/like.php:57
#, php-format
msgid "%1$s may attend %2$s's %3$s"
msgstr ""
-#: include/message.php:16 include/message.php:162
+#: include/message.php:17 include/message.php:163
msgid "[no subject]"
msgstr ""
-#: include/network.php:714
-msgid "view full size"
+#: include/nav.php:40 mod/navigation.php:22
+msgid "Nothing new here"
msgstr ""
-#: include/ostatus.php:1713
-#, php-format
-msgid "%s is now following %s."
+#: include/nav.php:44 mod/navigation.php:26
+msgid "Clear notifications"
msgstr ""
-#: include/ostatus.php:1714
-msgid "following"
+#: include/nav.php:45 include/text.php:1049
+msgid "@name, !forum, #tags, content"
msgstr ""
-#: include/ostatus.php:1717
-#, php-format
-msgid "%s stopped following %s."
+#: include/nav.php:83 view/theme/frio/theme.php:253 boot.php:901
+msgid "Logout"
msgstr ""
-#: include/ostatus.php:1718
-msgid "stopped following"
+#: include/nav.php:83 view/theme/frio/theme.php:253
+msgid "End this session"
msgstr ""
-#: include/text.php:315
-msgid "newer"
+#: include/nav.php:86 include/nav.php:166 view/theme/frio/theme.php:256
+msgid "Your posts and conversations"
msgstr ""
-#: include/text.php:316
-msgid "older"
+#: include/nav.php:87 view/theme/frio/theme.php:257
+msgid "Your profile page"
msgstr ""
-#: include/text.php:321
-msgid "first"
+#: include/nav.php:88 view/theme/frio/theme.php:258
+msgid "Your photos"
msgstr ""
-#: include/text.php:322
-msgid "prev"
+#: include/nav.php:89 view/theme/frio/theme.php:259
+msgid "Your videos"
msgstr ""
-#: include/text.php:356
-msgid "next"
+#: include/nav.php:90 view/theme/frio/theme.php:260
+msgid "Your events"
msgstr ""
-#: include/text.php:357
-msgid "last"
+#: include/nav.php:91
+msgid "Personal notes"
msgstr ""
-#: include/text.php:411
-msgid "Loading more entries..."
+#: include/nav.php:91
+msgid "Your personal notes"
msgstr ""
-#: include/text.php:412
-msgid "The end"
+#: include/nav.php:100 mod/bookmarklet.php:15 boot.php:902
+msgid "Login"
msgstr ""
-#: include/text.php:961
-msgid "No contacts"
+#: include/nav.php:100
+msgid "Sign in"
msgstr ""
-#: include/text.php:985
-#, php-format
-msgid "%d Contact"
-msgid_plural "%d Contacts"
-msgstr[0] ""
-msgstr[1] ""
-
-#: include/text.php:998
-msgid "View Contacts"
+#: include/nav.php:110 include/nav.php:166
+#: src/Core/NotificationsManager.php:197
+msgid "Home"
msgstr ""
-#: include/text.php:1088 mod/filer.php:32 mod/editpost.php:102 mod/notes.php:64
-msgid "Save"
+#: include/nav.php:110
+msgid "Home Page"
msgstr ""
-#: include/text.php:1149
-msgid "poke"
+#: include/nav.php:114 mod/register.php:296 boot.php:874
+msgid "Register"
msgstr ""
-#: include/text.php:1149
-msgid "poked"
+#: include/nav.php:114
+msgid "Create an account"
msgstr ""
-#: include/text.php:1150
-msgid "ping"
+#: include/nav.php:120 mod/help.php:51 view/theme/vier/theme.php:292
+msgid "Help"
msgstr ""
-#: include/text.php:1150
-msgid "pinged"
+#: include/nav.php:120
+msgid "Help and documentation"
msgstr ""
-#: include/text.php:1151
-msgid "prod"
+#: include/nav.php:124
+msgid "Apps"
msgstr ""
-#: include/text.php:1151
-msgid "prodded"
+#: include/nav.php:124
+msgid "Addon applications, utilities, games"
msgstr ""
-#: include/text.php:1152
+#: include/nav.php:128 include/text.php:1046 mod/search.php:148
+msgid "Search"
+msgstr ""
+
+#: include/nav.php:128
+msgid "Search site content"
+msgstr ""
+
+#: include/nav.php:131 include/text.php:1054
+msgid "Full Text"
+msgstr ""
+
+#: include/nav.php:132 include/tags.php:234 include/text.php:1055
+msgid "Tags"
+msgstr ""
+
+#: include/nav.php:136 include/text.php:1059 view/theme/vier/theme.php:249
+#: src/Content/ForumManager.php:121
+msgid "Forums"
+msgstr ""
+
+#: include/nav.php:148 include/nav.php:150 mod/community.php:89
+msgid "Community"
+msgstr ""
+
+#: include/nav.php:148
+msgid "Conversations on this site"
+msgstr ""
+
+#: include/nav.php:150
+msgid "Conversations on the network"
+msgstr ""
+
+#: include/nav.php:157
+msgid "Directory"
+msgstr ""
+
+#: include/nav.php:157
+msgid "People directory"
+msgstr ""
+
+#: include/nav.php:159
+msgid "Information"
+msgstr ""
+
+#: include/nav.php:159
+msgid "Information about this friendica instance"
+msgstr ""
+
+#: include/nav.php:163 mod/admin.php:592 view/theme/frio/theme.php:263
+#: src/Core/NotificationsManager.php:183
+msgid "Network"
+msgstr ""
+
+#: include/nav.php:163 view/theme/frio/theme.php:263
+msgid "Conversations from your friends"
+msgstr ""
+
+#: include/nav.php:164
+msgid "Network Reset"
+msgstr ""
+
+#: include/nav.php:164
+msgid "Load Network page with no filters"
+msgstr ""
+
+#: include/nav.php:171 src/Core/NotificationsManager.php:204
+msgid "Introductions"
+msgstr ""
+
+#: include/nav.php:171
+msgid "Friend Requests"
+msgstr ""
+
+#: include/nav.php:174 mod/notifications.php:100
+msgid "Notifications"
+msgstr ""
+
+#: include/nav.php:175
+msgid "See all notifications"
+msgstr ""
+
+#: include/nav.php:176 mod/settings.php:916
+msgid "Mark as seen"
+msgstr ""
+
+#: include/nav.php:176
+msgid "Mark all system notifications seen"
+msgstr ""
+
+#: include/nav.php:180 mod/message.php:182 view/theme/frio/theme.php:265
+msgid "Messages"
+msgstr ""
+
+#: include/nav.php:180 view/theme/frio/theme.php:265
+msgid "Private mail"
+msgstr ""
+
+#: include/nav.php:181
+msgid "Inbox"
+msgstr ""
+
+#: include/nav.php:182
+msgid "Outbox"
+msgstr ""
+
+#: include/nav.php:183 mod/message.php:21
+msgid "New Message"
+msgstr ""
+
+#: include/nav.php:186
+msgid "Manage"
+msgstr ""
+
+#: include/nav.php:186
+msgid "Manage other pages"
+msgstr ""
+
+#: include/nav.php:189 mod/settings.php:84
+msgid "Delegations"
+msgstr ""
+
+#: include/nav.php:189 mod/delegate.php:131
+msgid "Delegate Page Management"
+msgstr ""
+
+#: include/nav.php:191 mod/admin.php:1740 mod/admin.php:2016
+#: mod/newmember.php:16 mod/settings.php:114 view/theme/frio/theme.php:266
+msgid "Settings"
+msgstr ""
+
+#: include/nav.php:191 view/theme/frio/theme.php:266
+msgid "Account settings"
+msgstr ""
+
+#: include/nav.php:194
+msgid "Manage/Edit Profiles"
+msgstr ""
+
+#: include/nav.php:197 view/theme/frio/theme.php:267
+msgid "Manage/edit friends and contacts"
+msgstr ""
+
+#: include/nav.php:202 mod/admin.php:206
+msgid "Admin"
+msgstr ""
+
+#: include/nav.php:202
+msgid "Site setup and configuration"
+msgstr ""
+
+#: include/nav.php:205
+msgid "Navigation"
+msgstr ""
+
+#: include/nav.php:205
+msgid "Site map"
+msgstr ""
+
+#: include/network.php:732
+msgid "view full size"
+msgstr ""
+
+#: include/oembed.php:256
+msgid "Embedded content"
+msgstr ""
+
+#: include/oembed.php:264
+msgid "Embedding disabled"
+msgstr ""
+
+#: include/photos.php:57 include/photos.php:66 mod/fbrowser.php:43
+#: mod/fbrowser.php:65 mod/photos.php:193 mod/photos.php:1111
+#: mod/photos.php:1230 mod/photos.php:1247 mod/photos.php:1785
+#: mod/photos.php:1799
+msgid "Contact Photos"
+msgstr ""
+
+#: include/security.php:67
+msgid "Welcome "
+msgstr ""
+
+#: include/security.php:68
+msgid "Please upload a profile photo."
+msgstr ""
+
+#: include/security.php:70
+msgid "Welcome back "
+msgstr ""
+
+#: include/security.php:427
+msgid ""
+"The form security token was not correct. This probably happened because the "
+"form has been opened for too long (>3 hours) before submitting it."
+msgstr ""
+
+#: include/text.php:289
+msgid "newer"
+msgstr ""
+
+#: include/text.php:290
+msgid "older"
+msgstr ""
+
+#: include/text.php:295
+msgid "first"
+msgstr ""
+
+#: include/text.php:296
+msgid "prev"
+msgstr ""
+
+#: include/text.php:330
+msgid "next"
+msgstr ""
+
+#: include/text.php:331
+msgid "last"
+msgstr ""
+
+#: include/text.php:385
+msgid "Loading more entries..."
+msgstr ""
+
+#: include/text.php:386
+msgid "The end"
+msgstr ""
+
+#: include/text.php:922
+msgid "No contacts"
+msgstr ""
+
+#: include/text.php:946
+#, php-format
+msgid "%d Contact"
+msgid_plural "%d Contacts"
+msgstr[0] ""
+msgstr[1] ""
+
+#: include/text.php:959
+msgid "View Contacts"
+msgstr ""
+
+#: include/text.php:1047 mod/editpost.php:104 mod/filer.php:33 mod/notes.php:65
+msgid "Save"
+msgstr ""
+
+#: include/text.php:1106
+msgid "poke"
+msgstr ""
+
+#: include/text.php:1106
+msgid "poked"
+msgstr ""
+
+#: include/text.php:1107
+msgid "ping"
+msgstr ""
+
+#: include/text.php:1107
+msgid "pinged"
+msgstr ""
+
+#: include/text.php:1108
+msgid "prod"
+msgstr ""
+
+#: include/text.php:1108
+msgid "prodded"
+msgstr ""
+
+#: include/text.php:1109
msgid "slap"
msgstr ""
-#: include/text.php:1152
+#: include/text.php:1109
msgid "slapped"
msgstr ""
-#: include/text.php:1153
+#: include/text.php:1110
msgid "finger"
msgstr ""
-#: include/text.php:1153
+#: include/text.php:1110
msgid "fingered"
msgstr ""
-#: include/text.php:1154
+#: include/text.php:1111
msgid "rebuff"
msgstr ""
-#: include/text.php:1154
+#: include/text.php:1111
msgid "rebuffed"
msgstr ""
-#: include/text.php:1168
+#: include/text.php:1125
msgid "happy"
msgstr ""
-#: include/text.php:1169
+#: include/text.php:1126
msgid "sad"
msgstr ""
-#: include/text.php:1170
+#: include/text.php:1127
msgid "mellow"
msgstr ""
-#: include/text.php:1171
+#: include/text.php:1128
msgid "tired"
msgstr ""
-#: include/text.php:1172
+#: include/text.php:1129
msgid "perky"
msgstr ""
-#: include/text.php:1173
+#: include/text.php:1130
msgid "angry"
msgstr ""
-#: include/text.php:1174
+#: include/text.php:1131
msgid "stupified"
msgstr ""
-#: include/text.php:1175
+#: include/text.php:1132
msgid "puzzled"
msgstr ""
-#: include/text.php:1176
+#: include/text.php:1133
msgid "interested"
msgstr ""
-#: include/text.php:1177
+#: include/text.php:1134
msgid "bitter"
msgstr ""
-#: include/text.php:1178
+#: include/text.php:1135
msgid "cheerful"
msgstr ""
-#: include/text.php:1179
+#: include/text.php:1136
msgid "alive"
msgstr ""
-#: include/text.php:1180
+#: include/text.php:1137
msgid "annoyed"
msgstr ""
-#: include/text.php:1181
+#: include/text.php:1138
msgid "anxious"
msgstr ""
-#: include/text.php:1182
+#: include/text.php:1139
msgid "cranky"
msgstr ""
-#: include/text.php:1183
+#: include/text.php:1140
msgid "disturbed"
msgstr ""
-#: include/text.php:1184
+#: include/text.php:1141
msgid "frustrated"
msgstr ""
-#: include/text.php:1185
+#: include/text.php:1142
msgid "motivated"
msgstr ""
-#: include/text.php:1186
+#: include/text.php:1143
msgid "relaxed"
msgstr ""
-#: include/text.php:1187
+#: include/text.php:1144
msgid "surprised"
msgstr ""
-#: include/text.php:1220
+#: include/text.php:1177
msgid "Sund"
msgstr ""
-#: include/text.php:1223
+#: include/text.php:1180
msgid "Sep"
msgstr ""
-#: include/text.php:1421 mod/videos.php:390
+#: include/text.php:1377 mod/videos.php:387
msgid "View Video"
msgstr ""
-#: include/text.php:1438
+#: include/text.php:1394
msgid "bytes"
msgstr ""
-#: include/text.php:1473 include/text.php:1484
+#: include/text.php:1429 include/text.php:1440
msgid "Click to open/close"
msgstr ""
-#: include/text.php:1612
+#: include/text.php:1568
msgid "View on separate page"
msgstr ""
-#: include/text.php:1613
+#: include/text.php:1569
msgid "view on separate page"
msgstr ""
-#: include/text.php:1898
+#: include/text.php:1787
msgid "activity"
msgstr ""
-#: include/text.php:1900 object/Item.php:416 object/Item.php:428
+#: include/text.php:1789 src/Object/Item.php:421 src/Object/Item.php:433
msgid "comment"
msgid_plural "comments"
msgstr[0] ""
msgstr[1] ""
-#: include/text.php:1903
+#: include/text.php:1792
msgid "post"
msgstr ""
-#: include/text.php:2069
+#: include/text.php:1955
msgid "Item filed"
msgstr ""
-#: include/uimport.php:81
+#: include/uimport.php:82
msgid "Error decoding account file"
msgstr ""
-#: include/uimport.php:87
+#: include/uimport.php:88
msgid "Error! No version data in file! This is not a Friendica account file?"
msgstr ""
-#: include/uimport.php:104 include/uimport.php:115
+#: include/uimport.php:105 include/uimport.php:116
msgid "Error! Cannot check nickname"
msgstr ""
-#: include/uimport.php:108 include/uimport.php:119
+#: include/uimport.php:109 include/uimport.php:120
#, php-format
msgid "User '%s' already exists on this server!"
msgstr ""
msgid "Done. You can now login with your username and password"
msgstr ""
-#: include/user.php:41 mod/settings.php:373
+#: include/user.php:42 mod/settings.php:378
msgid "Passwords do not match. Password unchanged."
msgstr ""
-#: include/user.php:50
+#: include/user.php:51
msgid "An invitation is required."
msgstr ""
-#: include/user.php:55
+#: include/user.php:56
msgid "Invitation could not be verified."
msgstr ""
-#: include/user.php:63
+#: include/user.php:64
msgid "Invalid OpenID url"
msgstr ""
-#: include/user.php:84
+#: include/user.php:85
msgid "Please enter the required information."
msgstr ""
-#: include/user.php:98
+#: include/user.php:99
msgid "Please use a shorter name."
msgstr ""
-#: include/user.php:100
+#: include/user.php:101
msgid "Name too short."
msgstr ""
-#: include/user.php:108
+#: include/user.php:109
msgid "That doesn't appear to be your full (First Last) name."
msgstr ""
-#: include/user.php:113
+#: include/user.php:114
msgid "Your email domain is not among those allowed on this site."
msgstr ""
-#: include/user.php:116
+#: include/user.php:117
msgid "Not a valid email address."
msgstr ""
-#: include/user.php:129
+#: include/user.php:130
msgid "Cannot use that email."
msgstr ""
-#: include/user.php:135
+#: include/user.php:136
msgid "Your \"nickname\" can only contain \"a-z\", \"0-9\" and \"_\"."
msgstr ""
-#: include/user.php:142 include/user.php:224
+#: include/user.php:143 include/user.php:225
msgid "Nickname is already registered. Please choose another."
msgstr ""
-#: include/user.php:152
+#: include/user.php:153
msgid ""
"Nickname was once registered here and may not be re-used. Please choose "
"another."
msgstr ""
-#: include/user.php:168
+#: include/user.php:169
msgid "SERIOUS ERROR: Generation of security keys failed."
msgstr ""
-#: include/user.php:210
+#: include/user.php:211
msgid "An error occurred during registration. Please try again."
msgstr ""
-#: include/user.php:233 view/theme/duepuntozero/config.php:47
+#: include/user.php:234 view/theme/duepuntozero/config.php:49
msgid "default"
msgstr ""
-#: include/user.php:243
+#: include/user.php:244
msgid "An error occurred creating your default profile. Please try again."
msgstr ""
-#: include/user.php:393
+#: include/user.php:394
#, php-format
msgid ""
"\n"
"\t"
msgstr ""
-#: include/user.php:403
+#: include/user.php:404
#, php-format
msgid "Registration at %s"
msgstr ""
-#: include/user.php:413
+#: include/user.php:414
#, php-format
msgid ""
"\n"
"\t"
msgstr ""
-#: include/user.php:417
+#: include/user.php:418
#, php-format
msgid ""
"\n"
"\t\tThank you and welcome to %2$s."
msgstr ""
-#: include/user.php:449 mod/admin.php:1430
+#: include/user.php:450 mod/admin.php:1432
#, php-format
msgid "Registration details for %s"
msgstr ""
-#: mod/api.php:78 mod/api.php:104
-msgid "Authorize application connection"
-msgstr ""
-
-#: mod/api.php:79
-msgid "Return to your app and insert this Securty Code:"
-msgstr ""
-
-#: mod/api.php:91
-msgid "Please login to continue."
-msgstr ""
-
-#: mod/api.php:106
-msgid ""
-"Do you want to authorize this application to access your posts and contacts, "
-"and/or create new posts for you?"
-msgstr ""
-
-#: mod/api.php:108 mod/dfrn_request.php:881 mod/follow.php:150
-#: mod/profiles.php:639 mod/profiles.php:643 mod/profiles.php:669
-#: mod/register.php:251 mod/settings.php:1158 mod/settings.php:1164
-#: mod/settings.php:1171 mod/settings.php:1175 mod/settings.php:1180
-#: mod/settings.php:1185 mod/settings.php:1190 mod/settings.php:1195
-#: mod/settings.php:1221 mod/settings.php:1222 mod/settings.php:1223
-#: mod/settings.php:1224 mod/settings.php:1225
-msgid "No"
-msgstr ""
-
-#: mod/apps.php:9 index.php:259
-msgid "You must be logged in to use addons. "
-msgstr ""
-
-#: mod/apps.php:14
-msgid "Applications"
-msgstr ""
-
-#: mod/apps.php:17
-msgid "No installed applications."
-msgstr ""
-
-#: mod/attach.php:10
-msgid "Item not available."
-msgstr ""
-
-#: mod/attach.php:22
-msgid "Item was not found."
-msgstr ""
-
#: mod/babel.php:18
msgid "Source (bbcode) text:"
msgstr ""
msgid "diaspora2bb: "
msgstr ""
-#: mod/common.php:93
-msgid "No contacts in common."
-msgstr ""
-
-#: mod/common.php:143 mod/contacts.php:893
-msgid "Common Friends"
-msgstr ""
-
#: mod/credits.php:19
msgid "Credits"
msgstr ""
"code or the translation of Friendica. Thank you all!"
msgstr ""
-#: mod/crepair.php:92
-msgid "Contact settings applied."
+#: mod/maintenance.php:21
+msgid "System down for maintenance"
msgstr ""
-#: mod/crepair.php:94
-msgid "Contact update failed."
+#: mod/webfinger.php:10 mod/probe.php:9 mod/community.php:18
+#: mod/dfrn_request.php:807 mod/directory.php:34 mod/display.php:202
+#: mod/photos.php:967 mod/search.php:92 mod/search.php:98 mod/videos.php:205
+#: mod/viewcontacts.php:41
+msgid "Public access denied."
msgstr ""
-#: mod/crepair.php:119 mod/dfrn_confirm.php:130 mod/fsuggest.php:23
-#: mod/fsuggest.php:95
-msgid "Contact not found."
+#: mod/webfinger.php:11 mod/probe.php:10
+msgid "Only logged in users are permitted to perform a probing."
msgstr ""
-#: mod/crepair.php:125
-msgid ""
-"<strong>WARNING: This is highly advanced</strong> and if you enter incorrect "
-"information your communications with this contact may stop working."
+#: mod/bookmarklet.php:44
+msgid "The post was created"
msgstr ""
-#: mod/crepair.php:126
-msgid ""
-"Please use your browser 'Back' button <strong>now</strong> if you are "
-"uncertain what to do on this page."
+#: mod/help.php:45
+msgid "Help:"
msgstr ""
-#: mod/crepair.php:139 mod/crepair.php:141
-msgid "No mirroring"
+#: mod/help.php:57 mod/fetch.php:17 mod/fetch.php:53 mod/fetch.php:66
+#: mod/p.php:20 mod/p.php:47 mod/p.php:56 index.php:287
+msgid "Not Found"
msgstr ""
-#: mod/crepair.php:139
-msgid "Mirror as forwarded posting"
+#: mod/help.php:60 index.php:292
+msgid "Page not found."
msgstr ""
-#: mod/crepair.php:139 mod/crepair.php:141
-msgid "Mirror as my own posting"
+#: mod/localtime.php:26
+msgid "Time Conversion"
msgstr ""
-#: mod/crepair.php:155
-msgid "Return to contact editor"
+#: mod/localtime.php:28
+msgid ""
+"Friendica provides this service for sharing events with other networks and "
+"friends in unknown timezones."
msgstr ""
-#: mod/crepair.php:157
-msgid "Refetch contact data"
+#: mod/localtime.php:32
+#, php-format
+msgid "UTC time: %s"
msgstr ""
-#: mod/crepair.php:159 mod/invite.php:150 mod/localtime.php:47
-#: mod/manage.php:157 mod/message.php:338 mod/message.php:521
-#: mod/install.php:243 mod/install.php:283 mod/contacts.php:605
-#: mod/events.php:529 mod/fsuggest.php:110 mod/mood.php:141 mod/photos.php:1127
-#: mod/photos.php:1248 mod/photos.php:1574 mod/photos.php:1623
-#: mod/photos.php:1665 mod/photos.php:1745 mod/poke.php:206
-#: mod/profiles.php:680 object/Item.php:702
-#: view/theme/duepuntozero/config.php:65 view/theme/frio/config.php:108
-#: view/theme/quattro/config.php:71 view/theme/vier/config.php:114
-msgid "Submit"
+#: mod/localtime.php:35
+#, php-format
+msgid "Current timezone: %s"
msgstr ""
-#: mod/crepair.php:161
-msgid "Remote Self"
+#: mod/localtime.php:38
+#, php-format
+msgid "Converted localtime: %s"
msgstr ""
-#: mod/crepair.php:164
-msgid "Mirror postings from this contact"
+#: mod/localtime.php:43
+msgid "Please select your timezone:"
msgstr ""
-#: mod/crepair.php:166
-msgid ""
-"Mark this contact as remote_self, this will cause friendica to repost new "
-"entries from this contact."
+#: mod/localtime.php:47 mod/contacts.php:612 mod/crepair.php:162
+#: mod/events.php:531 mod/fsuggest.php:117 mod/install.php:244
+#: mod/install.php:284 mod/invite.php:152 mod/manage.php:158
+#: mod/message.php:340 mod/message.php:512 mod/mood.php:142 mod/photos.php:1129
+#: mod/photos.php:1241 mod/photos.php:1556 mod/photos.php:1605
+#: mod/photos.php:1647 mod/photos.php:1721 mod/poke.php:207
+#: mod/profiles.php:684 view/theme/duepuntozero/config.php:67
+#: view/theme/frio/config.php:108 view/theme/quattro/config.php:73
+#: view/theme/vier/config.php:117 src/Object/Item.php:787
+msgid "Submit"
msgstr ""
-#: mod/crepair.php:170 mod/admin.php:1612 mod/admin.php:1625 mod/admin.php:1638
-#: mod/admin.php:1654 mod/settings.php:693 mod/settings.php:719
-msgid "Name"
+#: mod/oexchange.php:25
+msgid "Post successful."
msgstr ""
-#: mod/crepair.php:171
-msgid "Account Nickname"
+#: mod/admin.php:102
+msgid "Theme settings updated."
msgstr ""
-#: mod/crepair.php:172
-msgid "@Tagname - overrides Name/Nickname"
+#: mod/admin.php:174 mod/admin.php:1177
+msgid "Site"
msgstr ""
-#: mod/crepair.php:173
-msgid "Account URL"
+#: mod/admin.php:175 mod/admin.php:1105 mod/admin.php:1620 mod/admin.php:1636
+msgid "Users"
msgstr ""
-#: mod/crepair.php:174
-msgid "Friend Request URL"
+#: mod/admin.php:176 mod/admin.php:1738 mod/admin.php:1801 mod/settings.php:77
+msgid "Plugins"
msgstr ""
-#: mod/crepair.php:175
-msgid "Friend Confirm URL"
+#: mod/admin.php:177 mod/admin.php:2014 mod/admin.php:2064
+msgid "Themes"
msgstr ""
-#: mod/crepair.php:176
-msgid "Notification Endpoint URL"
+#: mod/admin.php:178 mod/settings.php:55
+msgid "Additional features"
msgstr ""
-#: mod/crepair.php:177
-msgid "Poll/Feed URL"
+#: mod/admin.php:179
+msgid "DB updates"
msgstr ""
-#: mod/crepair.php:178
-msgid "New photo from this URL"
+#: mod/admin.php:180 mod/admin.php:587
+msgid "Inspect Queue"
msgstr ""
-#: mod/filer.php:31
-msgid "- select -"
+#: mod/admin.php:181 mod/admin.php:301
+msgid "Server Blocklist"
msgstr ""
-#: mod/lockview.php:33 mod/lockview.php:41
-msgid "Remote privacy information not available."
+#: mod/admin.php:182 mod/admin.php:553
+msgid "Federation Statistics"
msgstr ""
-#: mod/lockview.php:50
-msgid "Visible to:"
+#: mod/admin.php:183 mod/admin.php:378
+msgid "Delete Item"
msgstr ""
-#: mod/maintenance.php:21
-msgid "System down for maintenance"
+#: mod/admin.php:197 mod/admin.php:208 mod/admin.php:2138
+msgid "Logs"
msgstr ""
-#: mod/newmember.php:7
-msgid "Welcome to Friendica"
+#: mod/admin.php:198 mod/admin.php:2206
+msgid "View Logs"
msgstr ""
-#: mod/newmember.php:8
-msgid "New Member Checklist"
+#: mod/admin.php:199
+msgid "probe address"
msgstr ""
-#: mod/newmember.php:10
-msgid ""
-"We would like to offer some tips and links to help make your experience "
-"enjoyable. Click any item to visit the relevant page. A link to this page "
-"will be visible from your home page for two weeks after your initial "
-"registration and then will quietly disappear."
+#: mod/admin.php:200
+msgid "check webfinger"
msgstr ""
-#: mod/newmember.php:11
-msgid "Getting Started"
+#: mod/admin.php:207
+msgid "Plugin Features"
msgstr ""
-#: mod/newmember.php:13
-msgid "Friendica Walk-Through"
+#: mod/admin.php:209
+msgid "diagnostics"
msgstr ""
-#: mod/newmember.php:13
-msgid ""
-"On your <em>Quick Start</em> page - find a brief introduction to your "
-"profile and network tabs, make some new connections, and find some groups to "
-"join."
+#: mod/admin.php:210
+msgid "User registrations waiting for confirmation"
msgstr ""
-#: mod/newmember.php:17
-msgid "Go to Your Settings"
+#: mod/admin.php:292
+msgid "The blocked domain"
msgstr ""
-#: mod/newmember.php:17
-msgid ""
-"On your <em>Settings</em> page - change your initial password. Also make a "
-"note of your Identity Address. This looks just like an email address - and "
-"will be useful in making friends on the free social web."
+#: mod/admin.php:293 mod/admin.php:311 mod/friendica.php:117
+msgid "Reason for the block"
msgstr ""
-#: mod/newmember.php:18
-msgid ""
-"Review the other settings, particularly the privacy settings. An unpublished "
-"directory listing is like having an unlisted phone number. In general, you "
-"should probably publish your listing - unless all of your friends and "
-"potential friends know exactly how to find you."
+#: mod/admin.php:293 mod/admin.php:306
+msgid "The reason why you blocked this domain."
msgstr ""
-#: mod/newmember.php:22 mod/profile_photo.php:257 mod/profiles.php:699
-msgid "Upload Profile Photo"
+#: mod/admin.php:294
+msgid "Delete domain"
msgstr ""
-#: mod/newmember.php:22
-msgid ""
-"Upload a profile photo if you have not done so already. Studies have shown "
-"that people with real photos of themselves are ten times more likely to make "
-"friends than people who do not."
+#: mod/admin.php:294
+msgid "Check to delete this entry from the blocklist"
msgstr ""
-#: mod/newmember.php:23
-msgid "Edit Your Profile"
+#: mod/admin.php:300 mod/admin.php:377 mod/admin.php:552 mod/admin.php:586
+#: mod/admin.php:683 mod/admin.php:1176 mod/admin.php:1619 mod/admin.php:1737
+#: mod/admin.php:1800 mod/admin.php:2013 mod/admin.php:2063 mod/admin.php:2137
+#: mod/admin.php:2205
+msgid "Administration"
msgstr ""
-#: mod/newmember.php:23
+#: mod/admin.php:302
msgid ""
-"Edit your <strong>default</strong> profile to your liking. Review the "
-"settings for hiding your list of friends and hiding the profile from unknown "
-"visitors."
-msgstr ""
-
-#: mod/newmember.php:24
-msgid "Profile Keywords"
+"This page can be used to define a black list of servers from the federated "
+"network that are not allowed to interact with your node. For all entered "
+"domains you should also give a reason why you have blocked the remote server."
msgstr ""
-#: mod/newmember.php:24
+#: mod/admin.php:303
msgid ""
-"Set some public keywords for your default profile which describe your "
-"interests. We may be able to find other people with similar interests and "
-"suggest friendships."
+"The list of blocked servers will be made publically available on the /"
+"friendica page so that your users and people investigating communication "
+"problems can find the reason easily."
msgstr ""
-#: mod/newmember.php:26
-msgid "Connecting"
+#: mod/admin.php:304
+msgid "Add new entry to block list"
msgstr ""
-#: mod/newmember.php:32
-msgid "Importing Emails"
+#: mod/admin.php:305
+msgid "Server Domain"
msgstr ""
-#: mod/newmember.php:32
+#: mod/admin.php:305
msgid ""
-"Enter your email access information on your Connector Settings page if you "
-"wish to import and interact with friends or mailing lists from your email "
-"INBOX"
+"The domain of the new server to add to the block list. Do not include the "
+"protocol."
msgstr ""
-#: mod/newmember.php:35
-msgid "Go to Your Contacts Page"
+#: mod/admin.php:306
+msgid "Block reason"
msgstr ""
-#: mod/newmember.php:35
-msgid ""
-"Your Contacts page is your gateway to managing friendships and connecting "
-"with friends on other networks. Typically you enter their address or site "
-"URL in the <em>Add New Contact</em> dialog."
+#: mod/admin.php:307
+msgid "Add Entry"
msgstr ""
-#: mod/newmember.php:36
-msgid "Go to Your Site's Directory"
+#: mod/admin.php:308
+msgid "Save changes to the blocklist"
msgstr ""
-#: mod/newmember.php:36
-msgid ""
-"The Directory page lets you find other people in this network or other "
-"federated sites. Look for a <em>Connect</em> or <em>Follow</em> link on "
-"their profile page. Provide your own Identity Address if requested."
+#: mod/admin.php:309
+msgid "Current Entries in the Blocklist"
msgstr ""
-#: mod/newmember.php:37
-msgid "Finding New People"
+#: mod/admin.php:312
+msgid "Delete entry from blocklist"
msgstr ""
-#: mod/newmember.php:37
-msgid ""
-"On the side panel of the Contacts page are several tools to find new "
-"friends. We can match people by interest, look up people by name or "
-"interest, and provide suggestions based on network relationships. On a brand "
-"new site, friend suggestions will usually begin to be populated within 24 "
-"hours."
+#: mod/admin.php:315
+msgid "Delete entry from blocklist?"
msgstr ""
-#: mod/newmember.php:41
-msgid "Group Your Contacts"
+#: mod/admin.php:340
+msgid "Server added to blocklist."
msgstr ""
-#: mod/newmember.php:41
-msgid ""
-"Once you have made some friends, organize them into private conversation "
-"groups from the sidebar of your Contacts page and then you can interact with "
-"each group privately on your Network page."
+#: mod/admin.php:356
+msgid "Site blocklist updated."
msgstr ""
-#: mod/newmember.php:44
-msgid "Why Aren't My Posts Public?"
+#: mod/admin.php:379
+msgid "Delete this Item"
msgstr ""
-#: mod/newmember.php:44
+#: mod/admin.php:380
msgid ""
-"Friendica respects your privacy. By default, your posts will only show up to "
-"people you've added as friends. For more information, see the help section "
-"from the link above."
-msgstr ""
-
-#: mod/newmember.php:48
-msgid "Getting Help"
-msgstr ""
-
-#: mod/newmember.php:50
-msgid "Go to the Help Section"
+"On this page you can delete an item from your node. If the item is a top "
+"level posting, the entire thread will be deleted."
msgstr ""
-#: mod/newmember.php:50
+#: mod/admin.php:381
msgid ""
-"Our <strong>help</strong> pages may be consulted for detail on other program "
-"features and resources."
-msgstr ""
-
-#: mod/nogroup.php:45 mod/viewcontacts.php:105 mod/contacts.php:616
-#: mod/contacts.php:960
-#, php-format
-msgid "Visit %s's profile [%s]"
+"You need to know the GUID of the item. You can find it e.g. by looking at "
+"the display URL. The last part of http://example.com/display/123456 is the "
+"GUID, here 123456."
msgstr ""
-#: mod/nogroup.php:46 mod/contacts.php:961
-msgid "Edit contact"
+#: mod/admin.php:382
+msgid "GUID"
msgstr ""
-#: mod/nogroup.php:67
-msgid "Contacts who are not members of a group"
+#: mod/admin.php:382
+msgid "The GUID of the item you want to delete."
msgstr ""
-#: mod/profperm.php:22 mod/group.php:78 index.php:411
-msgid "Permission denied"
+#: mod/admin.php:419
+msgid "Item marked for deletion."
msgstr ""
-#: mod/profperm.php:28 mod/profperm.php:59
-msgid "Invalid profile identifier."
+#: mod/admin.php:483
+msgid "unknown"
msgstr ""
-#: mod/profperm.php:105
-msgid "Profile Visibility Editor"
+#: mod/admin.php:546
+msgid ""
+"This page offers you some numbers to the known part of the federated social "
+"network your Friendica node is part of. These numbers are not complete but "
+"only reflect the part of the network your node is aware of."
msgstr ""
-#: mod/profperm.php:109 mod/group.php:264
-msgid "Click on a contact to add or remove."
+#: mod/admin.php:547
+msgid ""
+"The <em>Auto Discovered Contact Directory</em> feature is not enabled, it "
+"will improve the data displayed here."
msgstr ""
-#: mod/profperm.php:118
-msgid "Visible To"
+#: mod/admin.php:559
+#, php-format
+msgid "Currently this node is aware of %d nodes from the following platforms:"
msgstr ""
-#: mod/profperm.php:134
-msgid "All Contacts (with secure profile access)"
+#: mod/admin.php:589
+msgid "ID"
msgstr ""
-#: mod/update_community.php:21 mod/update_display.php:25
-#: mod/update_notes.php:38 mod/update_profile.php:37 mod/update_network.php:29
-msgid "[Embedded content - reload page to view]"
+#: mod/admin.php:590
+msgid "Recipient Name"
msgstr ""
-#: mod/viewcontacts.php:39 mod/webfinger.php:10 mod/probe.php:9
-#: mod/community.php:17 mod/dfrn_request.php:805 mod/directory.php:31
-#: mod/search.php:89 mod/search.php:95 mod/display.php:202 mod/photos.php:965
-#: mod/videos.php:202
-msgid "Public access denied."
+#: mod/admin.php:591
+msgid "Recipient Profile"
msgstr ""
-#: mod/viewcontacts.php:78
-msgid "No contacts."
+#: mod/admin.php:593
+msgid "Created"
msgstr ""
-#: mod/viewsrc.php:8
-msgid "Access denied."
+#: mod/admin.php:594
+msgid "Last Tried"
msgstr ""
-#: mod/webfinger.php:11 mod/probe.php:10
-msgid "Only logged in users are permitted to perform a probing."
+#: mod/admin.php:595
+msgid ""
+"This page lists the content of the queue for outgoing postings. These are "
+"postings the initial delivery failed for. They will be resend later and "
+"eventually deleted if the delivery fails permanently."
msgstr ""
-#: mod/uimport.php:53 mod/register.php:203
+#: mod/admin.php:619
+#, php-format
msgid ""
-"This site has exceeded the number of allowed daily account registrations. "
-"Please try again tomorrow."
+"Your DB still runs with MyISAM tables. You should change the engine type to "
+"InnoDB. As Friendica will use InnoDB only features in the future, you should "
+"change this! See <a href=\"%s\">here</a> for a guide that may be helpful "
+"converting the table engines. You may also use the command <tt>php include/"
+"dbstructure.php toinnodb</tt> of your Friendica installation for an "
+"automatic conversion.<br />"
msgstr ""
-#: mod/uimport.php:68 mod/register.php:300
-msgid "Import"
+#: mod/admin.php:626
+#, php-format
+msgid ""
+"There is a new version of Friendica available for download. Your current "
+"version is %1$s, upstream version is %2$s"
msgstr ""
-#: mod/uimport.php:70
-msgid "Move account"
+#: mod/admin.php:637
+msgid ""
+"The database update failed. Please run \"php include/dbstructure.php update"
+"\" from the command line and have a look at the errors that might appear."
msgstr ""
-#: mod/uimport.php:71
-msgid "You can import an account from another Friendica server."
+#: mod/admin.php:643
+msgid "The worker was never executed. Please check your database structure!"
msgstr ""
-#: mod/uimport.php:72
+#: mod/admin.php:646
+#, php-format
msgid ""
-"You need to export your account from the old server and upload it here. We "
-"will recreate your old account here with all your contacts. We will try also "
-"to inform your friends that you moved here."
+"The last worker execution was on %s UTC. This is older than one hour. Please "
+"check your crontab settings."
msgstr ""
-#: mod/uimport.php:73
-msgid ""
-"This feature is experimental. We can't import contacts from the OStatus "
-"network (GNU Social/Statusnet) or from Diaspora"
+#: mod/admin.php:651 mod/admin.php:1569
+msgid "Normal Account"
msgstr ""
-#: mod/uimport.php:74
-msgid "Account file"
+#: mod/admin.php:652 mod/admin.php:1570
+msgid "Automatic Follower Account"
msgstr ""
-#: mod/uimport.php:74
-msgid ""
-"To export your account, go to \"Settings->Export your personal data\" and "
-"select \"Export account\""
+#: mod/admin.php:653 mod/admin.php:1571
+msgid "Public Forum Account"
msgstr ""
-#: mod/community.php:22
-msgid "Not available."
+#: mod/admin.php:654 mod/admin.php:1572
+msgid "Automatic Friend Account"
msgstr ""
-#: mod/community.php:49 mod/search.php:215
-msgid "No results."
+#: mod/admin.php:655
+msgid "Blog Account"
msgstr ""
-#: mod/allfriends.php:49
-msgid "No friends to display."
+#: mod/admin.php:656
+msgid "Private Forum Account"
msgstr ""
-#: mod/bookmarklet.php:44
-msgid "The post was created"
+#: mod/admin.php:678
+msgid "Message queues"
msgstr ""
-#: mod/cal.php:146 mod/profile.php:157 mod/display.php:339
-msgid "Access to this profile has been restricted."
+#: mod/admin.php:684
+msgid "Summary"
msgstr ""
-#: mod/cal.php:274 mod/events.php:384
-msgid "View"
+#: mod/admin.php:686
+msgid "Registered users"
msgstr ""
-#: mod/cal.php:275 mod/events.php:386
-msgid "Previous"
+#: mod/admin.php:688
+msgid "Pending registrations"
msgstr ""
-#: mod/cal.php:276 mod/install.php:202 mod/events.php:387
-msgid "Next"
+#: mod/admin.php:689
+msgid "Version"
msgstr ""
-#: mod/cal.php:285 mod/events.php:396
-msgid "list"
+#: mod/admin.php:694
+msgid "Active plugins"
msgstr ""
-#: mod/cal.php:295
-msgid "User not found"
+#: mod/admin.php:724
+msgid "Can not parse base url. Must have at least <scheme>://<domain>"
msgstr ""
-#: mod/cal.php:311
-msgid "This calendar format is not supported"
+#: mod/admin.php:1031
+msgid "Site settings updated."
msgstr ""
-#: mod/cal.php:313
-msgid "No exportable data found"
+#: mod/admin.php:1059 mod/settings.php:953
+msgid "No special theme for mobile devices"
msgstr ""
-#: mod/cal.php:328
-msgid "calendar"
+#: mod/admin.php:1088
+msgid "No community page"
msgstr ""
-#: mod/dfrn_poll.php:114 mod/dfrn_poll.php:550
-#, php-format
-msgid "%1$s welcomes %2$s"
+#: mod/admin.php:1089
+msgid "Public postings from users of this site"
msgstr ""
-#: mod/dfrn_request.php:104
-msgid "This introduction has already been accepted."
+#: mod/admin.php:1090
+msgid "Global community page"
msgstr ""
-#: mod/dfrn_request.php:127 mod/dfrn_request.php:529
-msgid "Profile location is not valid or does not contain profile information."
+#: mod/admin.php:1095 mod/contacts.php:553
+msgid "Never"
msgstr ""
-#: mod/dfrn_request.php:132 mod/dfrn_request.php:534
-msgid "Warning: profile location has no identifiable owner name."
+#: mod/admin.php:1096
+msgid "At post arrival"
msgstr ""
-#: mod/dfrn_request.php:135 mod/dfrn_request.php:537
-msgid "Warning: profile location has no profile photo."
+#: mod/admin.php:1104 mod/contacts.php:583
+msgid "Disabled"
msgstr ""
-#: mod/dfrn_request.php:139 mod/dfrn_request.php:541
-#, php-format
-msgid "%d required parameter was not found at the given location"
-msgid_plural "%d required parameters were not found at the given location"
-msgstr[0] ""
-msgstr[1] ""
-
-#: mod/dfrn_request.php:183
-msgid "Introduction complete."
+#: mod/admin.php:1106
+msgid "Users, Global Contacts"
msgstr ""
-#: mod/dfrn_request.php:228
-msgid "Unrecoverable protocol error."
+#: mod/admin.php:1107
+msgid "Users, Global Contacts/fallback"
msgstr ""
-#: mod/dfrn_request.php:256
-msgid "Profile unavailable."
+#: mod/admin.php:1111
+msgid "One month"
msgstr ""
-#: mod/dfrn_request.php:283
-#, php-format
-msgid "%s has received too many connection requests today."
+#: mod/admin.php:1112
+msgid "Three months"
msgstr ""
-#: mod/dfrn_request.php:284
-msgid "Spam protection measures have been invoked."
+#: mod/admin.php:1113
+msgid "Half a year"
msgstr ""
-#: mod/dfrn_request.php:285
-msgid "Friends are advised to please try again in 24 hours."
+#: mod/admin.php:1114
+msgid "One year"
msgstr ""
-#: mod/dfrn_request.php:347
-msgid "Invalid locator"
+#: mod/admin.php:1119
+msgid "Multi user instance"
msgstr ""
-#: mod/dfrn_request.php:356
-msgid "Invalid email address."
+#: mod/admin.php:1142
+msgid "Closed"
msgstr ""
-#: mod/dfrn_request.php:381
-msgid "This account has not been configured for email. Request failed."
+#: mod/admin.php:1143
+msgid "Requires approval"
msgstr ""
-#: mod/dfrn_request.php:484
-msgid "You have already introduced yourself here."
+#: mod/admin.php:1144
+msgid "Open"
msgstr ""
-#: mod/dfrn_request.php:488
-#, php-format
-msgid "Apparently you are already friends with %s."
+#: mod/admin.php:1148
+msgid "No SSL policy, links will track page SSL state"
msgstr ""
-#: mod/dfrn_request.php:509
-msgid "Invalid profile URL."
+#: mod/admin.php:1149
+msgid "Force all links to use SSL"
msgstr ""
-#: mod/dfrn_request.php:594 mod/contacts.php:223
-msgid "Failed to update contact record."
+#: mod/admin.php:1150
+msgid "Self-signed certificate, use SSL for local links only (discouraged)"
msgstr ""
-#: mod/dfrn_request.php:615
-msgid "Your introduction has been sent."
+#: mod/admin.php:1154
+msgid "Don't check"
msgstr ""
-#: mod/dfrn_request.php:657
-msgid ""
-"Remote subscription can't be done for your network. Please subscribe "
-"directly on your system."
+#: mod/admin.php:1155
+msgid "check the stable version"
msgstr ""
-#: mod/dfrn_request.php:678
-msgid "Please login to confirm introduction."
+#: mod/admin.php:1156
+msgid "check the development version"
msgstr ""
-#: mod/dfrn_request.php:688
-msgid ""
-"Incorrect identity currently logged in. Please login to <strong>this</"
-"strong> profile."
+#: mod/admin.php:1178 mod/admin.php:1802 mod/admin.php:2065 mod/admin.php:2139
+#: mod/admin.php:2289 mod/settings.php:696 mod/settings.php:807
+#: mod/settings.php:856 mod/settings.php:918 mod/settings.php:1006
+#: mod/settings.php:1255
+msgid "Save Settings"
msgstr ""
-#: mod/dfrn_request.php:702 mod/dfrn_request.php:719
-msgid "Confirm"
+#: mod/admin.php:1179
+msgid "Republish users to directory"
msgstr ""
-#: mod/dfrn_request.php:714
-msgid "Hide this contact"
+#: mod/admin.php:1180 mod/register.php:279
+msgid "Registration"
msgstr ""
-#: mod/dfrn_request.php:717
-#, php-format
-msgid "Welcome home %s."
+#: mod/admin.php:1181
+msgid "File upload"
msgstr ""
-#: mod/dfrn_request.php:718
-#, php-format
-msgid "Please confirm your introduction/connection request to %s."
+#: mod/admin.php:1182
+msgid "Policies"
msgstr ""
-#: mod/dfrn_request.php:849
-msgid ""
-"Please enter your 'Identity Address' from one of the following supported "
-"communications networks:"
+#: mod/admin.php:1184
+msgid "Auto Discovered Contact Directory"
msgstr ""
-#: mod/dfrn_request.php:873
-#, php-format
-msgid ""
-"If you are not yet a member of the free social web, <a href=\"%s/siteinfo"
-"\">follow this link to find a public Friendica site and join us today</a>."
+#: mod/admin.php:1185
+msgid "Performance"
msgstr ""
-#: mod/dfrn_request.php:878
-msgid "Friend/Connection Request"
+#: mod/admin.php:1186
+msgid "Worker"
msgstr ""
-#: mod/dfrn_request.php:879
+#: mod/admin.php:1187
msgid ""
-"Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, "
-"testuser@identi.ca"
+"Relocate - WARNING: advanced function. Could make this server unreachable."
msgstr ""
-#: mod/dfrn_request.php:880 mod/follow.php:149
-msgid "Please answer the following:"
+#: mod/admin.php:1190
+msgid "Site name"
msgstr ""
-#: mod/dfrn_request.php:881 mod/follow.php:150
-#, php-format
-msgid "Does %s know you?"
+#: mod/admin.php:1191
+msgid "Host name"
msgstr ""
-#: mod/dfrn_request.php:885 mod/follow.php:151
-msgid "Add a personal note:"
+#: mod/admin.php:1192
+msgid "Sender Email"
msgstr ""
-#: mod/dfrn_request.php:888
-msgid "StatusNet/Federated Social Web"
+#: mod/admin.php:1192
+msgid ""
+"The email address your server shall use to send notification emails from."
msgstr ""
-#: mod/dfrn_request.php:890
-#, php-format
-msgid ""
-" - please do not use this form. Instead, enter %s into your Diaspora search "
-"bar."
+#: mod/admin.php:1193
+msgid "Banner/Logo"
msgstr ""
-#: mod/dfrn_request.php:891 mod/follow.php:157 mod/unfollow.php:113
-msgid "Your Identity Address:"
+#: mod/admin.php:1194
+msgid "Shortcut icon"
msgstr ""
-#: mod/dfrn_request.php:894 mod/follow.php:63 mod/unfollow.php:65
-msgid "Submit Request"
+#: mod/admin.php:1194
+msgid "Link to an icon that will be used for browsers."
msgstr ""
-#: mod/editpost.php:20 mod/editpost.php:30
-msgid "Item not found"
+#: mod/admin.php:1195
+msgid "Touch icon"
msgstr ""
-#: mod/editpost.php:35
-msgid "Edit post"
+#: mod/admin.php:1195
+msgid "Link to an icon that will be used for tablets and mobiles."
msgstr ""
-#: mod/fetch.php:16 mod/fetch.php:43 mod/fetch.php:52 mod/help.php:57
-#: mod/p.php:20 mod/p.php:47 mod/p.php:56 index.php:303
-msgid "Not Found"
+#: mod/admin.php:1196
+msgid "Additional Info"
msgstr ""
-#: mod/follow.php:42
-msgid "Contact added"
+#: mod/admin.php:1196
+#, php-format
+msgid ""
+"For public servers: you can add additional information here that will be "
+"listed at %s/siteinfo."
msgstr ""
-#: mod/follow.php:74
-msgid "You already added this contact."
+#: mod/admin.php:1197
+msgid "System language"
msgstr ""
-#: mod/follow.php:83
-msgid "Diaspora support isn't enabled. Contact can't be added."
+#: mod/admin.php:1198
+msgid "System theme"
msgstr ""
-#: mod/follow.php:90
-msgid "OStatus support is disabled. Contact can't be added."
+#: mod/admin.php:1198
+msgid ""
+"Default system theme - may be over-ridden by user profiles - <a href='#' "
+"id='cnftheme'>change theme settings</a>"
msgstr ""
-#: mod/follow.php:97
-msgid "The network type couldn't be detected. Contact can't be added."
+#: mod/admin.php:1199
+msgid "Mobile system theme"
msgstr ""
-#: mod/follow.php:166 mod/notifications.php:258 mod/unfollow.php:122
-#: mod/contacts.php:654
-msgid "Profile URL"
+#: mod/admin.php:1199
+msgid "Theme for mobile devices"
msgstr ""
-#: mod/group.php:31
-msgid "Group created."
+#: mod/admin.php:1200
+msgid "SSL link policy"
msgstr ""
-#: mod/group.php:37
-msgid "Could not create group."
+#: mod/admin.php:1200
+msgid "Determines whether generated links should be forced to use SSL"
msgstr ""
-#: mod/group.php:51 mod/group.php:156
-msgid "Group not found."
+#: mod/admin.php:1201
+msgid "Force SSL"
msgstr ""
-#: mod/group.php:65
-msgid "Group name changed."
+#: mod/admin.php:1201
+msgid ""
+"Force all Non-SSL requests to SSL - Attention: on some systems it could lead "
+"to endless loops."
msgstr ""
-#: mod/group.php:95
-msgid "Save Group"
+#: mod/admin.php:1202
+msgid "Hide help entry from navigation menu"
msgstr ""
-#: mod/group.php:100
-msgid "Create a group of contacts/friends."
+#: mod/admin.php:1202
+msgid ""
+"Hides the menu entry for the Help pages from the navigation menu. You can "
+"still access it calling /help directly."
msgstr ""
-#: mod/group.php:125
-msgid "Group removed."
+#: mod/admin.php:1203
+msgid "Single user instance"
msgstr ""
-#: mod/group.php:127
-msgid "Unable to remove group."
+#: mod/admin.php:1203
+msgid "Make this instance multi-user or single-user for the named user"
msgstr ""
-#: mod/group.php:191
-msgid "Delete Group"
+#: mod/admin.php:1204
+msgid "Maximum image size"
msgstr ""
-#: mod/group.php:197
-msgid "Group Editor"
-msgstr ""
-
-#: mod/group.php:202
-msgid "Edit Group Name"
-msgstr ""
-
-#: mod/group.php:212
-msgid "Members"
-msgstr ""
-
-#: mod/group.php:214 mod/contacts.php:722
-msgid "All Contacts"
-msgstr ""
-
-#: mod/group.php:215 mod/network.php:655
-msgid "Group is empty"
-msgstr ""
-
-#: mod/group.php:228
-msgid "Remove Contact"
-msgstr ""
-
-#: mod/group.php:252
-msgid "Add Contact"
-msgstr ""
-
-#: mod/hcard.php:14
-msgid "No profile"
-msgstr ""
-
-#: mod/help.php:45
-msgid "Help:"
-msgstr ""
-
-#: mod/help.php:60 index.php:306
-msgid "Page not found."
-msgstr ""
-
-#: mod/home.php:42
-#, php-format
-msgid "Welcome to %s"
-msgstr ""
-
-#: mod/invite.php:31
-msgid "Total invitation limit exceeded."
-msgstr ""
-
-#: mod/invite.php:54
-#, php-format
-msgid "%s : Not a valid email address."
-msgstr ""
-
-#: mod/invite.php:79
-msgid "Please join us on Friendica"
-msgstr ""
-
-#: mod/invite.php:90
-msgid "Invitation limit exceeded. Please contact your site administrator."
-msgstr ""
-
-#: mod/invite.php:94
-#, php-format
-msgid "%s : Message delivery failed."
+#: mod/admin.php:1204
+msgid ""
+"Maximum size in bytes of uploaded images. Default is 0, which means no "
+"limits."
msgstr ""
-#: mod/invite.php:98
-#, php-format
-msgid "%d message sent."
-msgid_plural "%d messages sent."
-msgstr[0] ""
-msgstr[1] ""
-
-#: mod/invite.php:117
-msgid "You have no more invitations available"
+#: mod/admin.php:1205
+msgid "Maximum image length"
msgstr ""
-#: mod/invite.php:125
-#, php-format
+#: mod/admin.php:1205
msgid ""
-"Visit %s for a list of public sites that you can join. Friendica members on "
-"other sites can all connect with each other, as well as with members of many "
-"other social networks."
+"Maximum length in pixels of the longest side of uploaded images. Default is "
+"-1, which means no limits."
msgstr ""
-#: mod/invite.php:127
-#, php-format
-msgid ""
-"To accept this invitation, please visit and register at %s or any other "
-"public Friendica website."
+#: mod/admin.php:1206
+msgid "JPEG image quality"
msgstr ""
-#: mod/invite.php:128
-#, php-format
+#: mod/admin.php:1206
msgid ""
-"Friendica sites all inter-connect to create a huge privacy-enhanced social "
-"web that is owned and controlled by its members. They can also connect with "
-"many traditional social networks. See %s for a list of alternate Friendica "
-"sites you can join."
+"Uploaded JPEGS will be saved at this quality setting [0-100]. Default is "
+"100, which is full quality."
msgstr ""
-#: mod/invite.php:132
-msgid ""
-"Our apologies. This system is not currently configured to connect with other "
-"public sites or invite members."
+#: mod/admin.php:1208
+msgid "Register policy"
msgstr ""
-#: mod/invite.php:135
-#, php-format
-msgid "To accept this invitation, please visit and register at %s."
+#: mod/admin.php:1209
+msgid "Maximum Daily Registrations"
msgstr ""
-#: mod/invite.php:136
+#: mod/admin.php:1209
msgid ""
-"Friendica sites all inter-connect to create a huge privacy-enhanced social "
-"web that is owned and controlled by its members. They can also connect with "
-"many traditional social networks."
+"If registration is permitted above, this sets the maximum number of new user "
+"registrations to accept per day. If register is set to closed, this setting "
+"has no effect."
msgstr ""
-#: mod/invite.php:142
-msgid "Send invitations"
+#: mod/admin.php:1210
+msgid "Register text"
msgstr ""
-#: mod/invite.php:143
-msgid "Enter email addresses, one per line:"
+#: mod/admin.php:1210
+msgid "Will be displayed prominently on the registration page."
msgstr ""
-#: mod/invite.php:144 mod/message.php:332 mod/message.php:515
-#: mod/wallmessage.php:138
-msgid "Your message:"
+#: mod/admin.php:1211
+msgid "Accounts abandoned after x days"
msgstr ""
-#: mod/invite.php:145
+#: mod/admin.php:1211
msgid ""
-"You are cordially invited to join me and other close friends on Friendica - "
-"and help us to create a better social web."
-msgstr ""
-
-#: mod/invite.php:147
-msgid "You will need to supply this invitation code: $invite_code"
+"Will not waste system resources polling external sites for abandonded "
+"accounts. Enter 0 for no time limit."
msgstr ""
-#: mod/invite.php:147
-msgid ""
-"Once you have registered, please connect with me via my profile page at:"
+#: mod/admin.php:1212
+msgid "Allowed friend domains"
msgstr ""
-#: mod/invite.php:149
+#: mod/admin.php:1212
msgid ""
-"For more information about the Friendica project and why we feel it is "
-"important, please visit http://friendi.ca"
+"Comma separated list of domains which are allowed to establish friendships "
+"with this site. Wildcards are accepted. Empty to allow any domains"
msgstr ""
-#: mod/localtime.php:26
-msgid "Time Conversion"
+#: mod/admin.php:1213
+msgid "Allowed email domains"
msgstr ""
-#: mod/localtime.php:28
+#: mod/admin.php:1213
msgid ""
-"Friendica provides this service for sharing events with other networks and "
-"friends in unknown timezones."
-msgstr ""
-
-#: mod/localtime.php:32
-#, php-format
-msgid "UTC time: %s"
-msgstr ""
-
-#: mod/localtime.php:35
-#, php-format
-msgid "Current timezone: %s"
-msgstr ""
-
-#: mod/localtime.php:38
-#, php-format
-msgid "Converted localtime: %s"
-msgstr ""
-
-#: mod/localtime.php:43
-msgid "Please select your timezone:"
-msgstr ""
-
-#: mod/lostpass.php:22
-msgid "No valid account found."
-msgstr ""
-
-#: mod/lostpass.php:38
-msgid "Password reset request issued. Check your email."
+"Comma separated list of domains which are allowed in email addresses for "
+"registrations to this site. Wildcards are accepted. Empty to allow any "
+"domains"
msgstr ""
-#: mod/lostpass.php:44
-#, php-format
-msgid ""
-"\n"
-"\t\tDear %1$s,\n"
-"\t\t\tA request was recently received at \"%2$s\" to reset your account\n"
-"\t\tpassword. In order to confirm this request, please select the "
-"verification link\n"
-"\t\tbelow or paste it into your web browser address bar.\n"
-"\n"
-"\t\tIf you did NOT request this change, please DO NOT follow the link\n"
-"\t\tprovided and ignore and/or delete this email.\n"
-"\n"
-"\t\tYour password will not be changed unless we can verify that you\n"
-"\t\tissued this request."
+#: mod/admin.php:1214
+msgid "Block public"
msgstr ""
-#: mod/lostpass.php:55
-#, php-format
+#: mod/admin.php:1214
msgid ""
-"\n"
-"\t\tFollow this link to verify your identity:\n"
-"\n"
-"\t\t%1$s\n"
-"\n"
-"\t\tYou will then receive a follow-up message containing the new password.\n"
-"\t\tYou may change that password from your account settings page after "
-"logging in.\n"
-"\n"
-"\t\tThe login details are as follows:\n"
-"\n"
-"\t\tSite Location:\t%2$s\n"
-"\t\tLogin Name:\t%3$s"
+"Check to block public access to all otherwise public personal pages on this "
+"site unless you are currently logged in."
msgstr ""
-#: mod/lostpass.php:74
-#, php-format
-msgid "Password reset requested at %s"
+#: mod/admin.php:1215
+msgid "Force publish"
msgstr ""
-#: mod/lostpass.php:94
+#: mod/admin.php:1215
msgid ""
-"Request could not be verified. (You may have previously submitted it.) "
-"Password reset failed."
+"Check to force all profiles on this site to be listed in the site directory."
msgstr ""
-#: mod/lostpass.php:113 boot.php:889
-msgid "Password Reset"
+#: mod/admin.php:1216
+msgid "Global directory URL"
msgstr ""
-#: mod/lostpass.php:114
-msgid "Your password has been reset as requested."
+#: mod/admin.php:1216
+msgid ""
+"URL to the global directory. If this is not set, the global directory is "
+"completely unavailable to the application."
msgstr ""
-#: mod/lostpass.php:115
-msgid "Your new password is"
+#: mod/admin.php:1217
+msgid "Allow threaded items"
msgstr ""
-#: mod/lostpass.php:116
-msgid "Save or copy your new password - and then"
+#: mod/admin.php:1217
+msgid "Allow infinite level threading for items on this site."
msgstr ""
-#: mod/lostpass.php:117
-msgid "click here to login"
+#: mod/admin.php:1218
+msgid "Private posts by default for new users"
msgstr ""
-#: mod/lostpass.php:118
+#: mod/admin.php:1218
msgid ""
-"Your password may be changed from the <em>Settings</em> page after "
-"successful login."
+"Set default post permissions for all new members to the default privacy "
+"group rather than public."
msgstr ""
-#: mod/lostpass.php:128
-#, php-format
-msgid ""
-"\n"
-"\t\t\t\tDear %1$s,\n"
-"\t\t\t\t\tYour password has been changed as requested. Please retain this\n"
-"\t\t\t\tinformation for your records (or change your password immediately "
-"to\n"
-"\t\t\t\tsomething that you will remember).\n"
-"\t\t\t"
+#: mod/admin.php:1219
+msgid "Don't include post content in email notifications"
msgstr ""
-#: mod/lostpass.php:134
-#, php-format
+#: mod/admin.php:1219
msgid ""
-"\n"
-"\t\t\t\tYour login details are as follows:\n"
-"\n"
-"\t\t\t\tSite Location:\t%1$s\n"
-"\t\t\t\tLogin Name:\t%2$s\n"
-"\t\t\t\tPassword:\t%3$s\n"
-"\n"
-"\t\t\t\tYou may change that password from your account settings page after "
-"logging in.\n"
-"\t\t\t"
-msgstr ""
-
-#: mod/lostpass.php:150
-#, php-format
-msgid "Your password has been changed at %s"
+"Don't include the content of a post/comment/private message/etc. in the "
+"email notifications that are sent out from this site, as a privacy measure."
msgstr ""
-#: mod/lostpass.php:162
-msgid "Forgot your Password?"
+#: mod/admin.php:1220
+msgid "Disallow public access to addons listed in the apps menu."
msgstr ""
-#: mod/lostpass.php:163
+#: mod/admin.php:1220
msgid ""
-"Enter your email address and submit to have your password reset. Then check "
-"your email for further instructions."
-msgstr ""
-
-#: mod/lostpass.php:164 boot.php:877
-msgid "Nickname or Email: "
-msgstr ""
-
-#: mod/lostpass.php:165
-msgid "Reset"
+"Checking this box will restrict addons listed in the apps menu to members "
+"only."
msgstr ""
-#: mod/manage.php:153
-msgid "Manage Identities and/or Pages"
+#: mod/admin.php:1221
+msgid "Don't embed private images in posts"
msgstr ""
-#: mod/manage.php:154
+#: mod/admin.php:1221
msgid ""
-"Toggle between different identities or community/group pages which share "
-"your account details or which you have been granted \"manage\" permissions"
-msgstr ""
-
-#: mod/manage.php:155
-msgid "Select an identity to manage: "
-msgstr ""
-
-#: mod/match.php:39
-msgid "No keywords to match. Please add keywords to your default profile."
-msgstr ""
-
-#: mod/match.php:92
-msgid "is interested in:"
-msgstr ""
-
-#: mod/match.php:106
-msgid "Profile Match"
-msgstr ""
-
-#: mod/match.php:113 mod/dirfind.php:249
-msgid "No matches"
-msgstr ""
-
-#: mod/message.php:63 mod/wallmessage.php:53
-msgid "No recipient selected."
-msgstr ""
-
-#: mod/message.php:67
-msgid "Unable to locate contact information."
+"Don't replace locally-hosted private photos in posts with an embedded copy "
+"of the image. This means that contacts who receive posts containing private "
+"photos will have to authenticate and load each image, which may take a while."
msgstr ""
-#: mod/message.php:70 mod/wallmessage.php:59
-msgid "Message could not be sent."
+#: mod/admin.php:1222
+msgid "Allow Users to set remote_self"
msgstr ""
-#: mod/message.php:73 mod/wallmessage.php:62
-msgid "Message collection failure."
+#: mod/admin.php:1222
+msgid ""
+"With checking this, every user is allowed to mark every contact as a "
+"remote_self in the repair contact dialog. Setting this flag on a contact "
+"causes mirroring every posting of that contact in the users stream."
msgstr ""
-#: mod/message.php:76 mod/wallmessage.php:65
-msgid "Message sent."
+#: mod/admin.php:1223
+msgid "Block multiple registrations"
msgstr ""
-#: mod/message.php:205
-msgid "Do you really want to delete this message?"
+#: mod/admin.php:1223
+msgid "Disallow users to register additional accounts for use as pages."
msgstr ""
-#: mod/message.php:225
-msgid "Message deleted."
+#: mod/admin.php:1224
+msgid "OpenID support"
msgstr ""
-#: mod/message.php:255
-msgid "Conversation removed."
+#: mod/admin.php:1224
+msgid "OpenID support for registration and logins."
msgstr ""
-#: mod/message.php:322 mod/wallmessage.php:129
-msgid "Send Private Message"
+#: mod/admin.php:1225
+msgid "Fullname check"
msgstr ""
-#: mod/message.php:323 mod/message.php:510 mod/wallmessage.php:131
-msgid "To:"
+#: mod/admin.php:1225
+msgid ""
+"Force users to register with a space between firstname and lastname in Full "
+"name, as an antispam measure"
msgstr ""
-#: mod/message.php:328 mod/message.php:512 mod/wallmessage.php:132
-msgid "Subject:"
+#: mod/admin.php:1226
+msgid "Community Page Style"
msgstr ""
-#: mod/message.php:364
-msgid "No messages."
+#: mod/admin.php:1226
+msgid ""
+"Type of community page to show. 'Global community' shows every public "
+"posting from an open distributed network that arrived on this server."
msgstr ""
-#: mod/message.php:403
-msgid "Message not available."
+#: mod/admin.php:1227
+msgid "Posts per user on community page"
msgstr ""
-#: mod/message.php:478
-msgid "Delete message"
+#: mod/admin.php:1227
+msgid ""
+"The maximum number of posts per user on the community page. (Not valid for "
+"'Global Community')"
msgstr ""
-#: mod/message.php:503 mod/message.php:591
-msgid "Delete conversation"
+#: mod/admin.php:1228
+msgid "Enable OStatus support"
msgstr ""
-#: mod/message.php:505
+#: mod/admin.php:1228
msgid ""
-"No secure communications available. You <strong>may</strong> be able to "
-"respond from the sender's profile page."
+"Provide built-in OStatus (StatusNet, GNU Social etc.) compatibility. All "
+"communications in OStatus are public, so privacy warnings will be "
+"occasionally displayed."
msgstr ""
-#: mod/message.php:509
-msgid "Send Reply"
+#: mod/admin.php:1229
+msgid "Only import OStatus threads from our contacts"
msgstr ""
-#: mod/message.php:561
-#, php-format
-msgid "Unknown sender - %s"
+#: mod/admin.php:1229
+msgid ""
+"Normally we import every content from our OStatus contacts. With this option "
+"we only store threads that are started by a contact that is known on our "
+"system."
msgstr ""
-#: mod/message.php:563
-#, php-format
-msgid "You and %s"
+#: mod/admin.php:1230
+msgid "OStatus support can only be enabled if threading is enabled."
msgstr ""
-#: mod/message.php:565
-#, php-format
-msgid "%s and You"
+#: mod/admin.php:1232
+msgid ""
+"Diaspora support can't be enabled because Friendica was installed into a sub "
+"directory."
msgstr ""
-#: mod/message.php:594
-msgid "D, d M Y - g:i A"
+#: mod/admin.php:1233
+msgid "Enable Diaspora support"
msgstr ""
-#: mod/message.php:597
-#, php-format
-msgid "%d message"
-msgid_plural "%d messages"
-msgstr[0] ""
-msgstr[1] ""
-
-#: mod/notifications.php:38
-msgid "Invalid request identifier."
+#: mod/admin.php:1233
+msgid "Provide built-in Diaspora network compatibility."
msgstr ""
-#: mod/notifications.php:47 mod/notifications.php:183 mod/notifications.php:230
-msgid "Discard"
+#: mod/admin.php:1234
+msgid "Only allow Friendica contacts"
msgstr ""
-#: mod/notifications.php:63 mod/notifications.php:182 mod/notifications.php:266
-#: mod/contacts.php:636 mod/contacts.php:836 mod/contacts.php:1021
-msgid "Ignore"
+#: mod/admin.php:1234
+msgid ""
+"All contacts must use Friendica protocols. All other built-in communication "
+"protocols disabled."
msgstr ""
-#: mod/notifications.php:108
-msgid "Network Notifications"
+#: mod/admin.php:1235
+msgid "Verify SSL"
msgstr ""
-#: mod/notifications.php:114 mod/notify.php:73
-msgid "System Notifications"
+#: mod/admin.php:1235
+msgid ""
+"If you wish, you can turn on strict certificate checking. This will mean you "
+"cannot connect (at all) to self-signed SSL sites."
msgstr ""
-#: mod/notifications.php:120
-msgid "Personal Notifications"
+#: mod/admin.php:1236
+msgid "Proxy user"
msgstr ""
-#: mod/notifications.php:126
-msgid "Home Notifications"
+#: mod/admin.php:1237
+msgid "Proxy URL"
msgstr ""
-#: mod/notifications.php:155
-msgid "Show Ignored Requests"
+#: mod/admin.php:1238
+msgid "Network timeout"
msgstr ""
-#: mod/notifications.php:155
-msgid "Hide Ignored Requests"
+#: mod/admin.php:1238
+msgid "Value is in seconds. Set to 0 for unlimited (not recommended)."
msgstr ""
-#: mod/notifications.php:167 mod/notifications.php:237
-msgid "Notification type: "
+#: mod/admin.php:1239
+msgid "Maximum Load Average"
msgstr ""
-#: mod/notifications.php:170
-#, php-format
-msgid "suggested by %s"
+#: mod/admin.php:1239
+msgid ""
+"Maximum system load before delivery and poll processes are deferred - "
+"default 50."
msgstr ""
-#: mod/notifications.php:175 mod/notifications.php:254 mod/contacts.php:643
-msgid "Hide this contact from others"
+#: mod/admin.php:1240
+msgid "Maximum Load Average (Frontend)"
msgstr ""
-#: mod/notifications.php:176 mod/notifications.php:255
-msgid "Post a new friend activity"
+#: mod/admin.php:1240
+msgid "Maximum system load before the frontend quits service - default 50."
msgstr ""
-#: mod/notifications.php:176 mod/notifications.php:255
-msgid "if applicable"
+#: mod/admin.php:1241
+msgid "Minimal Memory"
msgstr ""
-#: mod/notifications.php:179 mod/notifications.php:264 mod/admin.php:1628
-msgid "Approve"
+#: mod/admin.php:1241
+msgid ""
+"Minimal free memory in MB for the worker. Needs access to /proc/meminfo - "
+"default 0 (deactivated)."
msgstr ""
-#: mod/notifications.php:198
-msgid "Claims to be known to you: "
+#: mod/admin.php:1242
+msgid "Maximum table size for optimization"
msgstr ""
-#: mod/notifications.php:199
-msgid "yes"
+#: mod/admin.php:1242
+msgid ""
+"Maximum table size (in MB) for the automatic optimization - default 100 MB. "
+"Enter -1 to disable it."
msgstr ""
-#: mod/notifications.php:199
-msgid "no"
+#: mod/admin.php:1243
+msgid "Minimum level of fragmentation"
msgstr ""
-#: mod/notifications.php:200 mod/notifications.php:205
-msgid "Shall your connection be bidirectional or not?"
+#: mod/admin.php:1243
+msgid ""
+"Minimum fragmenation level to start the automatic optimization - default "
+"value is 30%."
msgstr ""
-#: mod/notifications.php:201 mod/notifications.php:206
-#, php-format
-msgid ""
-"Accepting %s as a friend allows %s to subscribe to your posts, and you will "
-"also receive updates from them in your news feed."
+#: mod/admin.php:1245
+msgid "Periodical check of global contacts"
msgstr ""
-#: mod/notifications.php:202
-#, php-format
+#: mod/admin.php:1245
msgid ""
-"Accepting %s as a subscriber allows them to subscribe to your posts, but you "
-"will not receive updates from them in your news feed."
+"If enabled, the global contacts are checked periodically for missing or "
+"outdated data and the vitality of the contacts and servers."
msgstr ""
-#: mod/notifications.php:207
-#, php-format
-msgid ""
-"Accepting %s as a sharer allows them to subscribe to your posts, but you "
-"will not receive updates from them in your news feed."
+#: mod/admin.php:1246
+msgid "Days between requery"
msgstr ""
-#: mod/notifications.php:218
-msgid "Friend"
+#: mod/admin.php:1246
+msgid "Number of days after which a server is requeried for his contacts."
msgstr ""
-#: mod/notifications.php:219
-msgid "Sharer"
+#: mod/admin.php:1247
+msgid "Discover contacts from other servers"
msgstr ""
-#: mod/notifications.php:219
-msgid "Subscriber"
+#: mod/admin.php:1247
+msgid ""
+"Periodically query other servers for contacts. You can choose between "
+"'users': the users on the remote system, 'Global Contacts': active contacts "
+"that are known on the system. The fallback is meant for Redmatrix servers "
+"and older friendica servers, where global contacts weren't available. The "
+"fallback increases the server load, so the recommened setting is 'Users, "
+"Global Contacts'."
msgstr ""
-#: mod/notifications.php:275
-msgid "No introductions."
+#: mod/admin.php:1248
+msgid "Timeframe for fetching global contacts"
msgstr ""
-#: mod/notifications.php:316
-msgid "Show unread"
+#: mod/admin.php:1248
+msgid ""
+"When the discovery is activated, this value defines the timeframe for the "
+"activity of the global contacts that are fetched from other servers."
msgstr ""
-#: mod/notifications.php:316
-msgid "Show all"
+#: mod/admin.php:1249
+msgid "Search the local directory"
msgstr ""
-#: mod/notifications.php:322
-#, php-format
-msgid "No more %s notifications."
+#: mod/admin.php:1249
+msgid ""
+"Search the local directory instead of the global directory. When searching "
+"locally, every search will be executed on the global directory in the "
+"background. This improves the search results when the search is repeated."
msgstr ""
-#: mod/notify.php:69
-msgid "No more system notifications."
+#: mod/admin.php:1251
+msgid "Publish server information"
msgstr ""
-#: mod/oexchange.php:25
-msgid "Post successful."
+#: mod/admin.php:1251
+msgid ""
+"If enabled, general server and usage data will be published. The data "
+"contains the name and version of the server, number of users with public "
+"profiles, number of posts and the activated protocols and connectors. See <a "
+"href='http://the-federation.info/'>the-federation.info</a> for details."
msgstr ""
-#: mod/openid.php:25
-msgid "OpenID protocol error. No ID returned."
+#: mod/admin.php:1253
+msgid "Check upstream version"
msgstr ""
-#: mod/openid.php:61
+#: mod/admin.php:1253
msgid ""
-"Account not found and OpenID registration is not permitted on this site."
+"Enables checking for new Friendica versions at github. If there is a new "
+"version, you will be informed in the admin panel overview."
msgstr ""
-#: mod/p.php:13
-msgid "Not Extended"
+#: mod/admin.php:1254
+msgid "Suppress Tags"
msgstr ""
-#: mod/profile.php:177
-msgid "Tips for New Members"
+#: mod/admin.php:1254
+msgid "Suppress showing a list of hashtags at the end of the posting."
msgstr ""
-#: mod/removeme.php:55 mod/removeme.php:58
-msgid "Remove My Account"
+#: mod/admin.php:1255
+msgid "Path to item cache"
msgstr ""
-#: mod/removeme.php:56
-msgid ""
-"This will completely remove your account. Once this has been done it is not "
-"recoverable."
+#: mod/admin.php:1255
+msgid "The item caches buffers generated bbcode and external images."
msgstr ""
-#: mod/removeme.php:57
-msgid "Please enter your password for verification:"
+#: mod/admin.php:1256
+msgid "Cache duration in seconds"
msgstr ""
-#: mod/repair_ostatus.php:17
-msgid "Resubscribing to OStatus contacts"
+#: mod/admin.php:1256
+msgid ""
+"How long should the cache files be hold? Default value is 86400 seconds (One "
+"day). To disable the item cache, set the value to -1."
msgstr ""
-#: mod/repair_ostatus.php:33
-msgid "Error"
+#: mod/admin.php:1257
+msgid "Maximum numbers of comments per post"
msgstr ""
-#: mod/repair_ostatus.php:47 mod/ostatus_subscribe.php:57
-msgid "Done"
+#: mod/admin.php:1257
+msgid "How much comments should be shown for each post? Default value is 100."
msgstr ""
-#: mod/repair_ostatus.php:53 mod/ostatus_subscribe.php:81
-msgid "Keep this window open until done."
+#: mod/admin.php:1258
+msgid "Temp path"
msgstr ""
-#: mod/subthread.php:106
-#, php-format
-msgid "%1$s is following %2$s's %3$s"
+#: mod/admin.php:1258
+msgid ""
+"If you have a restricted system where the webserver can't access the system "
+"temp path, enter another path here."
msgstr ""
-#: mod/tagrm.php:46
-msgid "Tag removed"
+#: mod/admin.php:1259
+msgid "Base path to installation"
msgstr ""
-#: mod/tagrm.php:85
-msgid "Remove Item Tag"
+#: mod/admin.php:1259
+msgid ""
+"If the system cannot detect the correct path to your installation, enter the "
+"correct path here. This setting should only be set if you are using a "
+"restricted system and symbolic links to your webroot."
msgstr ""
-#: mod/tagrm.php:87
-msgid "Select a tag to remove: "
+#: mod/admin.php:1260
+msgid "Disable picture proxy"
msgstr ""
-#: mod/tagrm.php:98 mod/delegate.php:139
-msgid "Remove"
+#: mod/admin.php:1260
+msgid ""
+"The picture proxy increases performance and privacy. It shouldn't be used on "
+"systems with very low bandwith."
msgstr ""
-#: mod/uexport.php:39
-msgid "Export account"
+#: mod/admin.php:1261
+msgid "Only search in tags"
msgstr ""
-#: mod/uexport.php:39
-msgid ""
-"Export your account info and contacts. Use this to make a backup of your "
-"account and/or to move it to another server."
+#: mod/admin.php:1261
+msgid "On large systems the text search can slow down the system extremely."
msgstr ""
-#: mod/uexport.php:40
-msgid "Export all"
+#: mod/admin.php:1263
+msgid "New base url"
msgstr ""
-#: mod/uexport.php:40
+#: mod/admin.php:1263
msgid ""
-"Export your accout info, contacts and all your items as json. Could be a "
-"very big file, and could take a lot of time. Use this to make a full backup "
-"of your account (photos are not exported)"
+"Change base url for this server. Sends relocate message to all Friendica and "
+"Diaspora* contacts of all users."
msgstr ""
-#: mod/uexport.php:47 mod/settings.php:95
-msgid "Export personal data"
+#: mod/admin.php:1265
+msgid "RINO Encryption"
msgstr ""
-#: mod/wallmessage.php:45 mod/wallmessage.php:109
-#, php-format
-msgid "Number of daily wall messages for %s exceeded. Message failed."
+#: mod/admin.php:1265
+msgid "Encryption layer between nodes."
msgstr ""
-#: mod/wallmessage.php:56
-msgid "Unable to check your home location."
+#: mod/admin.php:1267
+msgid "Maximum number of parallel workers"
msgstr ""
-#: mod/wallmessage.php:83 mod/wallmessage.php:92
-msgid "No recipient."
+#: mod/admin.php:1267
+msgid ""
+"On shared hosters set this to 2. On larger systems, values of 10 are great. "
+"Default value is 4."
msgstr ""
-#: mod/wallmessage.php:130
-#, php-format
+#: mod/admin.php:1268
+msgid "Don't use 'proc_open' with the worker"
+msgstr ""
+
+#: mod/admin.php:1268
msgid ""
-"If you wish for %s to respond, please check that the privacy settings on "
-"your site allow private mail from unknown senders."
+"Enable this if your system doesn't allow the use of 'proc_open'. This can "
+"happen on shared hosters. If this is enabled you should increase the "
+"frequency of worker calls in your crontab."
msgstr ""
-#: mod/delegate.php:101
-msgid "No potential page delegates located."
+#: mod/admin.php:1269
+msgid "Enable fastlane"
msgstr ""
-#: mod/delegate.php:132
+#: mod/admin.php:1269
msgid ""
-"Delegates are able to manage all aspects of this account/page except for "
-"basic account settings. Please do not delegate your personal account to "
-"anybody that you do not trust completely."
+"When enabed, the fastlane mechanism starts an additional worker if processes "
+"with higher priority are blocked by processes of lower priority."
msgstr ""
-#: mod/delegate.php:133
-msgid "Existing Page Managers"
+#: mod/admin.php:1270
+msgid "Enable frontend worker"
msgstr ""
-#: mod/delegate.php:135
-msgid "Existing Page Delegates"
+#: mod/admin.php:1270
+#, php-format
+msgid ""
+"When enabled the Worker process is triggered when backend access is "
+"performed (e.g. messages being delivered). On smaller sites you might want "
+"to call %s/worker on a regular basis via an external cron job. You should "
+"only enable this option if you cannot utilize cron/scheduled jobs on your "
+"server."
msgstr ""
-#: mod/delegate.php:137
-msgid "Potential Delegates"
+#: mod/admin.php:1300
+msgid "Update has been marked successful"
msgstr ""
-#: mod/delegate.php:140
-msgid "Add"
+#: mod/admin.php:1308
+#, php-format
+msgid "Database structure update %s was successfully applied."
msgstr ""
-#: mod/delegate.php:141
-msgid "No entries."
+#: mod/admin.php:1311
+#, php-format
+msgid "Executing of database structure update %s failed with error: %s"
msgstr ""
-#: mod/suggest.php:30
-msgid "Do you really want to delete this suggestion?"
+#: mod/admin.php:1325
+#, php-format
+msgid "Executing %s failed with error: %s"
msgstr ""
-#: mod/suggest.php:71
-msgid ""
-"No suggestions available. If this is a new site, please try again in 24 "
-"hours."
+#: mod/admin.php:1328
+#, php-format
+msgid "Update %s was successfully applied."
msgstr ""
-#: mod/suggest.php:84 mod/suggest.php:104
-msgid "Ignore/Hide"
+#: mod/admin.php:1331
+#, php-format
+msgid "Update %s did not return a status. Unknown if it succeeded."
msgstr ""
-#: mod/directory.php:193 view/theme/vier/theme.php:194
-msgid "Global Directory"
+#: mod/admin.php:1334
+#, php-format
+msgid "There was no additional update function %s that needed to be called."
msgstr ""
-#: mod/directory.php:195
-msgid "Find on this site"
+#: mod/admin.php:1354
+msgid "No failed updates."
msgstr ""
-#: mod/directory.php:197
-msgid "Results for:"
+#: mod/admin.php:1355
+msgid "Check database structure"
msgstr ""
-#: mod/directory.php:199
-msgid "Site Directory"
+#: mod/admin.php:1360
+msgid "Failed Updates"
msgstr ""
-#: mod/directory.php:206
-msgid "No entries (some entries may be hidden)."
+#: mod/admin.php:1361
+msgid ""
+"This does not include updates prior to 1139, which did not return a status."
msgstr ""
-#: mod/fbrowser.php:136
-msgid "Files"
+#: mod/admin.php:1362
+msgid "Mark success (if update was manually applied)"
msgstr ""
-#: mod/friendica.php:70
-msgid "This is Friendica, version"
+#: mod/admin.php:1363
+msgid "Attempt to execute this update step automatically"
msgstr ""
-#: mod/friendica.php:71
-msgid "running at web location"
+#: mod/admin.php:1397
+#, php-format
+msgid ""
+"\n"
+"\t\t\tDear %1$s,\n"
+"\t\t\t\tthe administrator of %2$s has set up an account for you."
msgstr ""
-#: mod/friendica.php:75
+#: mod/admin.php:1400
+#, php-format
msgid ""
-"Please visit <a href=\"https://friendi.ca\">Friendi.ca</a> to learn more "
-"about the Friendica project."
+"\n"
+"\t\t\tThe login details are as follows:\n"
+"\n"
+"\t\t\tSite Location:\t%1$s\n"
+"\t\t\tLogin Name:\t\t%2$s\n"
+"\t\t\tPassword:\t\t%3$s\n"
+"\n"
+"\t\t\tYou may change your password from your account \"Settings\" page after "
+"logging\n"
+"\t\t\tin.\n"
+"\n"
+"\t\t\tPlease take a few moments to review the other account settings on that "
+"page.\n"
+"\n"
+"\t\t\tYou may also wish to add some basic information to your default "
+"profile\n"
+"\t\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
+"\n"
+"\t\t\tWe recommend setting your full name, adding a profile photo,\n"
+"\t\t\tadding some profile \"keywords\" (very useful in making new friends) - "
+"and\n"
+"\t\t\tperhaps what country you live in; if you do not wish to be more "
+"specific\n"
+"\t\t\tthan that.\n"
+"\n"
+"\t\t\tWe fully respect your right to privacy, and none of these items are "
+"necessary.\n"
+"\t\t\tIf you are new and do not know anybody here, they may help\n"
+"\t\t\tyou to make some new and interesting friends.\n"
+"\n"
+"\t\t\tThank you and welcome to %4$s."
msgstr ""
-#: mod/friendica.php:79
-msgid "Bug reports and issues: please visit"
-msgstr ""
+#: mod/admin.php:1444
+#, php-format
+msgid "%s user blocked/unblocked"
+msgid_plural "%s users blocked/unblocked"
+msgstr[0] ""
+msgstr[1] ""
-#: mod/friendica.php:79
-msgid "the bugtracker at github"
-msgstr ""
+#: mod/admin.php:1450
+#, php-format
+msgid "%s user deleted"
+msgid_plural "%s users deleted"
+msgstr[0] ""
+msgstr[1] ""
-#: mod/friendica.php:82
-msgid ""
-"Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - "
-"dot com"
+#: mod/admin.php:1496
+#, php-format
+msgid "User '%s' deleted"
msgstr ""
-#: mod/friendica.php:96
-msgid "Installed plugins/addons/apps:"
+#: mod/admin.php:1504
+#, php-format
+msgid "User '%s' unblocked"
msgstr ""
-#: mod/friendica.php:110
-msgid "No installed plugins/addons/apps"
+#: mod/admin.php:1504
+#, php-format
+msgid "User '%s' blocked"
msgstr ""
-#: mod/friendica.php:115
-msgid "On this server the following remote servers are blocked."
+#: mod/admin.php:1612 mod/admin.php:1625 mod/admin.php:1638 mod/admin.php:1654
+#: mod/crepair.php:173 mod/settings.php:698 mod/settings.php:724
+msgid "Name"
msgstr ""
-#: mod/friendica.php:116 mod/admin.php:291 mod/admin.php:309
-msgid "Reason for the block"
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Register date"
msgstr ""
-#: mod/install.php:107
-msgid "Friendica Communications Server - Setup"
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Last login"
msgstr ""
-#: mod/install.php:113
-msgid "Could not connect to database."
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Last item"
msgstr ""
-#: mod/install.php:117
-msgid "Could not create table."
+#: mod/admin.php:1612 mod/settings.php:46
+msgid "Account"
msgstr ""
-#: mod/install.php:123
-msgid "Your Friendica site database has been installed."
+#: mod/admin.php:1621
+msgid "Add User"
msgstr ""
-#: mod/install.php:128
-msgid ""
-"You may need to import the file \"database.sql\" manually using phpmyadmin "
-"or mysql."
+#: mod/admin.php:1622
+msgid "select all"
msgstr ""
-#: mod/install.php:129 mod/install.php:201 mod/install.php:548
-msgid "Please see the file \"INSTALL.txt\"."
+#: mod/admin.php:1623
+msgid "User registrations waiting for confirm"
msgstr ""
-#: mod/install.php:141
-msgid "Database already in use."
+#: mod/admin.php:1624
+msgid "User waiting for permanent deletion"
msgstr ""
-#: mod/install.php:198
-msgid "System check"
+#: mod/admin.php:1625
+msgid "Request date"
msgstr ""
-#: mod/install.php:203
-msgid "Check again"
+#: mod/admin.php:1626
+msgid "No registrations."
msgstr ""
-#: mod/install.php:222
-msgid "Database connection"
+#: mod/admin.php:1627
+msgid "Note from the user"
msgstr ""
-#: mod/install.php:223
-msgid ""
-"In order to install Friendica we need to know how to connect to your "
-"database."
+#: mod/admin.php:1628 mod/notifications.php:180 mod/notifications.php:265
+msgid "Approve"
msgstr ""
-#: mod/install.php:224
-msgid ""
-"Please contact your hosting provider or site administrator if you have "
-"questions about these settings."
+#: mod/admin.php:1629
+msgid "Deny"
msgstr ""
-#: mod/install.php:225
-msgid ""
-"The database you specify below should already exist. If it does not, please "
-"create it before continuing."
+#: mod/admin.php:1631 mod/contacts.php:642 mod/contacts.php:843
+#: mod/contacts.php:1021
+msgid "Block"
msgstr ""
-#: mod/install.php:229
-msgid "Database Server Name"
+#: mod/admin.php:1632 mod/contacts.php:642 mod/contacts.php:843
+#: mod/contacts.php:1021
+msgid "Unblock"
msgstr ""
-#: mod/install.php:230
-msgid "Database Login Name"
+#: mod/admin.php:1633
+msgid "Site admin"
msgstr ""
-#: mod/install.php:231
-msgid "Database Login Password"
+#: mod/admin.php:1634
+msgid "Account expired"
msgstr ""
-#: mod/install.php:231
-msgid "For security reasons the password must not be empty"
+#: mod/admin.php:1637
+msgid "New User"
msgstr ""
-#: mod/install.php:232
-msgid "Database Name"
+#: mod/admin.php:1638
+msgid "Deleted since"
msgstr ""
-#: mod/install.php:233 mod/install.php:274
-msgid "Site administrator email address"
+#: mod/admin.php:1643
+msgid ""
+"Selected users will be deleted!\\n\\nEverything these users had posted on "
+"this site will be permanently deleted!\\n\\nAre you sure?"
msgstr ""
-#: mod/install.php:233 mod/install.php:274
+#: mod/admin.php:1644
msgid ""
-"Your account email address must match this in order to use the web admin "
-"panel."
+"The user {0} will be deleted!\\n\\nEverything this user has posted on this "
+"site will be permanently deleted!\\n\\nAre you sure?"
msgstr ""
-#: mod/install.php:237 mod/install.php:277
-msgid "Please select a default timezone for your website"
+#: mod/admin.php:1654
+msgid "Name of the new user."
msgstr ""
-#: mod/install.php:264
-msgid "Site settings"
+#: mod/admin.php:1655
+msgid "Nickname"
msgstr ""
-#: mod/install.php:278
-msgid "System Language:"
+#: mod/admin.php:1655
+msgid "Nickname of the new user."
msgstr ""
-#: mod/install.php:278
-msgid ""
-"Set the default language for your Friendica installation interface and to "
-"send emails."
+#: mod/admin.php:1656
+msgid "Email address of the new user."
msgstr ""
-#: mod/install.php:318
-msgid "Could not find a command line version of PHP in the web server PATH."
+#: mod/admin.php:1699
+#, php-format
+msgid "Plugin %s disabled."
msgstr ""
-#: mod/install.php:319
-msgid ""
-"If you don't have a command line version of PHP installed on server, you "
-"will not be able to run the background processing. See <a href='https://"
-"github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-"
-"poller'>'Setup the poller'</a>"
+#: mod/admin.php:1703
+#, php-format
+msgid "Plugin %s enabled."
msgstr ""
-#: mod/install.php:323
-msgid "PHP executable path"
+#: mod/admin.php:1714 mod/admin.php:1966
+msgid "Disable"
msgstr ""
-#: mod/install.php:323
-msgid ""
-"Enter full path to php executable. You can leave this blank to continue the "
-"installation."
+#: mod/admin.php:1716 mod/admin.php:1968
+msgid "Enable"
msgstr ""
-#: mod/install.php:328
-msgid "Command line PHP"
+#: mod/admin.php:1739 mod/admin.php:2015
+msgid "Toggle"
msgstr ""
-#: mod/install.php:337
-msgid "PHP executable is not the php cli binary (could be cgi-fgci version)"
+#: mod/admin.php:1747 mod/admin.php:2024
+msgid "Author: "
msgstr ""
-#: mod/install.php:338
-msgid "Found PHP version: "
+#: mod/admin.php:1748 mod/admin.php:2025
+msgid "Maintainer: "
msgstr ""
-#: mod/install.php:340
-msgid "PHP cli binary"
+#: mod/admin.php:1803
+msgid "Reload active plugins"
msgstr ""
-#: mod/install.php:351
+#: mod/admin.php:1808
+#, php-format
msgid ""
-"The command line version of PHP on your system does not have "
-"\"register_argc_argv\" enabled."
+"There are currently no plugins available on your node. You can find the "
+"official plugin repository at %1$s and might find other interesting plugins "
+"in the open plugin registry at %2$s"
msgstr ""
-#: mod/install.php:352
-msgid "This is required for message delivery to work."
+#: mod/admin.php:1927
+msgid "No themes found."
msgstr ""
-#: mod/install.php:354
-msgid "PHP register_argc_argv"
+#: mod/admin.php:2006
+msgid "Screenshot"
msgstr ""
-#: mod/install.php:377
-msgid ""
-"Error: the \"openssl_pkey_new\" function on this system is not able to "
-"generate encryption keys"
+#: mod/admin.php:2066
+msgid "Reload active themes"
msgstr ""
-#: mod/install.php:378
-msgid ""
-"If running under Windows, please see \"http://www.php.net/manual/en/openssl."
-"installation.php\"."
+#: mod/admin.php:2071
+#, php-format
+msgid "No themes found on the system. They should be paced in %1$s"
msgstr ""
-#: mod/install.php:380
-msgid "Generate encryption keys"
+#: mod/admin.php:2072
+msgid "[Experimental]"
msgstr ""
-#: mod/install.php:387
-msgid "libCurl PHP module"
+#: mod/admin.php:2073
+msgid "[Unsupported]"
msgstr ""
-#: mod/install.php:388
-msgid "GD graphics PHP module"
+#: mod/admin.php:2097
+msgid "Log settings updated."
msgstr ""
-#: mod/install.php:389
-msgid "OpenSSL PHP module"
+#: mod/admin.php:2129
+msgid "PHP log currently enabled."
msgstr ""
-#: mod/install.php:390
-msgid "PDO or MySQLi PHP module"
+#: mod/admin.php:2131
+msgid "PHP log currently disabled."
msgstr ""
-#: mod/install.php:391
-msgid "mb_string PHP module"
+#: mod/admin.php:2140
+msgid "Clear"
msgstr ""
-#: mod/install.php:392
-msgid "XML PHP module"
+#: mod/admin.php:2145
+msgid "Enable Debugging"
msgstr ""
-#: mod/install.php:393
-msgid "iconv module"
+#: mod/admin.php:2146
+msgid "Log file"
msgstr ""
-#: mod/install.php:397 mod/install.php:399
-msgid "Apache mod_rewrite module"
+#: mod/admin.php:2146
+msgid ""
+"Must be writable by web server. Relative to your Friendica top-level "
+"directory."
msgstr ""
-#: mod/install.php:397
-msgid ""
-"Error: Apache webserver mod-rewrite module is required but not installed."
+#: mod/admin.php:2147
+msgid "Log level"
msgstr ""
-#: mod/install.php:405
-msgid "Error: libCURL PHP module required but not installed."
+#: mod/admin.php:2150
+msgid "PHP logging"
msgstr ""
-#: mod/install.php:409
+#: mod/admin.php:2151
msgid ""
-"Error: GD graphics PHP module with JPEG support required but not installed."
+"To enable logging of PHP errors and warnings you can add the following to "
+"the .htconfig.php file of your installation. The filename set in the "
+"'error_log' line is relative to the friendica top-level directory and must "
+"be writeable by the web server. The option '1' for 'log_errors' and "
+"'display_errors' is to enable these options, set to '0' to disable them."
msgstr ""
-#: mod/install.php:413
-msgid "Error: openssl PHP module required but not installed."
+#: mod/admin.php:2278 mod/admin.php:2279 mod/settings.php:797
+msgid "Off"
msgstr ""
-#: mod/install.php:417
-msgid "Error: PDO or MySQLi PHP module required but not installed."
+#: mod/admin.php:2278 mod/admin.php:2279 mod/settings.php:797
+msgid "On"
msgstr ""
-#: mod/install.php:421
-msgid "Error: The MySQL driver for PDO is not installed."
+#: mod/admin.php:2279
+#, php-format
+msgid "Lock feature %s"
msgstr ""
-#: mod/install.php:425
-msgid "Error: mb_string PHP module required but not installed."
+#: mod/admin.php:2287
+msgid "Manage Additional Features"
msgstr ""
-#: mod/install.php:429
-msgid "Error: iconv PHP module required but not installed."
+#: mod/allfriends.php:52
+msgid "No friends to display."
msgstr ""
-#: mod/install.php:439
-msgid "Error, XML PHP module required but not installed."
+#: mod/api.php:80 mod/api.php:106
+msgid "Authorize application connection"
msgstr ""
-#: mod/install.php:451
-msgid ""
-"The web installer needs to be able to create a file called \".htconfig.php\" "
-"in the top folder of your web server and it is unable to do so."
+#: mod/api.php:81
+msgid "Return to your app and insert this Securty Code:"
msgstr ""
-#: mod/install.php:452
-msgid ""
-"This is most often a permission setting, as the web server may not be able "
-"to write files in your folder - even if you can."
+#: mod/api.php:93
+msgid "Please login to continue."
msgstr ""
-#: mod/install.php:453
+#: mod/api.php:108
msgid ""
-"At the end of this procedure, we will give you a text to save in a file "
-"named .htconfig.php in your Friendica top folder."
+"Do you want to authorize this application to access your posts and contacts, "
+"and/or create new posts for you?"
msgstr ""
-#: mod/install.php:454
-msgid ""
-"You can alternatively skip this procedure and perform a manual installation. "
-"Please see the file \"INSTALL.txt\" for instructions."
+#: mod/api.php:110 mod/dfrn_request.php:883 mod/follow.php:151
+#: mod/profiles.php:643 mod/profiles.php:647 mod/profiles.php:673
+#: mod/register.php:253 mod/settings.php:1155 mod/settings.php:1161
+#: mod/settings.php:1168 mod/settings.php:1172 mod/settings.php:1177
+#: mod/settings.php:1182 mod/settings.php:1187 mod/settings.php:1192
+#: mod/settings.php:1218 mod/settings.php:1219 mod/settings.php:1220
+#: mod/settings.php:1221 mod/settings.php:1222
+msgid "No"
msgstr ""
-#: mod/install.php:457
-msgid ".htconfig.php is writable"
+#: mod/apps.php:10 index.php:246
+msgid "You must be logged in to use addons. "
msgstr ""
-#: mod/install.php:467
-msgid ""
-"Friendica uses the Smarty3 template engine to render its web views. Smarty3 "
-"compiles templates to PHP to speed up rendering."
+#: mod/apps.php:15
+msgid "Applications"
msgstr ""
-#: mod/install.php:468
-msgid ""
-"In order to store these compiled templates, the web server needs to have "
-"write access to the directory view/smarty3/ under the Friendica top level "
-"folder."
+#: mod/apps.php:18
+msgid "No installed applications."
msgstr ""
-#: mod/install.php:469
-msgid ""
-"Please ensure that the user that your web server runs as (e.g. www-data) has "
-"write access to this folder."
+#: mod/attach.php:11
+msgid "Item not available."
msgstr ""
-#: mod/install.php:470
-msgid ""
-"Note: as a security measure, you should give the web server write access to "
-"view/smarty3/ only--not the template files (.tpl) that it contains."
+#: mod/attach.php:23
+msgid "Item was not found."
msgstr ""
-#: mod/install.php:473
-msgid "view/smarty3 is writable"
+#: mod/cal.php:149 mod/display.php:339 mod/profile.php:162
+msgid "Access to this profile has been restricted."
msgstr ""
-#: mod/install.php:489
-msgid ""
-"Url rewrite in .htaccess is not working. Check your server configuration."
+#: mod/cal.php:277 mod/events.php:386
+msgid "View"
msgstr ""
-#: mod/install.php:491
-msgid "Url rewrite is working"
+#: mod/cal.php:278 mod/events.php:388
+msgid "Previous"
msgstr ""
-#: mod/install.php:510
-msgid "ImageMagick PHP extension is not installed"
+#: mod/cal.php:279 mod/events.php:389 mod/install.php:203
+msgid "Next"
msgstr ""
-#: mod/install.php:512
-msgid "ImageMagick PHP extension is installed"
+#: mod/cal.php:288 mod/events.php:398
+msgid "list"
msgstr ""
-#: mod/install.php:514
-msgid "ImageMagick supports GIF"
+#: mod/cal.php:298
+msgid "User not found"
msgstr ""
-#: mod/install.php:521
-msgid ""
-"The database configuration file \".htconfig.php\" could not be written. "
-"Please use the enclosed text to create a configuration file in your web "
-"server root."
+#: mod/cal.php:314
+msgid "This calendar format is not supported"
msgstr ""
-#: mod/install.php:546
-msgid "<h1>What next</h1>"
+#: mod/cal.php:316
+msgid "No exportable data found"
msgstr ""
-#: mod/install.php:547
-msgid ""
-"IMPORTANT: You will need to [manually] setup a scheduled task for the poller."
+#: mod/cal.php:331
+msgid "calendar"
msgstr ""
-#: mod/search.php:28 mod/network.php:189
-msgid "Remove term"
+#: mod/common.php:96
+msgid "No contacts in common."
msgstr ""
-#: mod/search.php:96
-msgid "Only logged in users are permitted to perform a search."
+#: mod/common.php:146 mod/contacts.php:901
+msgid "Common Friends"
msgstr ""
-#: mod/search.php:120
-msgid "Too Many Requests"
+#: mod/community.php:23
+msgid "Not available."
msgstr ""
-#: mod/search.php:121
-msgid "Only one search per minute is permitted for not logged in users."
+#: mod/community.php:48 mod/search.php:218
+msgid "No results."
msgstr ""
-#: mod/search.php:221
-#, php-format
-msgid "Items tagged with: %s"
+#: mod/community.php:91
+msgid ""
+"This community stream shows all public posts received by this node. They may "
+"not reflect the opinions of this node’s users."
msgstr ""
-#: mod/search.php:223 mod/contacts.php:827
+#: mod/contacts.php:139
#, php-format
-msgid "Results for: %s"
+msgid "%d contact edited."
+msgid_plural "%d contacts edited."
+msgstr[0] ""
+msgstr[1] ""
+
+#: mod/contacts.php:174 mod/contacts.php:393
+msgid "Could not access contact record."
msgstr ""
-#: mod/unfollow.php:33
-msgid "Contact wasn't found or can't be unfollowed."
+#: mod/contacts.php:188
+msgid "Could not locate selected profile."
msgstr ""
-#: mod/unfollow.php:47
-msgid "Contact unfollowed"
+#: mod/contacts.php:221
+msgid "Contact updated."
msgstr ""
-#: mod/unfollow.php:73
-msgid "You aren't a friend of this contact."
+#: mod/contacts.php:223 mod/dfrn_request.php:596
+msgid "Failed to update contact record."
msgstr ""
-#: mod/unfollow.php:79
-msgid "Unfollowing is currently not supported by your network."
+#: mod/contacts.php:414
+msgid "Contact has been blocked"
msgstr ""
-#: mod/unfollow.php:100 mod/contacts.php:593
-msgid "Disconnect/Unfollow"
+#: mod/contacts.php:414
+msgid "Contact has been unblocked"
msgstr ""
-#: mod/admin.php:100
-msgid "Theme settings updated."
+#: mod/contacts.php:425
+msgid "Contact has been ignored"
msgstr ""
-#: mod/admin.php:172 mod/admin.php:1175
-msgid "Site"
+#: mod/contacts.php:425
+msgid "Contact has been unignored"
msgstr ""
-#: mod/admin.php:173 mod/admin.php:1103 mod/admin.php:1620 mod/admin.php:1636
-msgid "Users"
+#: mod/contacts.php:437
+msgid "Contact has been archived"
msgstr ""
-#: mod/admin.php:174 mod/admin.php:1738 mod/admin.php:1801 mod/settings.php:74
-msgid "Plugins"
+#: mod/contacts.php:437
+msgid "Contact has been unarchived"
msgstr ""
-#: mod/admin.php:175 mod/admin.php:2014 mod/admin.php:2064
-msgid "Themes"
+#: mod/contacts.php:462
+msgid "Drop contact"
msgstr ""
-#: mod/admin.php:176 mod/settings.php:52
-msgid "Additional features"
+#: mod/contacts.php:465 mod/contacts.php:839
+msgid "Do you really want to delete this contact?"
msgstr ""
-#: mod/admin.php:177
-msgid "DB updates"
+#: mod/contacts.php:484
+msgid "Contact has been removed."
msgstr ""
-#: mod/admin.php:178 mod/admin.php:585
-msgid "Inspect Queue"
+#: mod/contacts.php:521
+#, php-format
+msgid "You are mutual friends with %s"
msgstr ""
-#: mod/admin.php:179 mod/admin.php:299
-msgid "Server Blocklist"
+#: mod/contacts.php:525
+#, php-format
+msgid "You are sharing with %s"
msgstr ""
-#: mod/admin.php:180 mod/admin.php:551
-msgid "Federation Statistics"
+#: mod/contacts.php:530
+#, php-format
+msgid "%s is sharing with you"
msgstr ""
-#: mod/admin.php:181 mod/admin.php:376
-msgid "Delete Item"
+#: mod/contacts.php:550
+msgid "Private communications are not available for this contact."
msgstr ""
-#: mod/admin.php:195 mod/admin.php:206 mod/admin.php:2138
-msgid "Logs"
+#: mod/contacts.php:557
+msgid "(Update was successful)"
msgstr ""
-#: mod/admin.php:196 mod/admin.php:2206
-msgid "View Logs"
+#: mod/contacts.php:557
+msgid "(Update was not successful)"
msgstr ""
-#: mod/admin.php:197
-msgid "probe address"
+#: mod/contacts.php:559 mod/contacts.php:1002
+msgid "Suggest friends"
msgstr ""
-#: mod/admin.php:198
-msgid "check webfinger"
+#: mod/contacts.php:563
+#, php-format
+msgid "Network type: %s"
msgstr ""
-#: mod/admin.php:205
-msgid "Plugin Features"
+#: mod/contacts.php:576
+msgid "Communications lost with this contact!"
msgstr ""
-#: mod/admin.php:207
-msgid "diagnostics"
+#: mod/contacts.php:580
+msgid "Fetch further information for feeds"
msgstr ""
-#: mod/admin.php:208
-msgid "User registrations waiting for confirmation"
+#: mod/contacts.php:582
+msgid ""
+"Fetch information like preview pictures, title and teaser from the feed "
+"item. You can activate this if the feed doesn't contain much text. Keywords "
+"are taken from the meta header in the feed item and are posted as hash tags."
+msgstr ""
+
+#: mod/contacts.php:584
+msgid "Fetch information"
+msgstr ""
+
+#: mod/contacts.php:585
+msgid "Fetch keywords"
+msgstr ""
+
+#: mod/contacts.php:586
+msgid "Fetch information and keywords"
msgstr ""
-#: mod/admin.php:290
-msgid "The blocked domain"
+#: mod/contacts.php:600 mod/unfollow.php:99
+msgid "Disconnect/Unfollow"
msgstr ""
-#: mod/admin.php:291 mod/admin.php:304
-msgid "The reason why you blocked this domain."
+#: mod/contacts.php:610
+msgid "Contact"
msgstr ""
-#: mod/admin.php:292
-msgid "Delete domain"
+#: mod/contacts.php:613
+msgid "Profile Visibility"
msgstr ""
-#: mod/admin.php:292
-msgid "Check to delete this entry from the blocklist"
+#: mod/contacts.php:614
+#, php-format
+msgid ""
+"Please choose the profile you would like to display to %s when viewing your "
+"profile securely."
msgstr ""
-#: mod/admin.php:298 mod/admin.php:375 mod/admin.php:550 mod/admin.php:584
-#: mod/admin.php:681 mod/admin.php:1174 mod/admin.php:1619 mod/admin.php:1737
-#: mod/admin.php:1800 mod/admin.php:2013 mod/admin.php:2063 mod/admin.php:2137
-#: mod/admin.php:2205
-msgid "Administration"
+#: mod/contacts.php:615
+msgid "Contact Information / Notes"
msgstr ""
-#: mod/admin.php:300
-msgid ""
-"This page can be used to define a black list of servers from the federated "
-"network that are not allowed to interact with your node. For all entered "
-"domains you should also give a reason why you have blocked the remote server."
+#: mod/contacts.php:616
+msgid "Their personal note"
msgstr ""
-#: mod/admin.php:301
-msgid ""
-"The list of blocked servers will be made publically available on the /"
-"friendica page so that your users and people investigating communication "
-"problems can find the reason easily."
+#: mod/contacts.php:618
+msgid "Edit contact notes"
msgstr ""
-#: mod/admin.php:302
-msgid "Add new entry to block list"
+#: mod/contacts.php:623 mod/contacts.php:968 mod/nogroup.php:44
+#: mod/viewcontacts.php:107
+#, php-format
+msgid "Visit %s's profile [%s]"
msgstr ""
-#: mod/admin.php:303
-msgid "Server Domain"
+#: mod/contacts.php:624
+msgid "Block/Unblock contact"
msgstr ""
-#: mod/admin.php:303
-msgid ""
-"The domain of the new server to add to the block list. Do not include the "
-"protocol."
+#: mod/contacts.php:625
+msgid "Ignore contact"
msgstr ""
-#: mod/admin.php:304
-msgid "Block reason"
+#: mod/contacts.php:626
+msgid "Repair URL settings"
msgstr ""
-#: mod/admin.php:305
-msgid "Add Entry"
+#: mod/contacts.php:627
+msgid "View conversations"
msgstr ""
-#: mod/admin.php:306
-msgid "Save changes to the blocklist"
+#: mod/contacts.php:633
+msgid "Last update:"
msgstr ""
-#: mod/admin.php:307
-msgid "Current Entries in the Blocklist"
+#: mod/contacts.php:635
+msgid "Update public posts"
msgstr ""
-#: mod/admin.php:310
-msgid "Delete entry from blocklist"
+#: mod/contacts.php:637 mod/contacts.php:1012
+msgid "Update now"
msgstr ""
-#: mod/admin.php:313
-msgid "Delete entry from blocklist?"
+#: mod/contacts.php:643 mod/contacts.php:844 mod/contacts.php:1029
+msgid "Unignore"
msgstr ""
-#: mod/admin.php:338
-msgid "Server added to blocklist."
+#: mod/contacts.php:643 mod/contacts.php:844 mod/contacts.php:1029
+#: mod/notifications.php:64 mod/notifications.php:183 mod/notifications.php:267
+msgid "Ignore"
msgstr ""
-#: mod/admin.php:354
-msgid "Site blocklist updated."
+#: mod/contacts.php:647
+msgid "Currently blocked"
msgstr ""
-#: mod/admin.php:377
-msgid "Delete this Item"
+#: mod/contacts.php:648
+msgid "Currently ignored"
msgstr ""
-#: mod/admin.php:378
-msgid ""
-"On this page you can delete an item from your node. If the item is a top "
-"level posting, the entire thread will be deleted."
+#: mod/contacts.php:649
+msgid "Currently archived"
msgstr ""
-#: mod/admin.php:379
-msgid ""
-"You need to know the GUID of the item. You can find it e.g. by looking at "
-"the display URL. The last part of http://example.com/display/123456 is the "
-"GUID, here 123456."
+#: mod/contacts.php:650
+msgid "Awaiting connection acknowledge"
msgstr ""
-#: mod/admin.php:380
-msgid "GUID"
+#: mod/contacts.php:651 mod/notifications.php:176 mod/notifications.php:255
+msgid "Hide this contact from others"
msgstr ""
-#: mod/admin.php:380
-msgid "The GUID of the item you want to delete."
+#: mod/contacts.php:651
+msgid ""
+"Replies/likes to your public posts <strong>may</strong> still be visible"
msgstr ""
-#: mod/admin.php:417
-msgid "Item marked for deletion."
+#: mod/contacts.php:652
+msgid "Notification for new posts"
msgstr ""
-#: mod/admin.php:481
-msgid "unknown"
+#: mod/contacts.php:652
+msgid "Send a notification of every new post of this contact"
msgstr ""
-#: mod/admin.php:544
-msgid ""
-"This page offers you some numbers to the known part of the federated social "
-"network your Friendica node is part of. These numbers are not complete but "
-"only reflect the part of the network your node is aware of."
+#: mod/contacts.php:655
+msgid "Blacklisted keywords"
msgstr ""
-#: mod/admin.php:545
+#: mod/contacts.php:655
msgid ""
-"The <em>Auto Discovered Contact Directory</em> feature is not enabled, it "
-"will improve the data displayed here."
+"Comma separated list of keywords that should not be converted to hashtags, "
+"when \"Fetch information and keywords\" is selected"
msgstr ""
-#: mod/admin.php:557
-#, php-format
-msgid "Currently this node is aware of %d nodes from the following platforms:"
+#: mod/contacts.php:662 mod/follow.php:167 mod/notifications.php:259
+#: mod/unfollow.php:121
+msgid "Profile URL"
msgstr ""
-#: mod/admin.php:587
-msgid "ID"
+#: mod/contacts.php:673
+msgid "Actions"
msgstr ""
-#: mod/admin.php:588
-msgid "Recipient Name"
+#: mod/contacts.php:676
+msgid "Contact Settings"
msgstr ""
-#: mod/admin.php:589
-msgid "Recipient Profile"
+#: mod/contacts.php:722
+msgid "Suggestions"
msgstr ""
-#: mod/admin.php:591
-msgid "Created"
+#: mod/contacts.php:725
+msgid "Suggest potential friends"
msgstr ""
-#: mod/admin.php:592
-msgid "Last Tried"
+#: mod/contacts.php:730 mod/group.php:214
+msgid "All Contacts"
msgstr ""
-#: mod/admin.php:593
-msgid ""
-"This page lists the content of the queue for outgoing postings. These are "
-"postings the initial delivery failed for. They will be resend later and "
-"eventually deleted if the delivery fails permanently."
+#: mod/contacts.php:733
+msgid "Show all contacts"
msgstr ""
-#: mod/admin.php:617
-#, php-format
-msgid ""
-"Your DB still runs with MyISAM tables. You should change the engine type to "
-"InnoDB. As Friendica will use InnoDB only features in the future, you should "
-"change this! See <a href=\"%s\">here</a> for a guide that may be helpful "
-"converting the table engines. You may also use the command <tt>php include/"
-"dbstructure.php toinnodb</tt> of your Friendica installation for an "
-"automatic conversion.<br />"
+#: mod/contacts.php:738
+msgid "Unblocked"
msgstr ""
-#: mod/admin.php:624
-#, php-format
-msgid ""
-"There is a new version of Friendica available for download. Your current "
-"version is %1$s, upstream version is %2$s"
+#: mod/contacts.php:741
+msgid "Only show unblocked contacts"
msgstr ""
-#: mod/admin.php:635
-msgid ""
-"The database update failed. Please run \"php include/dbstructure.php update"
-"\" from the command line and have a look at the errors that might appear."
+#: mod/contacts.php:747
+msgid "Blocked"
msgstr ""
-#: mod/admin.php:641
-msgid "The worker was never executed. Please check your database structure!"
+#: mod/contacts.php:750
+msgid "Only show blocked contacts"
msgstr ""
-#: mod/admin.php:644
-#, php-format
-msgid ""
-"The last worker execution was on %s UTC. This is older than one hour. Please "
-"check your crontab settings."
+#: mod/contacts.php:756
+msgid "Ignored"
msgstr ""
-#: mod/admin.php:649 mod/admin.php:1569
-msgid "Normal Account"
+#: mod/contacts.php:759
+msgid "Only show ignored contacts"
msgstr ""
-#: mod/admin.php:650 mod/admin.php:1570
-msgid "Automatic Follower Account"
+#: mod/contacts.php:765
+msgid "Archived"
msgstr ""
-#: mod/admin.php:651 mod/admin.php:1571
-msgid "Public Forum Account"
+#: mod/contacts.php:768
+msgid "Only show archived contacts"
msgstr ""
-#: mod/admin.php:652 mod/admin.php:1572
-msgid "Automatic Friend Account"
+#: mod/contacts.php:774
+msgid "Hidden"
msgstr ""
-#: mod/admin.php:653
-msgid "Blog Account"
+#: mod/contacts.php:777
+msgid "Only show hidden contacts"
msgstr ""
-#: mod/admin.php:654
-msgid "Private Forum Account"
+#: mod/contacts.php:834
+msgid "Search your contacts"
msgstr ""
-#: mod/admin.php:676
-msgid "Message queues"
+#: mod/contacts.php:835 mod/search.php:226
+#, php-format
+msgid "Results for: %s"
msgstr ""
-#: mod/admin.php:682
-msgid "Summary"
+#: mod/contacts.php:842 mod/settings.php:163 mod/settings.php:722
+msgid "Update"
msgstr ""
-#: mod/admin.php:684
-msgid "Registered users"
+#: mod/contacts.php:845 mod/contacts.php:1037
+msgid "Archive"
msgstr ""
-#: mod/admin.php:686
-msgid "Pending registrations"
+#: mod/contacts.php:845 mod/contacts.php:1037
+msgid "Unarchive"
msgstr ""
-#: mod/admin.php:687
-msgid "Version"
+#: mod/contacts.php:848
+msgid "Batch Actions"
msgstr ""
-#: mod/admin.php:692
-msgid "Active plugins"
+#: mod/contacts.php:894
+msgid "View all contacts"
msgstr ""
-#: mod/admin.php:722
-msgid "Can not parse base url. Must have at least <scheme>://<domain>"
+#: mod/contacts.php:904
+msgid "View all common friends"
msgstr ""
-#: mod/admin.php:1029
-msgid "Site settings updated."
+#: mod/contacts.php:911
+msgid "Advanced Contact Settings"
msgstr ""
-#: mod/admin.php:1057 mod/settings.php:948
-msgid "No special theme for mobile devices"
+#: mod/contacts.php:945
+msgid "Mutual Friendship"
msgstr ""
-#: mod/admin.php:1086
-msgid "No community page"
+#: mod/contacts.php:949
+msgid "is a fan of yours"
msgstr ""
-#: mod/admin.php:1087
-msgid "Public postings from users of this site"
+#: mod/contacts.php:953
+msgid "you are a fan of"
msgstr ""
-#: mod/admin.php:1088
-msgid "Global community page"
+#: mod/contacts.php:969 mod/nogroup.php:45
+msgid "Edit contact"
msgstr ""
-#: mod/admin.php:1093 mod/contacts.php:552
-msgid "Never"
+#: mod/contacts.php:1023
+msgid "Toggle Blocked status"
msgstr ""
-#: mod/admin.php:1094
-msgid "At post arrival"
+#: mod/contacts.php:1031
+msgid "Toggle Ignored status"
msgstr ""
-#: mod/admin.php:1102 mod/contacts.php:579
-msgid "Disabled"
+#: mod/contacts.php:1039
+msgid "Toggle Archive status"
msgstr ""
-#: mod/admin.php:1104
-msgid "Users, Global Contacts"
+#: mod/contacts.php:1047
+msgid "Delete contact"
msgstr ""
-#: mod/admin.php:1105
-msgid "Users, Global Contacts/fallback"
+#: mod/crepair.php:95
+msgid "Contact settings applied."
msgstr ""
-#: mod/admin.php:1109
-msgid "One month"
+#: mod/crepair.php:97
+msgid "Contact update failed."
msgstr ""
-#: mod/admin.php:1110
-msgid "Three months"
+#: mod/crepair.php:122 mod/dfrn_confirm.php:134 mod/fsuggest.php:24
+#: mod/fsuggest.php:98
+msgid "Contact not found."
msgstr ""
-#: mod/admin.php:1111
-msgid "Half a year"
+#: mod/crepair.php:128
+msgid ""
+"<strong>WARNING: This is highly advanced</strong> and if you enter incorrect "
+"information your communications with this contact may stop working."
msgstr ""
-#: mod/admin.php:1112
-msgid "One year"
+#: mod/crepair.php:129
+msgid ""
+"Please use your browser 'Back' button <strong>now</strong> if you are "
+"uncertain what to do on this page."
msgstr ""
-#: mod/admin.php:1117
-msgid "Multi user instance"
+#: mod/crepair.php:142 mod/crepair.php:144
+msgid "No mirroring"
msgstr ""
-#: mod/admin.php:1140
-msgid "Closed"
+#: mod/crepair.php:142
+msgid "Mirror as forwarded posting"
msgstr ""
-#: mod/admin.php:1141
-msgid "Requires approval"
+#: mod/crepair.php:142 mod/crepair.php:144
+msgid "Mirror as my own posting"
msgstr ""
-#: mod/admin.php:1142
-msgid "Open"
+#: mod/crepair.php:158
+msgid "Return to contact editor"
msgstr ""
-#: mod/admin.php:1146
-msgid "No SSL policy, links will track page SSL state"
+#: mod/crepair.php:160
+msgid "Refetch contact data"
msgstr ""
-#: mod/admin.php:1147
-msgid "Force all links to use SSL"
+#: mod/crepair.php:164
+msgid "Remote Self"
msgstr ""
-#: mod/admin.php:1148
-msgid "Self-signed certificate, use SSL for local links only (discouraged)"
+#: mod/crepair.php:167
+msgid "Mirror postings from this contact"
msgstr ""
-#: mod/admin.php:1152
-msgid "Don't check"
+#: mod/crepair.php:169
+msgid ""
+"Mark this contact as remote_self, this will cause friendica to repost new "
+"entries from this contact."
msgstr ""
-#: mod/admin.php:1153
-msgid "check the stable version"
+#: mod/crepair.php:174
+msgid "Account Nickname"
msgstr ""
-#: mod/admin.php:1154
-msgid "check the development version"
+#: mod/crepair.php:175
+msgid "@Tagname - overrides Name/Nickname"
msgstr ""
-#: mod/admin.php:1176 mod/admin.php:1802 mod/admin.php:2065 mod/admin.php:2139
-#: mod/admin.php:2292 mod/settings.php:691 mod/settings.php:802
-#: mod/settings.php:851 mod/settings.php:913 mod/settings.php:1010
-#: mod/settings.php:1258
-msgid "Save Settings"
+#: mod/crepair.php:176
+msgid "Account URL"
msgstr ""
-#: mod/admin.php:1177
-msgid "Republish users to directory"
+#: mod/crepair.php:177
+msgid "Friend Request URL"
msgstr ""
-#: mod/admin.php:1178 mod/register.php:277
-msgid "Registration"
+#: mod/crepair.php:178
+msgid "Friend Confirm URL"
msgstr ""
-#: mod/admin.php:1179
-msgid "File upload"
+#: mod/crepair.php:179
+msgid "Notification Endpoint URL"
msgstr ""
-#: mod/admin.php:1180
-msgid "Policies"
+#: mod/crepair.php:180
+msgid "Poll/Feed URL"
msgstr ""
-#: mod/admin.php:1182
-msgid "Auto Discovered Contact Directory"
+#: mod/crepair.php:181
+msgid "New photo from this URL"
msgstr ""
-#: mod/admin.php:1183
-msgid "Performance"
+#: mod/delegate.php:102
+msgid "No potential page delegates located."
msgstr ""
-#: mod/admin.php:1184
-msgid "Worker"
+#: mod/delegate.php:133
+msgid ""
+"Delegates are able to manage all aspects of this account/page except for "
+"basic account settings. Please do not delegate your personal account to "
+"anybody that you do not trust completely."
msgstr ""
-#: mod/admin.php:1185
-msgid ""
-"Relocate - WARNING: advanced function. Could make this server unreachable."
+#: mod/delegate.php:134
+msgid "Existing Page Managers"
msgstr ""
-#: mod/admin.php:1188
-msgid "Site name"
+#: mod/delegate.php:136
+msgid "Existing Page Delegates"
msgstr ""
-#: mod/admin.php:1189
-msgid "Host name"
+#: mod/delegate.php:138
+msgid "Potential Delegates"
msgstr ""
-#: mod/admin.php:1190
-msgid "Sender Email"
+#: mod/delegate.php:140 mod/tagrm.php:99
+msgid "Remove"
msgstr ""
-#: mod/admin.php:1190
-msgid ""
-"The email address your server shall use to send notification emails from."
+#: mod/delegate.php:141
+msgid "Add"
msgstr ""
-#: mod/admin.php:1191
-msgid "Banner/Logo"
+#: mod/delegate.php:142
+msgid "No entries."
msgstr ""
-#: mod/admin.php:1192
-msgid "Shortcut icon"
+#: mod/dfrn_confirm.php:78 mod/profiles.php:29 mod/profiles.php:139
+#: mod/profiles.php:186 mod/profiles.php:622
+msgid "Profile not found."
msgstr ""
-#: mod/admin.php:1192
-msgid "Link to an icon that will be used for browsers."
+#: mod/dfrn_confirm.php:135
+msgid ""
+"This may occasionally happen if contact was requested by both persons and it "
+"has already been approved."
msgstr ""
-#: mod/admin.php:1193
-msgid "Touch icon"
+#: mod/dfrn_confirm.php:252
+msgid "Response from remote site was not understood."
msgstr ""
-#: mod/admin.php:1193
-msgid "Link to an icon that will be used for tablets and mobiles."
+#: mod/dfrn_confirm.php:261 mod/dfrn_confirm.php:266
+msgid "Unexpected response from remote site: "
msgstr ""
-#: mod/admin.php:1194
-msgid "Additional Info"
+#: mod/dfrn_confirm.php:275
+msgid "Confirmation completed successfully."
msgstr ""
-#: mod/admin.php:1194
-#, php-format
-msgid ""
-"For public servers: you can add additional information here that will be "
-"listed at %s/siteinfo."
+#: mod/dfrn_confirm.php:277 mod/dfrn_confirm.php:291 mod/dfrn_confirm.php:298
+msgid "Remote site reported: "
msgstr ""
-#: mod/admin.php:1195
-msgid "System language"
+#: mod/dfrn_confirm.php:289
+msgid "Temporary failure. Please wait and try again."
msgstr ""
-#: mod/admin.php:1196
-msgid "System theme"
+#: mod/dfrn_confirm.php:296
+msgid "Introduction failed or was revoked."
msgstr ""
-#: mod/admin.php:1196
-msgid ""
-"Default system theme - may be over-ridden by user profiles - <a href='#' "
-"id='cnftheme'>change theme settings</a>"
+#: mod/dfrn_confirm.php:425
+msgid "Unable to set contact photo."
msgstr ""
-#: mod/admin.php:1197
-msgid "Mobile system theme"
+#: mod/dfrn_confirm.php:565
+#, php-format
+msgid "No user record found for '%s' "
msgstr ""
-#: mod/admin.php:1197
-msgid "Theme for mobile devices"
+#: mod/dfrn_confirm.php:575
+msgid "Our site encryption key is apparently messed up."
msgstr ""
-#: mod/admin.php:1198
-msgid "SSL link policy"
+#: mod/dfrn_confirm.php:586
+msgid "Empty site URL was provided or URL could not be decrypted by us."
msgstr ""
-#: mod/admin.php:1198
-msgid "Determines whether generated links should be forced to use SSL"
+#: mod/dfrn_confirm.php:608
+msgid "Contact record was not found for you on our site."
msgstr ""
-#: mod/admin.php:1199
-msgid "Force SSL"
+#: mod/dfrn_confirm.php:622
+#, php-format
+msgid "Site public key not available in contact record for URL %s."
msgstr ""
-#: mod/admin.php:1199
+#: mod/dfrn_confirm.php:642
msgid ""
-"Force all Non-SSL requests to SSL - Attention: on some systems it could lead "
-"to endless loops."
+"The ID provided by your system is a duplicate on our system. It should work "
+"if you try again."
msgstr ""
-#: mod/admin.php:1200
-msgid "Hide help entry from navigation menu"
+#: mod/dfrn_confirm.php:653
+msgid "Unable to set your contact credentials on our system."
msgstr ""
-#: mod/admin.php:1200
-msgid ""
-"Hides the menu entry for the Help pages from the navigation menu. You can "
-"still access it calling /help directly."
+#: mod/dfrn_confirm.php:715
+msgid "Unable to update your contact profile details on our system"
msgstr ""
-#: mod/admin.php:1201
-msgid "Single user instance"
+#: mod/dfrn_confirm.php:787
+#, php-format
+msgid "%1$s has joined %2$s"
msgstr ""
-#: mod/admin.php:1201
-msgid "Make this instance multi-user or single-user for the named user"
+#: mod/dfrn_poll.php:118 mod/dfrn_poll.php:554
+#, php-format
+msgid "%1$s welcomes %2$s"
msgstr ""
-#: mod/admin.php:1202
-msgid "Maximum image size"
+#: mod/dfrn_request.php:106
+msgid "This introduction has already been accepted."
msgstr ""
-#: mod/admin.php:1202
-msgid ""
-"Maximum size in bytes of uploaded images. Default is 0, which means no "
-"limits."
+#: mod/dfrn_request.php:129 mod/dfrn_request.php:531
+msgid "Profile location is not valid or does not contain profile information."
msgstr ""
-#: mod/admin.php:1203
-msgid "Maximum image length"
+#: mod/dfrn_request.php:134 mod/dfrn_request.php:536
+msgid "Warning: profile location has no identifiable owner name."
msgstr ""
-#: mod/admin.php:1203
-msgid ""
-"Maximum length in pixels of the longest side of uploaded images. Default is "
-"-1, which means no limits."
+#: mod/dfrn_request.php:137 mod/dfrn_request.php:539
+msgid "Warning: profile location has no profile photo."
msgstr ""
-#: mod/admin.php:1204
-msgid "JPEG image quality"
-msgstr ""
+#: mod/dfrn_request.php:141 mod/dfrn_request.php:543
+#, php-format
+msgid "%d required parameter was not found at the given location"
+msgid_plural "%d required parameters were not found at the given location"
+msgstr[0] ""
+msgstr[1] ""
-#: mod/admin.php:1204
-msgid ""
-"Uploaded JPEGS will be saved at this quality setting [0-100]. Default is "
-"100, which is full quality."
+#: mod/dfrn_request.php:185
+msgid "Introduction complete."
msgstr ""
-#: mod/admin.php:1206
-msgid "Register policy"
+#: mod/dfrn_request.php:230
+msgid "Unrecoverable protocol error."
msgstr ""
-#: mod/admin.php:1207
-msgid "Maximum Daily Registrations"
+#: mod/dfrn_request.php:258
+msgid "Profile unavailable."
msgstr ""
-#: mod/admin.php:1207
-msgid ""
-"If registration is permitted above, this sets the maximum number of new user "
-"registrations to accept per day. If register is set to closed, this setting "
-"has no effect."
+#: mod/dfrn_request.php:285
+#, php-format
+msgid "%s has received too many connection requests today."
msgstr ""
-#: mod/admin.php:1208
-msgid "Register text"
+#: mod/dfrn_request.php:286
+msgid "Spam protection measures have been invoked."
msgstr ""
-#: mod/admin.php:1208
-msgid "Will be displayed prominently on the registration page."
+#: mod/dfrn_request.php:287
+msgid "Friends are advised to please try again in 24 hours."
msgstr ""
-#: mod/admin.php:1209
-msgid "Accounts abandoned after x days"
+#: mod/dfrn_request.php:349
+msgid "Invalid locator"
msgstr ""
-#: mod/admin.php:1209
-msgid ""
-"Will not waste system resources polling external sites for abandonded "
-"accounts. Enter 0 for no time limit."
+#: mod/dfrn_request.php:358
+msgid "Invalid email address."
msgstr ""
-#: mod/admin.php:1210
-msgid "Allowed friend domains"
+#: mod/dfrn_request.php:383
+msgid "This account has not been configured for email. Request failed."
msgstr ""
-#: mod/admin.php:1210
-msgid ""
-"Comma separated list of domains which are allowed to establish friendships "
-"with this site. Wildcards are accepted. Empty to allow any domains"
+#: mod/dfrn_request.php:486
+msgid "You have already introduced yourself here."
msgstr ""
-#: mod/admin.php:1211
-msgid "Allowed email domains"
+#: mod/dfrn_request.php:490
+#, php-format
+msgid "Apparently you are already friends with %s."
msgstr ""
-#: mod/admin.php:1211
-msgid ""
-"Comma separated list of domains which are allowed in email addresses for "
-"registrations to this site. Wildcards are accepted. Empty to allow any "
-"domains"
+#: mod/dfrn_request.php:511
+msgid "Invalid profile URL."
msgstr ""
-#: mod/admin.php:1212
-msgid "Block public"
+#: mod/dfrn_request.php:617
+msgid "Your introduction has been sent."
msgstr ""
-#: mod/admin.php:1212
+#: mod/dfrn_request.php:659
msgid ""
-"Check to block public access to all otherwise public personal pages on this "
-"site unless you are currently logged in."
+"Remote subscription can't be done for your network. Please subscribe "
+"directly on your system."
msgstr ""
-#: mod/admin.php:1213
-msgid "Force publish"
+#: mod/dfrn_request.php:680
+msgid "Please login to confirm introduction."
msgstr ""
-#: mod/admin.php:1213
+#: mod/dfrn_request.php:690
msgid ""
-"Check to force all profiles on this site to be listed in the site directory."
+"Incorrect identity currently logged in. Please login to <strong>this</"
+"strong> profile."
msgstr ""
-#: mod/admin.php:1214
-msgid "Global directory URL"
+#: mod/dfrn_request.php:704 mod/dfrn_request.php:721
+msgid "Confirm"
msgstr ""
-#: mod/admin.php:1214
-msgid ""
-"URL to the global directory. If this is not set, the global directory is "
-"completely unavailable to the application."
+#: mod/dfrn_request.php:716
+msgid "Hide this contact"
msgstr ""
-#: mod/admin.php:1215
-msgid "Allow threaded items"
+#: mod/dfrn_request.php:719
+#, php-format
+msgid "Welcome home %s."
msgstr ""
-#: mod/admin.php:1215
-msgid "Allow infinite level threading for items on this site."
+#: mod/dfrn_request.php:720
+#, php-format
+msgid "Please confirm your introduction/connection request to %s."
msgstr ""
-#: mod/admin.php:1216
-msgid "Private posts by default for new users"
+#: mod/dfrn_request.php:851
+msgid ""
+"Please enter your 'Identity Address' from one of the following supported "
+"communications networks:"
msgstr ""
-#: mod/admin.php:1216
+#: mod/dfrn_request.php:875
+#, php-format
msgid ""
-"Set default post permissions for all new members to the default privacy "
-"group rather than public."
+"If you are not yet a member of the free social web, <a href=\"%s/siteinfo"
+"\">follow this link to find a public Friendica site and join us today</a>."
msgstr ""
-#: mod/admin.php:1217
-msgid "Don't include post content in email notifications"
+#: mod/dfrn_request.php:880
+msgid "Friend/Connection Request"
msgstr ""
-#: mod/admin.php:1217
+#: mod/dfrn_request.php:881
msgid ""
-"Don't include the content of a post/comment/private message/etc. in the "
-"email notifications that are sent out from this site, as a privacy measure."
+"Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, "
+"testuser@identi.ca"
msgstr ""
-#: mod/admin.php:1218
-msgid "Disallow public access to addons listed in the apps menu."
+#: mod/dfrn_request.php:882 mod/follow.php:150
+msgid "Please answer the following:"
msgstr ""
-#: mod/admin.php:1218
-msgid ""
-"Checking this box will restrict addons listed in the apps menu to members "
-"only."
+#: mod/dfrn_request.php:883 mod/follow.php:151
+#, php-format
+msgid "Does %s know you?"
msgstr ""
-#: mod/admin.php:1219
-msgid "Don't embed private images in posts"
+#: mod/dfrn_request.php:887 mod/follow.php:152
+msgid "Add a personal note:"
msgstr ""
-#: mod/admin.php:1219
+#: mod/dfrn_request.php:890
+msgid "StatusNet/Federated Social Web"
+msgstr ""
+
+#: mod/dfrn_request.php:892
+#, php-format
msgid ""
-"Don't replace locally-hosted private photos in posts with an embedded copy "
-"of the image. This means that contacts who receive posts containing private "
-"photos will have to authenticate and load each image, which may take a while."
+" - please do not use this form. Instead, enter %s into your Diaspora search "
+"bar."
msgstr ""
-#: mod/admin.php:1220
-msgid "Allow Users to set remote_self"
+#: mod/dfrn_request.php:893 mod/follow.php:158 mod/unfollow.php:112
+msgid "Your Identity Address:"
msgstr ""
-#: mod/admin.php:1220
-msgid ""
-"With checking this, every user is allowed to mark every contact as a "
-"remote_self in the repair contact dialog. Setting this flag on a contact "
-"causes mirroring every posting of that contact in the users stream."
+#: mod/dfrn_request.php:896 mod/follow.php:64 mod/unfollow.php:64
+msgid "Submit Request"
+msgstr ""
+
+#: mod/directory.php:191 view/theme/vier/theme.php:197
+msgid "Global Directory"
msgstr ""
-#: mod/admin.php:1221
-msgid "Block multiple registrations"
+#: mod/directory.php:193
+msgid "Find on this site"
msgstr ""
-#: mod/admin.php:1221
-msgid "Disallow users to register additional accounts for use as pages."
+#: mod/directory.php:195
+msgid "Results for:"
msgstr ""
-#: mod/admin.php:1222
-msgid "OpenID support"
+#: mod/directory.php:197
+msgid "Site Directory"
msgstr ""
-#: mod/admin.php:1222
-msgid "OpenID support for registration and logins."
+#: mod/directory.php:204
+msgid "No entries (some entries may be hidden)."
msgstr ""
-#: mod/admin.php:1223
-msgid "Fullname check"
+#: mod/dirfind.php:45
+#, php-format
+msgid "People Search - %s"
msgstr ""
-#: mod/admin.php:1223
-msgid ""
-"Force users to register with a space between firstname and lastname in Full "
-"name, as an antispam measure"
+#: mod/dirfind.php:56
+#, php-format
+msgid "Forum Search - %s"
msgstr ""
-#: mod/admin.php:1224
-msgid "Community Page Style"
+#: mod/dirfind.php:253 mod/match.php:122
+msgid "No matches"
msgstr ""
-#: mod/admin.php:1224
-msgid ""
-"Type of community page to show. 'Global community' shows every public "
-"posting from an open distributed network that arrived on this server."
+#: mod/display.php:482
+msgid "Item has been removed."
msgstr ""
-#: mod/admin.php:1225
-msgid "Posts per user on community page"
+#: mod/editpost.php:22 mod/editpost.php:32
+msgid "Item not found"
msgstr ""
-#: mod/admin.php:1225
-msgid ""
-"The maximum number of posts per user on the community page. (Not valid for "
-"'Global Community')"
+#: mod/editpost.php:37
+msgid "Edit post"
msgstr ""
-#: mod/admin.php:1226
-msgid "Enable OStatus support"
+#: mod/events.php:100 mod/events.php:102
+msgid "Event can not end before it has started."
msgstr ""
-#: mod/admin.php:1226
-msgid ""
-"Provide built-in OStatus (StatusNet, GNU Social etc.) compatibility. All "
-"communications in OStatus are public, so privacy warnings will be "
-"occasionally displayed."
+#: mod/events.php:109 mod/events.php:111
+msgid "Event title and start time are required."
msgstr ""
-#: mod/admin.php:1227
-msgid "Only import OStatus threads from our contacts"
+#: mod/events.php:387
+msgid "Create New Event"
msgstr ""
-#: mod/admin.php:1227
-msgid ""
-"Normally we import every content from our OStatus contacts. With this option "
-"we only store threads that are started by a contact that is known on our "
-"system."
+#: mod/events.php:507
+msgid "Event details"
msgstr ""
-#: mod/admin.php:1228
-msgid "OStatus support can only be enabled if threading is enabled."
+#: mod/events.php:508
+msgid "Starting date and Title are required."
msgstr ""
-#: mod/admin.php:1230
-msgid ""
-"Diaspora support can't be enabled because Friendica was installed into a sub "
-"directory."
+#: mod/events.php:509 mod/events.php:510
+msgid "Event Starts:"
msgstr ""
-#: mod/admin.php:1231
-msgid "Enable Diaspora support"
+#: mod/events.php:509 mod/events.php:521 mod/profiles.php:712
+msgid "Required"
msgstr ""
-#: mod/admin.php:1231
-msgid "Provide built-in Diaspora network compatibility."
+#: mod/events.php:511 mod/events.php:527
+msgid "Finish date/time is not known or not relevant"
msgstr ""
-#: mod/admin.php:1232
-msgid "Only allow Friendica contacts"
+#: mod/events.php:513 mod/events.php:514
+msgid "Event Finishes:"
msgstr ""
-#: mod/admin.php:1232
-msgid ""
-"All contacts must use Friendica protocols. All other built-in communication "
-"protocols disabled."
+#: mod/events.php:515 mod/events.php:528
+msgid "Adjust for viewer timezone"
msgstr ""
-#: mod/admin.php:1233
-msgid "Verify SSL"
+#: mod/events.php:517
+msgid "Description:"
msgstr ""
-#: mod/admin.php:1233
-msgid ""
-"If you wish, you can turn on strict certificate checking. This will mean you "
-"cannot connect (at all) to self-signed SSL sites."
+#: mod/events.php:521 mod/events.php:523
+msgid "Title:"
msgstr ""
-#: mod/admin.php:1234
-msgid "Proxy user"
+#: mod/events.php:524 mod/events.php:525
+msgid "Share this event"
msgstr ""
-#: mod/admin.php:1235
-msgid "Proxy URL"
+#: mod/events.php:554
+msgid "Failed to remove event"
msgstr ""
-#: mod/admin.php:1236
-msgid "Network timeout"
+#: mod/events.php:556
+msgid "Event removed"
msgstr ""
-#: mod/admin.php:1236
-msgid "Value is in seconds. Set to 0 for unlimited (not recommended)."
+#: mod/fbrowser.php:125
+msgid "Files"
msgstr ""
-#: mod/admin.php:1237
-msgid "Maximum Load Average"
+#: mod/filer.php:32
+msgid "- select -"
msgstr ""
-#: mod/admin.php:1237
-msgid ""
-"Maximum system load before delivery and poll processes are deferred - "
-"default 50."
+#: mod/follow.php:43
+msgid "Contact added"
msgstr ""
-#: mod/admin.php:1238
-msgid "Maximum Load Average (Frontend)"
+#: mod/follow.php:75
+msgid "You already added this contact."
msgstr ""
-#: mod/admin.php:1238
-msgid "Maximum system load before the frontend quits service - default 50."
+#: mod/follow.php:84
+msgid "Diaspora support isn't enabled. Contact can't be added."
msgstr ""
-#: mod/admin.php:1239
-msgid "Minimal Memory"
+#: mod/follow.php:91
+msgid "OStatus support is disabled. Contact can't be added."
msgstr ""
-#: mod/admin.php:1239
-msgid ""
-"Minimal free memory in MB for the poller. Needs access to /proc/meminfo - "
-"default 0 (deactivated)."
+#: mod/follow.php:98
+msgid "The network type couldn't be detected. Contact can't be added."
msgstr ""
-#: mod/admin.php:1240
-msgid "Maximum table size for optimization"
+#: mod/friendica.php:71
+msgid "This is Friendica, version"
msgstr ""
-#: mod/admin.php:1240
+#: mod/friendica.php:72
+msgid "running at web location"
+msgstr ""
+
+#: mod/friendica.php:76
msgid ""
-"Maximum table size (in MB) for the automatic optimization - default 100 MB. "
-"Enter -1 to disable it."
+"Please visit <a href=\"https://friendi.ca\">Friendi.ca</a> to learn more "
+"about the Friendica project."
msgstr ""
-#: mod/admin.php:1241
-msgid "Minimum level of fragmentation"
+#: mod/friendica.php:80
+msgid "Bug reports and issues: please visit"
msgstr ""
-#: mod/admin.php:1241
+#: mod/friendica.php:80
+msgid "the bugtracker at github"
+msgstr ""
+
+#: mod/friendica.php:83
msgid ""
-"Minimum fragmenation level to start the automatic optimization - default "
-"value is 30%."
+"Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - "
+"dot com"
msgstr ""
-#: mod/admin.php:1243
-msgid "Periodical check of global contacts"
+#: mod/friendica.php:97
+msgid "Installed plugins/addons/apps:"
msgstr ""
-#: mod/admin.php:1243
-msgid ""
-"If enabled, the global contacts are checked periodically for missing or "
-"outdated data and the vitality of the contacts and servers."
+#: mod/friendica.php:111
+msgid "No installed plugins/addons/apps"
msgstr ""
-#: mod/admin.php:1244
-msgid "Days between requery"
+#: mod/friendica.php:116
+msgid "On this server the following remote servers are blocked."
msgstr ""
-#: mod/admin.php:1244
-msgid "Number of days after which a server is requeried for his contacts."
+#: mod/fsuggest.php:67
+msgid "Friend suggestion sent."
msgstr ""
-#: mod/admin.php:1245
-msgid "Discover contacts from other servers"
+#: mod/fsuggest.php:103
+msgid "Suggest Friends"
msgstr ""
-#: mod/admin.php:1245
-msgid ""
-"Periodically query other servers for contacts. You can choose between "
-"'users': the users on the remote system, 'Global Contacts': active contacts "
-"that are known on the system. The fallback is meant for Redmatrix servers "
-"and older friendica servers, where global contacts weren't available. The "
-"fallback increases the server load, so the recommened setting is 'Users, "
-"Global Contacts'."
+#: mod/fsuggest.php:105
+#, php-format
+msgid "Suggest a friend for %s"
msgstr ""
-#: mod/admin.php:1246
-msgid "Timeframe for fetching global contacts"
+#: mod/group.php:34
+msgid "Group created."
msgstr ""
-#: mod/admin.php:1246
-msgid ""
-"When the discovery is activated, this value defines the timeframe for the "
-"activity of the global contacts that are fetched from other servers."
+#: mod/group.php:40
+msgid "Could not create group."
msgstr ""
-#: mod/admin.php:1247
-msgid "Search the local directory"
+#: mod/group.php:54 mod/group.php:156
+msgid "Group not found."
msgstr ""
-#: mod/admin.php:1247
-msgid ""
-"Search the local directory instead of the global directory. When searching "
-"locally, every search will be executed on the global directory in the "
-"background. This improves the search results when the search is repeated."
+#: mod/group.php:68
+msgid "Group name changed."
msgstr ""
-#: mod/admin.php:1249
-msgid "Publish server information"
+#: mod/group.php:81 mod/profperm.php:25 index.php:398
+msgid "Permission denied"
msgstr ""
-#: mod/admin.php:1249
-msgid ""
-"If enabled, general server and usage data will be published. The data "
-"contains the name and version of the server, number of users with public "
-"profiles, number of posts and the activated protocols and connectors. See <a "
-"href='http://the-federation.info/'>the-federation.info</a> for details."
+#: mod/group.php:95
+msgid "Save Group"
msgstr ""
-#: mod/admin.php:1251
-msgid "Check upstream version"
+#: mod/group.php:100
+msgid "Create a group of contacts/friends."
msgstr ""
-#: mod/admin.php:1251
-msgid ""
-"Enables checking for new Friendica versions at github. If there is a new "
-"version, you will be informed in the admin panel overview."
+#: mod/group.php:125
+msgid "Group removed."
msgstr ""
-#: mod/admin.php:1252
-msgid "Suppress Tags"
+#: mod/group.php:127
+msgid "Unable to remove group."
msgstr ""
-#: mod/admin.php:1252
-msgid "Suppress showing a list of hashtags at the end of the posting."
+#: mod/group.php:191
+msgid "Delete Group"
msgstr ""
-#: mod/admin.php:1253
-msgid "Path to item cache"
+#: mod/group.php:197
+msgid "Group Editor"
msgstr ""
-#: mod/admin.php:1253
-msgid "The item caches buffers generated bbcode and external images."
+#: mod/group.php:202
+msgid "Edit Group Name"
msgstr ""
-#: mod/admin.php:1254
-msgid "Cache duration in seconds"
+#: mod/group.php:212
+msgid "Members"
msgstr ""
-#: mod/admin.php:1254
-msgid ""
-"How long should the cache files be hold? Default value is 86400 seconds (One "
-"day). To disable the item cache, set the value to -1."
+#: mod/group.php:215 mod/network.php:661
+msgid "Group is empty"
msgstr ""
-#: mod/admin.php:1255
-msgid "Maximum numbers of comments per post"
+#: mod/group.php:228
+msgid "Remove Contact"
msgstr ""
-#: mod/admin.php:1255
-msgid "How much comments should be shown for each post? Default value is 100."
+#: mod/group.php:252
+msgid "Add Contact"
msgstr ""
-#: mod/admin.php:1256
-msgid "Temp path"
+#: mod/group.php:264 mod/profperm.php:110
+msgid "Click on a contact to add or remove."
msgstr ""
-#: mod/admin.php:1256
-msgid ""
-"If you have a restricted system where the webserver can't access the system "
-"temp path, enter another path here."
+#: mod/hcard.php:15
+msgid "No profile"
msgstr ""
-#: mod/admin.php:1257
-msgid "Base path to installation"
+#: mod/home.php:43
+#, php-format
+msgid "Welcome to %s"
msgstr ""
-#: mod/admin.php:1257
-msgid ""
-"If the system cannot detect the correct path to your installation, enter the "
-"correct path here. This setting should only be set if you are using a "
-"restricted system and symbolic links to your webroot."
+#: mod/install.php:108
+msgid "Friendica Communications Server - Setup"
msgstr ""
-#: mod/admin.php:1258
-msgid "Disable picture proxy"
+#: mod/install.php:114
+msgid "Could not connect to database."
msgstr ""
-#: mod/admin.php:1258
-msgid ""
-"The picture proxy increases performance and privacy. It shouldn't be used on "
-"systems with very low bandwith."
+#: mod/install.php:118
+msgid "Could not create table."
msgstr ""
-#: mod/admin.php:1259
-msgid "Only search in tags"
+#: mod/install.php:124
+msgid "Your Friendica site database has been installed."
msgstr ""
-#: mod/admin.php:1259
-msgid "On large systems the text search can slow down the system extremely."
+#: mod/install.php:129
+msgid ""
+"You may need to import the file \"database.sql\" manually using phpmyadmin "
+"or mysql."
msgstr ""
-#: mod/admin.php:1261
-msgid "New base url"
+#: mod/install.php:130 mod/install.php:202 mod/install.php:549
+msgid "Please see the file \"INSTALL.txt\"."
msgstr ""
-#: mod/admin.php:1261
-msgid ""
-"Change base url for this server. Sends relocate message to all Friendica and "
-"Diaspora* contacts of all users."
+#: mod/install.php:142
+msgid "Database already in use."
msgstr ""
-#: mod/admin.php:1263
-msgid "RINO Encryption"
+#: mod/install.php:199
+msgid "System check"
msgstr ""
-#: mod/admin.php:1263
-msgid "Encryption layer between nodes."
+#: mod/install.php:204
+msgid "Check again"
msgstr ""
-#: mod/admin.php:1265
-msgid "Maximum number of parallel workers"
+#: mod/install.php:223
+msgid "Database connection"
msgstr ""
-#: mod/admin.php:1265
+#: mod/install.php:224
msgid ""
-"On shared hosters set this to 2. On larger systems, values of 10 are great. "
-"Default value is 4."
+"In order to install Friendica we need to know how to connect to your "
+"database."
msgstr ""
-#: mod/admin.php:1266
-msgid "Don't use 'proc_open' with the worker"
+#: mod/install.php:225
+msgid ""
+"Please contact your hosting provider or site administrator if you have "
+"questions about these settings."
msgstr ""
-#: mod/admin.php:1266
+#: mod/install.php:226
msgid ""
-"Enable this if your system doesn't allow the use of 'proc_open'. This can "
-"happen on shared hosters. If this is enabled you should increase the "
-"frequency of poller calls in your crontab."
+"The database you specify below should already exist. If it does not, please "
+"create it before continuing."
msgstr ""
-#: mod/admin.php:1267
-msgid "Enable fastlane"
+#: mod/install.php:230
+msgid "Database Server Name"
msgstr ""
-#: mod/admin.php:1267
-msgid ""
-"When enabed, the fastlane mechanism starts an additional worker if processes "
-"with higher priority are blocked by processes of lower priority."
+#: mod/install.php:231
+msgid "Database Login Name"
msgstr ""
-#: mod/admin.php:1268
-msgid "Enable frontend worker"
+#: mod/install.php:232
+msgid "Database Login Password"
msgstr ""
-#: mod/admin.php:1268
-#, php-format
-msgid ""
-"When enabled the Worker process is triggered when backend access is "
-"performed (e.g. messages being delivered). On smaller sites you might want "
-"to call %s/worker on a regular basis via an external cron job. You should "
-"only enable this option if you cannot utilize cron/scheduled jobs on your "
-"server."
+#: mod/install.php:232
+msgid "For security reasons the password must not be empty"
msgstr ""
-#: mod/admin.php:1298
-msgid "Update has been marked successful"
+#: mod/install.php:233
+msgid "Database Name"
msgstr ""
-#: mod/admin.php:1306
-#, php-format
-msgid "Database structure update %s was successfully applied."
+#: mod/install.php:234 mod/install.php:275
+msgid "Site administrator email address"
msgstr ""
-#: mod/admin.php:1309
-#, php-format
-msgid "Executing of database structure update %s failed with error: %s"
+#: mod/install.php:234 mod/install.php:275
+msgid ""
+"Your account email address must match this in order to use the web admin "
+"panel."
msgstr ""
-#: mod/admin.php:1323
-#, php-format
-msgid "Executing %s failed with error: %s"
+#: mod/install.php:238 mod/install.php:278
+msgid "Please select a default timezone for your website"
msgstr ""
-#: mod/admin.php:1326
-#, php-format
-msgid "Update %s was successfully applied."
+#: mod/install.php:265
+msgid "Site settings"
msgstr ""
-#: mod/admin.php:1329
-#, php-format
-msgid "Update %s did not return a status. Unknown if it succeeded."
+#: mod/install.php:279
+msgid "System Language:"
msgstr ""
-#: mod/admin.php:1332
-#, php-format
-msgid "There was no additional update function %s that needed to be called."
+#: mod/install.php:279
+msgid ""
+"Set the default language for your Friendica installation interface and to "
+"send emails."
msgstr ""
-#: mod/admin.php:1352
-msgid "No failed updates."
+#: mod/install.php:319
+msgid "Could not find a command line version of PHP in the web server PATH."
msgstr ""
-#: mod/admin.php:1353
-msgid "Check database structure"
+#: mod/install.php:320
+msgid ""
+"If you don't have a command line version of PHP installed on server, you "
+"will not be able to run the background processing. See <a href='https://"
+"github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-"
+"worker'>'Setup the worker'</a>"
msgstr ""
-#: mod/admin.php:1358
-msgid "Failed Updates"
+#: mod/install.php:324
+msgid "PHP executable path"
msgstr ""
-#: mod/admin.php:1359
+#: mod/install.php:324
msgid ""
-"This does not include updates prior to 1139, which did not return a status."
+"Enter full path to php executable. You can leave this blank to continue the "
+"installation."
msgstr ""
-#: mod/admin.php:1360
-msgid "Mark success (if update was manually applied)"
+#: mod/install.php:329
+msgid "Command line PHP"
msgstr ""
-#: mod/admin.php:1361
-msgid "Attempt to execute this update step automatically"
+#: mod/install.php:338
+msgid "PHP executable is not the php cli binary (could be cgi-fgci version)"
msgstr ""
-#: mod/admin.php:1395
-#, php-format
-msgid ""
-"\n"
-"\t\t\tDear %1$s,\n"
-"\t\t\t\tthe administrator of %2$s has set up an account for you."
+#: mod/install.php:339
+msgid "Found PHP version: "
msgstr ""
-#: mod/admin.php:1398
-#, php-format
+#: mod/install.php:341
+msgid "PHP cli binary"
+msgstr ""
+
+#: mod/install.php:352
msgid ""
-"\n"
-"\t\t\tThe login details are as follows:\n"
-"\n"
-"\t\t\tSite Location:\t%1$s\n"
-"\t\t\tLogin Name:\t\t%2$s\n"
-"\t\t\tPassword:\t\t%3$s\n"
-"\n"
-"\t\t\tYou may change your password from your account \"Settings\" page after "
-"logging\n"
-"\t\t\tin.\n"
-"\n"
-"\t\t\tPlease take a few moments to review the other account settings on that "
-"page.\n"
-"\n"
-"\t\t\tYou may also wish to add some basic information to your default "
-"profile\n"
-"\t\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
-"\n"
-"\t\t\tWe recommend setting your full name, adding a profile photo,\n"
-"\t\t\tadding some profile \"keywords\" (very useful in making new friends) - "
-"and\n"
-"\t\t\tperhaps what country you live in; if you do not wish to be more "
-"specific\n"
-"\t\t\tthan that.\n"
-"\n"
-"\t\t\tWe fully respect your right to privacy, and none of these items are "
-"necessary.\n"
-"\t\t\tIf you are new and do not know anybody here, they may help\n"
-"\t\t\tyou to make some new and interesting friends.\n"
-"\n"
-"\t\t\tThank you and welcome to %4$s."
+"The command line version of PHP on your system does not have "
+"\"register_argc_argv\" enabled."
msgstr ""
-#: mod/admin.php:1442
-#, php-format
-msgid "%s user blocked/unblocked"
-msgid_plural "%s users blocked/unblocked"
-msgstr[0] ""
-msgstr[1] ""
+#: mod/install.php:353
+msgid "This is required for message delivery to work."
+msgstr ""
-#: mod/admin.php:1449
-#, php-format
-msgid "%s user deleted"
-msgid_plural "%s users deleted"
-msgstr[0] ""
-msgstr[1] ""
+#: mod/install.php:355
+msgid "PHP register_argc_argv"
+msgstr ""
-#: mod/admin.php:1496
-#, php-format
-msgid "User '%s' deleted"
+#: mod/install.php:378
+msgid ""
+"Error: the \"openssl_pkey_new\" function on this system is not able to "
+"generate encryption keys"
msgstr ""
-#: mod/admin.php:1504
-#, php-format
-msgid "User '%s' unblocked"
+#: mod/install.php:379
+msgid ""
+"If running under Windows, please see \"http://www.php.net/manual/en/openssl."
+"installation.php\"."
msgstr ""
-#: mod/admin.php:1504
-#, php-format
-msgid "User '%s' blocked"
+#: mod/install.php:381
+msgid "Generate encryption keys"
msgstr ""
-#: mod/admin.php:1612 mod/admin.php:1638
-msgid "Register date"
+#: mod/install.php:388
+msgid "libCurl PHP module"
msgstr ""
-#: mod/admin.php:1612 mod/admin.php:1638
-msgid "Last login"
+#: mod/install.php:389
+msgid "GD graphics PHP module"
msgstr ""
-#: mod/admin.php:1612 mod/admin.php:1638
-msgid "Last item"
+#: mod/install.php:390
+msgid "OpenSSL PHP module"
msgstr ""
-#: mod/admin.php:1612 mod/settings.php:43
-msgid "Account"
+#: mod/install.php:391
+msgid "PDO or MySQLi PHP module"
msgstr ""
-#: mod/admin.php:1621
-msgid "Add User"
+#: mod/install.php:392
+msgid "mb_string PHP module"
msgstr ""
-#: mod/admin.php:1622
-msgid "select all"
+#: mod/install.php:393
+msgid "XML PHP module"
msgstr ""
-#: mod/admin.php:1623
-msgid "User registrations waiting for confirm"
+#: mod/install.php:394
+msgid "iconv module"
msgstr ""
-#: mod/admin.php:1624
-msgid "User waiting for permanent deletion"
+#: mod/install.php:398 mod/install.php:400
+msgid "Apache mod_rewrite module"
msgstr ""
-#: mod/admin.php:1625
-msgid "Request date"
+#: mod/install.php:398
+msgid ""
+"Error: Apache webserver mod-rewrite module is required but not installed."
msgstr ""
-#: mod/admin.php:1626
-msgid "No registrations."
+#: mod/install.php:406
+msgid "Error: libCURL PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1627
-msgid "Note from the user"
+#: mod/install.php:410
+msgid ""
+"Error: GD graphics PHP module with JPEG support required but not installed."
msgstr ""
-#: mod/admin.php:1629
-msgid "Deny"
+#: mod/install.php:414
+msgid "Error: openssl PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1631 mod/contacts.php:635 mod/contacts.php:835
-#: mod/contacts.php:1013
-msgid "Block"
+#: mod/install.php:418
+msgid "Error: PDO or MySQLi PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1632 mod/contacts.php:635 mod/contacts.php:835
-#: mod/contacts.php:1013
-msgid "Unblock"
+#: mod/install.php:422
+msgid "Error: The MySQL driver for PDO is not installed."
msgstr ""
-#: mod/admin.php:1633
-msgid "Site admin"
+#: mod/install.php:426
+msgid "Error: mb_string PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1634
-msgid "Account expired"
+#: mod/install.php:430
+msgid "Error: iconv PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1637
-msgid "New User"
+#: mod/install.php:440
+msgid "Error, XML PHP module required but not installed."
msgstr ""
-#: mod/admin.php:1638
-msgid "Deleted since"
+#: mod/install.php:452
+msgid ""
+"The web installer needs to be able to create a file called \".htconfig.php\" "
+"in the top folder of your web server and it is unable to do so."
msgstr ""
-#: mod/admin.php:1643
+#: mod/install.php:453
msgid ""
-"Selected users will be deleted!\\n\\nEverything these users had posted on "
-"this site will be permanently deleted!\\n\\nAre you sure?"
+"This is most often a permission setting, as the web server may not be able "
+"to write files in your folder - even if you can."
msgstr ""
-#: mod/admin.php:1644
+#: mod/install.php:454
msgid ""
-"The user {0} will be deleted!\\n\\nEverything this user has posted on this "
-"site will be permanently deleted!\\n\\nAre you sure?"
+"At the end of this procedure, we will give you a text to save in a file "
+"named .htconfig.php in your Friendica top folder."
msgstr ""
-#: mod/admin.php:1654
-msgid "Name of the new user."
+#: mod/install.php:455
+msgid ""
+"You can alternatively skip this procedure and perform a manual installation. "
+"Please see the file \"INSTALL.txt\" for instructions."
msgstr ""
-#: mod/admin.php:1655
-msgid "Nickname"
+#: mod/install.php:458
+msgid ".htconfig.php is writable"
msgstr ""
-#: mod/admin.php:1655
-msgid "Nickname of the new user."
+#: mod/install.php:468
+msgid ""
+"Friendica uses the Smarty3 template engine to render its web views. Smarty3 "
+"compiles templates to PHP to speed up rendering."
msgstr ""
-#: mod/admin.php:1656
-msgid "Email address of the new user."
+#: mod/install.php:469
+msgid ""
+"In order to store these compiled templates, the web server needs to have "
+"write access to the directory view/smarty3/ under the Friendica top level "
+"folder."
msgstr ""
-#: mod/admin.php:1699
-#, php-format
-msgid "Plugin %s disabled."
+#: mod/install.php:470
+msgid ""
+"Please ensure that the user that your web server runs as (e.g. www-data) has "
+"write access to this folder."
msgstr ""
-#: mod/admin.php:1703
-#, php-format
-msgid "Plugin %s enabled."
+#: mod/install.php:471
+msgid ""
+"Note: as a security measure, you should give the web server write access to "
+"view/smarty3/ only--not the template files (.tpl) that it contains."
msgstr ""
-#: mod/admin.php:1714 mod/admin.php:1966
-msgid "Disable"
+#: mod/install.php:474
+msgid "view/smarty3 is writable"
msgstr ""
-#: mod/admin.php:1716 mod/admin.php:1968
-msgid "Enable"
+#: mod/install.php:490
+msgid ""
+"Url rewrite in .htaccess is not working. Check your server configuration."
msgstr ""
-#: mod/admin.php:1739 mod/admin.php:2015
-msgid "Toggle"
+#: mod/install.php:492
+msgid "Url rewrite is working"
msgstr ""
-#: mod/admin.php:1747 mod/admin.php:2024
-msgid "Author: "
+#: mod/install.php:511
+msgid "ImageMagick PHP extension is not installed"
msgstr ""
-#: mod/admin.php:1748 mod/admin.php:2025
-msgid "Maintainer: "
+#: mod/install.php:513
+msgid "ImageMagick PHP extension is installed"
msgstr ""
-#: mod/admin.php:1803
-msgid "Reload active plugins"
+#: mod/install.php:515
+msgid "ImageMagick supports GIF"
msgstr ""
-#: mod/admin.php:1808
-#, php-format
+#: mod/install.php:522
msgid ""
-"There are currently no plugins available on your node. You can find the "
-"official plugin repository at %1$s and might find other interesting plugins "
-"in the open plugin registry at %2$s"
+"The database configuration file \".htconfig.php\" could not be written. "
+"Please use the enclosed text to create a configuration file in your web "
+"server root."
msgstr ""
-#: mod/admin.php:1927
-msgid "No themes found."
+#: mod/install.php:547
+msgid "<h1>What next</h1>"
msgstr ""
-#: mod/admin.php:2006
-msgid "Screenshot"
+#: mod/install.php:548
+msgid ""
+"IMPORTANT: You will need to [manually] setup a scheduled task for the worker."
msgstr ""
-#: mod/admin.php:2066
-msgid "Reload active themes"
+#: mod/invite.php:33
+msgid "Total invitation limit exceeded."
msgstr ""
-#: mod/admin.php:2071
+#: mod/invite.php:56
#, php-format
-msgid "No themes found on the system. They should be paced in %1$s"
+msgid "%s : Not a valid email address."
msgstr ""
-#: mod/admin.php:2072
-msgid "[Experimental]"
+#: mod/invite.php:81
+msgid "Please join us on Friendica"
msgstr ""
-#: mod/admin.php:2073
-msgid "[Unsupported]"
+#: mod/invite.php:92
+msgid "Invitation limit exceeded. Please contact your site administrator."
msgstr ""
-#: mod/admin.php:2097
-msgid "Log settings updated."
+#: mod/invite.php:96
+#, php-format
+msgid "%s : Message delivery failed."
msgstr ""
-#: mod/admin.php:2129
-msgid "PHP log currently enabled."
-msgstr ""
+#: mod/invite.php:100
+#, php-format
+msgid "%d message sent."
+msgid_plural "%d messages sent."
+msgstr[0] ""
+msgstr[1] ""
-#: mod/admin.php:2131
-msgid "PHP log currently disabled."
+#: mod/invite.php:119
+msgid "You have no more invitations available"
msgstr ""
-#: mod/admin.php:2140
-msgid "Clear"
+#: mod/invite.php:127
+#, php-format
+msgid ""
+"Visit %s for a list of public sites that you can join. Friendica members on "
+"other sites can all connect with each other, as well as with members of many "
+"other social networks."
msgstr ""
-#: mod/admin.php:2145
-msgid "Enable Debugging"
+#: mod/invite.php:129
+#, php-format
+msgid ""
+"To accept this invitation, please visit and register at %s or any other "
+"public Friendica website."
msgstr ""
-#: mod/admin.php:2146
-msgid "Log file"
+#: mod/invite.php:130
+#, php-format
+msgid ""
+"Friendica sites all inter-connect to create a huge privacy-enhanced social "
+"web that is owned and controlled by its members. They can also connect with "
+"many traditional social networks. See %s for a list of alternate Friendica "
+"sites you can join."
msgstr ""
-#: mod/admin.php:2146
+#: mod/invite.php:134
msgid ""
-"Must be writable by web server. Relative to your Friendica top-level "
-"directory."
+"Our apologies. This system is not currently configured to connect with other "
+"public sites or invite members."
msgstr ""
-#: mod/admin.php:2147
-msgid "Log level"
+#: mod/invite.php:137
+#, php-format
+msgid "To accept this invitation, please visit and register at %s."
msgstr ""
-#: mod/admin.php:2150
-msgid "PHP logging"
+#: mod/invite.php:138
+msgid ""
+"Friendica sites all inter-connect to create a huge privacy-enhanced social "
+"web that is owned and controlled by its members. They can also connect with "
+"many traditional social networks."
msgstr ""
-#: mod/admin.php:2151
-msgid ""
-"To enable logging of PHP errors and warnings you can add the following to "
-"the .htconfig.php file of your installation. The filename set in the "
-"'error_log' line is relative to the friendica top-level directory and must "
-"be writeable by the web server. The option '1' for 'log_errors' and "
-"'display_errors' is to enable these options, set to '0' to disable them."
+#: mod/invite.php:144
+msgid "Send invitations"
msgstr ""
-#: mod/admin.php:2281 mod/admin.php:2282 mod/settings.php:792
-msgid "Off"
+#: mod/invite.php:145
+msgid "Enter email addresses, one per line:"
msgstr ""
-#: mod/admin.php:2281 mod/admin.php:2282 mod/settings.php:792
-msgid "On"
+#: mod/invite.php:146 mod/message.php:334 mod/message.php:506
+#: mod/wallmessage.php:139
+msgid "Your message:"
msgstr ""
-#: mod/admin.php:2282
-#, php-format
-msgid "Lock feature %s"
+#: mod/invite.php:147
+msgid ""
+"You are cordially invited to join me and other close friends on Friendica - "
+"and help us to create a better social web."
msgstr ""
-#: mod/admin.php:2290
-msgid "Manage Additional Features"
+#: mod/invite.php:149
+msgid "You will need to supply this invitation code: $invite_code"
msgstr ""
-#: mod/contacts.php:139
-#, php-format
-msgid "%d contact edited."
-msgid_plural "%d contacts edited."
-msgstr[0] ""
-msgstr[1] ""
+#: mod/invite.php:149
+msgid ""
+"Once you have registered, please connect with me via my profile page at:"
+msgstr ""
-#: mod/contacts.php:174 mod/contacts.php:392
-msgid "Could not access contact record."
+#: mod/invite.php:151
+msgid ""
+"For more information about the Friendica project and why we feel it is "
+"important, please visit http://friendi.ca"
msgstr ""
-#: mod/contacts.php:188
-msgid "Could not locate selected profile."
+#: mod/item.php:124
+msgid "Unable to locate original post."
msgstr ""
-#: mod/contacts.php:221
-msgid "Contact updated."
+#: mod/item.php:351
+msgid "Empty post discarded."
msgstr ""
-#: mod/contacts.php:413
-msgid "Contact has been blocked"
+#: mod/item.php:937
+msgid "System error. Post not saved."
msgstr ""
-#: mod/contacts.php:413
-msgid "Contact has been unblocked"
+#: mod/item.php:1028
+#, php-format
+msgid ""
+"This message was sent to you by %s, a member of the Friendica social network."
msgstr ""
-#: mod/contacts.php:424
-msgid "Contact has been ignored"
+#: mod/item.php:1030
+#, php-format
+msgid "You may visit them online at %s"
msgstr ""
-#: mod/contacts.php:424
-msgid "Contact has been unignored"
+#: mod/item.php:1031
+msgid ""
+"Please contact the sender by replying to this post if you do not wish to "
+"receive these messages."
msgstr ""
-#: mod/contacts.php:436
-msgid "Contact has been archived"
+#: mod/item.php:1035
+#, php-format
+msgid "%s posted an update."
msgstr ""
-#: mod/contacts.php:436
-msgid "Contact has been unarchived"
+#: mod/lockview.php:34 mod/lockview.php:42
+msgid "Remote privacy information not available."
msgstr ""
-#: mod/contacts.php:461
-msgid "Drop contact"
+#: mod/lockview.php:51
+msgid "Visible to:"
msgstr ""
-#: mod/contacts.php:464 mod/contacts.php:831
-msgid "Do you really want to delete this contact?"
+#: mod/lostpass.php:23
+msgid "No valid account found."
msgstr ""
-#: mod/contacts.php:483
-msgid "Contact has been removed."
+#: mod/lostpass.php:39
+msgid "Password reset request issued. Check your email."
msgstr ""
-#: mod/contacts.php:520
+#: mod/lostpass.php:45
#, php-format
-msgid "You are mutual friends with %s"
+msgid ""
+"\n"
+"\t\tDear %1$s,\n"
+"\t\t\tA request was recently received at \"%2$s\" to reset your account\n"
+"\t\tpassword. In order to confirm this request, please select the "
+"verification link\n"
+"\t\tbelow or paste it into your web browser address bar.\n"
+"\n"
+"\t\tIf you did NOT request this change, please DO NOT follow the link\n"
+"\t\tprovided and ignore and/or delete this email.\n"
+"\n"
+"\t\tYour password will not be changed unless we can verify that you\n"
+"\t\tissued this request."
msgstr ""
-#: mod/contacts.php:524
+#: mod/lostpass.php:56
#, php-format
-msgid "You are sharing with %s"
+msgid ""
+"\n"
+"\t\tFollow this link to verify your identity:\n"
+"\n"
+"\t\t%1$s\n"
+"\n"
+"\t\tYou will then receive a follow-up message containing the new password.\n"
+"\t\tYou may change that password from your account settings page after "
+"logging in.\n"
+"\n"
+"\t\tThe login details are as follows:\n"
+"\n"
+"\t\tSite Location:\t%2$s\n"
+"\t\tLogin Name:\t%3$s"
msgstr ""
-#: mod/contacts.php:529
+#: mod/lostpass.php:75
#, php-format
-msgid "%s is sharing with you"
+msgid "Password reset requested at %s"
msgstr ""
-#: mod/contacts.php:549
-msgid "Private communications are not available for this contact."
+#: mod/lostpass.php:95
+msgid ""
+"Request could not be verified. (You may have previously submitted it.) "
+"Password reset failed."
msgstr ""
-#: mod/contacts.php:556
-msgid "(Update was successful)"
+#: mod/lostpass.php:114 boot.php:916
+msgid "Password Reset"
msgstr ""
-#: mod/contacts.php:556
-msgid "(Update was not successful)"
+#: mod/lostpass.php:115
+msgid "Your password has been reset as requested."
msgstr ""
-#: mod/contacts.php:558 mod/contacts.php:994
-msgid "Suggest friends"
+#: mod/lostpass.php:116
+msgid "Your new password is"
msgstr ""
-#: mod/contacts.php:562
-#, php-format
-msgid "Network type: %s"
+#: mod/lostpass.php:117
+msgid "Save or copy your new password - and then"
msgstr ""
-#: mod/contacts.php:575
-msgid "Communications lost with this contact!"
+#: mod/lostpass.php:118
+msgid "click here to login"
msgstr ""
-#: mod/contacts.php:578
-msgid "Fetch further information for feeds"
+#: mod/lostpass.php:119
+msgid ""
+"Your password may be changed from the <em>Settings</em> page after "
+"successful login."
msgstr ""
-#: mod/contacts.php:579
-msgid "Fetch information"
+#: mod/lostpass.php:129
+#, php-format
+msgid ""
+"\n"
+"\t\t\t\tDear %1$s,\n"
+"\t\t\t\t\tYour password has been changed as requested. Please retain this\n"
+"\t\t\t\tinformation for your records (or change your password immediately "
+"to\n"
+"\t\t\t\tsomething that you will remember).\n"
+"\t\t\t"
msgstr ""
-#: mod/contacts.php:579
-msgid "Fetch information and keywords"
+#: mod/lostpass.php:135
+#, php-format
+msgid ""
+"\n"
+"\t\t\t\tYour login details are as follows:\n"
+"\n"
+"\t\t\t\tSite Location:\t%1$s\n"
+"\t\t\t\tLogin Name:\t%2$s\n"
+"\t\t\t\tPassword:\t%3$s\n"
+"\n"
+"\t\t\t\tYou may change that password from your account settings page after "
+"logging in.\n"
+"\t\t\t"
msgstr ""
-#: mod/contacts.php:603
-msgid "Contact"
+#: mod/lostpass.php:151
+#, php-format
+msgid "Your password has been changed at %s"
msgstr ""
-#: mod/contacts.php:606
-msgid "Profile Visibility"
+#: mod/lostpass.php:163
+msgid "Forgot your Password?"
msgstr ""
-#: mod/contacts.php:607
-#, php-format
+#: mod/lostpass.php:164
msgid ""
-"Please choose the profile you would like to display to %s when viewing your "
-"profile securely."
+"Enter your email address and submit to have your password reset. Then check "
+"your email for further instructions."
msgstr ""
-#: mod/contacts.php:608
-msgid "Contact Information / Notes"
+#: mod/lostpass.php:165 boot.php:904
+msgid "Nickname or Email: "
msgstr ""
-#: mod/contacts.php:609
-msgid "Their personal note"
+#: mod/lostpass.php:166
+msgid "Reset"
msgstr ""
-#: mod/contacts.php:611
-msgid "Edit contact notes"
+#: mod/manage.php:154
+msgid "Manage Identities and/or Pages"
msgstr ""
-#: mod/contacts.php:617
-msgid "Block/Unblock contact"
+#: mod/manage.php:155
+msgid ""
+"Toggle between different identities or community/group pages which share "
+"your account details or which you have been granted \"manage\" permissions"
msgstr ""
-#: mod/contacts.php:618
-msgid "Ignore contact"
+#: mod/manage.php:156
+msgid "Select an identity to manage: "
msgstr ""
-#: mod/contacts.php:619
-msgid "Repair URL settings"
+#: mod/match.php:45
+msgid "No keywords to match. Please add keywords to your default profile."
msgstr ""
-#: mod/contacts.php:620
-msgid "View conversations"
+#: mod/match.php:101
+msgid "is interested in:"
msgstr ""
-#: mod/contacts.php:626
-msgid "Last update:"
+#: mod/match.php:117
+msgid "Profile Match"
msgstr ""
-#: mod/contacts.php:628
-msgid "Update public posts"
+#: mod/message.php:65 mod/wallmessage.php:54
+msgid "No recipient selected."
msgstr ""
-#: mod/contacts.php:630 mod/contacts.php:1004
-msgid "Update now"
+#: mod/message.php:69
+msgid "Unable to locate contact information."
msgstr ""
-#: mod/contacts.php:636 mod/contacts.php:836 mod/contacts.php:1021
-msgid "Unignore"
+#: mod/message.php:72 mod/wallmessage.php:60
+msgid "Message could not be sent."
msgstr ""
-#: mod/contacts.php:640
-msgid "Currently blocked"
+#: mod/message.php:75 mod/wallmessage.php:63
+msgid "Message collection failure."
msgstr ""
-#: mod/contacts.php:641
-msgid "Currently ignored"
+#: mod/message.php:78 mod/wallmessage.php:66
+msgid "Message sent."
msgstr ""
-#: mod/contacts.php:642
-msgid "Currently archived"
+#: mod/message.php:207
+msgid "Do you really want to delete this message?"
msgstr ""
-#: mod/contacts.php:643
-msgid ""
-"Replies/likes to your public posts <strong>may</strong> still be visible"
+#: mod/message.php:227
+msgid "Message deleted."
msgstr ""
-#: mod/contacts.php:644
-msgid "Notification for new posts"
+#: mod/message.php:257
+msgid "Conversation removed."
msgstr ""
-#: mod/contacts.php:644
-msgid "Send a notification of every new post of this contact"
+#: mod/message.php:324 mod/wallmessage.php:130
+msgid "Send Private Message"
msgstr ""
-#: mod/contacts.php:647
-msgid "Blacklisted keywords"
+#: mod/message.php:325 mod/message.php:501 mod/wallmessage.php:132
+msgid "To:"
msgstr ""
-#: mod/contacts.php:647
-msgid ""
-"Comma separated list of keywords that should not be converted to hashtags, "
-"when \"Fetch information and keywords\" is selected"
+#: mod/message.php:330 mod/message.php:503 mod/wallmessage.php:133
+msgid "Subject:"
msgstr ""
-#: mod/contacts.php:665
-msgid "Actions"
+#: mod/message.php:366
+msgid "No messages."
msgstr ""
-#: mod/contacts.php:668
-msgid "Contact Settings"
+#: mod/message.php:405
+msgid "Message not available."
msgstr ""
-#: mod/contacts.php:714
-msgid "Suggestions"
+#: mod/message.php:473
+msgid "Delete message"
msgstr ""
-#: mod/contacts.php:717
-msgid "Suggest potential friends"
+#: mod/message.php:494 mod/message.php:576
+msgid "Delete conversation"
msgstr ""
-#: mod/contacts.php:725
-msgid "Show all contacts"
+#: mod/message.php:496
+msgid ""
+"No secure communications available. You <strong>may</strong> be able to "
+"respond from the sender's profile page."
msgstr ""
-#: mod/contacts.php:730
-msgid "Unblocked"
+#: mod/message.php:500
+msgid "Send Reply"
msgstr ""
-#: mod/contacts.php:733
-msgid "Only show unblocked contacts"
+#: mod/message.php:552
+#, php-format
+msgid "Unknown sender - %s"
msgstr ""
-#: mod/contacts.php:739
-msgid "Blocked"
+#: mod/message.php:554
+#, php-format
+msgid "You and %s"
msgstr ""
-#: mod/contacts.php:742
-msgid "Only show blocked contacts"
+#: mod/message.php:556
+#, php-format
+msgid "%s and You"
msgstr ""
-#: mod/contacts.php:748
-msgid "Ignored"
+#: mod/message.php:579
+msgid "D, d M Y - g:i A"
msgstr ""
-#: mod/contacts.php:751
-msgid "Only show ignored contacts"
-msgstr ""
+#: mod/message.php:582
+#, php-format
+msgid "%d message"
+msgid_plural "%d messages"
+msgstr[0] ""
+msgstr[1] ""
-#: mod/contacts.php:757
-msgid "Archived"
+#: mod/mood.php:138
+msgid "Mood"
msgstr ""
-#: mod/contacts.php:760
-msgid "Only show archived contacts"
+#: mod/mood.php:139
+msgid "Set your current mood and tell your friends"
msgstr ""
-#: mod/contacts.php:766
-msgid "Hidden"
+#: mod/network.php:195 mod/search.php:31
+msgid "Remove term"
msgstr ""
-#: mod/contacts.php:769
-msgid "Only show hidden contacts"
-msgstr ""
+#: mod/network.php:569
+#, php-format
+msgid ""
+"Warning: This group contains %s member from a network that doesn't allow non "
+"public messages."
+msgid_plural ""
+"Warning: This group contains %s members from a network that doesn't allow "
+"non public messages."
+msgstr[0] ""
+msgstr[1] ""
-#: mod/contacts.php:826
-msgid "Search your contacts"
+#: mod/network.php:572
+msgid "Messages in this group won't be send to these receivers."
msgstr ""
-#: mod/contacts.php:834 mod/settings.php:160 mod/settings.php:717
-msgid "Update"
+#: mod/network.php:640
+msgid "No such group"
msgstr ""
-#: mod/contacts.php:837 mod/contacts.php:1029
-msgid "Archive"
+#: mod/network.php:665
+#, php-format
+msgid "Group: %s"
msgstr ""
-#: mod/contacts.php:837 mod/contacts.php:1029
-msgid "Unarchive"
+#: mod/network.php:692
+msgid "Private messages to this person are at risk of public disclosure."
msgstr ""
-#: mod/contacts.php:840
-msgid "Batch Actions"
+#: mod/network.php:696
+msgid "Invalid contact."
msgstr ""
-#: mod/contacts.php:886
-msgid "View all contacts"
+#: mod/network.php:901
+msgid "Commented Order"
msgstr ""
-#: mod/contacts.php:896
-msgid "View all common friends"
+#: mod/network.php:904
+msgid "Sort by Comment Date"
msgstr ""
-#: mod/contacts.php:903
-msgid "Advanced Contact Settings"
+#: mod/network.php:909
+msgid "Posted Order"
msgstr ""
-#: mod/contacts.php:937
-msgid "Mutual Friendship"
+#: mod/network.php:912
+msgid "Sort by Post Date"
msgstr ""
-#: mod/contacts.php:941
-msgid "is a fan of yours"
+#: mod/network.php:920 mod/profiles.php:699
+#: src/Core/NotificationsManager.php:190
+msgid "Personal"
msgstr ""
-#: mod/contacts.php:945
-msgid "you are a fan of"
+#: mod/network.php:923
+msgid "Posts that mention or involve you"
msgstr ""
-#: mod/contacts.php:1015
-msgid "Toggle Blocked status"
+#: mod/network.php:931
+msgid "New"
msgstr ""
-#: mod/contacts.php:1023
-msgid "Toggle Ignored status"
+#: mod/network.php:934
+msgid "Activity Stream - by date"
msgstr ""
-#: mod/contacts.php:1031
-msgid "Toggle Archive status"
+#: mod/network.php:942
+msgid "Shared Links"
msgstr ""
-#: mod/contacts.php:1039
-msgid "Delete contact"
+#: mod/network.php:945
+msgid "Interesting Links"
msgstr ""
-#: mod/dfrn_confirm.php:74 mod/profiles.php:25 mod/profiles.php:135
-#: mod/profiles.php:182 mod/profiles.php:618
-msgid "Profile not found."
+#: mod/network.php:953
+msgid "Starred"
msgstr ""
-#: mod/dfrn_confirm.php:131
-msgid ""
-"This may occasionally happen if contact was requested by both persons and it "
-"has already been approved."
+#: mod/network.php:956
+msgid "Favourite Posts"
msgstr ""
-#: mod/dfrn_confirm.php:248
-msgid "Response from remote site was not understood."
+#: mod/newmember.php:8
+msgid "Welcome to Friendica"
msgstr ""
-#: mod/dfrn_confirm.php:257 mod/dfrn_confirm.php:262
-msgid "Unexpected response from remote site: "
+#: mod/newmember.php:9
+msgid "New Member Checklist"
msgstr ""
-#: mod/dfrn_confirm.php:271
-msgid "Confirmation completed successfully."
+#: mod/newmember.php:11
+msgid ""
+"We would like to offer some tips and links to help make your experience "
+"enjoyable. Click any item to visit the relevant page. A link to this page "
+"will be visible from your home page for two weeks after your initial "
+"registration and then will quietly disappear."
msgstr ""
-#: mod/dfrn_confirm.php:273 mod/dfrn_confirm.php:287 mod/dfrn_confirm.php:294
-msgid "Remote site reported: "
+#: mod/newmember.php:12
+msgid "Getting Started"
msgstr ""
-#: mod/dfrn_confirm.php:285
-msgid "Temporary failure. Please wait and try again."
+#: mod/newmember.php:14
+msgid "Friendica Walk-Through"
msgstr ""
-#: mod/dfrn_confirm.php:292
-msgid "Introduction failed or was revoked."
+#: mod/newmember.php:14
+msgid ""
+"On your <em>Quick Start</em> page - find a brief introduction to your "
+"profile and network tabs, make some new connections, and find some groups to "
+"join."
msgstr ""
-#: mod/dfrn_confirm.php:421
-msgid "Unable to set contact photo."
+#: mod/newmember.php:18
+msgid "Go to Your Settings"
msgstr ""
-#: mod/dfrn_confirm.php:562
-#, php-format
-msgid "No user record found for '%s' "
+#: mod/newmember.php:18
+msgid ""
+"On your <em>Settings</em> page - change your initial password. Also make a "
+"note of your Identity Address. This looks just like an email address - and "
+"will be useful in making friends on the free social web."
msgstr ""
-#: mod/dfrn_confirm.php:572
-msgid "Our site encryption key is apparently messed up."
+#: mod/newmember.php:19
+msgid ""
+"Review the other settings, particularly the privacy settings. An unpublished "
+"directory listing is like having an unlisted phone number. In general, you "
+"should probably publish your listing - unless all of your friends and "
+"potential friends know exactly how to find you."
msgstr ""
-#: mod/dfrn_confirm.php:583
-msgid "Empty site URL was provided or URL could not be decrypted by us."
+#: mod/newmember.php:23 mod/profile_photo.php:259 mod/profiles.php:703
+msgid "Upload Profile Photo"
msgstr ""
-#: mod/dfrn_confirm.php:605
-msgid "Contact record was not found for you on our site."
+#: mod/newmember.php:23
+msgid ""
+"Upload a profile photo if you have not done so already. Studies have shown "
+"that people with real photos of themselves are ten times more likely to make "
+"friends than people who do not."
msgstr ""
-#: mod/dfrn_confirm.php:619
-#, php-format
-msgid "Site public key not available in contact record for URL %s."
+#: mod/newmember.php:24
+msgid "Edit Your Profile"
msgstr ""
-#: mod/dfrn_confirm.php:639
+#: mod/newmember.php:24
msgid ""
-"The ID provided by your system is a duplicate on our system. It should work "
-"if you try again."
+"Edit your <strong>default</strong> profile to your liking. Review the "
+"settings for hiding your list of friends and hiding the profile from unknown "
+"visitors."
msgstr ""
-#: mod/dfrn_confirm.php:650
-msgid "Unable to set your contact credentials on our system."
+#: mod/newmember.php:25
+msgid "Profile Keywords"
msgstr ""
-#: mod/dfrn_confirm.php:712
-msgid "Unable to update your contact profile details on our system"
+#: mod/newmember.php:25
+msgid ""
+"Set some public keywords for your default profile which describe your "
+"interests. We may be able to find other people with similar interests and "
+"suggest friendships."
msgstr ""
-#: mod/dfrn_confirm.php:784
-#, php-format
-msgid "%1$s has joined %2$s"
+#: mod/newmember.php:27
+msgid "Connecting"
msgstr ""
-#: mod/dirfind.php:41
-#, php-format
-msgid "People Search - %s"
+#: mod/newmember.php:33
+msgid "Importing Emails"
msgstr ""
-#: mod/dirfind.php:52
-#, php-format
-msgid "Forum Search - %s"
+#: mod/newmember.php:33
+msgid ""
+"Enter your email access information on your Connector Settings page if you "
+"wish to import and interact with friends or mailing lists from your email "
+"INBOX"
msgstr ""
-#: mod/display.php:482
-msgid "Item has been removed."
+#: mod/newmember.php:36
+msgid "Go to Your Contacts Page"
msgstr ""
-#: mod/events.php:98 mod/events.php:100
-msgid "Event can not end before it has started."
+#: mod/newmember.php:36
+msgid ""
+"Your Contacts page is your gateway to managing friendships and connecting "
+"with friends on other networks. Typically you enter their address or site "
+"URL in the <em>Add New Contact</em> dialog."
msgstr ""
-#: mod/events.php:107 mod/events.php:109
-msgid "Event title and start time are required."
+#: mod/newmember.php:37
+msgid "Go to Your Site's Directory"
msgstr ""
-#: mod/events.php:385
-msgid "Create New Event"
+#: mod/newmember.php:37
+msgid ""
+"The Directory page lets you find other people in this network or other "
+"federated sites. Look for a <em>Connect</em> or <em>Follow</em> link on "
+"their profile page. Provide your own Identity Address if requested."
msgstr ""
-#: mod/events.php:505
-msgid "Event details"
+#: mod/newmember.php:38
+msgid "Finding New People"
msgstr ""
-#: mod/events.php:506
-msgid "Starting date and Title are required."
+#: mod/newmember.php:38
+msgid ""
+"On the side panel of the Contacts page are several tools to find new "
+"friends. We can match people by interest, look up people by name or "
+"interest, and provide suggestions based on network relationships. On a brand "
+"new site, friend suggestions will usually begin to be populated within 24 "
+"hours."
msgstr ""
-#: mod/events.php:507 mod/events.php:508
-msgid "Event Starts:"
+#: mod/newmember.php:42
+msgid "Group Your Contacts"
msgstr ""
-#: mod/events.php:507 mod/events.php:519 mod/profiles.php:708
-msgid "Required"
+#: mod/newmember.php:42
+msgid ""
+"Once you have made some friends, organize them into private conversation "
+"groups from the sidebar of your Contacts page and then you can interact with "
+"each group privately on your Network page."
msgstr ""
-#: mod/events.php:509 mod/events.php:525
-msgid "Finish date/time is not known or not relevant"
+#: mod/newmember.php:45
+msgid "Why Aren't My Posts Public?"
msgstr ""
-#: mod/events.php:511 mod/events.php:512
-msgid "Event Finishes:"
+#: mod/newmember.php:45
+msgid ""
+"Friendica respects your privacy. By default, your posts will only show up to "
+"people you've added as friends. For more information, see the help section "
+"from the link above."
msgstr ""
-#: mod/events.php:513 mod/events.php:526
-msgid "Adjust for viewer timezone"
+#: mod/newmember.php:49
+msgid "Getting Help"
msgstr ""
-#: mod/events.php:515
-msgid "Description:"
+#: mod/newmember.php:51
+msgid "Go to the Help Section"
msgstr ""
-#: mod/events.php:519 mod/events.php:521
-msgid "Title:"
+#: mod/newmember.php:51
+msgid ""
+"Our <strong>help</strong> pages may be consulted for detail on other program "
+"features and resources."
msgstr ""
-#: mod/events.php:522 mod/events.php:523
-msgid "Share this event"
+#: mod/nogroup.php:68
+msgid "Contacts who are not members of a group"
msgstr ""
-#: mod/events.php:552
-msgid "Failed to remove event"
+#: mod/notifications.php:39
+msgid "Invalid request identifier."
msgstr ""
-#: mod/events.php:554
-msgid "Event removed"
+#: mod/notifications.php:48 mod/notifications.php:184 mod/notifications.php:231
+msgid "Discard"
msgstr ""
-#: mod/fsuggest.php:66
-msgid "Friend suggestion sent."
+#: mod/notifications.php:109
+msgid "Network Notifications"
msgstr ""
-#: mod/fsuggest.php:100
-msgid "Suggest Friends"
+#: mod/notifications.php:115 mod/notify.php:73
+msgid "System Notifications"
msgstr ""
-#: mod/fsuggest.php:102
-#, php-format
-msgid "Suggest a friend for %s"
+#: mod/notifications.php:121
+msgid "Personal Notifications"
msgstr ""
-#: mod/item.php:120
-msgid "Unable to locate original post."
+#: mod/notifications.php:127
+msgid "Home Notifications"
msgstr ""
-#: mod/item.php:347
-msgid "Empty post discarded."
+#: mod/notifications.php:156
+msgid "Show Ignored Requests"
msgstr ""
-#: mod/item.php:931
-msgid "System error. Post not saved."
+#: mod/notifications.php:156
+msgid "Hide Ignored Requests"
msgstr ""
-#: mod/item.php:1022
-#, php-format
-msgid ""
-"This message was sent to you by %s, a member of the Friendica social network."
+#: mod/notifications.php:168 mod/notifications.php:238
+msgid "Notification type: "
msgstr ""
-#: mod/item.php:1024
+#: mod/notifications.php:171
#, php-format
-msgid "You may visit them online at %s"
+msgid "suggested by %s"
msgstr ""
-#: mod/item.php:1025
-msgid ""
-"Please contact the sender by replying to this post if you do not wish to "
-"receive these messages."
+#: mod/notifications.php:177 mod/notifications.php:256
+msgid "Post a new friend activity"
msgstr ""
-#: mod/item.php:1029
-#, php-format
-msgid "%s posted an update."
+#: mod/notifications.php:177 mod/notifications.php:256
+msgid "if applicable"
msgstr ""
-#: mod/mood.php:137
-msgid "Mood"
+#: mod/notifications.php:199
+msgid "Claims to be known to you: "
msgstr ""
-#: mod/mood.php:138
-msgid "Set your current mood and tell your friends"
+#: mod/notifications.php:200
+msgid "yes"
msgstr ""
-#: mod/network.php:563
-#, php-format
-msgid ""
-"Warning: This group contains %s member from a network that doesn't allow non "
-"public messages."
-msgid_plural ""
-"Warning: This group contains %s members from a network that doesn't allow "
-"non public messages."
-msgstr[0] ""
-msgstr[1] ""
-
-#: mod/network.php:566
-msgid "Messages in this group won't be send to these receivers."
+#: mod/notifications.php:200
+msgid "no"
msgstr ""
-#: mod/network.php:634
-msgid "No such group"
+#: mod/notifications.php:201 mod/notifications.php:206
+msgid "Shall your connection be bidirectional or not?"
msgstr ""
-#: mod/network.php:659
+#: mod/notifications.php:202 mod/notifications.php:207
#, php-format
-msgid "Group: %s"
-msgstr ""
-
-#: mod/network.php:686
-msgid "Private messages to this person are at risk of public disclosure."
+msgid ""
+"Accepting %s as a friend allows %s to subscribe to your posts, and you will "
+"also receive updates from them in your news feed."
msgstr ""
-#: mod/network.php:690
-msgid "Invalid contact."
+#: mod/notifications.php:203
+#, php-format
+msgid ""
+"Accepting %s as a subscriber allows them to subscribe to your posts, but you "
+"will not receive updates from them in your news feed."
msgstr ""
-#: mod/network.php:895
-msgid "Commented Order"
+#: mod/notifications.php:208
+#, php-format
+msgid ""
+"Accepting %s as a sharer allows them to subscribe to your posts, but you "
+"will not receive updates from them in your news feed."
msgstr ""
-#: mod/network.php:898
-msgid "Sort by Comment Date"
+#: mod/notifications.php:219
+msgid "Friend"
msgstr ""
-#: mod/network.php:903
-msgid "Posted Order"
+#: mod/notifications.php:220
+msgid "Sharer"
msgstr ""
-#: mod/network.php:906
-msgid "Sort by Post Date"
+#: mod/notifications.php:220
+msgid "Subscriber"
msgstr ""
-#: mod/network.php:917
-msgid "Posts that mention or involve you"
+#: mod/notifications.php:276
+msgid "No introductions."
msgstr ""
-#: mod/network.php:925
-msgid "New"
+#: mod/notifications.php:317
+msgid "Show unread"
msgstr ""
-#: mod/network.php:928
-msgid "Activity Stream - by date"
+#: mod/notifications.php:317
+msgid "Show all"
msgstr ""
-#: mod/network.php:936
-msgid "Shared Links"
+#: mod/notifications.php:323
+#, php-format
+msgid "No more %s notifications."
msgstr ""
-#: mod/network.php:939
-msgid "Interesting Links"
+#: mod/notify.php:69
+msgid "No more system notifications."
msgstr ""
-#: mod/network.php:947
-msgid "Starred"
+#: mod/openid.php:27
+msgid "OpenID protocol error. No ID returned."
msgstr ""
-#: mod/network.php:950
-msgid "Favourite Posts"
+#: mod/openid.php:63
+msgid ""
+"Account not found and OpenID registration is not permitted on this site."
msgstr ""
-#: mod/ostatus_subscribe.php:17
+#: mod/ostatus_subscribe.php:18
msgid "Subscribing to OStatus contacts"
msgstr ""
-#: mod/ostatus_subscribe.php:28
+#: mod/ostatus_subscribe.php:29
msgid "No contact provided."
msgstr ""
-#: mod/ostatus_subscribe.php:34
+#: mod/ostatus_subscribe.php:35
msgid "Couldn't fetch information for contact."
msgstr ""
-#: mod/ostatus_subscribe.php:43
+#: mod/ostatus_subscribe.php:44
msgid "Couldn't fetch friends for contact."
msgstr ""
-#: mod/ostatus_subscribe.php:71
+#: mod/ostatus_subscribe.php:58 mod/repair_ostatus.php:46
+msgid "Done"
+msgstr ""
+
+#: mod/ostatus_subscribe.php:72
msgid "success"
msgstr ""
-#: mod/ostatus_subscribe.php:73
+#: mod/ostatus_subscribe.php:74
msgid "failed"
msgstr ""
-#: mod/ostatus_subscribe.php:76 object/Item.php:262
+#: mod/ostatus_subscribe.php:77 src/Object/Item.php:276
msgid "ignored"
msgstr ""
-#: mod/photos.php:98 mod/photos.php:1877
+#: mod/ostatus_subscribe.php:82 mod/repair_ostatus.php:52
+msgid "Keep this window open until done."
+msgstr ""
+
+#: mod/p.php:13
+msgid "Not Extended"
+msgstr ""
+
+#: mod/photos.php:100 mod/photos.php:1841
msgid "Recent Photos"
msgstr ""
-#: mod/photos.php:101 mod/photos.php:1305 mod/photos.php:1879
+#: mod/photos.php:103 mod/photos.php:1293 mod/photos.php:1843
msgid "Upload New Photos"
msgstr ""
-#: mod/photos.php:116 mod/settings.php:36
+#: mod/photos.php:118 mod/settings.php:39
msgid "everybody"
msgstr ""
-#: mod/photos.php:180
+#: mod/photos.php:182
msgid "Contact information unavailable"
msgstr ""
-#: mod/photos.php:201
+#: mod/photos.php:203
msgid "Album not found."
msgstr ""
-#: mod/photos.php:234 mod/photos.php:246 mod/photos.php:1249
+#: mod/photos.php:236 mod/photos.php:248 mod/photos.php:1242
msgid "Delete Album"
msgstr ""
-#: mod/photos.php:244
+#: mod/photos.php:246
msgid "Do you really want to delete this photo album and all its photos?"
msgstr ""
-#: mod/photos.php:327 mod/photos.php:338 mod/photos.php:1575
+#: mod/photos.php:329 mod/photos.php:340 mod/photos.php:1557
msgid "Delete Photo"
msgstr ""
-#: mod/photos.php:336
+#: mod/photos.php:338
msgid "Do you really want to delete this photo?"
msgstr ""
-#: mod/photos.php:717
+#: mod/photos.php:719
#, php-format
msgid "%1$s was tagged in %2$s by %3$s"
msgstr ""
-#: mod/photos.php:717
+#: mod/photos.php:719
msgid "a photo"
msgstr ""
-#: mod/photos.php:817 mod/profile_photo.php:157 mod/wall_upload.php:182
+#: mod/photos.php:819 mod/profile_photo.php:159 mod/wall_upload.php:183
#, php-format
msgid "Image exceeds size limit of %s"
msgstr ""
-#: mod/photos.php:825
+#: mod/photos.php:827
msgid "Image file is empty."
msgstr ""
-#: mod/photos.php:840 mod/profile_photo.php:166 mod/wall_upload.php:196
+#: mod/photos.php:842 mod/profile_photo.php:168 mod/wall_upload.php:197
msgid "Unable to process image."
msgstr ""
-#: mod/photos.php:869 mod/profile_photo.php:316 mod/wall_upload.php:235
+#: mod/photos.php:871 mod/profile_photo.php:318 mod/wall_upload.php:236
msgid "Image upload failed."
msgstr ""
-#: mod/photos.php:974
+#: mod/photos.php:976
msgid "No photos selected"
msgstr ""
-#: mod/photos.php:1077 mod/videos.php:313
+#: mod/photos.php:1079 mod/videos.php:316
msgid "Access to this item is restricted."
msgstr ""
-#: mod/photos.php:1165
+#: mod/photos.php:1162
msgid "Upload Photos"
msgstr ""
-#: mod/photos.php:1169 mod/photos.php:1244
+#: mod/photos.php:1166 mod/photos.php:1237
msgid "New album name: "
msgstr ""
-#: mod/photos.php:1170
+#: mod/photos.php:1167
msgid "or existing album name: "
msgstr ""
-#: mod/photos.php:1171
+#: mod/photos.php:1168
msgid "Do not show a status post for this upload"
msgstr ""
-#: mod/photos.php:1182 mod/photos.php:1579 mod/settings.php:1294
+#: mod/photos.php:1179 mod/photos.php:1561 mod/settings.php:1291
msgid "Show to Groups"
msgstr ""
-#: mod/photos.php:1183 mod/photos.php:1580 mod/settings.php:1295
+#: mod/photos.php:1180 mod/photos.php:1562 mod/settings.php:1292
msgid "Show to Contacts"
msgstr ""
-#: mod/photos.php:1184
+#: mod/photos.php:1181
msgid "Private Photo"
msgstr ""
-#: mod/photos.php:1185
+#: mod/photos.php:1182
msgid "Public Photo"
msgstr ""
-#: mod/photos.php:1255
+#: mod/photos.php:1248
msgid "Edit Album"
msgstr ""
-#: mod/photos.php:1260
+#: mod/photos.php:1253
msgid "Show Newest First"
msgstr ""
-#: mod/photos.php:1262
+#: mod/photos.php:1255
msgid "Show Oldest First"
msgstr ""
-#: mod/photos.php:1291 mod/photos.php:1862
+#: mod/photos.php:1279 mod/photos.php:1826
msgid "View Photo"
msgstr ""
-#: mod/photos.php:1336
+#: mod/photos.php:1324
msgid "Permission denied. Access to this item may be restricted."
msgstr ""
-#: mod/photos.php:1338
+#: mod/photos.php:1326
msgid "Photo not available"
msgstr ""
-#: mod/photos.php:1399
+#: mod/photos.php:1387
msgid "View photo"
msgstr ""
-#: mod/photos.php:1399
+#: mod/photos.php:1387
msgid "Edit photo"
msgstr ""
-#: mod/photos.php:1400
+#: mod/photos.php:1388
msgid "Use as profile photo"
msgstr ""
-#: mod/photos.php:1406 object/Item.php:127
+#: mod/photos.php:1394 src/Object/Item.php:144
msgid "Private Message"
msgstr ""
-#: mod/photos.php:1425
+#: mod/photos.php:1413
msgid "View Full Size"
msgstr ""
-#: mod/photos.php:1515
+#: mod/photos.php:1503
msgid "Tags: "
msgstr ""
-#: mod/photos.php:1518
+#: mod/photos.php:1506
msgid "[Remove any tag]"
msgstr ""
-#: mod/photos.php:1561
+#: mod/photos.php:1543
msgid "New album name"
msgstr ""
-#: mod/photos.php:1562
+#: mod/photos.php:1544
msgid "Caption"
msgstr ""
-#: mod/photos.php:1563
+#: mod/photos.php:1545
msgid "Add a Tag"
msgstr ""
-#: mod/photos.php:1563
+#: mod/photos.php:1545
msgid "Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"
msgstr ""
-#: mod/photos.php:1564
+#: mod/photos.php:1546
msgid "Do not rotate"
msgstr ""
-#: mod/photos.php:1565
+#: mod/photos.php:1547
msgid "Rotate CW (right)"
msgstr ""
-#: mod/photos.php:1566
+#: mod/photos.php:1548
msgid "Rotate CCW (left)"
msgstr ""
-#: mod/photos.php:1581
+#: mod/photos.php:1563
msgid "Private photo"
msgstr ""
-#: mod/photos.php:1582
+#: mod/photos.php:1564
msgid "Public photo"
msgstr ""
-#: mod/photos.php:1602 object/Item.php:280
+#: mod/photos.php:1584 src/Object/Item.php:294
msgid "I like this (toggle)"
msgstr ""
-#: mod/photos.php:1603 object/Item.php:281
+#: mod/photos.php:1585 src/Object/Item.php:295
msgid "I don't like this (toggle)"
msgstr ""
-#: mod/photos.php:1620 mod/photos.php:1662 mod/photos.php:1742
-#: object/Item.php:699
+#: mod/photos.php:1602 mod/photos.php:1644 mod/photos.php:1718
+#: src/Object/Item.php:784
msgid "This is you"
msgstr ""
-#: mod/photos.php:1622 mod/photos.php:1664 mod/photos.php:1744
-#: object/Item.php:386 object/Item.php:701
+#: mod/photos.php:1604 mod/photos.php:1646 mod/photos.php:1720
+#: src/Object/Item.php:391 src/Object/Item.php:786
msgid "Comment"
msgstr ""
-#: mod/photos.php:1791
+#: mod/photos.php:1760
msgid "Map"
msgstr ""
-#: mod/photos.php:1868 mod/videos.php:397
+#: mod/photos.php:1832 mod/videos.php:394
msgid "View Album"
msgstr ""
-#: mod/ping.php:276
+#: mod/ping.php:287
msgid "{0} wants to be your friend"
msgstr ""
-#: mod/ping.php:291
+#: mod/ping.php:302
msgid "{0} sent you a message"
msgstr ""
-#: mod/ping.php:306
+#: mod/ping.php:317
msgid "{0} requested registration"
msgstr ""
-#: mod/poke.php:199
+#: mod/poke.php:200
msgid "Poke/Prod"
msgstr ""
-#: mod/poke.php:200
+#: mod/poke.php:201
msgid "poke, prod or do other things to somebody"
msgstr ""
-#: mod/poke.php:201
+#: mod/poke.php:202
msgid "Recipient"
msgstr ""
-#: mod/poke.php:202
+#: mod/poke.php:203
msgid "Choose what you wish to do to recipient"
msgstr ""
-#: mod/poke.php:205
+#: mod/poke.php:206
msgid "Make this post private"
msgstr ""
-#: mod/profile_photo.php:46
+#: mod/profile.php:182
+msgid "Tips for New Members"
+msgstr ""
+
+#: mod/profile_photo.php:48
msgid "Image uploaded but image cropping failed."
msgstr ""
-#: mod/profile_photo.php:79 mod/profile_photo.php:87 mod/profile_photo.php:95
-#: mod/profile_photo.php:324
+#: mod/profile_photo.php:81 mod/profile_photo.php:89 mod/profile_photo.php:97
+#: mod/profile_photo.php:326
#, php-format
msgid "Image size reduction [%s] failed."
msgstr ""
-#: mod/profile_photo.php:129
+#: mod/profile_photo.php:131
msgid ""
"Shift-reload the page or clear browser cache if the new photo does not "
"display immediately."
msgstr ""
-#: mod/profile_photo.php:138
+#: mod/profile_photo.php:140
msgid "Unable to process image"
msgstr ""
-#: mod/profile_photo.php:255
+#: mod/profile_photo.php:257
msgid "Upload File:"
msgstr ""
-#: mod/profile_photo.php:256
+#: mod/profile_photo.php:258
msgid "Select a profile:"
msgstr ""
-#: mod/profile_photo.php:258
+#: mod/profile_photo.php:260
msgid "Upload"
msgstr ""
-#: mod/profile_photo.php:261
+#: mod/profile_photo.php:263
msgid "or"
msgstr ""
-#: mod/profile_photo.php:261
+#: mod/profile_photo.php:263
msgid "skip this step"
msgstr ""
-#: mod/profile_photo.php:261
+#: mod/profile_photo.php:263
msgid "select a photo from your photo albums"
msgstr ""
-#: mod/profile_photo.php:275
+#: mod/profile_photo.php:277
msgid "Crop Image"
msgstr ""
-#: mod/profile_photo.php:276
+#: mod/profile_photo.php:278
msgid "Please adjust the image cropping for optimum viewing."
msgstr ""
-#: mod/profile_photo.php:278
+#: mod/profile_photo.php:280
msgid "Done Editing"
msgstr ""
-#: mod/profile_photo.php:314
+#: mod/profile_photo.php:316
msgid "Image uploaded successfully."
msgstr ""
-#: mod/profiles.php:44
+#: mod/profiles.php:48
msgid "Profile deleted."
msgstr ""
-#: mod/profiles.php:60 mod/profiles.php:96
+#: mod/profiles.php:64 mod/profiles.php:100
msgid "Profile-"
msgstr ""
-#: mod/profiles.php:79 mod/profiles.php:118
+#: mod/profiles.php:83 mod/profiles.php:122
msgid "New profile created."
msgstr ""
-#: mod/profiles.php:102
+#: mod/profiles.php:106
msgid "Profile unavailable to clone."
msgstr ""
-#: mod/profiles.php:192
+#: mod/profiles.php:196
msgid "Profile Name is required."
msgstr ""
-#: mod/profiles.php:332
+#: mod/profiles.php:336
msgid "Marital Status"
msgstr ""
-#: mod/profiles.php:336
+#: mod/profiles.php:340
msgid "Romantic Partner"
msgstr ""
-#: mod/profiles.php:348
+#: mod/profiles.php:352
msgid "Work/Employment"
msgstr ""
-#: mod/profiles.php:351
+#: mod/profiles.php:355
msgid "Religion"
msgstr ""
-#: mod/profiles.php:355
+#: mod/profiles.php:359
msgid "Political Views"
msgstr ""
-#: mod/profiles.php:359
+#: mod/profiles.php:363
msgid "Gender"
msgstr ""
-#: mod/profiles.php:363
+#: mod/profiles.php:367
msgid "Sexual Preference"
msgstr ""
-#: mod/profiles.php:367
+#: mod/profiles.php:371
msgid "XMPP"
msgstr ""
-#: mod/profiles.php:371
+#: mod/profiles.php:375
msgid "Homepage"
msgstr ""
-#: mod/profiles.php:375 mod/profiles.php:694
+#: mod/profiles.php:379 mod/profiles.php:698
msgid "Interests"
msgstr ""
-#: mod/profiles.php:379
+#: mod/profiles.php:383
msgid "Address"
msgstr ""
-#: mod/profiles.php:386 mod/profiles.php:690
+#: mod/profiles.php:390 mod/profiles.php:694
msgid "Location"
msgstr ""
-#: mod/profiles.php:471
+#: mod/profiles.php:475
msgid "Profile updated."
msgstr ""
-#: mod/profiles.php:563
+#: mod/profiles.php:567
msgid " and "
msgstr ""
-#: mod/profiles.php:572
+#: mod/profiles.php:576
msgid "public profile"
msgstr ""
-#: mod/profiles.php:575
+#: mod/profiles.php:579
#, php-format
msgid "%1$s changed %2$s to “%3$s”"
msgstr ""
-#: mod/profiles.php:576
+#: mod/profiles.php:580
#, php-format
msgid " - Visit %1$s's %2$s"
msgstr ""
-#: mod/profiles.php:578
+#: mod/profiles.php:582
#, php-format
msgid "%1$s has an updated %2$s, changing %3$s."
msgstr ""
-#: mod/profiles.php:636
+#: mod/profiles.php:640
msgid "Hide contacts and friends:"
msgstr ""
-#: mod/profiles.php:641
+#: mod/profiles.php:645
msgid "Hide your contact/friend list from viewers of this profile?"
msgstr ""
-#: mod/profiles.php:666
+#: mod/profiles.php:670
msgid "Show more profile fields:"
msgstr ""
-#: mod/profiles.php:678
+#: mod/profiles.php:682
msgid "Profile Actions"
msgstr ""
-#: mod/profiles.php:679
+#: mod/profiles.php:683
msgid "Edit Profile Details"
msgstr ""
-#: mod/profiles.php:681
+#: mod/profiles.php:685
msgid "Change Profile Photo"
msgstr ""
-#: mod/profiles.php:682
+#: mod/profiles.php:686
msgid "View this profile"
msgstr ""
-#: mod/profiles.php:684
+#: mod/profiles.php:688
msgid "Create a new profile using these settings"
msgstr ""
-#: mod/profiles.php:685
+#: mod/profiles.php:689
msgid "Clone this profile"
msgstr ""
-#: mod/profiles.php:686
+#: mod/profiles.php:690
msgid "Delete this profile"
msgstr ""
-#: mod/profiles.php:688
+#: mod/profiles.php:692
msgid "Basic information"
msgstr ""
-#: mod/profiles.php:689
+#: mod/profiles.php:693
msgid "Profile picture"
msgstr ""
-#: mod/profiles.php:691
+#: mod/profiles.php:695
msgid "Preferences"
msgstr ""
-#: mod/profiles.php:692
+#: mod/profiles.php:696
msgid "Status information"
msgstr ""
-#: mod/profiles.php:693
+#: mod/profiles.php:697
msgid "Additional information"
msgstr ""
-#: mod/profiles.php:696
+#: mod/profiles.php:700
msgid "Relation"
msgstr ""
-#: mod/profiles.php:700
+#: mod/profiles.php:704
msgid "Your Gender:"
msgstr ""
-#: mod/profiles.php:701
+#: mod/profiles.php:705
msgid "<span class=\"heart\">♥</span> Marital Status:"
msgstr ""
-#: mod/profiles.php:703
+#: mod/profiles.php:707
msgid "Example: fishing photography software"
msgstr ""
-#: mod/profiles.php:708
+#: mod/profiles.php:712
msgid "Profile Name:"
msgstr ""
-#: mod/profiles.php:710
+#: mod/profiles.php:714
msgid ""
"This is your <strong>public</strong> profile.<br />It <strong>may</strong> "
"be visible to anybody using the internet."
msgstr ""
-#: mod/profiles.php:711
+#: mod/profiles.php:715
msgid "Your Full Name:"
msgstr ""
-#: mod/profiles.php:712
+#: mod/profiles.php:716
msgid "Title/Description:"
msgstr ""
-#: mod/profiles.php:715
+#: mod/profiles.php:719
msgid "Street Address:"
msgstr ""
-#: mod/profiles.php:716
+#: mod/profiles.php:720
msgid "Locality/City:"
msgstr ""
-#: mod/profiles.php:717
+#: mod/profiles.php:721
msgid "Region/State:"
msgstr ""
-#: mod/profiles.php:718
+#: mod/profiles.php:722
msgid "Postal/Zip Code:"
msgstr ""
-#: mod/profiles.php:719
+#: mod/profiles.php:723
msgid "Country:"
msgstr ""
-#: mod/profiles.php:723
+#: mod/profiles.php:727
msgid "Who: (if applicable)"
msgstr ""
-#: mod/profiles.php:723
+#: mod/profiles.php:727
msgid "Examples: cathy123, Cathy Williams, cathy@example.com"
msgstr ""
-#: mod/profiles.php:724
+#: mod/profiles.php:728
msgid "Since [date]:"
msgstr ""
-#: mod/profiles.php:726
+#: mod/profiles.php:730
msgid "Tell us about yourself..."
msgstr ""
-#: mod/profiles.php:727
+#: mod/profiles.php:731
msgid "XMPP (Jabber) address:"
msgstr ""
-#: mod/profiles.php:727
+#: mod/profiles.php:731
msgid ""
"The XMPP address will be propagated to your contacts so that they can follow "
"you."
msgstr ""
-#: mod/profiles.php:728
+#: mod/profiles.php:732
msgid "Homepage URL:"
msgstr ""
-#: mod/profiles.php:731
+#: mod/profiles.php:735
msgid "Religious Views:"
msgstr ""
-#: mod/profiles.php:732
+#: mod/profiles.php:736
msgid "Public Keywords:"
msgstr ""
-#: mod/profiles.php:732
+#: mod/profiles.php:736
msgid "(Used for suggesting potential friends, can be seen by others)"
msgstr ""
-#: mod/profiles.php:733
+#: mod/profiles.php:737
msgid "Private Keywords:"
msgstr ""
-#: mod/profiles.php:733
+#: mod/profiles.php:737
msgid "(Used for searching profiles, never shown to others)"
msgstr ""
-#: mod/profiles.php:736
+#: mod/profiles.php:740
msgid "Musical interests"
msgstr ""
-#: mod/profiles.php:737
+#: mod/profiles.php:741
msgid "Books, literature"
msgstr ""
-#: mod/profiles.php:738
+#: mod/profiles.php:742
msgid "Television"
msgstr ""
-#: mod/profiles.php:739
+#: mod/profiles.php:743
msgid "Film/dance/culture/entertainment"
msgstr ""
-#: mod/profiles.php:740
+#: mod/profiles.php:744
msgid "Hobbies/Interests"
msgstr ""
-#: mod/profiles.php:741
+#: mod/profiles.php:745
msgid "Love/romance"
msgstr ""
-#: mod/profiles.php:742
+#: mod/profiles.php:746
msgid "Work/employment"
msgstr ""
-#: mod/profiles.php:743
-msgid "School/education"
+#: mod/profiles.php:747
+msgid "School/education"
+msgstr ""
+
+#: mod/profiles.php:748
+msgid "Contact information and Social Networks"
+msgstr ""
+
+#: mod/profiles.php:788
+msgid "Edit/Manage Profiles"
+msgstr ""
+
+#: mod/profperm.php:31 mod/profperm.php:60
+msgid "Invalid profile identifier."
+msgstr ""
+
+#: mod/profperm.php:106
+msgid "Profile Visibility Editor"
msgstr ""
-#: mod/profiles.php:744
-msgid "Contact information and Social Networks"
+#: mod/profperm.php:119
+msgid "Visible To"
msgstr ""
-#: mod/profiles.php:785
-msgid "Edit/Manage Profiles"
+#: mod/profperm.php:135
+msgid "All Contacts (with secure profile access)"
msgstr ""
-#: mod/register.php:98
+#: mod/register.php:100
msgid ""
"Registration successful. Please check your email for further instructions."
msgstr ""
-#: mod/register.php:103
+#: mod/register.php:105
#, php-format
msgid ""
"Failed to send email message. Here your accout details:<br> login: %s<br> "
"password: %s<br><br>You can change your password after login."
msgstr ""
-#: mod/register.php:110
+#: mod/register.php:112
msgid "Registration successful."
msgstr ""
-#: mod/register.php:116
+#: mod/register.php:118
msgid "Your registration can not be processed."
msgstr ""
-#: mod/register.php:165
+#: mod/register.php:167
msgid "Your registration is pending approval by the site owner."
msgstr ""
-#: mod/register.php:231
+#: mod/register.php:205 mod/uimport.php:54
+msgid ""
+"This site has exceeded the number of allowed daily account registrations. "
+"Please try again tomorrow."
+msgstr ""
+
+#: mod/register.php:233
msgid ""
"You may (optionally) fill in this form via OpenID by supplying your OpenID "
"and clicking 'Register'."
msgstr ""
-#: mod/register.php:232
+#: mod/register.php:234
msgid ""
"If you are not familiar with OpenID, please leave that field blank and fill "
"in the rest of the items."
msgstr ""
-#: mod/register.php:233
+#: mod/register.php:235
msgid "Your OpenID (optional): "
msgstr ""
-#: mod/register.php:247
+#: mod/register.php:249
msgid "Include your profile in member directory?"
msgstr ""
-#: mod/register.php:272
+#: mod/register.php:274
msgid "Note for the admin"
msgstr ""
-#: mod/register.php:272
+#: mod/register.php:274
msgid "Leave a message for the admin, why you want to join this node"
msgstr ""
-#: mod/register.php:273
+#: mod/register.php:275
msgid "Membership on this site is by invitation only."
msgstr ""
-#: mod/register.php:274
+#: mod/register.php:276
msgid "Your invitation ID: "
msgstr ""
-#: mod/register.php:285
+#: mod/register.php:287
msgid "Your Full Name (e.g. Joe Smith, real or real-looking): "
msgstr ""
-#: mod/register.php:286
-msgid "Your Email Address: "
+#: mod/register.php:288
+msgid ""
+"Your Email Address: (Initial information will be send there, so this has to "
+"be an existing address.)"
msgstr ""
-#: mod/register.php:288 mod/settings.php:1265
+#: mod/register.php:290 mod/settings.php:1262
msgid "New Password:"
msgstr ""
-#: mod/register.php:288
+#: mod/register.php:290
msgid "Leave empty for an auto generated password."
msgstr ""
-#: mod/register.php:289 mod/settings.php:1266
+#: mod/register.php:291 mod/settings.php:1263
msgid "Confirm:"
msgstr ""
-#: mod/register.php:290
+#: mod/register.php:292
msgid ""
"Choose a profile nickname. This must begin with a text character. Your "
"profile address on this site will then be '<strong>nickname@$sitename</"
"strong>'."
msgstr ""
-#: mod/register.php:291
+#: mod/register.php:293
msgid "Choose a nickname: "
msgstr ""
-#: mod/register.php:301
+#: mod/register.php:302 mod/uimport.php:69
+msgid "Import"
+msgstr ""
+
+#: mod/register.php:303
msgid "Import your profile to this friendica instance"
msgstr ""
-#: mod/regmod.php:62
+#: mod/regmod.php:64
msgid "Account approved."
msgstr ""
-#: mod/regmod.php:90
+#: mod/regmod.php:92
#, php-format
msgid "Registration revoked for %s"
msgstr ""
-#: mod/regmod.php:102
+#: mod/regmod.php:104
msgid "Please login."
msgstr ""
-#: mod/settings.php:60
+#: mod/removeme.php:55 mod/removeme.php:58
+msgid "Remove My Account"
+msgstr ""
+
+#: mod/removeme.php:56
+msgid ""
+"This will completely remove your account. Once this has been done it is not "
+"recoverable."
+msgstr ""
+
+#: mod/removeme.php:57
+msgid "Please enter your password for verification:"
+msgstr ""
+
+#: mod/repair_ostatus.php:16
+msgid "Resubscribing to OStatus contacts"
+msgstr ""
+
+#: mod/repair_ostatus.php:32
+msgid "Error"
+msgstr ""
+
+#: mod/search.php:99
+msgid "Only logged in users are permitted to perform a search."
+msgstr ""
+
+#: mod/search.php:123
+msgid "Too Many Requests"
+msgstr ""
+
+#: mod/search.php:124
+msgid "Only one search per minute is permitted for not logged in users."
+msgstr ""
+
+#: mod/search.php:224
+#, php-format
+msgid "Items tagged with: %s"
+msgstr ""
+
+#: mod/settings.php:63
msgid "Display"
msgstr ""
-#: mod/settings.php:67 mod/settings.php:895
+#: mod/settings.php:70 mod/settings.php:900
msgid "Social Networks"
msgstr ""
-#: mod/settings.php:88
+#: mod/settings.php:91
msgid "Connected apps"
msgstr ""
-#: mod/settings.php:102
+#: mod/settings.php:98 mod/uexport.php:48
+msgid "Export personal data"
+msgstr ""
+
+#: mod/settings.php:105
msgid "Remove account"
msgstr ""
-#: mod/settings.php:157
+#: mod/settings.php:160
msgid "Missing some important data!"
msgstr ""
-#: mod/settings.php:267
+#: mod/settings.php:270
msgid "Failed to connect with email account using the settings provided."
msgstr ""
-#: mod/settings.php:272
+#: mod/settings.php:275
msgid "Email settings updated."
msgstr ""
-#: mod/settings.php:288
+#: mod/settings.php:291
msgid "Features updated"
msgstr ""
-#: mod/settings.php:359
+#: mod/settings.php:364
msgid "Relocate message has been send to your contacts"
msgstr ""
-#: mod/settings.php:378
+#: mod/settings.php:383
msgid "Empty passwords are not allowed. Password unchanged."
msgstr ""
-#: mod/settings.php:386
+#: mod/settings.php:391
msgid "Wrong password."
msgstr ""
-#: mod/settings.php:397
+#: mod/settings.php:402
msgid "Password changed."
msgstr ""
-#: mod/settings.php:399
+#: mod/settings.php:404
msgid "Password update failed. Please try again."
msgstr ""
-#: mod/settings.php:489
+#: mod/settings.php:494
msgid " Please use a shorter name."
msgstr ""
-#: mod/settings.php:492
+#: mod/settings.php:497
msgid " Name too short."
msgstr ""
-#: mod/settings.php:502
+#: mod/settings.php:507
msgid "Wrong Password"
msgstr ""
-#: mod/settings.php:507
+#: mod/settings.php:512
msgid " Not valid email."
msgstr ""
-#: mod/settings.php:514
+#: mod/settings.php:519
msgid " Cannot change to that email."
msgstr ""
-#: mod/settings.php:570
+#: mod/settings.php:575
msgid "Private forum has no privacy permissions. Using default privacy group."
msgstr ""
-#: mod/settings.php:573
+#: mod/settings.php:578
msgid "Private forum has no privacy permissions and no default privacy group."
msgstr ""
-#: mod/settings.php:613
+#: mod/settings.php:618
msgid "Settings updated."
msgstr ""
-#: mod/settings.php:690 mod/settings.php:716 mod/settings.php:752
+#: mod/settings.php:695 mod/settings.php:721 mod/settings.php:757
msgid "Add application"
msgstr ""
-#: mod/settings.php:694 mod/settings.php:720
+#: mod/settings.php:699 mod/settings.php:725
msgid "Consumer Key"
msgstr ""
-#: mod/settings.php:695 mod/settings.php:721
+#: mod/settings.php:700 mod/settings.php:726
msgid "Consumer Secret"
msgstr ""
-#: mod/settings.php:696 mod/settings.php:722
+#: mod/settings.php:701 mod/settings.php:727
msgid "Redirect"
msgstr ""
-#: mod/settings.php:697 mod/settings.php:723
+#: mod/settings.php:702 mod/settings.php:728
msgid "Icon url"
msgstr ""
-#: mod/settings.php:708
+#: mod/settings.php:713
msgid "You can't edit this application."
msgstr ""
-#: mod/settings.php:751
+#: mod/settings.php:756
msgid "Connected Apps"
msgstr ""
-#: mod/settings.php:753 object/Item.php:132 object/Item.php:134
+#: mod/settings.php:758 src/Object/Item.php:149 src/Object/Item.php:151
msgid "Edit"
msgstr ""
-#: mod/settings.php:755
+#: mod/settings.php:760
msgid "Client key starts with"
msgstr ""
-#: mod/settings.php:756
+#: mod/settings.php:761
msgid "No name"
msgstr ""
-#: mod/settings.php:757
+#: mod/settings.php:762
msgid "Remove authorization"
msgstr ""
-#: mod/settings.php:769
+#: mod/settings.php:774
msgid "No Plugin settings configured"
msgstr ""
-#: mod/settings.php:778
+#: mod/settings.php:783
msgid "Plugin Settings"
msgstr ""
-#: mod/settings.php:800
+#: mod/settings.php:805
msgid "Additional Features"
msgstr ""
-#: mod/settings.php:810 mod/settings.php:814
+#: mod/settings.php:815 mod/settings.php:819
msgid "General Social Media Settings"
msgstr ""
-#: mod/settings.php:820
+#: mod/settings.php:825
msgid "Disable intelligent shortening"
msgstr ""
-#: mod/settings.php:822
+#: mod/settings.php:827
msgid ""
"Normally the system tries to find the best link to add to shortened posts. "
"If this option is enabled then every shortened post will always point to the "
"original friendica post."
msgstr ""
-#: mod/settings.php:828
+#: mod/settings.php:833
msgid "Automatically follow any GNU Social (OStatus) followers/mentioners"
msgstr ""
-#: mod/settings.php:830
+#: mod/settings.php:835
msgid ""
"If you receive a message from an unknown OStatus user, this option decides "
"what to do. If it is checked, a new contact will be created for every "
"unknown user."
msgstr ""
-#: mod/settings.php:836
+#: mod/settings.php:841
msgid "Default group for OStatus contacts"
msgstr ""
-#: mod/settings.php:844
+#: mod/settings.php:849
msgid "Your legacy GNU Social account"
msgstr ""
-#: mod/settings.php:846
+#: mod/settings.php:851
msgid ""
"If you enter your old GNU Social/Statusnet account name here (in the format "
"user@domain.tld), your contacts will be added automatically. The field will "
"be emptied when done."
msgstr ""
-#: mod/settings.php:849
+#: mod/settings.php:854
msgid "Repair OStatus subscriptions"
msgstr ""
-#: mod/settings.php:858 mod/settings.php:859
+#: mod/settings.php:863 mod/settings.php:864
#, php-format
msgid "Built-in support for %s connectivity is %s"
msgstr ""
-#: mod/settings.php:858 mod/settings.php:859
+#: mod/settings.php:863 mod/settings.php:864
msgid "enabled"
msgstr ""
-#: mod/settings.php:858 mod/settings.php:859
+#: mod/settings.php:863 mod/settings.php:864
msgid "disabled"
msgstr ""
-#: mod/settings.php:859
+#: mod/settings.php:864
msgid "GNU Social (OStatus)"
msgstr ""
-#: mod/settings.php:890
+#: mod/settings.php:895
msgid "Email access is disabled on this site."
msgstr ""
-#: mod/settings.php:900
+#: mod/settings.php:905
msgid "Email/Mailbox Setup"
msgstr ""
-#: mod/settings.php:901
+#: mod/settings.php:906
msgid ""
"If you wish to communicate with email contacts using this service "
"(optional), please specify how to connect to your mailbox."
msgstr ""
-#: mod/settings.php:902
+#: mod/settings.php:907
msgid "Last successful email check:"
msgstr ""
-#: mod/settings.php:904
+#: mod/settings.php:909
msgid "IMAP server name:"
msgstr ""
-#: mod/settings.php:905
+#: mod/settings.php:910
msgid "IMAP port:"
msgstr ""
-#: mod/settings.php:906
+#: mod/settings.php:911
msgid "Security:"
msgstr ""
-#: mod/settings.php:906 mod/settings.php:911
+#: mod/settings.php:911 mod/settings.php:916
msgid "None"
msgstr ""
-#: mod/settings.php:907
+#: mod/settings.php:912
msgid "Email login name:"
msgstr ""
-#: mod/settings.php:908
+#: mod/settings.php:913
msgid "Email password:"
msgstr ""
-#: mod/settings.php:909
+#: mod/settings.php:914
msgid "Reply-to address:"
msgstr ""
-#: mod/settings.php:910
+#: mod/settings.php:915
msgid "Send public posts to all email contacts:"
msgstr ""
-#: mod/settings.php:911
+#: mod/settings.php:916
msgid "Action after import:"
msgstr ""
-#: mod/settings.php:911
+#: mod/settings.php:916
msgid "Move to folder"
msgstr ""
-#: mod/settings.php:912
+#: mod/settings.php:917
msgid "Move to folder:"
msgstr ""
-#: mod/settings.php:1008
+#: mod/settings.php:1004
msgid "Display Settings"
msgstr ""
-#: mod/settings.php:1014 mod/settings.php:1037
+#: mod/settings.php:1010 mod/settings.php:1034
msgid "Display Theme:"
msgstr ""
-#: mod/settings.php:1015
+#: mod/settings.php:1011
msgid "Mobile Theme:"
msgstr ""
-#: mod/settings.php:1016
+#: mod/settings.php:1012
msgid "Suppress warning of insecure networks"
msgstr ""
-#: mod/settings.php:1016
+#: mod/settings.php:1012
msgid ""
"Should the system suppress the warning that the current group contains "
"members of networks that can't receive non public postings."
msgstr ""
-#: mod/settings.php:1017
+#: mod/settings.php:1013
msgid "Update browser every xx seconds"
msgstr ""
-#: mod/settings.php:1017
+#: mod/settings.php:1013
msgid "Minimum of 10 seconds. Enter -1 to disable it."
msgstr ""
-#: mod/settings.php:1018
+#: mod/settings.php:1014
msgid "Number of items to display per page:"
msgstr ""
-#: mod/settings.php:1018 mod/settings.php:1019
+#: mod/settings.php:1014 mod/settings.php:1015
msgid "Maximum of 100 items"
msgstr ""
-#: mod/settings.php:1019
+#: mod/settings.php:1015
msgid "Number of items to display per page when viewed from mobile device:"
msgstr ""
-#: mod/settings.php:1020
+#: mod/settings.php:1016
msgid "Don't show emoticons"
msgstr ""
-#: mod/settings.php:1021
+#: mod/settings.php:1017
msgid "Calendar"
msgstr ""
-#: mod/settings.php:1022
+#: mod/settings.php:1018
msgid "Beginning of week:"
msgstr ""
-#: mod/settings.php:1023
+#: mod/settings.php:1019
msgid "Don't show notices"
msgstr ""
-#: mod/settings.php:1024
+#: mod/settings.php:1020
msgid "Infinite scroll"
msgstr ""
-#: mod/settings.php:1025
+#: mod/settings.php:1021
msgid "Automatic updates only at the top of the network page"
msgstr ""
-#: mod/settings.php:1025
+#: mod/settings.php:1021
msgid ""
"When disabled, the network page is updated all the time, which could be "
"confusing while reading."
msgstr ""
-#: mod/settings.php:1026
+#: mod/settings.php:1022
msgid "Bandwith Saver Mode"
msgstr ""
-#: mod/settings.php:1026
+#: mod/settings.php:1022
msgid ""
"When enabled, embedded content is not displayed on automatic updates, they "
"only show on page reload."
msgstr ""
-#: mod/settings.php:1028
+#: mod/settings.php:1023
+msgid "Smart Threading"
+msgstr ""
+
+#: mod/settings.php:1023
+msgid ""
+"When enabled, suppress extraneous thread indentation while keeping it where "
+"it matters. Only works if threading is available and enabled."
+msgstr ""
+
+#: mod/settings.php:1025
msgid "General Theme Settings"
msgstr ""
-#: mod/settings.php:1029
+#: mod/settings.php:1026
msgid "Custom Theme Settings"
msgstr ""
-#: mod/settings.php:1030
+#: mod/settings.php:1027
msgid "Content Settings"
msgstr ""
-#: mod/settings.php:1031 view/theme/duepuntozero/config.php:67
-#: view/theme/frio/config.php:110 view/theme/quattro/config.php:73
-#: view/theme/vier/config.php:116
+#: mod/settings.php:1028 view/theme/duepuntozero/config.php:69
+#: view/theme/frio/config.php:110 view/theme/quattro/config.php:75
+#: view/theme/vier/config.php:119
msgid "Theme settings"
msgstr ""
-#: mod/settings.php:1097
+#: mod/settings.php:1094
msgid "Account Types"
msgstr ""
-#: mod/settings.php:1098
+#: mod/settings.php:1095
msgid "Personal Page Subtypes"
msgstr ""
-#: mod/settings.php:1099
+#: mod/settings.php:1096
msgid "Community Forum Subtypes"
msgstr ""
-#: mod/settings.php:1106
+#: mod/settings.php:1103
msgid "Personal Page"
msgstr ""
-#: mod/settings.php:1107
+#: mod/settings.php:1104
msgid "Account for a personal profile."
msgstr ""
-#: mod/settings.php:1110
+#: mod/settings.php:1107
msgid "Organisation Page"
msgstr ""
-#: mod/settings.php:1111
+#: mod/settings.php:1108
msgid ""
"Account for an organisation that automatically approves contact requests as "
"\"Followers\"."
msgstr ""
-#: mod/settings.php:1114
+#: mod/settings.php:1111
msgid "News Page"
msgstr ""
-#: mod/settings.php:1115
+#: mod/settings.php:1112
msgid ""
"Account for a news reflector that automatically approves contact requests as "
"\"Followers\"."
msgstr ""
-#: mod/settings.php:1118
+#: mod/settings.php:1115
msgid "Community Forum"
msgstr ""
-#: mod/settings.php:1119
+#: mod/settings.php:1116
msgid "Account for community discussions."
msgstr ""
-#: mod/settings.php:1122
+#: mod/settings.php:1119
msgid "Normal Account Page"
msgstr ""
-#: mod/settings.php:1123
+#: mod/settings.php:1120
msgid ""
"Account for a regular personal profile that requires manual approval of "
"\"Friends\" and \"Followers\"."
msgstr ""
-#: mod/settings.php:1126
+#: mod/settings.php:1123
msgid "Soapbox Page"
msgstr ""
-#: mod/settings.php:1127
+#: mod/settings.php:1124
msgid ""
"Account for a public profile that automatically approves contact requests as "
"\"Followers\"."
msgstr ""
-#: mod/settings.php:1130
+#: mod/settings.php:1127
msgid "Public Forum"
msgstr ""
-#: mod/settings.php:1131
+#: mod/settings.php:1128
msgid "Automatically approves all contact requests."
msgstr ""
-#: mod/settings.php:1134
+#: mod/settings.php:1131
msgid "Automatic Friend Page"
msgstr ""
-#: mod/settings.php:1135
+#: mod/settings.php:1132
msgid ""
"Account for a popular profile that automatically approves contact requests "
"as \"Friends\"."
msgstr ""
-#: mod/settings.php:1138
+#: mod/settings.php:1135
msgid "Private Forum [Experimental]"
msgstr ""
-#: mod/settings.php:1139
+#: mod/settings.php:1136
msgid "Requires manual approval of contact requests."
msgstr ""
-#: mod/settings.php:1150
+#: mod/settings.php:1147
msgid "OpenID:"
msgstr ""
-#: mod/settings.php:1150
+#: mod/settings.php:1147
msgid "(Optional) Allow this OpenID to login to this account."
msgstr ""
-#: mod/settings.php:1158
+#: mod/settings.php:1155
msgid "Publish your default profile in your local site directory?"
msgstr ""
-#: mod/settings.php:1158
+#: mod/settings.php:1155
msgid "Your profile may be visible in public."
msgstr ""
-#: mod/settings.php:1164
+#: mod/settings.php:1161
msgid "Publish your default profile in the global social directory?"
msgstr ""
-#: mod/settings.php:1171
+#: mod/settings.php:1168
msgid "Hide your contact/friend list from viewers of your default profile?"
msgstr ""
-#: mod/settings.php:1175
+#: mod/settings.php:1172
msgid ""
"If enabled, posting public messages to Diaspora and other networks isn't "
"possible."
msgstr ""
-#: mod/settings.php:1180
+#: mod/settings.php:1177
msgid "Allow friends to post to your profile page?"
msgstr ""
-#: mod/settings.php:1185
+#: mod/settings.php:1182
msgid "Allow friends to tag your posts?"
msgstr ""
-#: mod/settings.php:1190
+#: mod/settings.php:1187
msgid "Allow us to suggest you as a potential friend to new members?"
msgstr ""
-#: mod/settings.php:1195
+#: mod/settings.php:1192
msgid "Permit unknown people to send you private mail?"
msgstr ""
-#: mod/settings.php:1203
+#: mod/settings.php:1200
msgid "Profile is <strong>not published</strong>."
msgstr ""
-#: mod/settings.php:1211
+#: mod/settings.php:1208
#, php-format
msgid "Your Identity Address is <strong>'%s'</strong> or '%s'."
msgstr ""
-#: mod/settings.php:1218
+#: mod/settings.php:1215
msgid "Automatically expire posts after this many days:"
msgstr ""
-#: mod/settings.php:1218
+#: mod/settings.php:1215
msgid "If empty, posts will not expire. Expired posts will be deleted"
msgstr ""
-#: mod/settings.php:1219
+#: mod/settings.php:1216
msgid "Advanced expiration settings"
msgstr ""
-#: mod/settings.php:1220
+#: mod/settings.php:1217
msgid "Advanced Expiration"
msgstr ""
-#: mod/settings.php:1221
+#: mod/settings.php:1218
msgid "Expire posts:"
msgstr ""
-#: mod/settings.php:1222
+#: mod/settings.php:1219
msgid "Expire personal notes:"
msgstr ""
-#: mod/settings.php:1223
+#: mod/settings.php:1220
msgid "Expire starred posts:"
msgstr ""
-#: mod/settings.php:1224
+#: mod/settings.php:1221
msgid "Expire photos:"
msgstr ""
-#: mod/settings.php:1225
+#: mod/settings.php:1222
msgid "Only expire posts by others:"
msgstr ""
-#: mod/settings.php:1256
+#: mod/settings.php:1253
msgid "Account Settings"
msgstr ""
-#: mod/settings.php:1264
+#: mod/settings.php:1261
msgid "Password Settings"
msgstr ""
-#: mod/settings.php:1266
+#: mod/settings.php:1263
msgid "Leave password fields blank unless changing"
msgstr ""
-#: mod/settings.php:1267
+#: mod/settings.php:1264
msgid "Current Password:"
msgstr ""
-#: mod/settings.php:1267 mod/settings.php:1268
+#: mod/settings.php:1264 mod/settings.php:1265
msgid "Your current password to confirm the changes"
msgstr ""
-#: mod/settings.php:1268
+#: mod/settings.php:1265
msgid "Password:"
msgstr ""
-#: mod/settings.php:1272
+#: mod/settings.php:1269
msgid "Basic Settings"
msgstr ""
-#: mod/settings.php:1274
+#: mod/settings.php:1271
msgid "Email Address:"
msgstr ""
-#: mod/settings.php:1275
+#: mod/settings.php:1272
msgid "Your Timezone:"
msgstr ""
-#: mod/settings.php:1276
+#: mod/settings.php:1273
msgid "Your Language:"
msgstr ""
-#: mod/settings.php:1276
+#: mod/settings.php:1273
msgid ""
"Set the language we use to show you friendica interface and to send you "
"emails"
msgstr ""
-#: mod/settings.php:1277
+#: mod/settings.php:1274
msgid "Default Post Location:"
msgstr ""
-#: mod/settings.php:1278
+#: mod/settings.php:1275
msgid "Use Browser Location:"
msgstr ""
-#: mod/settings.php:1281
+#: mod/settings.php:1278
msgid "Security and Privacy Settings"
msgstr ""
-#: mod/settings.php:1283
+#: mod/settings.php:1280
msgid "Maximum Friend Requests/Day:"
msgstr ""
-#: mod/settings.php:1283 mod/settings.php:1313
+#: mod/settings.php:1280 mod/settings.php:1310
msgid "(to prevent spam abuse)"
msgstr ""
-#: mod/settings.php:1284
+#: mod/settings.php:1281
msgid "Default Post Permissions"
msgstr ""
-#: mod/settings.php:1285
+#: mod/settings.php:1282
msgid "(click to open/close)"
msgstr ""
-#: mod/settings.php:1296
+#: mod/settings.php:1293
msgid "Default Private Post"
msgstr ""
-#: mod/settings.php:1297
+#: mod/settings.php:1294
msgid "Default Public Post"
msgstr ""
-#: mod/settings.php:1301
+#: mod/settings.php:1298
msgid "Default Permissions for New Posts"
msgstr ""
-#: mod/settings.php:1313
+#: mod/settings.php:1310
msgid "Maximum private messages per day from unknown people:"
msgstr ""
-#: mod/settings.php:1316
+#: mod/settings.php:1313
msgid "Notification Settings"
msgstr ""
-#: mod/settings.php:1317
+#: mod/settings.php:1314
msgid "By default post a status message when:"
msgstr ""
-#: mod/settings.php:1318
+#: mod/settings.php:1315
msgid "accepting a friend request"
msgstr ""
-#: mod/settings.php:1319
+#: mod/settings.php:1316
msgid "joining a forum/community"
msgstr ""
-#: mod/settings.php:1320
+#: mod/settings.php:1317
msgid "making an <em>interesting</em> profile change"
msgstr ""
-#: mod/settings.php:1321
+#: mod/settings.php:1318
msgid "Send a notification email when:"
msgstr ""
-#: mod/settings.php:1322
+#: mod/settings.php:1319
msgid "You receive an introduction"
msgstr ""
-#: mod/settings.php:1323
+#: mod/settings.php:1320
msgid "Your introductions are confirmed"
msgstr ""
-#: mod/settings.php:1324
+#: mod/settings.php:1321
msgid "Someone writes on your profile wall"
msgstr ""
-#: mod/settings.php:1325
+#: mod/settings.php:1322
msgid "Someone writes a followup comment"
msgstr ""
-#: mod/settings.php:1326
+#: mod/settings.php:1323
msgid "You receive a private message"
msgstr ""
-#: mod/settings.php:1327
+#: mod/settings.php:1324
msgid "You receive a friend suggestion"
msgstr ""
-#: mod/settings.php:1328
+#: mod/settings.php:1325
msgid "You are tagged in a post"
msgstr ""
-#: mod/settings.php:1329
+#: mod/settings.php:1326
msgid "You are poked/prodded/etc. in a post"
msgstr ""
-#: mod/settings.php:1331
+#: mod/settings.php:1328
msgid "Activate desktop notifications"
msgstr ""
-#: mod/settings.php:1331
+#: mod/settings.php:1328
msgid "Show desktop popup on new notifications"
msgstr ""
-#: mod/settings.php:1333
+#: mod/settings.php:1330
msgid "Text-only notification emails"
msgstr ""
-#: mod/settings.php:1335
+#: mod/settings.php:1332
msgid "Send text only notification emails, without the html part"
msgstr ""
-#: mod/settings.php:1337
+#: mod/settings.php:1334
msgid "Show detailled notifications"
msgstr ""
-#: mod/settings.php:1339
+#: mod/settings.php:1336
msgid ""
"Per default the notificiation are condensed to a single notification per "
"item. When enabled, every notification is displayed."
msgstr ""
-#: mod/settings.php:1341
+#: mod/settings.php:1338
msgid "Advanced Account/Page Type Settings"
msgstr ""
-#: mod/settings.php:1342
+#: mod/settings.php:1339
msgid "Change the behaviour of this account for special situations"
msgstr ""
-#: mod/settings.php:1345
+#: mod/settings.php:1342
msgid "Relocate"
msgstr ""
-#: mod/settings.php:1346
+#: mod/settings.php:1343
msgid ""
"If you have moved this profile from another server, and some of your "
"contacts don't receive your updates, try pushing this button."
msgstr ""
-#: mod/settings.php:1347
+#: mod/settings.php:1344
msgid "Resend relocate message to contacts"
msgstr ""
-#: mod/videos.php:128
-msgid "Do you really want to delete this video?"
-msgstr ""
-
-#: mod/videos.php:133
-msgid "Delete Video"
-msgstr ""
-
-#: mod/videos.php:212
-msgid "No videos selected"
+#: mod/subthread.php:107
+#, php-format
+msgid "%1$s is following %2$s's %3$s"
msgstr ""
-#: mod/videos.php:406
-msgid "Recent Videos"
+#: mod/suggest.php:34
+msgid "Do you really want to delete this suggestion?"
msgstr ""
-#: mod/videos.php:408
-msgid "Upload New Videos"
+#: mod/suggest.php:75
+msgid ""
+"No suggestions available. If this is a new site, please try again in 24 "
+"hours."
msgstr ""
-#: mod/wall_attach.php:19 mod/wall_attach.php:27 mod/wall_attach.php:78
-#: mod/wall_upload.php:37 mod/wall_upload.php:53 mod/wall_upload.php:111
-#: mod/wall_upload.php:151 mod/wall_upload.php:154
-msgid "Invalid request."
+#: mod/suggest.php:88 mod/suggest.php:108
+msgid "Ignore/Hide"
msgstr ""
-#: mod/wall_attach.php:96
-msgid "Sorry, maybe your upload is bigger than the PHP configuration allows"
+#: mod/tagrm.php:47
+msgid "Tag removed"
msgstr ""
-#: mod/wall_attach.php:96
-msgid "Or - did you try to upload an empty file?"
+#: mod/tagrm.php:86
+msgid "Remove Item Tag"
msgstr ""
-#: mod/wall_attach.php:107
-#, php-format
-msgid "File exceeds size limit of %s"
+#: mod/tagrm.php:88
+msgid "Select a tag to remove: "
msgstr ""
-#: mod/wall_attach.php:131 mod/wall_attach.php:147
-msgid "File upload failed."
+#: mod/uexport.php:40
+msgid "Export account"
msgstr ""
-#: object/Item.php:106
-msgid "This entry was edited"
+#: mod/uexport.php:40
+msgid ""
+"Export your account info and contacts. Use this to make a backup of your "
+"account and/or to move it to another server."
msgstr ""
-#: object/Item.php:151
-msgid "save to folder"
+#: mod/uexport.php:41
+msgid "Export all"
msgstr ""
-#: object/Item.php:221
-msgid "I will attend"
+#: mod/uexport.php:41
+msgid ""
+"Export your accout info, contacts and all your items as json. Could be a "
+"very big file, and could take a lot of time. Use this to make a full backup "
+"of your account (photos are not exported)"
msgstr ""
-#: object/Item.php:221
-msgid "I will not attend"
+#: mod/uimport.php:71
+msgid "Move account"
msgstr ""
-#: object/Item.php:221
-msgid "I might attend"
+#: mod/uimport.php:72
+msgid "You can import an account from another Friendica server."
msgstr ""
-#: object/Item.php:247
-msgid "add star"
+#: mod/uimport.php:73
+msgid ""
+"You need to export your account from the old server and upload it here. We "
+"will recreate your old account here with all your contacts. We will try also "
+"to inform your friends that you moved here."
msgstr ""
-#: object/Item.php:248
-msgid "remove star"
+#: mod/uimport.php:74
+msgid ""
+"This feature is experimental. We can't import contacts from the OStatus "
+"network (GNU Social/Statusnet) or from Diaspora"
msgstr ""
-#: object/Item.php:249
-msgid "toggle star status"
+#: mod/uimport.php:75
+msgid "Account file"
msgstr ""
-#: object/Item.php:252
-msgid "starred"
+#: mod/uimport.php:75
+msgid ""
+"To export your account, go to \"Settings->Export your personal data\" and "
+"select \"Export account\""
msgstr ""
-#: object/Item.php:257
-msgid "ignore thread"
+#: mod/unfollow.php:33
+msgid "Contact wasn't found or can't be unfollowed."
msgstr ""
-#: object/Item.php:258
-msgid "unignore thread"
+#: mod/unfollow.php:46
+msgid "Contact unfollowed"
msgstr ""
-#: object/Item.php:259
-msgid "toggle ignore status"
+#: mod/unfollow.php:72
+msgid "You aren't a friend of this contact."
msgstr ""
-#: object/Item.php:269
-msgid "add tag"
+#: mod/unfollow.php:78
+msgid "Unfollowing is currently not supported by your network."
msgstr ""
-#: object/Item.php:280
-msgid "like"
+#: mod/update_community.php:22 mod/update_display.php:26
+#: mod/update_network.php:30 mod/update_notes.php:39 mod/update_profile.php:38
+msgid "[Embedded content - reload page to view]"
msgstr ""
-#: object/Item.php:281
-msgid "dislike"
+#: mod/videos.php:131
+msgid "Do you really want to delete this video?"
msgstr ""
-#: object/Item.php:284
-msgid "Share this"
+#: mod/videos.php:136
+msgid "Delete Video"
msgstr ""
-#: object/Item.php:284
-msgid "share"
+#: mod/videos.php:215
+msgid "No videos selected"
msgstr ""
-#: object/Item.php:352
-msgid "to"
+#: mod/videos.php:403
+msgid "Recent Videos"
msgstr ""
-#: object/Item.php:353
-msgid "via"
+#: mod/videos.php:405
+msgid "Upload New Videos"
msgstr ""
-#: object/Item.php:354
-msgid "Wall-to-Wall"
+#: mod/viewcontacts.php:80
+msgid "No contacts."
msgstr ""
-#: object/Item.php:355
-msgid "via Wall-To-Wall:"
+#: mod/viewsrc.php:9
+msgid "Access denied."
msgstr ""
-#: object/Item.php:414
-#, php-format
-msgid "%d comment"
-msgid_plural "%d comments"
-msgstr[0] ""
-msgstr[1] ""
+#: mod/wall_attach.php:21 mod/wall_attach.php:29 mod/wall_attach.php:80
+#: mod/wall_upload.php:38 mod/wall_upload.php:54 mod/wall_upload.php:112
+#: mod/wall_upload.php:152 mod/wall_upload.php:155
+msgid "Invalid request."
+msgstr ""
-#: object/Item.php:703
-msgid "Bold"
+#: mod/wall_attach.php:98
+msgid "Sorry, maybe your upload is bigger than the PHP configuration allows"
msgstr ""
-#: object/Item.php:704
-msgid "Italic"
+#: mod/wall_attach.php:98
+msgid "Or - did you try to upload an empty file?"
msgstr ""
-#: object/Item.php:705
-msgid "Underline"
+#: mod/wall_attach.php:109
+#, php-format
+msgid "File exceeds size limit of %s"
msgstr ""
-#: object/Item.php:706
-msgid "Quote"
+#: mod/wall_attach.php:133 mod/wall_attach.php:149
+msgid "File upload failed."
msgstr ""
-#: object/Item.php:707
-msgid "Code"
+#: mod/wallmessage.php:46 mod/wallmessage.php:110
+#, php-format
+msgid "Number of daily wall messages for %s exceeded. Message failed."
msgstr ""
-#: object/Item.php:708
-msgid "Image"
+#: mod/wallmessage.php:57
+msgid "Unable to check your home location."
msgstr ""
-#: object/Item.php:709
-msgid "Link"
+#: mod/wallmessage.php:84 mod/wallmessage.php:93
+msgid "No recipient."
msgstr ""
-#: object/Item.php:710
-msgid "Video"
+#: mod/wallmessage.php:131
+#, php-format
+msgid ""
+"If you wish for %s to respond, please check that the privacy settings on "
+"your site allow private mail from unknown senders."
msgstr ""
-#: view/theme/duepuntozero/config.php:48
+#: view/theme/duepuntozero/config.php:50
msgid "greenzero"
msgstr ""
-#: view/theme/duepuntozero/config.php:49
+#: view/theme/duepuntozero/config.php:51
msgid "purplezero"
msgstr ""
-#: view/theme/duepuntozero/config.php:50
+#: view/theme/duepuntozero/config.php:52
msgid "easterbunny"
msgstr ""
-#: view/theme/duepuntozero/config.php:51
+#: view/theme/duepuntozero/config.php:53
msgid "darkzero"
msgstr ""
-#: view/theme/duepuntozero/config.php:52
+#: view/theme/duepuntozero/config.php:54
msgid "comix"
msgstr ""
-#: view/theme/duepuntozero/config.php:53
+#: view/theme/duepuntozero/config.php:55
msgid "slackr"
msgstr ""
-#: view/theme/duepuntozero/config.php:68
+#: view/theme/duepuntozero/config.php:70
msgid "Variations"
msgstr ""
msgid "Set the background image"
msgstr ""
-#: view/theme/frio/theme.php:231
+#: view/theme/frio/theme.php:234
msgid "Guest"
msgstr ""
-#: view/theme/frio/theme.php:237
+#: view/theme/frio/theme.php:240
msgid "Visitor"
msgstr ""
-#: view/theme/quattro/config.php:74
+#: view/theme/quattro/config.php:76
msgid "Alignment"
msgstr ""
-#: view/theme/quattro/config.php:74
+#: view/theme/quattro/config.php:76
msgid "Left"
msgstr ""
-#: view/theme/quattro/config.php:74
+#: view/theme/quattro/config.php:76
msgid "Center"
msgstr ""
-#: view/theme/quattro/config.php:75
+#: view/theme/quattro/config.php:77
msgid "Color scheme"
msgstr ""
-#: view/theme/quattro/config.php:76
+#: view/theme/quattro/config.php:78
msgid "Posts font size"
msgstr ""
-#: view/theme/quattro/config.php:77
+#: view/theme/quattro/config.php:79
msgid "Textareas font size"
msgstr ""
-#: view/theme/vier/theme.php:144 view/theme/vier/config.php:119
+#: view/theme/vier/config.php:73
+msgid "Comma separated list of helper forums"
+msgstr ""
+
+#: view/theme/vier/config.php:120
+msgid "Set style"
+msgstr ""
+
+#: view/theme/vier/config.php:121
+msgid "Community Pages"
+msgstr ""
+
+#: view/theme/vier/config.php:122 view/theme/vier/theme.php:147
msgid "Community Profiles"
msgstr ""
-#: view/theme/vier/theme.php:174 view/theme/vier/config.php:123
-msgid "Last users"
+#: view/theme/vier/config.php:123
+msgid "Help or @NewHere ?"
+msgstr ""
+
+#: view/theme/vier/config.php:124 view/theme/vier/theme.php:385
+msgid "Connect Services"
msgstr ""
-#: view/theme/vier/theme.php:192 view/theme/vier/config.php:122
+#: view/theme/vier/config.php:125 view/theme/vier/theme.php:195
msgid "Find Friends"
msgstr ""
-#: view/theme/vier/theme.php:193
+#: view/theme/vier/config.php:126 view/theme/vier/theme.php:177
+msgid "Last users"
+msgstr ""
+
+#: view/theme/vier/theme.php:196
msgid "Local Directory"
msgstr ""
+#: view/theme/vier/theme.php:251 src/Content/ForumManager.php:123
+msgid "External link to forum"
+msgstr ""
+
#: view/theme/vier/theme.php:285
msgid "Quick Start"
msgstr ""
-#: view/theme/vier/theme.php:385 view/theme/vier/config.php:121
-msgid "Connect Services"
+#: src/Core/NotificationsManager.php:176
+msgid "System"
msgstr ""
-#: view/theme/vier/config.php:71
-msgid "Comma separated list of helper forums"
+#: src/Core/NotificationsManager.php:261 src/Core/NotificationsManager.php:273
+#, php-format
+msgid "%s commented on %s's post"
msgstr ""
-#: view/theme/vier/config.php:117
-msgid "Set style"
+#: src/Core/NotificationsManager.php:272
+#, php-format
+msgid "%s created a new post"
msgstr ""
-#: view/theme/vier/config.php:118
-msgid "Community Pages"
+#: src/Core/NotificationsManager.php:286
+#, php-format
+msgid "%s liked %s's post"
msgstr ""
-#: view/theme/vier/config.php:120
-msgid "Help or @NewHere ?"
+#: src/Core/NotificationsManager.php:299
+#, php-format
+msgid "%s disliked %s's post"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:312
+#, php-format
+msgid "%s is attending %s's event"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:325
+#, php-format
+msgid "%s is not attending %s's event"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:338
+#, php-format
+msgid "%s may attend %s's event"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:355
+#, php-format
+msgid "%s is now friends with %s"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:829
+msgid "Friend Suggestion"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:856
+msgid "Friend/Connect Request"
+msgstr ""
+
+#: src/Core/NotificationsManager.php:856
+msgid "New Follower"
msgstr ""
#: src/App.php:522
msgid "show fewer"
msgstr ""
-#: boot.php:738
+#: src/Object/Contact.php:440
+msgid "Drop Contact"
+msgstr ""
+
+#: src/Object/Contact.php:807
+msgid "Organisation"
+msgstr ""
+
+#: src/Object/Contact.php:810
+msgid "News"
+msgstr ""
+
+#: src/Object/Contact.php:813
+msgid "Forum"
+msgstr ""
+
+#: src/Object/Item.php:123
+msgid "This entry was edited"
+msgstr ""
+
+#: src/Object/Item.php:168
+msgid "save to folder"
+msgstr ""
+
+#: src/Object/Item.php:235
+msgid "I will attend"
+msgstr ""
+
+#: src/Object/Item.php:235
+msgid "I will not attend"
+msgstr ""
+
+#: src/Object/Item.php:235
+msgid "I might attend"
+msgstr ""
+
+#: src/Object/Item.php:261
+msgid "add star"
+msgstr ""
+
+#: src/Object/Item.php:262
+msgid "remove star"
+msgstr ""
+
+#: src/Object/Item.php:263
+msgid "toggle star status"
+msgstr ""
+
+#: src/Object/Item.php:266
+msgid "starred"
+msgstr ""
+
+#: src/Object/Item.php:271
+msgid "ignore thread"
+msgstr ""
+
+#: src/Object/Item.php:272
+msgid "unignore thread"
+msgstr ""
+
+#: src/Object/Item.php:273
+msgid "toggle ignore status"
+msgstr ""
+
+#: src/Object/Item.php:283
+msgid "add tag"
+msgstr ""
+
+#: src/Object/Item.php:294
+msgid "like"
+msgstr ""
+
+#: src/Object/Item.php:295
+msgid "dislike"
+msgstr ""
+
+#: src/Object/Item.php:298
+msgid "Share this"
+msgstr ""
+
+#: src/Object/Item.php:298
+msgid "share"
+msgstr ""
+
+#: src/Object/Item.php:357
+msgid "to"
+msgstr ""
+
+#: src/Object/Item.php:358
+msgid "via"
+msgstr ""
+
+#: src/Object/Item.php:359
+msgid "Wall-to-Wall"
+msgstr ""
+
+#: src/Object/Item.php:360
+msgid "via Wall-To-Wall:"
+msgstr ""
+
+#: src/Object/Item.php:419
+#, php-format
+msgid "%d comment"
+msgid_plural "%d comments"
+msgstr[0] ""
+msgstr[1] ""
+
+#: src/Object/Item.php:788
+msgid "Bold"
+msgstr ""
+
+#: src/Object/Item.php:789
+msgid "Italic"
+msgstr ""
+
+#: src/Object/Item.php:790
+msgid "Underline"
+msgstr ""
+
+#: src/Object/Item.php:791
+msgid "Quote"
+msgstr ""
+
+#: src/Object/Item.php:792
+msgid "Code"
+msgstr ""
+
+#: src/Object/Item.php:793
+msgid "Image"
+msgstr ""
+
+#: src/Object/Item.php:794
+msgid "Link"
+msgstr ""
+
+#: src/Object/Item.php:795
+msgid "Video"
+msgstr ""
+
+#: src/Protocol/DFRN.php:1416
+#, php-format
+msgid "%s\\'s birthday"
+msgstr ""
+
+#: src/Protocol/Diaspora.php:2488
+msgid "Sharing notification from Diaspora network"
+msgstr ""
+
+#: src/Protocol/Diaspora.php:3530
+msgid "Attachments:"
+msgstr ""
+
+#: src/Protocol/OStatus.php:1786
+#, php-format
+msgid "%s is now following %s."
+msgstr ""
+
+#: src/Protocol/OStatus.php:1787
+msgid "following"
+msgstr ""
+
+#: src/Protocol/OStatus.php:1790
+#, php-format
+msgid "%s stopped following %s."
+msgstr ""
+
+#: src/Protocol/OStatus.php:1791
+msgid "stopped following"
+msgstr ""
+
+#: src/Worker/Delivery.php:421
+msgid "(no subject)"
+msgstr ""
+
+#: boot.php:762
#, php-format
msgid "Update %s failed. See error logs."
msgstr ""
-#: boot.php:850
+#: boot.php:873
msgid "Create a New Account"
msgstr ""
-#: boot.php:878
+#: boot.php:905
msgid "Password: "
msgstr ""
-#: boot.php:879
+#: boot.php:906
msgid "Remember me"
msgstr ""
-#: boot.php:882
+#: boot.php:909
msgid "Or login using OpenID: "
msgstr ""
-#: boot.php:888
+#: boot.php:915
msgid "Forgot your password?"
msgstr ""
-#: boot.php:891
+#: boot.php:918
msgid "Website Terms of Service"
msgstr ""
-#: boot.php:892
+#: boot.php:919
msgid "terms of service"
msgstr ""
-#: boot.php:894
+#: boot.php:921
msgid "Website Privacy Policy"
msgstr ""
-#: boot.php:895
+#: boot.php:922
msgid "privacy policy"
msgstr ""
-#: index.php:438
+#: index.php:427
msgid "toggle mobile"
msgstr ""
$MYSQL -uroot -proot friendica < /vagrant/friendica_test_data.sql
# create cronjob - activate if you have enough memory in you dev VM
-echo "*/10 * * * * cd /vagrant; /usr/bin/php include/poller.php" >> friendicacron
+echo "*/10 * * * * cd /vagrant; /usr/bin/php scripts/worker.php" >> friendicacron
sudo crontab friendicacron
sudo rm friendicacron
'Console_Getopt' => $vendorDir . '/pear-pear.php.net/Console_Getopt/Console/Getopt.php',
'Detection\\MobileDetect' => $vendorDir . '/mobiledetect/mobiledetectlib/namespaced/Detection/MobileDetect.php',
'Friendica\\App' => $baseDir . '/src/App.php',
+ 'Friendica\\BaseObject' => $baseDir . '/src/BaseObject.php',
+ 'Friendica\\Content\\ForumManager' => $baseDir . '/src/Content/ForumManager.php',
+ 'Friendica\\Content\\Smilies' => $baseDir . '/src/Content/Smilies.php',
+ 'Friendica\\Core\\Cache' => $baseDir . '/src/Core/Cache.php',
'Friendica\\Core\\Config' => $baseDir . '/src/Core/Config.php',
'Friendica\\Core\\NotificationsManager' => $baseDir . '/src/Core/NotificationsManager.php',
'Friendica\\Core\\PConfig' => $baseDir . '/src/Core/PConfig.php',
'Friendica\\Core\\System' => $baseDir . '/src/Core/System.php',
'Friendica\\Core\\Worker' => $baseDir . '/src/Core/Worker.php',
'Friendica\\Database\\DBM' => $baseDir . '/src/Database/DBM.php',
+ 'Friendica\\Model\\GlobalContact' => $baseDir . '/src/Model/GlobalContact.php',
+ 'Friendica\\Model\\User' => $baseDir . '/src/Model/User.php',
+ 'Friendica\\Network\\HTTPException' => $baseDir . '/src/Network/HTTPException.php',
+ 'Friendica\\Network\\HTTPException\\BadGatewayException' => $baseDir . '/src/Network/HTTPException/BadGatewayException.php',
+ 'Friendica\\Network\\HTTPException\\BadRequestException' => $baseDir . '/src/Network/HTTPException/BadRequestException.php',
+ 'Friendica\\Network\\HTTPException\\ConflictException' => $baseDir . '/src/Network/HTTPException/ConflictException.php',
+ 'Friendica\\Network\\HTTPException\\ExpectationFailedException' => $baseDir . '/src/Network/HTTPException/ExpectationFailedException.php',
+ 'Friendica\\Network\\HTTPException\\ForbiddenException' => $baseDir . '/src/Network/HTTPException/ForbiddenException.php',
+ 'Friendica\\Network\\HTTPException\\GatewayTimeoutException' => $baseDir . '/src/Network/HTTPException/GatewayTimeoutException.php',
+ 'Friendica\\Network\\HTTPException\\GoneException' => $baseDir . '/src/Network/HTTPException/GoneException.php',
+ 'Friendica\\Network\\HTTPException\\ImATeapotException' => $baseDir . '/src/Network/HTTPException/ImATeapotException.php',
+ 'Friendica\\Network\\HTTPException\\InternalServerErrorException' => $baseDir . '/src/Network/HTTPException/InternalServerErrorException.php',
+ 'Friendica\\Network\\HTTPException\\LenghtRequiredException' => $baseDir . '/src/Network/HTTPException/LenghtRequiredException.php',
+ 'Friendica\\Network\\HTTPException\\MethodNotAllowedException' => $baseDir . '/src/Network/HTTPException/MethodNotAllowedException.php',
+ 'Friendica\\Network\\HTTPException\\NonAcceptableException' => $baseDir . '/src/Network/HTTPException/NonAcceptableException.php',
+ 'Friendica\\Network\\HTTPException\\NotFoundException' => $baseDir . '/src/Network/HTTPException/NotFoundException.php',
+ 'Friendica\\Network\\HTTPException\\NotImplementedException' => $baseDir . '/src/Network/HTTPException/NotImplementedException.php',
+ 'Friendica\\Network\\HTTPException\\PreconditionFailedException' => $baseDir . '/src/Network/HTTPException/PreconditionFailedException.php',
+ 'Friendica\\Network\\HTTPException\\ServiceUnavaiableException' => $baseDir . '/src/Network/HTTPException/ServiceUnavaiableException.php',
+ 'Friendica\\Network\\HTTPException\\TooManyRequestsException' => $baseDir . '/src/Network/HTTPException/TooManyRequestsException.php',
+ 'Friendica\\Network\\HTTPException\\UnauthorizedException' => $baseDir . '/src/Network/HTTPException/UnauthorizedException.php',
+ 'Friendica\\Network\\HTTPException\\UnprocessableEntityException' => $baseDir . '/src/Network/HTTPException/UnprocessableEntityException.php',
+ 'Friendica\\Network\\HTTPException\\UnsupportedMediaTypeException' => $baseDir . '/src/Network/HTTPException/UnsupportedMediaTypeException.php',
'Friendica\\Network\\Probe' => $baseDir . '/src/Network/Probe.php',
+ 'Friendica\\Object\\Contact' => $baseDir . '/src/Object/Contact.php',
+ 'Friendica\\Object\\Conversation' => $baseDir . '/src/Object/Conversation.php',
+ 'Friendica\\Object\\Item' => $baseDir . '/src/Object/Item.php',
+ 'Friendica\\Object\\Profile' => $baseDir . '/src/Object/Profile.php',
'Friendica\\ParseUrl' => $baseDir . '/src/ParseUrl.php',
'Friendica\\Protocol\\DFRN' => $baseDir . '/src/Protocol/DFRN.php',
'Friendica\\Protocol\\Diaspora' => $baseDir . '/src/Protocol/Diaspora.php',
+ 'Friendica\\Protocol\\OStatus' => $baseDir . '/src/Protocol/OStatus.php',
+ 'Friendica\\Protocol\\PortableContact' => $baseDir . '/src/Protocol/PortableContact.php',
+ 'Friendica\\Render\\ITemplateEngine' => $baseDir . '/src/Render/ITemplateEngine.php',
+ 'Friendica\\Util\\Emailer' => $baseDir . '/src/Util/Emailer.php',
+ 'Friendica\\Util\\ExAuth' => $baseDir . '/src/Util/ExAuth.php',
'Friendica\\Util\\Lock' => $baseDir . '/src/Util/Lock.php',
+ 'Friendica\\Util\\XML' => $baseDir . '/src/Util/XML.php',
+ 'Friendica\\Worker\\CheckVersion' => $baseDir . '/src/Worker/CheckVersion.php',
+ 'Friendica\\Worker\\CreateShadowEntry' => $baseDir . '/src/Worker/CreateShadowEntry.php',
+ 'Friendica\\Worker\\Cron' => $baseDir . '/src/Worker/Cron.php',
+ 'Friendica\\Worker\\CronHooks' => $baseDir . '/src/Worker/CronHooks.php',
+ 'Friendica\\Worker\\CronJobs' => $baseDir . '/src/Worker/CronJobs.php',
+ 'Friendica\\Worker\\DBClean' => $baseDir . '/src/Worker/DBClean.php',
+ 'Friendica\\Worker\\DBUpdate' => $baseDir . '/src/Worker/DBUpdate.php',
+ 'Friendica\\Worker\\Delivery' => $baseDir . '/src/Worker/Delivery.php',
+ 'Friendica\\Worker\\Directory' => $baseDir . '/src/Worker/Directory.php',
+ 'Friendica\\Worker\\DiscoverPoCo' => $baseDir . '/src/Worker/DiscoverPoCo.php',
+ 'Friendica\\Worker\\Expire' => $baseDir . '/src/Worker/Expire.php',
+ 'Friendica\\Worker\\GProbe' => $baseDir . '/src/Worker/GProbe.php',
+ 'Friendica\\Worker\\Notifier' => $baseDir . '/src/Worker/Notifier.php',
+ 'Friendica\\Worker\\OnePoll' => $baseDir . '/src/Worker/OnePoll.php',
+ 'Friendica\\Worker\\ProfileUpdate' => $baseDir . '/src/Worker/ProfileUpdate.php',
+ 'Friendica\\Worker\\PubSubPublish' => $baseDir . '/src/Worker/PubSubPublish.php',
+ 'Friendica\\Worker\\Queue' => $baseDir . '/src/Worker/Queue.php',
+ 'Friendica\\Worker\\RemoveContact' => $baseDir . '/src/Worker/RemoveContact.php',
+ 'Friendica\\Worker\\SpoolPost' => $baseDir . '/src/Worker/SpoolPost.php',
+ 'Friendica\\Worker\\TagUpdate' => $baseDir . '/src/Worker/TagUpdate.php',
+ 'Friendica\\Worker\\ThreadUpdate' => $baseDir . '/src/Worker/ThreadUpdate.php',
+ 'Friendica\\Worker\\UpdateGContact' => $baseDir . '/src/Worker/UpdateGContact.php',
'HTMLPurifier' => $vendorDir . '/ezyang/htmlpurifier/library/HTMLPurifier.php',
'HTMLPurifier_Arborize' => $vendorDir . '/ezyang/htmlpurifier/library/HTMLPurifier/Arborize.php',
'HTMLPurifier_AttrCollections' => $vendorDir . '/ezyang/htmlpurifier/library/HTMLPurifier/AttrCollections.php',
return array(
'2cffec82183ee1cea088009cef9a6fc3' => $vendorDir . '/ezyang/htmlpurifier/library/HTMLPurifier.composer.php',
'8170285c807a9f24f165f37b15bc9a36' => $vendorDir . '/defuse/php-encryption/Crypto.php',
+ '5255c38a0faeba867671b61dfda6d864' => $vendorDir . '/paragonie/random_compat/lib/random.php',
);
public static $files = array (
'2cffec82183ee1cea088009cef9a6fc3' => __DIR__ . '/..' . '/ezyang/htmlpurifier/library/HTMLPurifier.composer.php',
'8170285c807a9f24f165f37b15bc9a36' => __DIR__ . '/..' . '/defuse/php-encryption/Crypto.php',
+ '5255c38a0faeba867671b61dfda6d864' => __DIR__ . '/..' . '/paragonie/random_compat/lib/random.php',
);
public static $prefixLengthsPsr4 = array (
'Console_Getopt' => __DIR__ . '/..' . '/pear-pear.php.net/Console_Getopt/Console/Getopt.php',
'Detection\\MobileDetect' => __DIR__ . '/..' . '/mobiledetect/mobiledetectlib/namespaced/Detection/MobileDetect.php',
'Friendica\\App' => __DIR__ . '/../..' . '/src/App.php',
+ 'Friendica\\BaseObject' => __DIR__ . '/../..' . '/src/BaseObject.php',
+ 'Friendica\\Content\\ForumManager' => __DIR__ . '/../..' . '/src/Content/ForumManager.php',
+ 'Friendica\\Content\\Smilies' => __DIR__ . '/../..' . '/src/Content/Smilies.php',
+ 'Friendica\\Core\\Cache' => __DIR__ . '/../..' . '/src/Core/Cache.php',
'Friendica\\Core\\Config' => __DIR__ . '/../..' . '/src/Core/Config.php',
'Friendica\\Core\\NotificationsManager' => __DIR__ . '/../..' . '/src/Core/NotificationsManager.php',
'Friendica\\Core\\PConfig' => __DIR__ . '/../..' . '/src/Core/PConfig.php',
'Friendica\\Core\\System' => __DIR__ . '/../..' . '/src/Core/System.php',
'Friendica\\Core\\Worker' => __DIR__ . '/../..' . '/src/Core/Worker.php',
'Friendica\\Database\\DBM' => __DIR__ . '/../..' . '/src/Database/DBM.php',
+ 'Friendica\\Model\\GlobalContact' => __DIR__ . '/../..' . '/src/Model/GlobalContact.php',
+ 'Friendica\\Model\\User' => __DIR__ . '/../..' . '/src/Model/User.php',
+ 'Friendica\\Network\\HTTPException' => __DIR__ . '/../..' . '/src/Network/HTTPException.php',
+ 'Friendica\\Network\\HTTPException\\BadGatewayException' => __DIR__ . '/../..' . '/src/Network/HTTPException/BadGatewayException.php',
+ 'Friendica\\Network\\HTTPException\\BadRequestException' => __DIR__ . '/../..' . '/src/Network/HTTPException/BadRequestException.php',
+ 'Friendica\\Network\\HTTPException\\ConflictException' => __DIR__ . '/../..' . '/src/Network/HTTPException/ConflictException.php',
+ 'Friendica\\Network\\HTTPException\\ExpectationFailedException' => __DIR__ . '/../..' . '/src/Network/HTTPException/ExpectationFailedException.php',
+ 'Friendica\\Network\\HTTPException\\ForbiddenException' => __DIR__ . '/../..' . '/src/Network/HTTPException/ForbiddenException.php',
+ 'Friendica\\Network\\HTTPException\\GatewayTimeoutException' => __DIR__ . '/../..' . '/src/Network/HTTPException/GatewayTimeoutException.php',
+ 'Friendica\\Network\\HTTPException\\GoneException' => __DIR__ . '/../..' . '/src/Network/HTTPException/GoneException.php',
+ 'Friendica\\Network\\HTTPException\\ImATeapotException' => __DIR__ . '/../..' . '/src/Network/HTTPException/ImATeapotException.php',
+ 'Friendica\\Network\\HTTPException\\InternalServerErrorException' => __DIR__ . '/../..' . '/src/Network/HTTPException/InternalServerErrorException.php',
+ 'Friendica\\Network\\HTTPException\\LenghtRequiredException' => __DIR__ . '/../..' . '/src/Network/HTTPException/LenghtRequiredException.php',
+ 'Friendica\\Network\\HTTPException\\MethodNotAllowedException' => __DIR__ . '/../..' . '/src/Network/HTTPException/MethodNotAllowedException.php',
+ 'Friendica\\Network\\HTTPException\\NonAcceptableException' => __DIR__ . '/../..' . '/src/Network/HTTPException/NonAcceptableException.php',
+ 'Friendica\\Network\\HTTPException\\NotFoundException' => __DIR__ . '/../..' . '/src/Network/HTTPException/NotFoundException.php',
+ 'Friendica\\Network\\HTTPException\\NotImplementedException' => __DIR__ . '/../..' . '/src/Network/HTTPException/NotImplementedException.php',
+ 'Friendica\\Network\\HTTPException\\PreconditionFailedException' => __DIR__ . '/../..' . '/src/Network/HTTPException/PreconditionFailedException.php',
+ 'Friendica\\Network\\HTTPException\\ServiceUnavaiableException' => __DIR__ . '/../..' . '/src/Network/HTTPException/ServiceUnavaiableException.php',
+ 'Friendica\\Network\\HTTPException\\TooManyRequestsException' => __DIR__ . '/../..' . '/src/Network/HTTPException/TooManyRequestsException.php',
+ 'Friendica\\Network\\HTTPException\\UnauthorizedException' => __DIR__ . '/../..' . '/src/Network/HTTPException/UnauthorizedException.php',
+ 'Friendica\\Network\\HTTPException\\UnprocessableEntityException' => __DIR__ . '/../..' . '/src/Network/HTTPException/UnprocessableEntityException.php',
+ 'Friendica\\Network\\HTTPException\\UnsupportedMediaTypeException' => __DIR__ . '/../..' . '/src/Network/HTTPException/UnsupportedMediaTypeException.php',
'Friendica\\Network\\Probe' => __DIR__ . '/../..' . '/src/Network/Probe.php',
+ 'Friendica\\Object\\Contact' => __DIR__ . '/../..' . '/src/Object/Contact.php',
+ 'Friendica\\Object\\Conversation' => __DIR__ . '/../..' . '/src/Object/Conversation.php',
+ 'Friendica\\Object\\Item' => __DIR__ . '/../..' . '/src/Object/Item.php',
+ 'Friendica\\Object\\Profile' => __DIR__ . '/../..' . '/src/Object/Profile.php',
'Friendica\\ParseUrl' => __DIR__ . '/../..' . '/src/ParseUrl.php',
'Friendica\\Protocol\\DFRN' => __DIR__ . '/../..' . '/src/Protocol/DFRN.php',
'Friendica\\Protocol\\Diaspora' => __DIR__ . '/../..' . '/src/Protocol/Diaspora.php',
+ 'Friendica\\Protocol\\OStatus' => __DIR__ . '/../..' . '/src/Protocol/OStatus.php',
+ 'Friendica\\Protocol\\PortableContact' => __DIR__ . '/../..' . '/src/Protocol/PortableContact.php',
+ 'Friendica\\Render\\ITemplateEngine' => __DIR__ . '/../..' . '/src/Render/ITemplateEngine.php',
+ 'Friendica\\Util\\Emailer' => __DIR__ . '/../..' . '/src/Util/Emailer.php',
+ 'Friendica\\Util\\ExAuth' => __DIR__ . '/../..' . '/src/Util/ExAuth.php',
'Friendica\\Util\\Lock' => __DIR__ . '/../..' . '/src/Util/Lock.php',
+ 'Friendica\\Util\\XML' => __DIR__ . '/../..' . '/src/Util/XML.php',
+ 'Friendica\\Worker\\CheckVersion' => __DIR__ . '/../..' . '/src/Worker/CheckVersion.php',
+ 'Friendica\\Worker\\CreateShadowEntry' => __DIR__ . '/../..' . '/src/Worker/CreateShadowEntry.php',
+ 'Friendica\\Worker\\Cron' => __DIR__ . '/../..' . '/src/Worker/Cron.php',
+ 'Friendica\\Worker\\CronHooks' => __DIR__ . '/../..' . '/src/Worker/CronHooks.php',
+ 'Friendica\\Worker\\CronJobs' => __DIR__ . '/../..' . '/src/Worker/CronJobs.php',
+ 'Friendica\\Worker\\DBClean' => __DIR__ . '/../..' . '/src/Worker/DBClean.php',
+ 'Friendica\\Worker\\DBUpdate' => __DIR__ . '/../..' . '/src/Worker/DBUpdate.php',
+ 'Friendica\\Worker\\Delivery' => __DIR__ . '/../..' . '/src/Worker/Delivery.php',
+ 'Friendica\\Worker\\Directory' => __DIR__ . '/../..' . '/src/Worker/Directory.php',
+ 'Friendica\\Worker\\DiscoverPoCo' => __DIR__ . '/../..' . '/src/Worker/DiscoverPoCo.php',
+ 'Friendica\\Worker\\Expire' => __DIR__ . '/../..' . '/src/Worker/Expire.php',
+ 'Friendica\\Worker\\GProbe' => __DIR__ . '/../..' . '/src/Worker/GProbe.php',
+ 'Friendica\\Worker\\Notifier' => __DIR__ . '/../..' . '/src/Worker/Notifier.php',
+ 'Friendica\\Worker\\OnePoll' => __DIR__ . '/../..' . '/src/Worker/OnePoll.php',
+ 'Friendica\\Worker\\ProfileUpdate' => __DIR__ . '/../..' . '/src/Worker/ProfileUpdate.php',
+ 'Friendica\\Worker\\PubSubPublish' => __DIR__ . '/../..' . '/src/Worker/PubSubPublish.php',
+ 'Friendica\\Worker\\Queue' => __DIR__ . '/../..' . '/src/Worker/Queue.php',
+ 'Friendica\\Worker\\RemoveContact' => __DIR__ . '/../..' . '/src/Worker/RemoveContact.php',
+ 'Friendica\\Worker\\SpoolPost' => __DIR__ . '/../..' . '/src/Worker/SpoolPost.php',
+ 'Friendica\\Worker\\TagUpdate' => __DIR__ . '/../..' . '/src/Worker/TagUpdate.php',
+ 'Friendica\\Worker\\ThreadUpdate' => __DIR__ . '/../..' . '/src/Worker/ThreadUpdate.php',
+ 'Friendica\\Worker\\UpdateGContact' => __DIR__ . '/../..' . '/src/Worker/UpdateGContact.php',
'HTMLPurifier' => __DIR__ . '/..' . '/ezyang/htmlpurifier/library/HTMLPurifier.php',
'HTMLPurifier_Arborize' => __DIR__ . '/..' . '/ezyang/htmlpurifier/library/HTMLPurifier/Arborize.php',
'HTMLPurifier_AttrCollections' => __DIR__ . '/..' . '/ezyang/htmlpurifier/library/HTMLPurifier/AttrCollections.php',
"mcrypt",
"security"
]
+ },
+ {
+ "name": "paragonie/random_compat",
+ "version": "v2.0.11",
+ "version_normalized": "2.0.11.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/paragonie/random_compat.git",
+ "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8",
+ "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8",
+ "shasum": ""
+ },
+ "require": {
+ "php": ">=5.2.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "4.*|5.*"
+ },
+ "suggest": {
+ "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes."
+ },
+ "time": "2017-09-27T21:40:39+00:00",
+ "type": "library",
+ "installation-source": "dist",
+ "autoload": {
+ "files": [
+ "lib/random.php"
+ ]
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Paragon Initiative Enterprises",
+ "email": "security@paragonie.com",
+ "homepage": "https://paragonie.com"
+ }
+ ],
+ "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7",
+ "keywords": [
+ "csprng",
+ "pseudorandom",
+ "random"
+ ]
}
]
--- /dev/null
+The MIT License (MIT)
+
+Copyright (c) 2015 Paragon Initiative Enterprises
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
--- /dev/null
+#!/usr/bin/env bash
+
+basedir=$( dirname $( readlink -f ${BASH_SOURCE[0]} ) )
+
+php -dphar.readonly=0 "$basedir/other/build_phar.php" $*
\ No newline at end of file
--- /dev/null
+{
+ "name": "paragonie/random_compat",
+ "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7",
+ "keywords": [
+ "csprng",
+ "random",
+ "pseudorandom"
+ ],
+ "license": "MIT",
+ "type": "library",
+ "authors": [
+ {
+ "name": "Paragon Initiative Enterprises",
+ "email": "security@paragonie.com",
+ "homepage": "https://paragonie.com"
+ }
+ ],
+ "support": {
+ "issues": "https://github.com/paragonie/random_compat/issues",
+ "email": "info@paragonie.com",
+ "source": "https://github.com/paragonie/random_compat"
+ },
+ "require": {
+ "php": ">=5.2.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "4.*|5.*"
+ },
+ "suggest": {
+ "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes."
+ },
+ "autoload": {
+ "files": [
+ "lib/random.php"
+ ]
+ }
+}
--- /dev/null
+-----BEGIN PUBLIC KEY-----
+MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEEd+wCqJDrx5B4OldM0dQE0ZMX+lx1ZWm
+pui0SUqD4G29L3NGsz9UhJ/0HjBdbnkhIK5xviT0X5vtjacF6ajgcCArbTB+ds+p
++h7Q084NuSuIpNb6YPfoUFgC/CL9kAoc
+-----END PUBLIC KEY-----
--- /dev/null
+-----BEGIN PGP SIGNATURE-----
+Version: GnuPG v2.0.22 (MingW32)
+
+iQEcBAABAgAGBQJWtW1hAAoJEGuXocKCZATaJf0H+wbZGgskK1dcRTsuVJl9IWip
+QwGw/qIKI280SD6/ckoUMxKDCJiFuPR14zmqnS36k7N5UNPnpdTJTS8T11jttSpg
+1LCmgpbEIpgaTah+cELDqFCav99fS+bEiAL5lWDAHBTE/XPjGVCqeehyPYref4IW
+NDBIEsvnHPHPLsn6X5jq4+Yj5oUixgxaMPiR+bcO4Sh+RzOVB6i2D0upWfRXBFXA
+NNnsg9/zjvoC7ZW73y9uSH+dPJTt/Vgfeiv52/v41XliyzbUyLalf02GNPY+9goV
+JHG1ulEEBJOCiUD9cE1PUIJwHA/HqyhHIvV350YoEFiHl8iSwm7SiZu5kPjaq74=
+=B6+8
+-----END PGP SIGNATURE-----
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('RandomCompat_strlen')) {
+ if (
+ defined('MB_OVERLOAD_STRING') &&
+ ini_get('mbstring.func_overload') & MB_OVERLOAD_STRING
+ ) {
+ /**
+ * strlen() implementation that isn't brittle to mbstring.func_overload
+ *
+ * This version uses mb_strlen() in '8bit' mode to treat strings as raw
+ * binary rather than UTF-8, ISO-8859-1, etc
+ *
+ * @param string $binary_string
+ *
+ * @throws TypeError
+ *
+ * @return int
+ */
+ function RandomCompat_strlen($binary_string)
+ {
+ if (!is_string($binary_string)) {
+ throw new TypeError(
+ 'RandomCompat_strlen() expects a string'
+ );
+ }
+
+ return (int) mb_strlen($binary_string, '8bit');
+ }
+
+ } else {
+ /**
+ * strlen() implementation that isn't brittle to mbstring.func_overload
+ *
+ * This version just used the default strlen()
+ *
+ * @param string $binary_string
+ *
+ * @throws TypeError
+ *
+ * @return int
+ */
+ function RandomCompat_strlen($binary_string)
+ {
+ if (!is_string($binary_string)) {
+ throw new TypeError(
+ 'RandomCompat_strlen() expects a string'
+ );
+ }
+ return (int) strlen($binary_string);
+ }
+ }
+}
+
+if (!is_callable('RandomCompat_substr')) {
+
+ if (
+ defined('MB_OVERLOAD_STRING')
+ &&
+ ini_get('mbstring.func_overload') & MB_OVERLOAD_STRING
+ ) {
+ /**
+ * substr() implementation that isn't brittle to mbstring.func_overload
+ *
+ * This version uses mb_substr() in '8bit' mode to treat strings as raw
+ * binary rather than UTF-8, ISO-8859-1, etc
+ *
+ * @param string $binary_string
+ * @param int $start
+ * @param int $length (optional)
+ *
+ * @throws TypeError
+ *
+ * @return string
+ */
+ function RandomCompat_substr($binary_string, $start, $length = null)
+ {
+ if (!is_string($binary_string)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): First argument should be a string'
+ );
+ }
+
+ if (!is_int($start)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): Second argument should be an integer'
+ );
+ }
+
+ if ($length === null) {
+ /**
+ * mb_substr($str, 0, NULL, '8bit') returns an empty string on
+ * PHP 5.3, so we have to find the length ourselves.
+ */
+ $length = RandomCompat_strlen($binary_string) - $start;
+ } elseif (!is_int($length)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): Third argument should be an integer, or omitted'
+ );
+ }
+
+ // Consistency with PHP's behavior
+ if ($start === RandomCompat_strlen($binary_string) && $length === 0) {
+ return '';
+ }
+ if ($start > RandomCompat_strlen($binary_string)) {
+ return '';
+ }
+
+ return (string) mb_substr($binary_string, $start, $length, '8bit');
+ }
+
+ } else {
+
+ /**
+ * substr() implementation that isn't brittle to mbstring.func_overload
+ *
+ * This version just uses the default substr()
+ *
+ * @param string $binary_string
+ * @param int $start
+ * @param int $length (optional)
+ *
+ * @throws TypeError
+ *
+ * @return string
+ */
+ function RandomCompat_substr($binary_string, $start, $length = null)
+ {
+ if (!is_string($binary_string)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): First argument should be a string'
+ );
+ }
+
+ if (!is_int($start)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): Second argument should be an integer'
+ );
+ }
+
+ if ($length !== null) {
+ if (!is_int($length)) {
+ throw new TypeError(
+ 'RandomCompat_substr(): Third argument should be an integer, or omitted'
+ );
+ }
+
+ return (string) substr($binary_string, $start, $length);
+ }
+
+ return (string) substr($binary_string, $start);
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('RandomCompat_intval')) {
+
+ /**
+ * Cast to an integer if we can, safely.
+ *
+ * If you pass it a float in the range (~PHP_INT_MAX, PHP_INT_MAX)
+ * (non-inclusive), it will sanely cast it to an int. If you it's equal to
+ * ~PHP_INT_MAX or PHP_INT_MAX, we let it fail as not an integer. Floats
+ * lose precision, so the <= and => operators might accidentally let a float
+ * through.
+ *
+ * @param int|float $number The number we want to convert to an int
+ * @param bool $fail_open Set to true to not throw an exception
+ *
+ * @return float|int
+ * @psalm-suppress InvalidReturnType
+ *
+ * @throws TypeError
+ */
+ function RandomCompat_intval($number, $fail_open = false)
+ {
+ if (is_int($number) || is_float($number)) {
+ $number += 0;
+ } elseif (is_numeric($number)) {
+ $number += 0;
+ }
+
+ if (
+ is_float($number)
+ &&
+ $number > ~PHP_INT_MAX
+ &&
+ $number < PHP_INT_MAX
+ ) {
+ $number = (int) $number;
+ }
+
+ if (is_int($number)) {
+ return (int) $number;
+ } elseif (!$fail_open) {
+ throw new TypeError(
+ 'Expected an integer.'
+ );
+ }
+ return $number;
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!class_exists('Error', false)) {
+ // We can't really avoid making this extend Exception in PHP 5.
+ class Error extends Exception
+ {
+
+ }
+}
+
+if (!class_exists('TypeError', false)) {
+ if (is_subclass_of('Error', 'Exception')) {
+ class TypeError extends Error
+ {
+
+ }
+ } else {
+ class TypeError extends Exception
+ {
+
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * @version 2.0.10
+ * @released 2017-03-13
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!defined('PHP_VERSION_ID')) {
+ // This constant was introduced in PHP 5.2.7
+ $RandomCompatversion = array_map('intval', explode('.', PHP_VERSION));
+ define(
+ 'PHP_VERSION_ID',
+ $RandomCompatversion[0] * 10000
+ + $RandomCompatversion[1] * 100
+ + $RandomCompatversion[2]
+ );
+ $RandomCompatversion = null;
+}
+
+/**
+ * PHP 7.0.0 and newer have these functions natively.
+ */
+if (PHP_VERSION_ID >= 70000) {
+ return;
+}
+
+if (!defined('RANDOM_COMPAT_READ_BUFFER')) {
+ define('RANDOM_COMPAT_READ_BUFFER', 8);
+}
+
+$RandomCompatDIR = dirname(__FILE__);
+
+require_once $RandomCompatDIR . '/byte_safe_strings.php';
+require_once $RandomCompatDIR . '/cast_to_int.php';
+require_once $RandomCompatDIR . '/error_polyfill.php';
+
+if (!is_callable('random_bytes')) {
+ /**
+ * PHP 5.2.0 - 5.6.x way to implement random_bytes()
+ *
+ * We use conditional statements here to define the function in accordance
+ * to the operating environment. It's a micro-optimization.
+ *
+ * In order of preference:
+ * 1. Use libsodium if available.
+ * 2. fread() /dev/urandom if available (never on Windows)
+ * 3. mcrypt_create_iv($bytes, MCRYPT_DEV_URANDOM)
+ * 4. COM('CAPICOM.Utilities.1')->GetRandom()
+ *
+ * See RATIONALE.md for our reasoning behind this particular order
+ */
+ if (extension_loaded('libsodium')) {
+ // See random_bytes_libsodium.php
+ if (PHP_VERSION_ID >= 50300 && is_callable('\\Sodium\\randombytes_buf')) {
+ require_once $RandomCompatDIR . '/random_bytes_libsodium.php';
+ } elseif (method_exists('Sodium', 'randombytes_buf')) {
+ require_once $RandomCompatDIR . '/random_bytes_libsodium_legacy.php';
+ }
+ }
+
+ /**
+ * Reading directly from /dev/urandom:
+ */
+ if (DIRECTORY_SEPARATOR === '/') {
+ // DIRECTORY_SEPARATOR === '/' on Unix-like OSes -- this is a fast
+ // way to exclude Windows.
+ $RandomCompatUrandom = true;
+ $RandomCompat_basedir = ini_get('open_basedir');
+
+ if (!empty($RandomCompat_basedir)) {
+ $RandomCompat_open_basedir = explode(
+ PATH_SEPARATOR,
+ strtolower($RandomCompat_basedir)
+ );
+ $RandomCompatUrandom = (array() !== array_intersect(
+ array('/dev', '/dev/', '/dev/urandom'),
+ $RandomCompat_open_basedir
+ ));
+ $RandomCompat_open_basedir = null;
+ }
+
+ if (
+ !is_callable('random_bytes')
+ &&
+ $RandomCompatUrandom
+ &&
+ @is_readable('/dev/urandom')
+ ) {
+ // Error suppression on is_readable() in case of an open_basedir
+ // or safe_mode failure. All we care about is whether or not we
+ // can read it at this point. If the PHP environment is going to
+ // panic over trying to see if the file can be read in the first
+ // place, that is not helpful to us here.
+
+ // See random_bytes_dev_urandom.php
+ require_once $RandomCompatDIR . '/random_bytes_dev_urandom.php';
+ }
+ // Unset variables after use
+ $RandomCompat_basedir = null;
+ } else {
+ $RandomCompatUrandom = false;
+ }
+
+ /**
+ * mcrypt_create_iv()
+ *
+ * We only want to use mcypt_create_iv() if:
+ *
+ * - random_bytes() hasn't already been defined
+ * - the mcrypt extensions is loaded
+ * - One of these two conditions is true:
+ * - We're on Windows (DIRECTORY_SEPARATOR !== '/')
+ * - We're not on Windows and /dev/urandom is readabale
+ * (i.e. we're not in a chroot jail)
+ * - Special case:
+ * - If we're not on Windows, but the PHP version is between
+ * 5.6.10 and 5.6.12, we don't want to use mcrypt. It will
+ * hang indefinitely. This is bad.
+ * - If we're on Windows, we want to use PHP >= 5.3.7 or else
+ * we get insufficient entropy errors.
+ */
+ if (
+ !is_callable('random_bytes')
+ &&
+ // Windows on PHP < 5.3.7 is broken, but non-Windows is not known to be.
+ (DIRECTORY_SEPARATOR === '/' || PHP_VERSION_ID >= 50307)
+ &&
+ // Prevent this code from hanging indefinitely on non-Windows;
+ // see https://bugs.php.net/bug.php?id=69833
+ (
+ DIRECTORY_SEPARATOR !== '/' ||
+ (PHP_VERSION_ID <= 50609 || PHP_VERSION_ID >= 50613)
+ )
+ &&
+ extension_loaded('mcrypt')
+ ) {
+ // See random_bytes_mcrypt.php
+ require_once $RandomCompatDIR . '/random_bytes_mcrypt.php';
+ }
+ $RandomCompatUrandom = null;
+
+ /**
+ * This is a Windows-specific fallback, for when the mcrypt extension
+ * isn't loaded.
+ */
+ if (
+ !is_callable('random_bytes')
+ &&
+ extension_loaded('com_dotnet')
+ &&
+ class_exists('COM')
+ ) {
+ $RandomCompat_disabled_classes = preg_split(
+ '#\s*,\s*#',
+ strtolower(ini_get('disable_classes'))
+ );
+
+ if (!in_array('com', $RandomCompat_disabled_classes)) {
+ try {
+ $RandomCompatCOMtest = new COM('CAPICOM.Utilities.1');
+ if (method_exists($RandomCompatCOMtest, 'GetRandom')) {
+ // See random_bytes_com_dotnet.php
+ require_once $RandomCompatDIR . '/random_bytes_com_dotnet.php';
+ }
+ } catch (com_exception $e) {
+ // Don't try to use it.
+ }
+ }
+ $RandomCompat_disabled_classes = null;
+ $RandomCompatCOMtest = null;
+ }
+
+ /**
+ * throw new Exception
+ */
+ if (!is_callable('random_bytes')) {
+ /**
+ * We don't have any more options, so let's throw an exception right now
+ * and hope the developer won't let it fail silently.
+ *
+ * @param mixed $length
+ * @return void
+ * @throws Exception
+ */
+ function random_bytes($length)
+ {
+ unset($length); // Suppress "variable not used" warnings.
+ throw new Exception(
+ 'There is no suitable CSPRNG installed on your system'
+ );
+ }
+ }
+}
+
+if (!is_callable('random_int')) {
+ require_once $RandomCompatDIR . '/random_int.php';
+}
+
+$RandomCompatDIR = null;
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('random_bytes')) {
+ /**
+ * Windows with PHP < 5.3.0 will not have the function
+ * openssl_random_pseudo_bytes() available, so let's use
+ * CAPICOM to work around this deficiency.
+ *
+ * @param int $bytes
+ *
+ * @throws Exception
+ *
+ * @return string
+ */
+ function random_bytes($bytes)
+ {
+ try {
+ $bytes = RandomCompat_intval($bytes);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_bytes(): $bytes must be an integer'
+ );
+ }
+
+ if ($bytes < 1) {
+ throw new Error(
+ 'Length must be greater than 0'
+ );
+ }
+
+ $buf = '';
+ if (!class_exists('COM')) {
+ throw new Error(
+ 'COM does not exist'
+ );
+ }
+ $util = new COM('CAPICOM.Utilities.1');
+ $execCount = 0;
+
+ /**
+ * Let's not let it loop forever. If we run N times and fail to
+ * get N bytes of random data, then CAPICOM has failed us.
+ */
+ do {
+ $buf .= base64_decode($util->GetRandom($bytes, 0));
+ if (RandomCompat_strlen($buf) >= $bytes) {
+ /**
+ * Return our random entropy buffer here:
+ */
+ return RandomCompat_substr($buf, 0, $bytes);
+ }
+ ++$execCount;
+ } while ($execCount < $bytes);
+
+ /**
+ * If we reach here, PHP has failed us.
+ */
+ throw new Exception(
+ 'Could not gather sufficient random data'
+ );
+ }
+}
\ No newline at end of file
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!defined('RANDOM_COMPAT_READ_BUFFER')) {
+ define('RANDOM_COMPAT_READ_BUFFER', 8);
+}
+
+if (!is_callable('random_bytes')) {
+ /**
+ * Unless open_basedir is enabled, use /dev/urandom for
+ * random numbers in accordance with best practices
+ *
+ * Why we use /dev/urandom and not /dev/random
+ * @ref http://sockpuppet.org/blog/2014/02/25/safely-generate-random-numbers
+ *
+ * @param int $bytes
+ *
+ * @throws Exception
+ *
+ * @return string
+ */
+ function random_bytes($bytes)
+ {
+ static $fp = null;
+ /**
+ * This block should only be run once
+ */
+ if (empty($fp)) {
+ /**
+ * We use /dev/urandom if it is a char device.
+ * We never fall back to /dev/random
+ */
+ $fp = fopen('/dev/urandom', 'rb');
+ if (!empty($fp)) {
+ $st = fstat($fp);
+ if (($st['mode'] & 0170000) !== 020000) {
+ fclose($fp);
+ $fp = false;
+ }
+ }
+
+ if (!empty($fp)) {
+ /**
+ * stream_set_read_buffer() does not exist in HHVM
+ *
+ * If we don't set the stream's read buffer to 0, PHP will
+ * internally buffer 8192 bytes, which can waste entropy
+ *
+ * stream_set_read_buffer returns 0 on success
+ */
+ if (is_callable('stream_set_read_buffer')) {
+ stream_set_read_buffer($fp, RANDOM_COMPAT_READ_BUFFER);
+ }
+ if (is_callable('stream_set_chunk_size')) {
+ stream_set_chunk_size($fp, RANDOM_COMPAT_READ_BUFFER);
+ }
+ }
+ }
+
+ try {
+ $bytes = RandomCompat_intval($bytes);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_bytes(): $bytes must be an integer'
+ );
+ }
+
+ if ($bytes < 1) {
+ throw new Error(
+ 'Length must be greater than 0'
+ );
+ }
+
+ /**
+ * This if() block only runs if we managed to open a file handle
+ *
+ * It does not belong in an else {} block, because the above
+ * if (empty($fp)) line is logic that should only be run once per
+ * page load.
+ */
+ if (!empty($fp)) {
+ /**
+ * @var int
+ */
+ $remaining = $bytes;
+
+ /**
+ * @var string|bool
+ */
+ $buf = '';
+
+ /**
+ * We use fread() in a loop to protect against partial reads
+ */
+ do {
+ /**
+ * @var string|bool
+ */
+ $read = fread($fp, $remaining);
+ if (!is_string($read)) {
+ if ($read === false) {
+ /**
+ * We cannot safely read from the file. Exit the
+ * do-while loop and trigger the exception condition
+ *
+ * @var string|bool
+ */
+ $buf = false;
+ break;
+ }
+ }
+ /**
+ * Decrease the number of bytes returned from remaining
+ */
+ $remaining -= RandomCompat_strlen($read);
+ /**
+ * @var string|bool
+ */
+ $buf = $buf . $read;
+ } while ($remaining > 0);
+
+ /**
+ * Is our result valid?
+ */
+ if (is_string($buf)) {
+ if (RandomCompat_strlen($buf) === $bytes) {
+ /**
+ * Return our random entropy buffer here:
+ */
+ return $buf;
+ }
+ }
+ }
+
+ /**
+ * If we reach here, PHP has failed us.
+ */
+ throw new Exception(
+ 'Error reading from source device'
+ );
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('random_bytes')) {
+ /**
+ * If the libsodium PHP extension is loaded, we'll use it above any other
+ * solution.
+ *
+ * libsodium-php project:
+ * @ref https://github.com/jedisct1/libsodium-php
+ *
+ * @param int $bytes
+ *
+ * @throws Exception
+ *
+ * @return string
+ */
+ function random_bytes($bytes)
+ {
+ try {
+ $bytes = RandomCompat_intval($bytes);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_bytes(): $bytes must be an integer'
+ );
+ }
+
+ if ($bytes < 1) {
+ throw new Error(
+ 'Length must be greater than 0'
+ );
+ }
+
+ /**
+ * \Sodium\randombytes_buf() doesn't allow more than 2147483647 bytes to be
+ * generated in one invocation.
+ */
+ if ($bytes > 2147483647) {
+ $buf = '';
+ for ($i = 0; $i < $bytes; $i += 1073741824) {
+ $n = ($bytes - $i) > 1073741824
+ ? 1073741824
+ : $bytes - $i;
+ $buf .= \Sodium\randombytes_buf($n);
+ }
+ } else {
+ $buf = \Sodium\randombytes_buf($bytes);
+ }
+
+ if ($buf !== false) {
+ if (RandomCompat_strlen($buf) === $bytes) {
+ return $buf;
+ }
+ }
+
+ /**
+ * If we reach here, PHP has failed us.
+ */
+ throw new Exception(
+ 'Could not gather sufficient random data'
+ );
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('random_bytes')) {
+ /**
+ * If the libsodium PHP extension is loaded, we'll use it above any other
+ * solution.
+ *
+ * libsodium-php project:
+ * @ref https://github.com/jedisct1/libsodium-php
+ *
+ * @param int $bytes
+ *
+ * @throws Exception
+ *
+ * @return string
+ */
+ function random_bytes($bytes)
+ {
+ try {
+ $bytes = RandomCompat_intval($bytes);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_bytes(): $bytes must be an integer'
+ );
+ }
+
+ if ($bytes < 1) {
+ throw new Error(
+ 'Length must be greater than 0'
+ );
+ }
+
+ /**
+ * @var string
+ */
+ $buf = '';
+
+ /**
+ * \Sodium\randombytes_buf() doesn't allow more than 2147483647 bytes to be
+ * generated in one invocation.
+ */
+ if ($bytes > 2147483647) {
+ for ($i = 0; $i < $bytes; $i += 1073741824) {
+ $n = ($bytes - $i) > 1073741824
+ ? 1073741824
+ : $bytes - $i;
+ $buf .= Sodium::randombytes_buf((int) $n);
+ }
+ } else {
+ $buf .= Sodium::randombytes_buf((int) $bytes);
+ }
+
+ if (is_string($buf)) {
+ if (RandomCompat_strlen($buf) === $bytes) {
+ return $buf;
+ }
+ }
+
+ /**
+ * If we reach here, PHP has failed us.
+ */
+ throw new Exception(
+ 'Could not gather sufficient random data'
+ );
+ }
+}
--- /dev/null
+<?php
+/**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+if (!is_callable('random_bytes')) {
+ /**
+ * Powered by ext/mcrypt (and thankfully NOT libmcrypt)
+ *
+ * @ref https://bugs.php.net/bug.php?id=55169
+ * @ref https://github.com/php/php-src/blob/c568ffe5171d942161fc8dda066bce844bdef676/ext/mcrypt/mcrypt.c#L1321-L1386
+ *
+ * @param int $bytes
+ *
+ * @throws Exception
+ *
+ * @return string
+ */
+ function random_bytes($bytes)
+ {
+ try {
+ $bytes = RandomCompat_intval($bytes);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_bytes(): $bytes must be an integer'
+ );
+ }
+
+ if ($bytes < 1) {
+ throw new Error(
+ 'Length must be greater than 0'
+ );
+ }
+
+ $buf = @mcrypt_create_iv($bytes, MCRYPT_DEV_URANDOM);
+ if (
+ $buf !== false
+ &&
+ RandomCompat_strlen($buf) === $bytes
+ ) {
+ /**
+ * Return our random entropy buffer here:
+ */
+ return $buf;
+ }
+
+ /**
+ * If we reach here, PHP has failed us.
+ */
+ throw new Exception(
+ 'Could not gather sufficient random data'
+ );
+ }
+}
--- /dev/null
+<?php
+
+if (!is_callable('random_int')) {
+ /**
+ * Random_* Compatibility Library
+ * for using the new PHP 7 random_* API in PHP 5 projects
+ *
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 - 2017 Paragon Initiative Enterprises
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+ * SOFTWARE.
+ */
+
+ /**
+ * Fetch a random integer between $min and $max inclusive
+ *
+ * @param int $min
+ * @param int $max
+ *
+ * @throws Exception
+ *
+ * @return int
+ */
+ function random_int($min, $max)
+ {
+ /**
+ * Type and input logic checks
+ *
+ * If you pass it a float in the range (~PHP_INT_MAX, PHP_INT_MAX)
+ * (non-inclusive), it will sanely cast it to an int. If you it's equal to
+ * ~PHP_INT_MAX or PHP_INT_MAX, we let it fail as not an integer. Floats
+ * lose precision, so the <= and => operators might accidentally let a float
+ * through.
+ */
+
+ try {
+ $min = RandomCompat_intval($min);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_int(): $min must be an integer'
+ );
+ }
+
+ try {
+ $max = RandomCompat_intval($max);
+ } catch (TypeError $ex) {
+ throw new TypeError(
+ 'random_int(): $max must be an integer'
+ );
+ }
+
+ /**
+ * Now that we've verified our weak typing system has given us an integer,
+ * let's validate the logic then we can move forward with generating random
+ * integers along a given range.
+ */
+ if ($min > $max) {
+ throw new Error(
+ 'Minimum value must be less than or equal to the maximum value'
+ );
+ }
+
+ if ($max === $min) {
+ return (int) $min;
+ }
+
+ /**
+ * Initialize variables to 0
+ *
+ * We want to store:
+ * $bytes => the number of random bytes we need
+ * $mask => an integer bitmask (for use with the &) operator
+ * so we can minimize the number of discards
+ */
+ $attempts = $bits = $bytes = $mask = $valueShift = 0;
+
+ /**
+ * At this point, $range is a positive number greater than 0. It might
+ * overflow, however, if $max - $min > PHP_INT_MAX. PHP will cast it to
+ * a float and we will lose some precision.
+ */
+ $range = $max - $min;
+
+ /**
+ * Test for integer overflow:
+ */
+ if (!is_int($range)) {
+
+ /**
+ * Still safely calculate wider ranges.
+ * Provided by @CodesInChaos, @oittaa
+ *
+ * @ref https://gist.github.com/CodesInChaos/03f9ea0b58e8b2b8d435
+ *
+ * We use ~0 as a mask in this case because it generates all 1s
+ *
+ * @ref https://eval.in/400356 (32-bit)
+ * @ref http://3v4l.org/XX9r5 (64-bit)
+ */
+ $bytes = PHP_INT_SIZE;
+ $mask = ~0;
+
+ } else {
+
+ /**
+ * $bits is effectively ceil(log($range, 2)) without dealing with
+ * type juggling
+ */
+ while ($range > 0) {
+ if ($bits % 8 === 0) {
+ ++$bytes;
+ }
+ ++$bits;
+ $range >>= 1;
+ $mask = $mask << 1 | 1;
+ }
+ $valueShift = $min;
+ }
+
+ $val = 0;
+ /**
+ * Now that we have our parameters set up, let's begin generating
+ * random integers until one falls between $min and $max
+ */
+ do {
+ /**
+ * The rejection probability is at most 0.5, so this corresponds
+ * to a failure probability of 2^-128 for a working RNG
+ */
+ if ($attempts > 128) {
+ throw new Exception(
+ 'random_int: RNG is broken - too many rejections'
+ );
+ }
+
+ /**
+ * Let's grab the necessary number of random bytes
+ */
+ $randomByteString = random_bytes($bytes);
+
+ /**
+ * Let's turn $randomByteString into an integer
+ *
+ * This uses bitwise operators (<< and |) to build an integer
+ * out of the values extracted from ord()
+ *
+ * Example: [9F] | [6D] | [32] | [0C] =>
+ * 159 + 27904 + 3276800 + 201326592 =>
+ * 204631455
+ */
+ $val &= 0;
+ for ($i = 0; $i < $bytes; ++$i) {
+ $val |= ord($randomByteString[$i]) << ($i * 8);
+ }
+
+ /**
+ * Apply mask
+ */
+ $val &= $mask;
+ $val += $valueShift;
+
+ ++$attempts;
+ /**
+ * If $val overflows to a floating point number,
+ * ... or is larger than $max,
+ * ... or smaller than $min,
+ * then try again.
+ */
+ } while (!is_int($val) || $val > $max || $val < $min);
+
+ return (int) $val;
+ }
+}
--- /dev/null
+<?php
+$dist = dirname(__DIR__).'/dist';
+if (!is_dir($dist)) {
+ mkdir($dist, 0755);
+}
+if (file_exists($dist.'/random_compat.phar')) {
+ unlink($dist.'/random_compat.phar');
+}
+$phar = new Phar(
+ $dist.'/random_compat.phar',
+ FilesystemIterator::CURRENT_AS_FILEINFO | \FilesystemIterator::KEY_AS_FILENAME,
+ 'random_compat.phar'
+);
+rename(
+ dirname(__DIR__).'/lib/random.php',
+ dirname(__DIR__).'/lib/index.php'
+);
+$phar->buildFromDirectory(dirname(__DIR__).'/lib');
+rename(
+ dirname(__DIR__).'/lib/index.php',
+ dirname(__DIR__).'/lib/random.php'
+);
+
+/**
+ * If we pass an (optional) path to a private key as a second argument, we will
+ * sign the Phar with OpenSSL.
+ *
+ * If you leave this out, it will produce an unsigned .phar!
+ */
+if ($argc > 1) {
+ if (!@is_readable($argv[1])) {
+ echo 'Could not read the private key file:', $argv[1], "\n";
+ exit(255);
+ }
+ $pkeyFile = file_get_contents($argv[1]);
+
+ $private = openssl_get_privatekey($pkeyFile);
+ if ($private !== false) {
+ $pkey = '';
+ openssl_pkey_export($private, $pkey);
+ $phar->setSignatureAlgorithm(Phar::OPENSSL, $pkey);
+
+ /**
+ * Save the corresponding public key to the file
+ */
+ if (!@is_readable($dist.'/random_compat.phar.pubkey')) {
+ $details = openssl_pkey_get_details($private);
+ file_put_contents(
+ $dist.'/random_compat.phar.pubkey',
+ $details['key']
+ );
+ }
+ } else {
+ echo 'An error occurred reading the private key from OpenSSL.', "\n";
+ exit(255);
+ }
+}
--- /dev/null
+<?php
+
+require_once 'lib/byte_safe_strings.php';
+require_once 'lib/cast_to_int.php';
+require_once 'lib/error_polyfill.php';
+require_once 'other/ide_stubs/libsodium.php';
+require_once 'lib/random.php';
+
+$int = random_int(0, 65536);
--- /dev/null
+<?xml version="1.0"?>
+<psalm
+ autoloader="psalm-autoload.php"
+ stopOnFirstError="false"
+ useDocblockTypes="true"
+>
+ <projectFiles>
+ <directory name="lib" />
+ </projectFiles>
+ <issueHandlers>
+ <DuplicateClass errorLevel="info" />
+ <InvalidOperand errorLevel="info" />
+ <UndefinedConstant errorLevel="info" />
+ <MissingReturnType errorLevel="info" />
+ </issueHandlers>
+</psalm>
.invalid-src:after,
.invalid-href:after { content: '⚠️'}
img.invalid-src:after { vertical-align: top;}
+
+/* Tag cloud */
+.tag1, .tag1:hover {
+ font-size: 0.9em ;
+ color: DarkGray;
+}
+.tag2, .tag2:hover {
+ font-size: 1.0em;
+ color: LawnGreen;
+}
+.tag3, .tag3:hover {
+ font-size: 1.1em;
+ color: DarkOrange;
+}
+.tag4, .tag4:hover {
+ font-size: 1.2em;
+ color: Red;
+}
+.tag5, .tag5:hover {
+ font-size: 1.3em;
+ color: Gold;
+}
+.tag6, .tag6:hover {
+ font-size: 1.4em;
+ color: Teal;
+}
+.tag7, .tag7:hover {
+ font-size: 1.5em;
+ color: DarkMagenta;
+}
+.tag8, .tag8:hover {
+ font-size: 1.6em;
+ color: DarkGoldenRod;
+}
+.tag9, .tag9:hover {
+ font-size: 1.7em;
+ color: DarkBlue;
+}
+.tag10 .tag10:hover {
+ font-size: 1.8em;
+ color: DeepPink;
+}
+.tags > a:hover {
+ text-decoration: underline;
+}
+.tag-cloud {
+ word-wrap: break-word;
+}
\ No newline at end of file
# fabrixxm <fabrix.xm@gmail.com>, 2011-2012
# Francesco Apruzzese <cescoap@gmail.com>, 2012-2013
# ufic <marco@carnazzo.it>, 2012
+# Mauro Batini <mbatini@gmail.com>, 2017
# Paolo Wave <pynolo@tarine.net>, 2012
# Sandro Santilli <strk@kbt.io>, 2015-2016
msgid ""
msgstr ""
"Project-Id-Version: friendica\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2017-05-03 07:08+0200\n"
-"PO-Revision-Date: 2017-05-15 11:24+0000\n"
-"Last-Translator: fabrixxm <fabrix.xm@gmail.com>\n"
+"POT-Creation-Date: 2017-11-07 07:03+0100\n"
+"PO-Revision-Date: 2017-11-18 18:26+0000\n"
+"Last-Translator: Mauro Batini <mbatini@gmail.com>\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"
"Language: it\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: include/ForumManager.php:114 include/nav.php:131 include/text.php:1093
-#: view/theme/vier/theme.php:254
-msgid "Forums"
-msgstr "Forum"
-
-#: include/ForumManager.php:116 view/theme/vier/theme.php:256
-msgid "External link to forum"
-msgstr "Link esterno al forum"
+#: include/features.php:65
+msgid "General Features"
+msgstr "Funzionalità generali"
-#: include/ForumManager.php:119 include/contact_widgets.php:269
-#: include/items.php:2450 mod/content.php:624 object/Item.php:420
-#: view/theme/vier/theme.php:259 boot.php:1000
-msgid "show more"
-msgstr "mostra di più"
+#: include/features.php:67
+msgid "Multiple Profiles"
+msgstr "Profili multipli"
-#: include/NotificationsManager.php:153
-msgid "System"
-msgstr "Sistema"
+#: include/features.php:67
+msgid "Ability to create multiple profiles"
+msgstr "Possibilità di creare profili multipli"
-#: include/NotificationsManager.php:160 include/nav.php:158 mod/admin.php:517
-#: view/theme/frio/theme.php:253
-msgid "Network"
-msgstr "Rete"
+#: include/features.php:68
+msgid "Photo Location"
+msgstr "Località Foto"
-#: include/NotificationsManager.php:167 mod/network.php:832
-#: mod/profiles.php:696
-msgid "Personal"
-msgstr "Personale"
+#: include/features.php:68
+msgid ""
+"Photo metadata is normally stripped. This extracts the location (if present)"
+" prior to stripping metadata and links it to a map."
+msgstr "I metadati delle foto vengono rimossi. Questa opzione estrae la località (se presenta) prima di rimuovere i metadati e la collega a una mappa."
-#: include/NotificationsManager.php:174 include/nav.php:105
-#: include/nav.php:161
-msgid "Home"
-msgstr "Home"
+#: include/features.php:69
+msgid "Export Public Calendar"
+msgstr "Esporta calendario pubblico"
-#: include/NotificationsManager.php:181 include/nav.php:166
-msgid "Introductions"
-msgstr "Presentazioni"
+#: include/features.php:69
+msgid "Ability for visitors to download the public calendar"
+msgstr "Permesso ai visitatori di scaricare il calendario pubblico"
-#: include/NotificationsManager.php:239 include/NotificationsManager.php:251
-#, php-format
-msgid "%s commented on %s's post"
-msgstr "%s ha commentato il messaggio di %s"
+#: include/features.php:74
+msgid "Post Composition Features"
+msgstr "Funzionalità di composizione dei post"
-#: include/NotificationsManager.php:250
-#, php-format
-msgid "%s created a new post"
-msgstr "%s a creato un nuovo messaggio"
+#: include/features.php:75
+msgid "Post Preview"
+msgstr "Anteprima dei post"
-#: include/NotificationsManager.php:265
-#, php-format
-msgid "%s liked %s's post"
-msgstr "a %s è piaciuto il messaggio di %s"
+#: include/features.php:75
+msgid "Allow previewing posts and comments before publishing them"
+msgstr "Permetti di avere un'anteprima di messaggi e commenti prima di pubblicarli"
-#: include/NotificationsManager.php:278
-#, php-format
-msgid "%s disliked %s's post"
-msgstr "a %s non è piaciuto il messaggio di %s"
+#: include/features.php:76
+msgid "Auto-mention Forums"
+msgstr "Auto-cita i Forum"
-#: include/NotificationsManager.php:291
-#, php-format
-msgid "%s is attending %s's event"
-msgstr "%s partecipa all'evento di %s"
+#: include/features.php:76
+msgid ""
+"Add/remove mention when a forum page is selected/deselected in ACL window."
+msgstr "Aggiunge/rimuove una menzione quando una pagina forum è selezionata/deselezionata nella finestra dei permessi."
-#: include/NotificationsManager.php:304
-#, php-format
-msgid "%s is not attending %s's event"
-msgstr "%s non partecipa all'evento di %s"
+#: include/features.php:81
+msgid "Network Sidebar Widgets"
+msgstr "Widget della barra laterale nella pagina Rete"
-#: include/NotificationsManager.php:317
-#, php-format
-msgid "%s may attend %s's event"
-msgstr "%s potrebbe partecipare all'evento di %s"
+#: include/features.php:82
+msgid "Search by Date"
+msgstr "Cerca per data"
-#: include/NotificationsManager.php:334
-#, php-format
-msgid "%s is now friends with %s"
-msgstr "%s è ora amico di %s"
+#: include/features.php:82
+msgid "Ability to select posts by date ranges"
+msgstr "Permette di filtrare i post per data"
-#: include/NotificationsManager.php:770
-msgid "Friend Suggestion"
-msgstr "Amico suggerito"
+#: include/features.php:83 include/features.php:113
+msgid "List Forums"
+msgstr "Elenco forum"
-#: include/NotificationsManager.php:803
-msgid "Friend/Connect Request"
-msgstr "Richiesta amicizia/connessione"
+#: include/features.php:83
+msgid "Enable widget to display the forums your are connected with"
+msgstr "Abilita il widget che mostra i forum ai quali sei connesso"
-#: include/NotificationsManager.php:803
-msgid "New Follower"
-msgstr "Qualcuno inizia a seguirti"
+#: include/features.php:84
+msgid "Group Filter"
+msgstr "Filtra gruppi"
-#: include/Photo.php:1038 include/Photo.php:1054 include/Photo.php:1062
-#: include/Photo.php:1087 include/message.php:146 mod/wall_upload.php:249
-#: mod/item.php:467
-msgid "Wall Photos"
-msgstr "Foto della bacheca"
+#: include/features.php:84
+msgid "Enable widget to display Network posts only from selected group"
+msgstr "Abilita il widget per filtrare i post solo per il gruppo selezionato"
-#: include/delivery.php:427
-msgid "(no subject)"
-msgstr "(nessun oggetto)"
+#: include/features.php:85
+msgid "Network Filter"
+msgstr "Filtro reti"
-#: include/delivery.php:439 include/enotify.php:43
-msgid "noreply"
-msgstr "nessuna risposta"
+#: include/features.php:85
+msgid "Enable widget to display Network posts only from selected network"
+msgstr "Abilita il widget per mostrare i post solo per la rete selezionata"
-#: include/like.php:27 include/conversation.php:153 include/diaspora.php:1576
-#, php-format
-msgid "%1$s likes %2$s's %3$s"
-msgstr "A %1$s piace %3$s di %2$s"
+#: include/features.php:86 mod/search.php:37 mod/network.php:196
+msgid "Saved Searches"
+msgstr "Ricerche salvate"
-#: include/like.php:31 include/like.php:36 include/conversation.php:156
-#, php-format
-msgid "%1$s doesn't like %2$s's %3$s"
-msgstr "A %1$s non piace %3$s di %2$s"
+#: include/features.php:86
+msgid "Save search terms for re-use"
+msgstr "Salva i termini cercati per riutilizzarli"
-#: include/like.php:41
-#, php-format
-msgid "%1$s is attending %2$s's %3$s"
-msgstr "%1$s parteciperà a %3$s di %2$s"
+#: include/features.php:91
+msgid "Network Tabs"
+msgstr "Schede pagina Rete"
-#: include/like.php:46
-#, php-format
-msgid "%1$s is not attending %2$s's %3$s"
-msgstr "%1$s non parteciperà a %3$s di %2$s"
+#: include/features.php:92
+msgid "Network Personal Tab"
+msgstr "Scheda Personali"
-#: include/like.php:51
-#, php-format
-msgid "%1$s may attend %2$s's %3$s"
-msgstr "%1$s forse parteciperà a %3$s di %2$s"
+#: include/features.php:92
+msgid "Enable tab to display only Network posts that you've interacted on"
+msgstr "Abilita la scheda per mostrare solo i post a cui hai partecipato"
-#: include/like.php:178 include/conversation.php:141
-#: include/conversation.php:293 include/text.php:1872 mod/subthread.php:88
-#: mod/tagger.php:62
-msgid "photo"
-msgstr "foto"
+#: include/features.php:93
+msgid "Network New Tab"
+msgstr "Scheda Nuovi"
-#: include/like.php:178 include/conversation.php:136
-#: include/conversation.php:146 include/conversation.php:288
-#: include/conversation.php:297 include/diaspora.php:1580 mod/subthread.php:88
-#: mod/tagger.php:62
-msgid "status"
-msgstr "stato"
+#: include/features.php:93
+msgid "Enable tab to display only new Network posts (from the last 12 hours)"
+msgstr "Abilita la scheda per mostrare solo i post nuovi (nelle ultime 12 ore)"
-#: include/like.php:180 include/conversation.php:133
-#: include/conversation.php:285 include/text.php:1870
-msgid "event"
-msgstr "l'evento"
+#: include/features.php:94
+msgid "Network Shared Links Tab"
+msgstr "Scheda Link Condivisi"
-#: include/message.php:15 include/message.php:169
-msgid "[no subject]"
-msgstr "[nessun oggetto]"
+#: include/features.php:94
+msgid "Enable tab to display only Network posts with links in them"
+msgstr "Abilita la scheda per mostrare solo i post che contengono link"
-#: include/nav.php:35 mod/navigation.php:19
-msgid "Nothing new here"
-msgstr "Niente di nuovo qui"
+#: include/features.php:99
+msgid "Post/Comment Tools"
+msgstr "Strumenti per messaggi/commenti"
-#: include/nav.php:39 mod/navigation.php:23
-msgid "Clear notifications"
-msgstr "Pulisci le notifiche"
+#: include/features.php:100
+msgid "Multiple Deletion"
+msgstr "Eliminazione multipla"
-#: include/nav.php:40 include/text.php:1083
-msgid "@name, !forum, #tags, content"
-msgstr "@nome, !forum, #tag, contenuto"
+#: include/features.php:100
+msgid "Select and delete multiple posts/comments at once"
+msgstr "Seleziona ed elimina vari messaggi e commenti in una volta sola"
-#: include/nav.php:78 view/theme/frio/theme.php:243 boot.php:1867
-msgid "Logout"
-msgstr "Esci"
+#: include/features.php:101
+msgid "Edit Sent Posts"
+msgstr "Modifica i post inviati"
-#: include/nav.php:78 view/theme/frio/theme.php:243
-msgid "End this session"
-msgstr "Finisci questa sessione"
+#: include/features.php:101
+msgid "Edit and correct posts and comments after sending"
+msgstr "Modifica e correggi messaggi e commenti dopo averli inviati"
-#: include/nav.php:81 include/identity.php:769 mod/contacts.php:645
-#: mod/contacts.php:841 view/theme/frio/theme.php:246
-msgid "Status"
-msgstr "Stato"
+#: include/features.php:102
+msgid "Tagging"
+msgstr "Aggiunta tag"
-#: include/nav.php:81 include/nav.php:161 view/theme/frio/theme.php:246
-msgid "Your posts and conversations"
-msgstr "I tuoi messaggi e le tue conversazioni"
+#: include/features.php:102
+msgid "Ability to tag existing posts"
+msgstr "Permette di aggiungere tag ai post già esistenti"
-#: include/nav.php:82 include/identity.php:622 include/identity.php:744
-#: include/identity.php:777 mod/contacts.php:647 mod/contacts.php:849
-#: mod/newmember.php:32 mod/profperm.php:105 view/theme/frio/theme.php:247
-msgid "Profile"
-msgstr "Profilo"
+#: include/features.php:103
+msgid "Post Categories"
+msgstr "Categorie post"
-#: include/nav.php:82 view/theme/frio/theme.php:247
-msgid "Your profile page"
-msgstr "Pagina del tuo profilo"
+#: include/features.php:103
+msgid "Add categories to your posts"
+msgstr "Aggiungi categorie ai tuoi post"
-#: include/nav.php:83 include/identity.php:785 mod/fbrowser.php:31
-#: view/theme/frio/theme.php:248
-msgid "Photos"
-msgstr "Foto"
+#: include/features.php:104 include/contact_widgets.php:167
+msgid "Saved Folders"
+msgstr "Cartelle Salvate"
-#: include/nav.php:83 view/theme/frio/theme.php:248
-msgid "Your photos"
-msgstr "Le tue foto"
+#: include/features.php:104
+msgid "Ability to file posts under folders"
+msgstr "Permette di archiviare i post in cartelle"
-#: include/nav.php:84 include/identity.php:793 include/identity.php:796
-#: view/theme/frio/theme.php:249
-msgid "Videos"
-msgstr "Video"
+#: include/features.php:105
+msgid "Dislike Posts"
+msgstr "Non mi piace"
-#: include/nav.php:84 view/theme/frio/theme.php:249
-msgid "Your videos"
-msgstr "I tuoi video"
+#: include/features.php:105
+msgid "Ability to dislike posts/comments"
+msgstr "Permetti di inviare \"non mi piace\" ai messaggi"
-#: include/nav.php:85 include/nav.php:149 include/identity.php:805
-#: include/identity.php:816 mod/cal.php:270 mod/events.php:374
-#: view/theme/frio/theme.php:250 view/theme/frio/theme.php:254
-msgid "Events"
-msgstr "Eventi"
+#: include/features.php:106
+msgid "Star Posts"
+msgstr "Post preferiti"
-#: include/nav.php:85 view/theme/frio/theme.php:250
-msgid "Your events"
-msgstr "I tuoi eventi"
+#: include/features.php:106
+msgid "Ability to mark special posts with a star indicator"
+msgstr "Permette di segnare i post preferiti con una stella"
-#: include/nav.php:86
-msgid "Personal notes"
-msgstr "Note personali"
+#: include/features.php:107
+msgid "Mute Post Notifications"
+msgstr "Silenzia le notifiche di nuovi post"
-#: include/nav.php:86
-msgid "Your personal notes"
-msgstr "Le tue note personali"
+#: include/features.php:107
+msgid "Ability to mute notifications for a thread"
+msgstr "Permette di silenziare le notifiche di nuovi post in una discussione"
-#: include/nav.php:95 mod/bookmarklet.php:12 boot.php:1868
-msgid "Login"
-msgstr "Accedi"
-
-#: include/nav.php:95
-msgid "Sign in"
-msgstr "Entra"
-
-#: include/nav.php:105
-msgid "Home Page"
-msgstr "Home Page"
-
-#: include/nav.php:109 mod/register.php:289 boot.php:1844
-msgid "Register"
-msgstr "Registrati"
-
-#: include/nav.php:109
-msgid "Create an account"
-msgstr "Crea un account"
-
-#: include/nav.php:115 mod/help.php:47 view/theme/vier/theme.php:297
-msgid "Help"
-msgstr "Guida"
-
-#: include/nav.php:115
-msgid "Help and documentation"
-msgstr "Guida e documentazione"
-
-#: include/nav.php:119
-msgid "Apps"
-msgstr "Applicazioni"
-
-#: include/nav.php:119
-msgid "Addon applications, utilities, games"
-msgstr "Applicazioni, utilità e giochi aggiuntivi"
-
-#: include/nav.php:123 include/text.php:1080 mod/search.php:149
-msgid "Search"
-msgstr "Cerca"
-
-#: include/nav.php:123
-msgid "Search site content"
-msgstr "Cerca nel contenuto del sito"
-
-#: include/nav.php:126 include/text.php:1088
-msgid "Full Text"
-msgstr "Testo Completo"
-
-#: include/nav.php:127 include/text.php:1089
-msgid "Tags"
-msgstr "Tags:"
-
-#: include/nav.php:128 include/nav.php:192 include/identity.php:838
-#: include/identity.php:841 include/text.php:1090 mod/contacts.php:800
-#: mod/contacts.php:861 mod/viewcontacts.php:121 view/theme/frio/theme.php:257
-msgid "Contacts"
-msgstr "Contatti"
-
-#: include/nav.php:143 include/nav.php:145 mod/community.php:32
-msgid "Community"
-msgstr "Comunità"
-
-#: include/nav.php:143
-msgid "Conversations on this site"
-msgstr "Conversazioni su questo sito"
-
-#: include/nav.php:145
-msgid "Conversations on the network"
-msgstr "Conversazioni nella rete"
-
-#: include/nav.php:149 include/identity.php:808 include/identity.php:819
-#: view/theme/frio/theme.php:254
-msgid "Events and Calendar"
-msgstr "Eventi e calendario"
-
-#: include/nav.php:152
-msgid "Directory"
-msgstr "Elenco"
-
-#: include/nav.php:152
-msgid "People directory"
-msgstr "Elenco delle persone"
-
-#: include/nav.php:154
-msgid "Information"
-msgstr "Informazioni"
-
-#: include/nav.php:154
-msgid "Information about this friendica instance"
-msgstr "Informazioni su questo server friendica"
-
-#: include/nav.php:158 view/theme/frio/theme.php:253
-msgid "Conversations from your friends"
-msgstr "Conversazioni dai tuoi amici"
-
-#: include/nav.php:159
-msgid "Network Reset"
-msgstr "Reset pagina Rete"
-
-#: include/nav.php:159
-msgid "Load Network page with no filters"
-msgstr "Carica la pagina Rete senza nessun filtro"
-
-#: include/nav.php:166
-msgid "Friend Requests"
-msgstr "Richieste di amicizia"
-
-#: include/nav.php:169 mod/notifications.php:96
-msgid "Notifications"
-msgstr "Notifiche"
+#: include/features.php:112
+msgid "Advanced Profile Settings"
+msgstr "Impostazioni Avanzate Profilo"
-#: include/nav.php:170
-msgid "See all notifications"
-msgstr "Vedi tutte le notifiche"
+#: include/features.php:113
+msgid "Show visitors public community forums at the Advanced Profile Page"
+msgstr "Mostra ai visitatori i forum nella pagina Profilo Avanzato"
-#: include/nav.php:171 mod/settings.php:906
-msgid "Mark as seen"
-msgstr "Segna come letto"
+#: include/datetime.php:66 include/datetime.php:68 mod/profiles.php:697
+msgid "Miscellaneous"
+msgstr "Varie"
-#: include/nav.php:171
-msgid "Mark all system notifications seen"
-msgstr "Segna tutte le notifiche come viste"
+#: include/datetime.php:196 include/identity.php:655
+msgid "Birthday:"
+msgstr "Compleanno:"
-#: include/nav.php:175 mod/message.php:179 view/theme/frio/theme.php:255
-msgid "Messages"
-msgstr "Messaggi"
+#: include/datetime.php:198 mod/profiles.php:720
+msgid "Age: "
+msgstr "Età : "
-#: include/nav.php:175 view/theme/frio/theme.php:255
-msgid "Private mail"
-msgstr "Posta privata"
+#: include/datetime.php:200
+msgid "YYYY-MM-DD or MM-DD"
+msgstr "AAAA-MM-GG o MM-GG"
-#: include/nav.php:176
-msgid "Inbox"
-msgstr "In arrivo"
+#: include/datetime.php:370
+msgid "never"
+msgstr "mai"
-#: include/nav.php:177
-msgid "Outbox"
-msgstr "Inviati"
+#: include/datetime.php:376
+msgid "less than a second ago"
+msgstr "meno di un secondo fa"
-#: include/nav.php:178 mod/message.php:16
-msgid "New Message"
-msgstr "Nuovo messaggio"
+#: include/datetime.php:379
+msgid "year"
+msgstr "anno"
-#: include/nav.php:181
-msgid "Manage"
-msgstr "Gestisci"
+#: include/datetime.php:379
+msgid "years"
+msgstr "anni"
-#: include/nav.php:181
-msgid "Manage other pages"
-msgstr "Gestisci altre pagine"
+#: include/datetime.php:380 include/event.php:490 mod/cal.php:282
+#: mod/events.php:393
+msgid "month"
+msgstr "mese"
-#: include/nav.php:184 mod/settings.php:81
-msgid "Delegations"
-msgstr "Delegazioni"
+#: include/datetime.php:380
+msgid "months"
+msgstr "mesi"
-#: include/nav.php:184 mod/delegate.php:130
-msgid "Delegate Page Management"
-msgstr "Gestione delegati per la pagina"
+#: include/datetime.php:381 include/event.php:491 mod/cal.php:283
+#: mod/events.php:394
+msgid "week"
+msgstr "settimana"
-#: include/nav.php:186 mod/newmember.php:22 mod/settings.php:111
-#: mod/admin.php:1618 mod/admin.php:1894 view/theme/frio/theme.php:256
-msgid "Settings"
-msgstr "Impostazioni"
+#: include/datetime.php:381
+msgid "weeks"
+msgstr "settimane"
-#: include/nav.php:186 view/theme/frio/theme.php:256
-msgid "Account settings"
-msgstr "Parametri account"
+#: include/datetime.php:382 include/event.php:492 mod/cal.php:284
+#: mod/events.php:395
+msgid "day"
+msgstr "giorno"
-#: include/nav.php:189 include/identity.php:290
-msgid "Profiles"
-msgstr "Profili"
+#: include/datetime.php:382
+msgid "days"
+msgstr "giorni"
-#: include/nav.php:189
-msgid "Manage/Edit Profiles"
-msgstr "Gestisci/Modifica i profili"
+#: include/datetime.php:383
+msgid "hour"
+msgstr "ora"
-#: include/nav.php:192 view/theme/frio/theme.php:257
-msgid "Manage/edit friends and contacts"
-msgstr "Gestisci/modifica amici e contatti"
+#: include/datetime.php:383
+msgid "hours"
+msgstr "ore"
-#: include/nav.php:197 mod/admin.php:196
-msgid "Admin"
-msgstr "Amministrazione"
+#: include/datetime.php:384
+msgid "minute"
+msgstr "minuto"
-#: include/nav.php:197
-msgid "Site setup and configuration"
-msgstr "Configurazione del sito"
+#: include/datetime.php:384
+msgid "minutes"
+msgstr "minuti"
-#: include/nav.php:200
-msgid "Navigation"
-msgstr "Navigazione"
+#: include/datetime.php:385
+msgid "second"
+msgstr "secondo"
-#: include/nav.php:200
-msgid "Site map"
-msgstr "Mappa del sito"
+#: include/datetime.php:385
+msgid "seconds"
+msgstr "secondi"
-#: include/plugin.php:530 include/plugin.php:532
-msgid "Click here to upgrade."
-msgstr "Clicca qui per aggiornare."
+#: include/datetime.php:394
+#, php-format
+msgid "%1$d %2$s ago"
+msgstr "%1$d %2$s fa"
-#: include/plugin.php:538
-msgid "This action exceeds the limits set by your subscription plan."
-msgstr "Questa azione eccede i limiti del tuo piano di sottoscrizione."
+#: include/datetime.php:620
+#, php-format
+msgid "%s's birthday"
+msgstr "Compleanno di %s"
-#: include/plugin.php:543
-msgid "This action is not available under your subscription plan."
-msgstr "Questa azione non è disponibile nel tuo piano di sottoscrizione."
+#: include/datetime.php:621 include/dfrn.php:1361
+#, php-format
+msgid "Happy Birthday %s"
+msgstr "Buon compleanno %s"
#: include/profile_selectors.php:6
msgid "Male"
msgid "Other"
msgstr "Altro"
-#: include/profile_selectors.php:6 include/conversation.php:1547
+#: include/profile_selectors.php:6 include/conversation.php:1565
msgid "Undecided"
msgid_plural "Undecided"
msgstr[0] "Indeciso"
msgid "Sex Addict"
msgstr "Sesso-dipendente"
-#: include/profile_selectors.php:42 include/user.php:263 include/user.php:267
+#: include/profile_selectors.php:42 include/user.php:256 include/user.php:260
msgid "Friends"
msgstr "Amici"
msgid "Ask me"
msgstr "Chiedimelo"
-#: include/security.php:61
-msgid "Welcome "
-msgstr "Ciao"
-
-#: include/security.php:62
-msgid "Please upload a profile photo."
-msgstr "Carica una foto per il profilo."
-
-#: include/security.php:65
-msgid "Welcome back "
-msgstr "Ciao "
-
-#: include/security.php:429
+#: include/group.php:25
msgid ""
-"The form security token was not correct. This probably happened because the "
-"form has been opened for too long (>3 hours) before submitting it."
-msgstr "Il token di sicurezza della form non era corretto. Probabilmente la form è rimasta aperta troppo a lungo (più di tre ore) prima di inviarla."
+"A deleted group with this name was revived. Existing item permissions "
+"<strong>may</strong> apply to this group and any future members. If this is "
+"not what you intended, please create another group with a different name."
+msgstr "Un gruppo eliminato con questo nome è stato ricreato. I permessi esistenti su un elemento <strong>possono</strong> essere applicati a questo gruppo e tutti i membri futuri. Se questo non è ciò che si intende, si prega di creare un altro gruppo con un nome diverso."
-#: include/uimport.php:91
-msgid "Error decoding account file"
-msgstr "Errore decodificando il file account"
+#: include/group.php:201
+msgid "Default privacy group for new contacts"
+msgstr "Gruppo predefinito per i nuovi contatti"
-#: include/uimport.php:97
-msgid "Error! No version data in file! This is not a Friendica account file?"
-msgstr "Errore! Nessuna informazione di versione nel file! Potrebbe non essere un file account di Friendica?"
+#: include/group.php:234
+msgid "Everybody"
+msgstr "Tutti"
-#: include/uimport.php:113 include/uimport.php:124
-msgid "Error! Cannot check nickname"
-msgstr "Errore! Non posso controllare il nickname"
+#: include/group.php:257
+msgid "edit"
+msgstr "modifica"
-#: include/uimport.php:117 include/uimport.php:128
-#, php-format
-msgid "User '%s' already exists on this server!"
-msgstr "L'utente '%s' esiste già su questo server!"
+#: include/group.php:278 mod/newmember.php:39
+msgid "Groups"
+msgstr "Gruppi"
-#: include/uimport.php:150
-msgid "User creation error"
-msgstr "Errore creando l'utente"
+#: include/group.php:280
+msgid "Edit groups"
+msgstr "Modifica gruppi"
-#: include/uimport.php:170
-msgid "User profile creation error"
-msgstr "Errore creando il profilo dell'utente"
+#: include/group.php:282
+msgid "Edit group"
+msgstr "Modifica gruppo"
-#: include/uimport.php:219
-#, php-format
-msgid "%d contact not imported"
-msgid_plural "%d contacts not imported"
-msgstr[0] "%d contatto non importato"
-msgstr[1] "%d contatti non importati"
+#: include/group.php:283
+msgid "Create a new group"
+msgstr "Crea un nuovo gruppo"
-#: include/uimport.php:289
-msgid "Done. You can now login with your username and password"
-msgstr "Fatto. Ora puoi entrare con il tuo nome utente e la tua password"
+#: include/group.php:284 mod/group.php:101 mod/group.php:198
+msgid "Group Name: "
+msgstr "Nome del gruppo:"
-#: include/Contact.php:395 include/Contact.php:408 include/Contact.php:453
-#: include/conversation.php:1004 include/conversation.php:1020
-#: mod/allfriends.php:68 mod/directory.php:157 mod/match.php:73
-#: mod/suggest.php:82 mod/dirfind.php:209
-msgid "View Profile"
-msgstr "Visualizza profilo"
+#: include/group.php:286
+msgid "Contacts not in any group"
+msgstr "Contatti in nessun gruppo."
-#: include/Contact.php:409 include/contact_widgets.php:32
-#: include/conversation.php:1017 mod/allfriends.php:69 mod/contacts.php:610
-#: mod/match.php:74 mod/suggest.php:83 mod/dirfind.php:210 mod/follow.php:106
-msgid "Connect/Follow"
-msgstr "Connetti/segui"
+#: include/group.php:288 mod/network.php:197
+msgid "add"
+msgstr "aggiungi"
-#: include/Contact.php:452 include/conversation.php:1003
-msgid "View Status"
-msgstr "Visualizza stato"
-
-#: include/Contact.php:454 include/conversation.php:1005
-msgid "View Photos"
-msgstr "Visualizza foto"
-
-#: include/Contact.php:455 include/conversation.php:1006
-msgid "Network Posts"
-msgstr "Post della Rete"
-
-#: include/Contact.php:456 include/conversation.php:1007
-msgid "View Contact"
-msgstr "Mostra contatto"
+#: include/ForumManager.php:119 include/nav.php:134 include/text.php:1100
+#: view/theme/vier/theme.php:249
+msgid "Forums"
+msgstr "Forum"
-#: include/Contact.php:457
-msgid "Drop Contact"
-msgstr "Rimuovi contatto"
+#: include/ForumManager.php:121 view/theme/vier/theme.php:251
+msgid "External link to forum"
+msgstr "Link esterno al forum"
-#: include/Contact.php:458 include/conversation.php:1008
-msgid "Send PM"
-msgstr "Invia messaggio privato"
+#: include/ForumManager.php:124 include/contact_widgets.php:272
+#: include/items.php:2413 object/Item.php:417 view/theme/vier/theme.php:254
+#: src/App.php:523
+msgid "show more"
+msgstr "mostra di più"
-#: include/Contact.php:459 include/conversation.php:1012
-msgid "Poke"
-msgstr "Stuzzica"
+#: include/NotificationsManager.php:157
+msgid "System"
+msgstr "Sistema"
-#: include/Contact.php:840
-msgid "Organisation"
-msgstr "Organizzazione"
+#: include/NotificationsManager.php:164 include/nav.php:161 mod/admin.php:590
+#: view/theme/frio/theme.php:260
+msgid "Network"
+msgstr "Rete"
-#: include/Contact.php:843
-msgid "News"
-msgstr "Notizie"
+#: include/NotificationsManager.php:171 mod/network.php:914
+#: mod/profiles.php:695
+msgid "Personal"
+msgstr "Personale"
-#: include/Contact.php:846
-msgid "Forum"
-msgstr "Forum"
+#: include/NotificationsManager.php:178 include/nav.php:108
+#: include/nav.php:164
+msgid "Home"
+msgstr "Home"
-#: include/acl_selectors.php:353
-msgid "Post to Email"
-msgstr "Invia a email"
+#: include/NotificationsManager.php:185 include/nav.php:169
+msgid "Introductions"
+msgstr "Presentazioni"
-#: include/acl_selectors.php:358
+#: include/NotificationsManager.php:243 include/NotificationsManager.php:255
#, php-format
-msgid "Connectors disabled, since \"%s\" is enabled."
-msgstr "Connettore disabilitato, dato che \"%s\" è abilitato."
-
-#: include/acl_selectors.php:359 mod/settings.php:1188
-msgid "Hide your profile details from unknown viewers?"
-msgstr "Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?"
-
-#: include/acl_selectors.php:365
-msgid "Visible to everybody"
-msgstr "Visibile a tutti"
-
-#: include/acl_selectors.php:366 view/theme/vier/config.php:108
-msgid "show"
-msgstr "mostra"
-
-#: include/acl_selectors.php:367 view/theme/vier/config.php:108
-msgid "don't show"
-msgstr "non mostrare"
+msgid "%s commented on %s's post"
+msgstr "%s ha commentato il messaggio di %s"
-#: include/acl_selectors.php:373 mod/editpost.php:123
-msgid "CC: email addresses"
-msgstr "CC: indirizzi email"
+#: include/NotificationsManager.php:254
+#, php-format
+msgid "%s created a new post"
+msgstr "%s a creato un nuovo messaggio"
-#: include/acl_selectors.php:374 mod/editpost.php:130
-msgid "Example: bob@example.com, mary@example.com"
-msgstr "Esempio: bob@example.com, mary@example.com"
+#: include/NotificationsManager.php:269
+#, php-format
+msgid "%s liked %s's post"
+msgstr "a %s è piaciuto il messaggio di %s"
-#: include/acl_selectors.php:376 mod/events.php:508 mod/photos.php:1196
-#: mod/photos.php:1593
-msgid "Permissions"
-msgstr "Permessi"
+#: include/NotificationsManager.php:282
+#, php-format
+msgid "%s disliked %s's post"
+msgstr "a %s non è piaciuto il messaggio di %s"
-#: include/acl_selectors.php:377
-msgid "Close"
-msgstr "Chiudi"
+#: include/NotificationsManager.php:295
+#, php-format
+msgid "%s is attending %s's event"
+msgstr "%s partecipa all'evento di %s"
-#: include/api.php:1089
+#: include/NotificationsManager.php:308
#, php-format
-msgid "Daily posting limit of %d posts reached. The post was rejected."
-msgstr "Limite giornaliero di %d messaggi raggiunto. Il messaggio è stato rifiutato"
+msgid "%s is not attending %s's event"
+msgstr "%s non partecipa all'evento di %s"
-#: include/api.php:1110
+#: include/NotificationsManager.php:321
#, php-format
-msgid "Weekly posting limit of %d posts reached. The post was rejected."
-msgstr "Limite settimanale di %d messaggi raggiunto. Il messaggio è stato rifiutato"
+msgid "%s may attend %s's event"
+msgstr "%s potrebbe partecipare all'evento di %s"
-#: include/api.php:1131
+#: include/NotificationsManager.php:338
#, php-format
-msgid "Monthly posting limit of %d posts reached. The post was rejected."
-msgstr "Limite mensile di %d messaggi raggiunto. Il messaggio è stato rifiutato"
+msgid "%s is now friends with %s"
+msgstr "%s è ora amico di %s"
+
+#: include/NotificationsManager.php:776
+msgid "Friend Suggestion"
+msgstr "Amico suggerito"
+
+#: include/NotificationsManager.php:805
+msgid "Friend/Connect Request"
+msgstr "Richiesta amicizia/connessione"
+
+#: include/NotificationsManager.php:805
+msgid "New Follower"
+msgstr "Qualcuno inizia a seguirti"
-#: include/auth.php:51
+#: include/auth.php:53
msgid "Logged out."
msgstr "Uscita effettuata."
-#: include/auth.php:122 include/auth.php:184 mod/openid.php:110
+#: include/auth.php:124 include/auth.php:186 mod/openid.php:111
msgid "Login failed."
msgstr "Accesso fallito."
-#: include/auth.php:138 include/user.php:75
+#: include/auth.php:140 include/user.php:77
msgid ""
"We encountered a problem while logging in with the OpenID you provided. "
"Please check the correct spelling of the ID."
msgstr "Abbiamo incontrato un problema mentre contattavamo il server OpenID che ci hai fornito. Controlla di averlo scritto giusto."
-#: include/auth.php:138 include/user.php:75
+#: include/auth.php:140 include/user.php:77
msgid "The error message was:"
msgstr "Il messaggio riportato era:"
-#: include/bb2diaspora.php:230 include/event.php:17 mod/localtime.php:12
+#: include/bb2diaspora.php:234 include/event.php:19 include/event.php:933
+#: mod/localtime.php:14
msgid "l F d, Y \\@ g:i A"
msgstr "l d F Y \\@ G:i"
-#: include/bb2diaspora.php:236 include/event.php:34 include/event.php:54
-#: include/event.php:525
+#: include/bb2diaspora.php:240 include/event.php:36 include/event.php:53
+#: include/event.php:496 include/event.php:985
msgid "Starts:"
msgstr "Inizia:"
-#: include/bb2diaspora.php:244 include/event.php:37 include/event.php:60
-#: include/event.php:526
+#: include/bb2diaspora.php:248 include/event.php:39 include/event.php:59
+#: include/event.php:497 include/event.php:989
msgid "Finishes:"
msgstr "Finisce:"
-#: include/bb2diaspora.php:253 include/event.php:41 include/event.php:67
-#: include/event.php:527 include/identity.php:336 mod/contacts.php:636
-#: mod/directory.php:139 mod/events.php:493 mod/notifications.php:244
+#: include/bb2diaspora.php:257 include/event.php:43 include/event.php:68
+#: include/event.php:498 include/event.php:1003 include/identity.php:340
+#: mod/notifications.php:247 mod/directory.php:133 mod/contacts.php:658
+#: mod/events.php:517
msgid "Location:"
msgstr "Posizione:"
-#: include/bbcode.php:380 include/bbcode.php:1132 include/bbcode.php:1133
-msgid "Image/photo"
-msgstr "Immagine/foto"
-
-#: include/bbcode.php:497
-#, php-format
-msgid "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
-msgstr "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
-
-#: include/bbcode.php:1089 include/bbcode.php:1111
-msgid "$1 wrote:"
-msgstr "$1 ha scritto:"
-
-#: include/bbcode.php:1141 include/bbcode.php:1142
-msgid "Encrypted content"
-msgstr "Contenuto criptato"
-
-#: include/bbcode.php:1257
-msgid "Invalid source protocol"
-msgstr "Protocollo sorgente non valido"
-
-#: include/bbcode.php:1267
-msgid "Invalid link protocol"
-msgstr "Protocollo link non valido"
-
-#: include/contact_selectors.php:32
-msgid "Unknown | Not categorised"
-msgstr "Sconosciuto | non categorizzato"
-
-#: include/contact_selectors.php:33
-msgid "Block immediately"
-msgstr "Blocca immediatamente"
-
-#: include/contact_selectors.php:34
-msgid "Shady, spammer, self-marketer"
-msgstr "Losco, venditore di fumo"
-
-#: include/contact_selectors.php:35
-msgid "Known to me, but no opinion"
-msgstr "Lo conosco, ma non ho un'opinione particolare"
-
-#: include/contact_selectors.php:36
-msgid "OK, probably harmless"
-msgstr "E' ok, probabilmente innocuo"
-
-#: include/contact_selectors.php:37
-msgid "Reputable, has my trust"
-msgstr "Rispettabile, ha la mia fiducia"
-
-#: include/contact_selectors.php:56 mod/admin.php:980
-msgid "Frequently"
-msgstr "Frequentemente"
-
-#: include/contact_selectors.php:57 mod/admin.php:981
-msgid "Hourly"
-msgstr "Ogni ora"
-
-#: include/contact_selectors.php:58 mod/admin.php:982
-msgid "Twice daily"
-msgstr "Due volte al dì"
-
-#: include/contact_selectors.php:59 mod/admin.php:983
-msgid "Daily"
-msgstr "Giornalmente"
-
-#: include/contact_selectors.php:60
-msgid "Weekly"
-msgstr "Settimanalmente"
-
-#: include/contact_selectors.php:61
-msgid "Monthly"
-msgstr "Mensilmente"
-
-#: include/contact_selectors.php:76 mod/dfrn_request.php:886
-msgid "Friendica"
-msgstr "Friendica"
-
-#: include/contact_selectors.php:77
-msgid "OStatus"
-msgstr "Ostatus"
-
-#: include/contact_selectors.php:78
-msgid "RSS/Atom"
-msgstr "RSS / Atom"
-
-#: include/contact_selectors.php:79 include/contact_selectors.php:86
-#: mod/admin.php:1490 mod/admin.php:1503 mod/admin.php:1516 mod/admin.php:1534
-msgid "Email"
-msgstr "Email"
-
-#: include/contact_selectors.php:80 mod/dfrn_request.php:888
-#: mod/settings.php:848
-msgid "Diaspora"
-msgstr "Diaspora"
-
-#: include/contact_selectors.php:81
-msgid "Facebook"
-msgstr "Facebook"
-
-#: include/contact_selectors.php:82
-msgid "Zot!"
-msgstr "Zot!"
-
-#: include/contact_selectors.php:83
-msgid "LinkedIn"
-msgstr "LinkedIn"
-
-#: include/contact_selectors.php:84
-msgid "XMPP/IM"
-msgstr "XMPP/IM"
-
-#: include/contact_selectors.php:85
-msgid "MySpace"
-msgstr "MySpace"
-
-#: include/contact_selectors.php:87
-msgid "Google+"
-msgstr "Google+"
-
-#: include/contact_selectors.php:88
-msgid "pump.io"
-msgstr "pump.io"
-
-#: include/contact_selectors.php:89
-msgid "Twitter"
-msgstr "Twitter"
-
-#: include/contact_selectors.php:90
-msgid "Diaspora Connector"
-msgstr "Connettore Diaspora"
-
-#: include/contact_selectors.php:91
-msgid "GNU Social Connector"
-msgstr "Connettore GNU Social"
-
-#: include/contact_selectors.php:92
-msgid "pnut"
-msgstr "pnut"
-
-#: include/contact_selectors.php:93
-msgid "App.net"
-msgstr "App.net"
-
-#: include/contact_widgets.php:6
+#: include/contact_widgets.php:12
msgid "Add New Contact"
msgstr "Aggiungi nuovo contatto"
-#: include/contact_widgets.php:7
+#: include/contact_widgets.php:13
msgid "Enter address or web location"
msgstr "Inserisci posizione o indirizzo web"
-#: include/contact_widgets.php:8
+#: include/contact_widgets.php:14
msgid "Example: bob@example.com, http://example.com/barbara"
msgstr "Esempio: bob@example.com, http://example.com/barbara"
-#: include/contact_widgets.php:10 include/identity.php:224
-#: mod/allfriends.php:85 mod/match.php:89 mod/suggest.php:101
-#: mod/dirfind.php:207
+#: include/contact_widgets.php:16 include/identity.php:230
+#: mod/allfriends.php:88 mod/match.php:93 mod/suggest.php:101
+#: mod/dirfind.php:211
msgid "Connect"
msgstr "Connetti"
-#: include/contact_widgets.php:24
+#: include/contact_widgets.php:31
#, php-format
msgid "%d invitation available"
msgid_plural "%d invitations available"
msgstr[0] "%d invito disponibile"
msgstr[1] "%d inviti disponibili"
-#: include/contact_widgets.php:30
+#: include/contact_widgets.php:37
msgid "Find People"
msgstr "Trova persone"
-#: include/contact_widgets.php:31
+#: include/contact_widgets.php:38
msgid "Enter name or interest"
msgstr "Inserisci un nome o un interesse"
-#: include/contact_widgets.php:33
+#: include/contact_widgets.php:39 include/Contact.php:411
+#: include/conversation.php:1035 mod/allfriends.php:72 mod/follow.php:143
+#: mod/match.php:78 mod/suggest.php:83 mod/contacts.php:590
+#: mod/dirfind.php:214
+msgid "Connect/Follow"
+msgstr "Connetti/segui"
+
+#: include/contact_widgets.php:40
msgid "Examples: Robert Morgenstein, Fishing"
msgstr "Esempi: Mario Rossi, Pesca"
-#: include/contact_widgets.php:34 mod/contacts.php:806 mod/directory.php:206
+#: include/contact_widgets.php:41 mod/directory.php:200 mod/contacts.php:828
msgid "Find"
msgstr "Trova"
-#: include/contact_widgets.php:35 mod/suggest.php:114
-#: view/theme/vier/theme.php:201
+#: include/contact_widgets.php:42 mod/suggest.php:114
+#: view/theme/vier/theme.php:196
msgid "Friend Suggestions"
msgstr "Contatti suggeriti"
-#: include/contact_widgets.php:36 view/theme/vier/theme.php:200
+#: include/contact_widgets.php:43 view/theme/vier/theme.php:195
msgid "Similar Interests"
msgstr "Interessi simili"
-#: include/contact_widgets.php:37
+#: include/contact_widgets.php:44
msgid "Random Profile"
msgstr "Profilo causale"
-#: include/contact_widgets.php:38 view/theme/vier/theme.php:202
+#: include/contact_widgets.php:45 view/theme/vier/theme.php:197
msgid "Invite Friends"
msgstr "Invita amici"
-#: include/contact_widgets.php:125
+#: include/contact_widgets.php:46
+msgid "View Global Directory"
+msgstr "Vedi Directory Globale"
+
+#: include/contact_widgets.php:132
msgid "Networks"
msgstr "Reti"
-#: include/contact_widgets.php:128
+#: include/contact_widgets.php:135
msgid "All Networks"
msgstr "Tutte le Reti"
-#: include/contact_widgets.php:160 include/features.php:104
-msgid "Saved Folders"
-msgstr "Cartelle Salvate"
-
-#: include/contact_widgets.php:163 include/contact_widgets.php:198
+#: include/contact_widgets.php:170 include/contact_widgets.php:205
msgid "Everything"
msgstr "Tutto"
-#: include/contact_widgets.php:195
+#: include/contact_widgets.php:202
msgid "Categories"
msgstr "Categorie"
-#: include/contact_widgets.php:264
+#: include/contact_widgets.php:267
#, php-format
msgid "%d contact in common"
msgid_plural "%d contacts in common"
msgstr[0] "%d contatto in comune"
msgstr[1] "%d contatti in comune"
-#: include/conversation.php:159
-#, php-format
-msgid "%1$s attends %2$s's %3$s"
-msgstr "%1$s partecipa a %3$s di %2$s"
+#: include/enotify.php:28
+msgid "Friendica Notification"
+msgstr "Notifica Friendica"
-#: include/conversation.php:162
-#, php-format
-msgid "%1$s doesn't attend %2$s's %3$s"
-msgstr "%1$s non partecipa a %3$s di %2$s"
+#: include/enotify.php:31
+msgid "Thank You,"
+msgstr "Grazie,"
-#: include/conversation.php:165
+#: include/enotify.php:34
#, php-format
-msgid "%1$s attends maybe %2$s's %3$s"
-msgstr "%1$s forse partecipa a %3$s di %2$s"
+msgid "%s Administrator"
+msgstr "Amministratore %s"
-#: include/conversation.php:198 mod/dfrn_confirm.php:478
+#: include/enotify.php:36
#, php-format
-msgid "%1$s is now friends with %2$s"
-msgstr "%1$s e %2$s adesso sono amici"
+msgid "%1$s, %2$s Administrator"
+msgstr "%1$s, amministratore di %2$s"
-#: include/conversation.php:239
-#, php-format
-msgid "%1$s poked %2$s"
-msgstr "%1$s ha stuzzicato %2$s"
+#: include/enotify.php:47 include/delivery.php:441
+msgid "noreply"
+msgstr "nessuna risposta"
-#: include/conversation.php:260 mod/mood.php:63
+#: include/enotify.php:81
#, php-format
-msgid "%1$s is currently %2$s"
-msgstr "%1$s al momento è %2$s"
+msgid "%s <!item_type!>"
+msgstr "%s <!item_type!>"
-#: include/conversation.php:307 mod/tagger.php:95
+#: include/enotify.php:94
#, php-format
-msgid "%1$s tagged %2$s's %3$s with %4$s"
-msgstr "%1$s ha taggato %3$s di %2$s con %4$s"
-
-#: include/conversation.php:334
-msgid "post/item"
-msgstr "post/elemento"
+msgid "[Friendica:Notify] New mail received at %s"
+msgstr "[Friendica:Notifica] Nuovo messaggio privato ricevuto su %s"
-#: include/conversation.php:335
+#: include/enotify.php:96
#, php-format
-msgid "%1$s marked %2$s's %3$s as favorite"
-msgstr "%1$s ha segnato il/la %3$s di %2$s come preferito"
-
-#: include/conversation.php:614 mod/content.php:372 mod/photos.php:1662
-#: mod/profiles.php:340
-msgid "Likes"
-msgstr "Mi piace"
-
-#: include/conversation.php:614 mod/content.php:372 mod/photos.php:1662
-#: mod/profiles.php:344
-msgid "Dislikes"
-msgstr "Non mi piace"
-
-#: include/conversation.php:615 include/conversation.php:1541
-#: mod/content.php:373 mod/photos.php:1663
-msgid "Attending"
-msgid_plural "Attending"
-msgstr[0] "Partecipa"
-msgstr[1] "Partecipano"
-
-#: include/conversation.php:615 mod/content.php:373 mod/photos.php:1663
-msgid "Not attending"
-msgstr "Non partecipa"
-
-#: include/conversation.php:615 mod/content.php:373 mod/photos.php:1663
-msgid "Might attend"
-msgstr "Forse partecipa"
+msgid "%1$s sent you a new private message at %2$s."
+msgstr "%1$s ti ha inviato un nuovo messaggio privato su %2$s."
-#: include/conversation.php:747 mod/content.php:453 mod/content.php:759
-#: mod/photos.php:1728 object/Item.php:137
-msgid "Select"
-msgstr "Seleziona"
+#: include/enotify.php:97
+#, php-format
+msgid "%1$s sent you %2$s."
+msgstr "%1$s ti ha inviato %2$s"
-#: include/conversation.php:748 mod/contacts.php:816 mod/contacts.php:1015
-#: mod/content.php:454 mod/content.php:760 mod/photos.php:1729
-#: mod/settings.php:744 mod/admin.php:1508 object/Item.php:138
-msgid "Delete"
-msgstr "Rimuovi"
+#: include/enotify.php:97
+msgid "a private message"
+msgstr "un messaggio privato"
-#: include/conversation.php:791 mod/content.php:487 mod/content.php:915
-#: mod/content.php:916 object/Item.php:356 object/Item.php:357
+#: include/enotify.php:99
#, php-format
-msgid "View %s's profile @ %s"
-msgstr "Vedi il profilo di %s @ %s"
-
-#: include/conversation.php:803 object/Item.php:344
-msgid "Categories:"
-msgstr "Categorie:"
+msgid "Please visit %s to view and/or reply to your private messages."
+msgstr "Visita %s per vedere e/o rispondere ai tuoi messaggi privati."
-#: include/conversation.php:804 object/Item.php:345
-msgid "Filed under:"
-msgstr "Archiviato in:"
+#: include/enotify.php:145
+#, php-format
+msgid "%1$s commented on [url=%2$s]a %3$s[/url]"
+msgstr "%1$s ha commentato [url=%2$s]%3$s[/url]"
-#: include/conversation.php:811 mod/content.php:497 mod/content.php:928
-#: object/Item.php:370
+#: include/enotify.php:152
#, php-format
-msgid "%s from %s"
-msgstr "%s da %s"
+msgid "%1$s commented on [url=%2$s]%3$s's %4$s[/url]"
+msgstr "%1$s ha commentato [url=%2$s]%4$s di %3$s[/url]"
-#: include/conversation.php:827 mod/content.php:513
-msgid "View in context"
-msgstr "Vedi nel contesto"
+#: include/enotify.php:160
+#, php-format
+msgid "%1$s commented on [url=%2$s]your %3$s[/url]"
+msgstr "%1$s ha commentato un [url=%2$s]tuo %3$s[/url]"
-#: include/conversation.php:829 include/conversation.php:1298
-#: mod/content.php:515 mod/content.php:953 mod/editpost.php:114
-#: mod/wallmessage.php:140 mod/message.php:337 mod/message.php:522
-#: mod/photos.php:1627 object/Item.php:395
-msgid "Please wait"
-msgstr "Attendi"
+#: include/enotify.php:170
+#, php-format
+msgid "[Friendica:Notify] Comment to conversation #%1$d by %2$s"
+msgstr "[Friendica:Notifica] Commento di %2$s alla conversazione #%1$d"
-#: include/conversation.php:906
-msgid "remove"
-msgstr "rimuovi"
+#: include/enotify.php:172
+#, php-format
+msgid "%s commented on an item/conversation you have been following."
+msgstr "%s ha commentato un elemento che stavi seguendo."
-#: include/conversation.php:910
-msgid "Delete Selected Items"
-msgstr "Cancella elementi selezionati"
+#: include/enotify.php:175 include/enotify.php:189 include/enotify.php:203
+#: include/enotify.php:217 include/enotify.php:235 include/enotify.php:249
+#, php-format
+msgid "Please visit %s to view and/or reply to the conversation."
+msgstr "Visita %s per vedere e/o commentare la conversazione"
-#: include/conversation.php:1002
-msgid "Follow Thread"
-msgstr "Segui la discussione"
+#: include/enotify.php:182
+#, php-format
+msgid "[Friendica:Notify] %s posted to your profile wall"
+msgstr "[Friendica:Notifica] %s ha scritto sulla tua bacheca"
-#: include/conversation.php:1139
+#: include/enotify.php:184
#, php-format
-msgid "%s likes this."
-msgstr "Piace a %s."
+msgid "%1$s posted to your profile wall at %2$s"
+msgstr "%1$s ha scritto sulla tua bacheca su %2$s"
-#: include/conversation.php:1142
+#: include/enotify.php:185
#, php-format
-msgid "%s doesn't like this."
-msgstr "Non piace a %s."
+msgid "%1$s posted to [url=%2$s]your wall[/url]"
+msgstr "%1$s ha inviato un messaggio sulla [url=%2$s]tua bacheca[/url]"
-#: include/conversation.php:1145
+#: include/enotify.php:196
#, php-format
-msgid "%s attends."
-msgstr "%s partecipa."
+msgid "[Friendica:Notify] %s tagged you"
+msgstr "[Friendica:Notifica] %s ti ha taggato"
-#: include/conversation.php:1148
+#: include/enotify.php:198
#, php-format
-msgid "%s doesn't attend."
-msgstr "%s non partecipa."
+msgid "%1$s tagged you at %2$s"
+msgstr "%1$s ti ha taggato su %2$s"
-#: include/conversation.php:1151
+#: include/enotify.php:199
#, php-format
-msgid "%s attends maybe."
-msgstr "%s forse partecipa."
+msgid "%1$s [url=%2$s]tagged you[/url]."
+msgstr "%1$s [url=%2$s]ti ha taggato[/url]."
-#: include/conversation.php:1162
-msgid "and"
-msgstr "e"
+#: include/enotify.php:210
+#, php-format
+msgid "[Friendica:Notify] %s shared a new post"
+msgstr "[Friendica:Notifica] %s ha condiviso un nuovo messaggio"
-#: include/conversation.php:1168
+#: include/enotify.php:212
#, php-format
-msgid ", and %d other people"
-msgstr "e altre %d persone"
+msgid "%1$s shared a new post at %2$s"
+msgstr "%1$s ha condiviso un nuovo messaggio su %2$s"
-#: include/conversation.php:1177
+#: include/enotify.php:213
#, php-format
-msgid "<span %1$s>%2$d people</span> like this"
-msgstr "Piace a <span %1$s>%2$d persone</span>."
+msgid "%1$s [url=%2$s]shared a post[/url]."
+msgstr "%1$s [url=%2$s]ha condiviso un messaggio[/url]."
-#: include/conversation.php:1178
+#: include/enotify.php:224
#, php-format
-msgid "%s like this."
-msgstr "a %s piace."
+msgid "[Friendica:Notify] %1$s poked you"
+msgstr "[Friendica:Notifica] %1$s ti ha stuzzicato"
-#: include/conversation.php:1181
+#: include/enotify.php:226
#, php-format
-msgid "<span %1$s>%2$d people</span> don't like this"
-msgstr "Non piace a <span %1$s>%2$d persone</span>."
+msgid "%1$s poked you at %2$s"
+msgstr "%1$s ti ha stuzzicato su %2$s"
-#: include/conversation.php:1182
+#: include/enotify.php:227
#, php-format
-msgid "%s don't like this."
-msgstr "a %s non piace."
+msgid "%1$s [url=%2$s]poked you[/url]."
+msgstr "%1$s [url=%2$s]ti ha stuzzicato[/url]."
-#: include/conversation.php:1185
+#: include/enotify.php:242
#, php-format
-msgid "<span %1$s>%2$d people</span> attend"
-msgstr "<span %1$s>%2$d persone</span> partecipano"
+msgid "[Friendica:Notify] %s tagged your post"
+msgstr "[Friendica:Notifica] %s ha taggato un tuo messaggio"
-#: include/conversation.php:1186
+#: include/enotify.php:244
#, php-format
-msgid "%s attend."
-msgstr "%s partecipa."
+msgid "%1$s tagged your post at %2$s"
+msgstr "%1$s ha taggato il tuo post su %2$s"
-#: include/conversation.php:1189
+#: include/enotify.php:245
#, php-format
-msgid "<span %1$s>%2$d people</span> don't attend"
-msgstr "<span %1$s>%2$d persone</span> non partecipano"
+msgid "%1$s tagged [url=%2$s]your post[/url]"
+msgstr "%1$s ha taggato [url=%2$s]il tuo post[/url]"
+
+#: include/enotify.php:256
+msgid "[Friendica:Notify] Introduction received"
+msgstr "[Friendica:Notifica] Hai ricevuto una presentazione"
-#: include/conversation.php:1190
+#: include/enotify.php:258
#, php-format
-msgid "%s don't attend."
-msgstr "%s non partecipa."
+msgid "You've received an introduction from '%1$s' at %2$s"
+msgstr "Hai ricevuto un'introduzione da '%1$s' su %2$s"
-#: include/conversation.php:1193
+#: include/enotify.php:259
#, php-format
-msgid "<span %1$s>%2$d people</span> attend maybe"
-msgstr "<span %1$s>%2$d persone</span> forse partecipano"
+msgid "You've received [url=%1$s]an introduction[/url] from %2$s."
+msgstr "Hai ricevuto [url=%1$s]un'introduzione[/url] da %2$s."
-#: include/conversation.php:1194
+#: include/enotify.php:263 include/enotify.php:306
#, php-format
-msgid "%s anttend maybe."
-msgstr "%s forse partecipano."
+msgid "You may visit their profile at %s"
+msgstr "Puoi visitare il suo profilo presso %s"
-#: include/conversation.php:1223 include/conversation.php:1239
-msgid "Visible to <strong>everybody</strong>"
-msgstr "Visibile a <strong>tutti</strong>"
+#: include/enotify.php:265
+#, php-format
+msgid "Please visit %s to approve or reject the introduction."
+msgstr "Visita %s per approvare o rifiutare la presentazione."
-#: include/conversation.php:1224 include/conversation.php:1240
-#: mod/wallmessage.php:114 mod/wallmessage.php:121 mod/message.php:271
-#: mod/message.php:278 mod/message.php:418 mod/message.php:425
-msgid "Please enter a link URL:"
-msgstr "Inserisci l'indirizzo del link:"
+#: include/enotify.php:273
+msgid "[Friendica:Notify] A new person is sharing with you"
+msgstr "[Friendica:Notifica] Una nuova persona sta condividendo con te"
-#: include/conversation.php:1225 include/conversation.php:1241
-msgid "Please enter a video link/URL:"
-msgstr "Inserisci un collegamento video / URL:"
+#: include/enotify.php:275 include/enotify.php:276
+#, php-format
+msgid "%1$s is sharing with you at %2$s"
+msgstr "%1$s sta condividendo con te su %2$s"
-#: include/conversation.php:1226 include/conversation.php:1242
-msgid "Please enter an audio link/URL:"
-msgstr "Inserisci un collegamento audio / URL:"
+#: include/enotify.php:282
+msgid "[Friendica:Notify] You have a new follower"
+msgstr "[Friendica:Notifica] Una nuova persona ti segue"
-#: include/conversation.php:1227 include/conversation.php:1243
-msgid "Tag term:"
-msgstr "Tag:"
+#: include/enotify.php:284 include/enotify.php:285
+#, php-format
+msgid "You have a new follower at %2$s : %1$s"
+msgstr "Un nuovo utente ha iniziato a seguirti su %2$s : %1$s"
-#: include/conversation.php:1228 include/conversation.php:1244
-#: mod/filer.php:30
-msgid "Save to Folder:"
-msgstr "Salva nella Cartella:"
+#: include/enotify.php:296
+msgid "[Friendica:Notify] Friend suggestion received"
+msgstr "[Friendica:Notifica] Hai ricevuto un suggerimento di amicizia"
-#: include/conversation.php:1229 include/conversation.php:1245
-msgid "Where are you right now?"
-msgstr "Dove sei ora?"
+#: include/enotify.php:298
+#, php-format
+msgid "You've received a friend suggestion from '%1$s' at %2$s"
+msgstr "Hai ricevuto un suggerimento di amicizia da '%1$s' su %2$s"
-#: include/conversation.php:1230
-msgid "Delete item(s)?"
-msgstr "Cancellare questo elemento/i?"
+#: include/enotify.php:299
+#, php-format
+msgid ""
+"You've received [url=%1$s]a friend suggestion[/url] for %2$s from %3$s."
+msgstr "Hai ricevuto [url=%1$s]un suggerimento di amicizia[/url] per %2$s su %3$s"
-#: include/conversation.php:1279
-msgid "Share"
-msgstr "Condividi"
+#: include/enotify.php:304
+msgid "Name:"
+msgstr "Nome:"
-#: include/conversation.php:1280 mod/editpost.php:100 mod/wallmessage.php:138
-#: mod/message.php:335 mod/message.php:519
-msgid "Upload photo"
-msgstr "Carica foto"
+#: include/enotify.php:305
+msgid "Photo:"
+msgstr "Foto:"
-#: include/conversation.php:1281 mod/editpost.php:101
-msgid "upload photo"
-msgstr "carica foto"
+#: include/enotify.php:308
+#, php-format
+msgid "Please visit %s to approve or reject the suggestion."
+msgstr "Visita %s per approvare o rifiutare il suggerimento."
-#: include/conversation.php:1282 mod/editpost.php:102
-msgid "Attach file"
-msgstr "Allega file"
+#: include/enotify.php:316 include/enotify.php:330
+msgid "[Friendica:Notify] Connection accepted"
+msgstr "[Friendica:Notifica] Connessione accettata"
-#: include/conversation.php:1283 mod/editpost.php:103
-msgid "attach file"
-msgstr "allega file"
+#: include/enotify.php:318 include/enotify.php:332
+#, php-format
+msgid "'%1$s' has accepted your connection request at %2$s"
+msgstr "'%1$s' ha accettato la tua richiesta di connessione su %2$s"
-#: include/conversation.php:1284 mod/editpost.php:104 mod/wallmessage.php:139
-#: mod/message.php:336 mod/message.php:520
-msgid "Insert web link"
-msgstr "Inserisci link"
+#: include/enotify.php:319 include/enotify.php:333
+#, php-format
+msgid "%2$s has accepted your [url=%1$s]connection request[/url]."
+msgstr "%2$s ha accettato la tua [url=%1$s]richiesta di connessione[/url]"
-#: include/conversation.php:1285 mod/editpost.php:105
-msgid "web link"
-msgstr "link web"
+#: include/enotify.php:323
+msgid ""
+"You are now mutual friends and may exchange status updates, photos, and "
+"email without restriction."
+msgstr "Ora siete amici reciproci e potete scambiarvi aggiornamenti di stato, foto e messaggi privati senza restrizioni."
-#: include/conversation.php:1286 mod/editpost.php:106
-msgid "Insert video link"
-msgstr "Inserire collegamento video"
+#: include/enotify.php:325
+#, php-format
+msgid "Please visit %s if you wish to make any changes to this relationship."
+msgstr "Visita %s se vuoi modificare questa relazione."
-#: include/conversation.php:1287 mod/editpost.php:107
-msgid "video link"
-msgstr "link video"
+#: include/enotify.php:337
+#, php-format
+msgid ""
+"'%1$s' has chosen to accept you a \"fan\", which restricts some forms of "
+"communication - such as private messaging and some profile interactions. If "
+"this is a celebrity or community page, these settings were applied "
+"automatically."
+msgstr "'%1$s' ha scelto di accettarti come \"fan\", il che limita alcune forme di comunicazione, come i messaggi privati, e alcune possibilità di interazione col profilo. Se è una pagina di una comunità o di una celebrità, queste impostazioni sono state applicate automaticamente."
-#: include/conversation.php:1288 mod/editpost.php:108
-msgid "Insert audio link"
-msgstr "Inserisci collegamento audio"
+#: include/enotify.php:339
+#, php-format
+msgid ""
+"'%1$s' may choose to extend this into a two-way or more permissive "
+"relationship in the future."
+msgstr "'%1$s' può scegliere di estendere questa relazione in una relazione più permissiva in futuro."
-#: include/conversation.php:1289 mod/editpost.php:109
-msgid "audio link"
-msgstr "link audio"
-
-#: include/conversation.php:1290 mod/editpost.php:110
-msgid "Set your location"
-msgstr "La tua posizione"
+#: include/enotify.php:341
+#, php-format
+msgid "Please visit %s if you wish to make any changes to this relationship."
+msgstr "Visita %s se desideri modificare questo collegamento."
-#: include/conversation.php:1291 mod/editpost.php:111
-msgid "set location"
-msgstr "posizione"
+#: include/enotify.php:351
+msgid "[Friendica System:Notify] registration request"
+msgstr "[Friendica System:Notifica] richiesta di registrazione"
-#: include/conversation.php:1292 mod/editpost.php:112
-msgid "Clear browser location"
-msgstr "Rimuovi la localizzazione data dal browser"
+#: include/enotify.php:353
+#, php-format
+msgid "You've received a registration request from '%1$s' at %2$s"
+msgstr "Hai ricevuto una richiesta di registrazione da '%1$s' su %2$s"
-#: include/conversation.php:1293 mod/editpost.php:113
-msgid "clear location"
-msgstr "canc. pos."
+#: include/enotify.php:354
+#, php-format
+msgid "You've received a [url=%1$s]registration request[/url] from %2$s."
+msgstr "Hai ricevuto una [url=%1$s]richiesta di registrazione[/url] da %2$s."
-#: include/conversation.php:1295 mod/editpost.php:127
-msgid "Set title"
-msgstr "Scegli un titolo"
+#: include/enotify.php:358
+#, php-format
+msgid "Full Name:\t%1$s\\nSite Location:\t%2$s\\nLogin Name:\t%3$s (%4$s)"
+msgstr "Nome completo: %1$s\nIndirizzo del sito: %2$s\nNome utente: %3$s (%4$s)"
-#: include/conversation.php:1297 mod/editpost.php:129
-msgid "Categories (comma-separated list)"
-msgstr "Categorie (lista separata da virgola)"
+#: include/enotify.php:361
+#, php-format
+msgid "Please visit %s to approve or reject the request."
+msgstr "Visita %s per approvare o rifiutare la richiesta."
-#: include/conversation.php:1299 mod/editpost.php:115
-msgid "Permission settings"
-msgstr "Impostazioni permessi"
+#: include/oembed.php:254
+msgid "Embedded content"
+msgstr "Contenuto incorporato"
-#: include/conversation.php:1300 mod/editpost.php:144
-msgid "permissions"
-msgstr "permessi"
+#: include/oembed.php:262
+msgid "Embedding disabled"
+msgstr "Embed disabilitato"
-#: include/conversation.php:1308 mod/editpost.php:124
-msgid "Public post"
-msgstr "Messaggio pubblico"
+#: include/security.php:64
+msgid "Welcome "
+msgstr "Ciao"
-#: include/conversation.php:1313 mod/content.php:737 mod/editpost.php:135
-#: mod/events.php:503 mod/photos.php:1647 mod/photos.php:1689
-#: mod/photos.php:1769 object/Item.php:714
-msgid "Preview"
-msgstr "Anteprima"
+#: include/security.php:65
+msgid "Please upload a profile photo."
+msgstr "Carica una foto per il profilo."
-#: include/conversation.php:1317 include/items.php:2167 mod/contacts.php:455
-#: mod/editpost.php:138 mod/fbrowser.php:100 mod/fbrowser.php:135
-#: mod/suggest.php:32 mod/tagrm.php:11 mod/tagrm.php:96
-#: mod/dfrn_request.php:894 mod/follow.php:124 mod/message.php:209
-#: mod/photos.php:245 mod/photos.php:337 mod/settings.php:682
-#: mod/settings.php:708 mod/videos.php:132
-msgid "Cancel"
-msgstr "Annulla"
+#: include/security.php:67
+msgid "Welcome back "
+msgstr "Ciao "
-#: include/conversation.php:1323
-msgid "Post to Groups"
-msgstr "Invia ai Gruppi"
+#: include/security.php:424
+msgid ""
+"The form security token was not correct. This probably happened because the "
+"form has been opened for too long (>3 hours) before submitting it."
+msgstr "Il token di sicurezza della form non era corretto. Probabilmente la form è rimasta aperta troppo a lungo (più di tre ore) prima di inviarla."
-#: include/conversation.php:1324
-msgid "Post to Contacts"
-msgstr "Invia ai Contatti"
+#: include/photos.php:57 include/photos.php:66 mod/fbrowser.php:43
+#: mod/fbrowser.php:65 mod/photos.php:191 mod/photos.php:1109
+#: mod/photos.php:1233 mod/photos.php:1254 mod/photos.php:1816
+#: mod/photos.php:1830
+msgid "Contact Photos"
+msgstr "Foto dei contatti"
-#: include/conversation.php:1325
-msgid "Private post"
-msgstr "Post privato"
+#: include/nav.php:38 mod/navigation.php:22
+msgid "Nothing new here"
+msgstr "Niente di nuovo qui"
-#: include/conversation.php:1330 include/identity.php:264 mod/editpost.php:142
-msgid "Message"
-msgstr "Messaggio"
+#: include/nav.php:42 mod/navigation.php:26
+msgid "Clear notifications"
+msgstr "Pulisci le notifiche"
-#: include/conversation.php:1331 mod/editpost.php:143
-msgid "Browser"
-msgstr "Browser"
+#: include/nav.php:43 include/text.php:1090
+msgid "@name, !forum, #tags, content"
+msgstr "@nome, !forum, #tag, contenuto"
-#: include/conversation.php:1513
-msgid "View all"
-msgstr "Mostra tutto"
+#: include/nav.php:81 view/theme/frio/theme.php:250 boot.php:874
+msgid "Logout"
+msgstr "Esci"
-#: include/conversation.php:1535
-msgid "Like"
-msgid_plural "Likes"
-msgstr[0] "Mi piace"
-msgstr[1] "Mi piace"
+#: include/nav.php:81 view/theme/frio/theme.php:250
+msgid "End this session"
+msgstr "Finisci questa sessione"
-#: include/conversation.php:1538
-msgid "Dislike"
-msgid_plural "Dislikes"
-msgstr[0] "Non mi piace"
-msgstr[1] "Non mi piace"
+#: include/nav.php:84 include/identity.php:785 mod/contacts.php:667
+#: mod/contacts.php:863 view/theme/frio/theme.php:253
+msgid "Status"
+msgstr "Stato"
-#: include/conversation.php:1544
-msgid "Not Attending"
-msgid_plural "Not Attending"
-msgstr[0] "Non partecipa"
-msgstr[1] "Non partecipano"
+#: include/nav.php:84 include/nav.php:164 view/theme/frio/theme.php:253
+msgid "Your posts and conversations"
+msgstr "I tuoi messaggi e le tue conversazioni"
-#: include/datetime.php:66 include/datetime.php:68 mod/profiles.php:698
-msgid "Miscellaneous"
-msgstr "Varie"
+#: include/nav.php:85 include/identity.php:631 include/identity.php:760
+#: include/identity.php:793 mod/newmember.php:20 mod/profperm.php:107
+#: mod/contacts.php:669 mod/contacts.php:871 view/theme/frio/theme.php:254
+msgid "Profile"
+msgstr "Profilo"
-#: include/datetime.php:196 include/identity.php:644
-msgid "Birthday:"
-msgstr "Compleanno:"
+#: include/nav.php:85 view/theme/frio/theme.php:254
+msgid "Your profile page"
+msgstr "Pagina del tuo profilo"
-#: include/datetime.php:198 mod/profiles.php:721
-msgid "Age: "
-msgstr "Età : "
+#: include/nav.php:86 include/identity.php:801 mod/fbrowser.php:34
+#: view/theme/frio/theme.php:255
+msgid "Photos"
+msgstr "Foto"
-#: include/datetime.php:200
-msgid "YYYY-MM-DD or MM-DD"
-msgstr "AAAA-MM-GG o MM-GG"
+#: include/nav.php:86 view/theme/frio/theme.php:255
+msgid "Your photos"
+msgstr "Le tue foto"
-#: include/datetime.php:370
-msgid "never"
-msgstr "mai"
+#: include/nav.php:87 include/identity.php:809 include/identity.php:812
+#: view/theme/frio/theme.php:256
+msgid "Videos"
+msgstr "Video"
-#: include/datetime.php:376
-msgid "less than a second ago"
-msgstr "meno di un secondo fa"
+#: include/nav.php:87 view/theme/frio/theme.php:256
+msgid "Your videos"
+msgstr "I tuoi video"
-#: include/datetime.php:379
-msgid "year"
-msgstr "anno"
+#: include/nav.php:88 include/nav.php:152 include/identity.php:821
+#: include/identity.php:832 mod/cal.php:273 mod/events.php:383
+#: view/theme/frio/theme.php:257 view/theme/frio/theme.php:261
+msgid "Events"
+msgstr "Eventi"
-#: include/datetime.php:379
-msgid "years"
-msgstr "anni"
+#: include/nav.php:88 view/theme/frio/theme.php:257
+msgid "Your events"
+msgstr "I tuoi eventi"
-#: include/datetime.php:380 include/event.php:519 mod/cal.php:279
-#: mod/events.php:384
-msgid "month"
-msgstr "mese"
+#: include/nav.php:89
+msgid "Personal notes"
+msgstr "Note personali"
-#: include/datetime.php:380
-msgid "months"
-msgstr "mesi"
+#: include/nav.php:89
+msgid "Your personal notes"
+msgstr "Le tue note personali"
-#: include/datetime.php:381 include/event.php:520 mod/cal.php:280
-#: mod/events.php:385
-msgid "week"
-msgstr "settimana"
+#: include/nav.php:98 mod/bookmarklet.php:15 boot.php:875
+msgid "Login"
+msgstr "Accedi"
-#: include/datetime.php:381
-msgid "weeks"
-msgstr "settimane"
+#: include/nav.php:98
+msgid "Sign in"
+msgstr "Entra"
-#: include/datetime.php:382 include/event.php:521 mod/cal.php:281
-#: mod/events.php:386
-msgid "day"
-msgstr "giorno"
+#: include/nav.php:108
+msgid "Home Page"
+msgstr "Home Page"
-#: include/datetime.php:382
-msgid "days"
-msgstr "giorni"
+#: include/nav.php:112 mod/register.php:294 boot.php:851
+msgid "Register"
+msgstr "Registrati"
-#: include/datetime.php:383
-msgid "hour"
-msgstr "ora"
+#: include/nav.php:112
+msgid "Create an account"
+msgstr "Crea un account"
-#: include/datetime.php:383
-msgid "hours"
-msgstr "ore"
+#: include/nav.php:118 mod/help.php:51 view/theme/vier/theme.php:292
+msgid "Help"
+msgstr "Guida"
-#: include/datetime.php:384
-msgid "minute"
-msgstr "minuto"
+#: include/nav.php:118
+msgid "Help and documentation"
+msgstr "Guida e documentazione"
-#: include/datetime.php:384
-msgid "minutes"
-msgstr "minuti"
+#: include/nav.php:122
+msgid "Apps"
+msgstr "Applicazioni"
-#: include/datetime.php:385
-msgid "second"
-msgstr "secondo"
+#: include/nav.php:122
+msgid "Addon applications, utilities, games"
+msgstr "Applicazioni, utilità e giochi aggiuntivi"
-#: include/datetime.php:385
-msgid "seconds"
-msgstr "secondi"
+#: include/nav.php:126 include/text.php:1087 mod/search.php:145
+msgid "Search"
+msgstr "Cerca"
-#: include/datetime.php:394
-#, php-format
-msgid "%1$d %2$s ago"
-msgstr "%1$d %2$s fa"
+#: include/nav.php:126
+msgid "Search site content"
+msgstr "Cerca nel contenuto del sito"
-#: include/datetime.php:620
-#, php-format
-msgid "%s's birthday"
-msgstr "Compleanno di %s"
+#: include/nav.php:129 include/text.php:1095
+msgid "Full Text"
+msgstr "Testo Completo"
-#: include/datetime.php:621 include/dfrn.php:1252
-#, php-format
-msgid "Happy Birthday %s"
-msgstr "Buon compleanno %s"
+#: include/nav.php:130 include/text.php:1096
+msgid "Tags"
+msgstr "Tags:"
-#: include/dba_pdo.php:72 include/dba.php:47
-#, php-format
-msgid "Cannot locate DNS info for database server '%s'"
-msgstr "Non trovo le informazioni DNS per il database server '%s'"
+#: include/nav.php:131 include/nav.php:195 include/identity.php:854
+#: include/identity.php:857 include/text.php:1097 mod/viewcontacts.php:124
+#: mod/contacts.php:822 mod/contacts.php:883 view/theme/frio/theme.php:264
+msgid "Contacts"
+msgstr "Contatti"
-#: include/enotify.php:24
-msgid "Friendica Notification"
-msgstr "Notifica Friendica"
+#: include/nav.php:146 include/nav.php:148 mod/community.php:31
+msgid "Community"
+msgstr "Comunità"
-#: include/enotify.php:27
-msgid "Thank You,"
-msgstr "Grazie,"
+#: include/nav.php:146
+msgid "Conversations on this site"
+msgstr "Conversazioni su questo sito"
-#: include/enotify.php:30
-#, php-format
-msgid "%s Administrator"
-msgstr "Amministratore %s"
+#: include/nav.php:148
+msgid "Conversations on the network"
+msgstr "Conversazioni nella rete"
-#: include/enotify.php:32
-#, php-format
-msgid "%1$s, %2$s Administrator"
-msgstr "%1$s, amministratore di %2$s"
+#: include/nav.php:152 include/identity.php:824 include/identity.php:835
+#: view/theme/frio/theme.php:261
+msgid "Events and Calendar"
+msgstr "Eventi e calendario"
-#: include/enotify.php:70
-#, php-format
-msgid "%s <!item_type!>"
-msgstr "%s <!item_type!>"
+#: include/nav.php:155
+msgid "Directory"
+msgstr "Elenco"
-#: include/enotify.php:83
-#, php-format
-msgid "[Friendica:Notify] New mail received at %s"
-msgstr "[Friendica:Notifica] Nuovo messaggio privato ricevuto su %s"
+#: include/nav.php:155
+msgid "People directory"
+msgstr "Elenco delle persone"
-#: include/enotify.php:85
-#, php-format
-msgid "%1$s sent you a new private message at %2$s."
-msgstr "%1$s ti ha inviato un nuovo messaggio privato su %2$s."
+#: include/nav.php:157
+msgid "Information"
+msgstr "Informazioni"
-#: include/enotify.php:86
-#, php-format
-msgid "%1$s sent you %2$s."
-msgstr "%1$s ti ha inviato %2$s"
+#: include/nav.php:157
+msgid "Information about this friendica instance"
+msgstr "Informazioni su questo server friendica"
-#: include/enotify.php:86
-msgid "a private message"
-msgstr "un messaggio privato"
+#: include/nav.php:161 view/theme/frio/theme.php:260
+msgid "Conversations from your friends"
+msgstr "Conversazioni dai tuoi amici"
-#: include/enotify.php:88
-#, php-format
-msgid "Please visit %s to view and/or reply to your private messages."
-msgstr "Visita %s per vedere e/o rispondere ai tuoi messaggi privati."
+#: include/nav.php:162
+msgid "Network Reset"
+msgstr "Reset pagina Rete"
-#: include/enotify.php:134
-#, php-format
-msgid "%1$s commented on [url=%2$s]a %3$s[/url]"
-msgstr "%1$s ha commentato [url=%2$s]%3$s[/url]"
+#: include/nav.php:162
+msgid "Load Network page with no filters"
+msgstr "Carica la pagina Rete senza nessun filtro"
-#: include/enotify.php:141
-#, php-format
-msgid "%1$s commented on [url=%2$s]%3$s's %4$s[/url]"
-msgstr "%1$s ha commentato [url=%2$s]%4$s di %3$s[/url]"
+#: include/nav.php:169
+msgid "Friend Requests"
+msgstr "Richieste di amicizia"
-#: include/enotify.php:149
-#, php-format
-msgid "%1$s commented on [url=%2$s]your %3$s[/url]"
-msgstr "%1$s ha commentato un [url=%2$s]tuo %3$s[/url]"
+#: include/nav.php:172 mod/notifications.php:99
+msgid "Notifications"
+msgstr "Notifiche"
-#: include/enotify.php:159
-#, php-format
-msgid "[Friendica:Notify] Comment to conversation #%1$d by %2$s"
-msgstr "[Friendica:Notifica] Commento di %2$s alla conversazione #%1$d"
+#: include/nav.php:173
+msgid "See all notifications"
+msgstr "Vedi tutte le notifiche"
-#: include/enotify.php:161
-#, php-format
-msgid "%s commented on an item/conversation you have been following."
-msgstr "%s ha commentato un elemento che stavi seguendo."
+#: include/nav.php:174 mod/settings.php:911
+msgid "Mark as seen"
+msgstr "Segna come letto"
-#: include/enotify.php:164 include/enotify.php:178 include/enotify.php:192
-#: include/enotify.php:206 include/enotify.php:224 include/enotify.php:238
-#, php-format
-msgid "Please visit %s to view and/or reply to the conversation."
-msgstr "Visita %s per vedere e/o commentare la conversazione"
+#: include/nav.php:174
+msgid "Mark all system notifications seen"
+msgstr "Segna tutte le notifiche come viste"
-#: include/enotify.php:171
-#, php-format
-msgid "[Friendica:Notify] %s posted to your profile wall"
-msgstr "[Friendica:Notifica] %s ha scritto sulla tua bacheca"
+#: include/nav.php:178 mod/message.php:180 view/theme/frio/theme.php:262
+msgid "Messages"
+msgstr "Messaggi"
-#: include/enotify.php:173
-#, php-format
-msgid "%1$s posted to your profile wall at %2$s"
-msgstr "%1$s ha scritto sulla tua bacheca su %2$s"
+#: include/nav.php:178 view/theme/frio/theme.php:262
+msgid "Private mail"
+msgstr "Posta privata"
-#: include/enotify.php:174
-#, php-format
-msgid "%1$s posted to [url=%2$s]your wall[/url]"
-msgstr "%1$s ha inviato un messaggio sulla [url=%2$s]tua bacheca[/url]"
+#: include/nav.php:179
+msgid "Inbox"
+msgstr "In arrivo"
-#: include/enotify.php:185
-#, php-format
-msgid "[Friendica:Notify] %s tagged you"
-msgstr "[Friendica:Notifica] %s ti ha taggato"
+#: include/nav.php:180
+msgid "Outbox"
+msgstr "Inviati"
-#: include/enotify.php:187
-#, php-format
-msgid "%1$s tagged you at %2$s"
-msgstr "%1$s ti ha taggato su %2$s"
+#: include/nav.php:181 mod/message.php:19
+msgid "New Message"
+msgstr "Nuovo messaggio"
-#: include/enotify.php:188
-#, php-format
-msgid "%1$s [url=%2$s]tagged you[/url]."
-msgstr "%1$s [url=%2$s]ti ha taggato[/url]."
+#: include/nav.php:184
+msgid "Manage"
+msgstr "Gestisci"
-#: include/enotify.php:199
-#, php-format
-msgid "[Friendica:Notify] %s shared a new post"
-msgstr "[Friendica:Notifica] %s ha condiviso un nuovo messaggio"
+#: include/nav.php:184
+msgid "Manage other pages"
+msgstr "Gestisci altre pagine"
-#: include/enotify.php:201
-#, php-format
-msgid "%1$s shared a new post at %2$s"
-msgstr "%1$s ha condiviso un nuovo messaggio su %2$s"
+#: include/nav.php:187 mod/settings.php:81
+msgid "Delegations"
+msgstr "Delegazioni"
-#: include/enotify.php:202
-#, php-format
-msgid "%1$s [url=%2$s]shared a post[/url]."
-msgstr "%1$s [url=%2$s]ha condiviso un messaggio[/url]."
+#: include/nav.php:187 mod/delegate.php:130
+msgid "Delegate Page Management"
+msgstr "Gestione delegati per la pagina"
-#: include/enotify.php:213
-#, php-format
-msgid "[Friendica:Notify] %1$s poked you"
-msgstr "[Friendica:Notifica] %1$s ti ha stuzzicato"
+#: include/nav.php:189 mod/newmember.php:15 mod/admin.php:1740
+#: mod/admin.php:2016 mod/settings.php:111 view/theme/frio/theme.php:263
+msgid "Settings"
+msgstr "Impostazioni"
-#: include/enotify.php:215
-#, php-format
-msgid "%1$s poked you at %2$s"
-msgstr "%1$s ti ha stuzzicato su %2$s"
+#: include/nav.php:189 view/theme/frio/theme.php:263
+msgid "Account settings"
+msgstr "Parametri account"
-#: include/enotify.php:216
-#, php-format
-msgid "%1$s [url=%2$s]poked you[/url]."
-msgstr "%1$s [url=%2$s]ti ha stuzzicato[/url]."
+#: include/nav.php:192 include/identity.php:294
+msgid "Profiles"
+msgstr "Profili"
-#: include/enotify.php:231
-#, php-format
-msgid "[Friendica:Notify] %s tagged your post"
-msgstr "[Friendica:Notifica] %s ha taggato un tuo messaggio"
+#: include/nav.php:192
+msgid "Manage/Edit Profiles"
+msgstr "Gestisci/Modifica i profili"
-#: include/enotify.php:233
-#, php-format
-msgid "%1$s tagged your post at %2$s"
-msgstr "%1$s ha taggato il tuo post su %2$s"
+#: include/nav.php:195 view/theme/frio/theme.php:264
+msgid "Manage/edit friends and contacts"
+msgstr "Gestisci/modifica amici e contatti"
-#: include/enotify.php:234
-#, php-format
-msgid "%1$s tagged [url=%2$s]your post[/url]"
-msgstr "%1$s ha taggato [url=%2$s]il tuo post[/url]"
+#: include/nav.php:200 mod/admin.php:204
+msgid "Admin"
+msgstr "Amministrazione"
-#: include/enotify.php:245
-msgid "[Friendica:Notify] Introduction received"
-msgstr "[Friendica:Notifica] Hai ricevuto una presentazione"
+#: include/nav.php:200
+msgid "Site setup and configuration"
+msgstr "Configurazione del sito"
-#: include/enotify.php:247
-#, php-format
-msgid "You've received an introduction from '%1$s' at %2$s"
-msgstr "Hai ricevuto un'introduzione da '%1$s' su %2$s"
+#: include/nav.php:203
+msgid "Navigation"
+msgstr "Navigazione"
-#: include/enotify.php:248
-#, php-format
-msgid "You've received [url=%1$s]an introduction[/url] from %2$s."
-msgstr "Hai ricevuto [url=%1$s]un'introduzione[/url] da %2$s."
+#: include/nav.php:203
+msgid "Site map"
+msgstr "Mappa del sito"
-#: include/enotify.php:252 include/enotify.php:295
-#, php-format
-msgid "You may visit their profile at %s"
-msgstr "Puoi visitare il suo profilo presso %s"
+#: include/Contact.php:397 include/Contact.php:410 include/Contact.php:455
+#: include/conversation.php:1022 include/conversation.php:1038
+#: mod/allfriends.php:71 mod/match.php:77 mod/suggest.php:82
+#: mod/directory.php:151 mod/dirfind.php:213
+msgid "View Profile"
+msgstr "Visualizza profilo"
-#: include/enotify.php:254
-#, php-format
-msgid "Please visit %s to approve or reject the introduction."
-msgstr "Visita %s per approvare o rifiutare la presentazione."
+#: include/Contact.php:454 include/conversation.php:1021
+msgid "View Status"
+msgstr "Visualizza stato"
-#: include/enotify.php:262
-msgid "[Friendica:Notify] A new person is sharing with you"
-msgstr "[Friendica:Notifica] Una nuova persona sta condividendo con te"
+#: include/Contact.php:456 include/conversation.php:1023
+msgid "View Photos"
+msgstr "Visualizza foto"
-#: include/enotify.php:264 include/enotify.php:265
-#, php-format
-msgid "%1$s is sharing with you at %2$s"
-msgstr "%1$s sta condividendo con te su %2$s"
+#: include/Contact.php:457 include/conversation.php:1024
+msgid "Network Posts"
+msgstr "Post della Rete"
-#: include/enotify.php:271
-msgid "[Friendica:Notify] You have a new follower"
-msgstr "[Friendica:Notifica] Una nuova persona ti segue"
+#: include/Contact.php:458 include/conversation.php:1025
+msgid "View Contact"
+msgstr "Mostra contatto"
-#: include/enotify.php:273 include/enotify.php:274
-#, php-format
-msgid "You have a new follower at %2$s : %1$s"
-msgstr "Un nuovo utente ha iniziato a seguirti su %2$s : %1$s"
+#: include/Contact.php:459
+msgid "Drop Contact"
+msgstr "Rimuovi contatto"
-#: include/enotify.php:285
-msgid "[Friendica:Notify] Friend suggestion received"
-msgstr "[Friendica:Notifica] Hai ricevuto un suggerimento di amicizia"
+#: include/Contact.php:460 include/conversation.php:1026
+msgid "Send PM"
+msgstr "Invia messaggio privato"
-#: include/enotify.php:287
-#, php-format
-msgid "You've received a friend suggestion from '%1$s' at %2$s"
-msgstr "Hai ricevuto un suggerimento di amicizia da '%1$s' su %2$s"
+#: include/Contact.php:461 include/conversation.php:1030
+msgid "Poke"
+msgstr "Stuzzica"
-#: include/enotify.php:288
-#, php-format
-msgid ""
-"You've received [url=%1$s]a friend suggestion[/url] for %2$s from %3$s."
-msgstr "Hai ricevuto [url=%1$s]un suggerimento di amicizia[/url] per %2$s su %3$s"
+#: include/Contact.php:884
+msgid "Organisation"
+msgstr "Organizzazione"
-#: include/enotify.php:293
-msgid "Name:"
-msgstr "Nome:"
+#: include/Contact.php:887
+msgid "News"
+msgstr "Notizie"
-#: include/enotify.php:294
-msgid "Photo:"
-msgstr "Foto:"
+#: include/Contact.php:890
+msgid "Forum"
+msgstr "Forum"
-#: include/enotify.php:297
-#, php-format
-msgid "Please visit %s to approve or reject the suggestion."
-msgstr "Visita %s per approvare o rifiutare il suggerimento."
+#: include/Photo.php:995 include/Photo.php:1011 include/Photo.php:1019
+#: include/Photo.php:1044 include/message.php:139 mod/item.php:470
+#: mod/wall_upload.php:227
+msgid "Wall Photos"
+msgstr "Foto della bacheca"
-#: include/enotify.php:305 include/enotify.php:319
-msgid "[Friendica:Notify] Connection accepted"
-msgstr "[Friendica:Notifica] Connessione accettata"
+#: include/acl_selectors.php:355
+msgid "Post to Email"
+msgstr "Invia a email"
-#: include/enotify.php:307 include/enotify.php:321
+#: include/acl_selectors.php:360
#, php-format
-msgid "'%1$s' has accepted your connection request at %2$s"
-msgstr "'%1$s' ha accettato la tua richiesta di connessione su %2$s"
+msgid "Connectors disabled, since \"%s\" is enabled."
+msgstr "Connettore disabilitato, dato che \"%s\" è abilitato."
-#: include/enotify.php:308 include/enotify.php:322
-#, php-format
-msgid "%2$s has accepted your [url=%1$s]connection request[/url]."
-msgstr "%2$s ha accettato la tua [url=%1$s]richiesta di connessione[/url]"
+#: include/acl_selectors.php:361 mod/settings.php:1175
+msgid "Hide your profile details from unknown viewers?"
+msgstr "Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?"
-#: include/enotify.php:312
-msgid ""
-"You are now mutual friends and may exchange status updates, photos, and "
-"email without restriction."
-msgstr "Ora siete amici reciproci e potete scambiarvi aggiornamenti di stato, foto e messaggi privati senza restrizioni."
+#: include/acl_selectors.php:367
+msgid "Visible to everybody"
+msgstr "Visibile a tutti"
-#: include/enotify.php:314
-#, php-format
-msgid "Please visit %s if you wish to make any changes to this relationship."
-msgstr "Visita %s se vuoi modificare questa relazione."
+#: include/acl_selectors.php:368 view/theme/vier/config.php:110
+msgid "show"
+msgstr "mostra"
-#: include/enotify.php:326
-#, php-format
-msgid ""
-"'%1$s' has chosen to accept you a \"fan\", which restricts some forms of "
-"communication - such as private messaging and some profile interactions. If "
-"this is a celebrity or community page, these settings were applied "
-"automatically."
-msgstr "'%1$s' ha scelto di accettarti come \"fan\", il che limita alcune forme di comunicazione, come i messaggi privati, e alcune possibilità di interazione col profilo. Se è una pagina di una comunità o di una celebrità, queste impostazioni sono state applicate automaticamente."
+#: include/acl_selectors.php:369 view/theme/vier/config.php:110
+msgid "don't show"
+msgstr "non mostrare"
-#: include/enotify.php:328
-#, php-format
-msgid ""
-"'%1$s' may choose to extend this into a two-way or more permissive "
-"relationship in the future."
-msgstr "'%1$s' può scegliere di estendere questa relazione in una relazione più permissiva in futuro."
+#: include/acl_selectors.php:375 mod/editpost.php:126
+msgid "CC: email addresses"
+msgstr "CC: indirizzi email"
-#: include/enotify.php:330
-#, php-format
-msgid "Please visit %s if you wish to make any changes to this relationship."
-msgstr "Visita %s se desideri modificare questo collegamento."
+#: include/acl_selectors.php:376 mod/editpost.php:133
+msgid "Example: bob@example.com, mary@example.com"
+msgstr "Esempio: bob@example.com, mary@example.com"
-#: include/enotify.php:340
-msgid "[Friendica System:Notify] registration request"
-msgstr "[Friendica System:Notifica] richiesta di registrazione"
+#: include/acl_selectors.php:378 mod/events.php:532 mod/photos.php:1173
+#: mod/photos.php:1570
+msgid "Permissions"
+msgstr "Permessi"
-#: include/enotify.php:342
-#, php-format
-msgid "You've received a registration request from '%1$s' at %2$s"
-msgstr "Hai ricevuto una richiesta di registrazione da '%1$s' su %2$s"
+#: include/acl_selectors.php:379
+msgid "Close"
+msgstr "Chiudi"
-#: include/enotify.php:343
+#: include/api.php:1104
#, php-format
-msgid "You've received a [url=%1$s]registration request[/url] from %2$s."
-msgstr "Hai ricevuto una [url=%1$s]richiesta di registrazione[/url] da %2$s."
+msgid "Daily posting limit of %d posts reached. The post was rejected."
+msgstr "Limite giornaliero di %d messaggi raggiunto. Il messaggio è stato rifiutato"
-#: include/enotify.php:347
+#: include/api.php:1125
#, php-format
-msgid "Full Name:\t%1$s\\nSite Location:\t%2$s\\nLogin Name:\t%3$s (%4$s)"
-msgstr "Nome completo: %1$s\nIndirizzo del sito: %2$s\nNome utente: %3$s (%4$s)"
+msgid "Weekly posting limit of %d posts reached. The post was rejected."
+msgstr "Limite settimanale di %d messaggi raggiunto. Il messaggio è stato rifiutato"
-#: include/enotify.php:350
+#: include/api.php:1146
#, php-format
-msgid "Please visit %s to approve or reject the request."
-msgstr "Visita %s per approvare o rifiutare la richiesta."
+msgid "Monthly posting limit of %d posts reached. The post was rejected."
+msgstr "Limite mensile di %d messaggi raggiunto. Il messaggio è stato rifiutato"
-#: include/event.php:474
-msgid "all-day"
-msgstr "tutto il giorno"
+#: include/api.php:3718 include/user.php:302 include/user.php:310
+#: include/user.php:318 mod/photos.php:75 mod/photos.php:191
+#: mod/photos.php:778 mod/photos.php:1233 mod/photos.php:1254
+#: mod/photos.php:1840 mod/profile_photo.php:76 mod/profile_photo.php:84
+#: mod/profile_photo.php:92 mod/profile_photo.php:216
+#: mod/profile_photo.php:311 mod/profile_photo.php:321
+msgid "Profile Photos"
+msgstr "Foto del profilo"
-#: include/event.php:476
-msgid "Sun"
-msgstr "Dom"
-
-#: include/event.php:477
-msgid "Mon"
-msgstr "Lun"
+#: include/bbcode.php:429 include/bbcode.php:1192 include/bbcode.php:1193
+msgid "Image/photo"
+msgstr "Immagine/foto"
-#: include/event.php:478
-msgid "Tue"
-msgstr "Mar"
+#: include/bbcode.php:545
+#, php-format
+msgid "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
+msgstr "<a href=\"%1$s\" target=\"_blank\">%2$s</a> %3$s"
-#: include/event.php:479
-msgid "Wed"
-msgstr "Mer"
+#: include/bbcode.php:1149 include/bbcode.php:1171
+msgid "$1 wrote:"
+msgstr "$1 ha scritto:"
-#: include/event.php:480
-msgid "Thu"
-msgstr "Gio"
+#: include/bbcode.php:1201 include/bbcode.php:1202
+msgid "Encrypted content"
+msgstr "Contenuto criptato"
-#: include/event.php:481
-msgid "Fri"
-msgstr "Ven"
+#: include/bbcode.php:1321
+msgid "Invalid source protocol"
+msgstr "Protocollo sorgente non valido"
-#: include/event.php:482
-msgid "Sat"
-msgstr "Sab"
+#: include/bbcode.php:1332
+msgid "Invalid link protocol"
+msgstr "Protocollo link non valido"
-#: include/event.php:484 include/text.php:1198 mod/settings.php:981
-msgid "Sunday"
-msgstr "Domenica"
+#: include/contact_selectors.php:32
+msgid "Unknown | Not categorised"
+msgstr "Sconosciuto | non categorizzato"
-#: include/event.php:485 include/text.php:1198 mod/settings.php:981
-msgid "Monday"
-msgstr "Lunedì"
+#: include/contact_selectors.php:33
+msgid "Block immediately"
+msgstr "Blocca immediatamente"
-#: include/event.php:486 include/text.php:1198
-msgid "Tuesday"
-msgstr "Martedì"
+#: include/contact_selectors.php:34
+msgid "Shady, spammer, self-marketer"
+msgstr "Losco, venditore di fumo"
-#: include/event.php:487 include/text.php:1198
-msgid "Wednesday"
-msgstr "Mercoledì"
+#: include/contact_selectors.php:35
+msgid "Known to me, but no opinion"
+msgstr "Lo conosco, ma non ho un'opinione particolare"
-#: include/event.php:488 include/text.php:1198
-msgid "Thursday"
-msgstr "Giovedì"
+#: include/contact_selectors.php:36
+msgid "OK, probably harmless"
+msgstr "E' ok, probabilmente innocuo"
-#: include/event.php:489 include/text.php:1198
-msgid "Friday"
-msgstr "Venerdì"
+#: include/contact_selectors.php:37
+msgid "Reputable, has my trust"
+msgstr "Rispettabile, ha la mia fiducia"
-#: include/event.php:490 include/text.php:1198
-msgid "Saturday"
-msgstr "Sabato"
+#: include/contact_selectors.php:56 mod/admin.php:1095
+msgid "Frequently"
+msgstr "Frequentemente"
-#: include/event.php:492
-msgid "Jan"
-msgstr "Gen"
+#: include/contact_selectors.php:57 mod/admin.php:1096
+msgid "Hourly"
+msgstr "Ogni ora"
-#: include/event.php:493
-msgid "Feb"
-msgstr "Feb"
+#: include/contact_selectors.php:58 mod/admin.php:1097
+msgid "Twice daily"
+msgstr "Due volte al dì"
-#: include/event.php:494
-msgid "Mar"
-msgstr "Mar"
+#: include/contact_selectors.php:59 mod/admin.php:1098
+msgid "Daily"
+msgstr "Giornalmente"
-#: include/event.php:495
-msgid "Apr"
-msgstr "Apr"
+#: include/contact_selectors.php:60
+msgid "Weekly"
+msgstr "Settimanalmente"
-#: include/event.php:496 include/event.php:509 include/text.php:1202
-msgid "May"
-msgstr "Maggio"
+#: include/contact_selectors.php:61
+msgid "Monthly"
+msgstr "Mensilmente"
-#: include/event.php:497
-msgid "Jun"
-msgstr "Giu"
+#: include/contact_selectors.php:76 mod/dfrn_request.php:887
+msgid "Friendica"
+msgstr "Friendica"
-#: include/event.php:498
-msgid "Jul"
-msgstr "Lug"
+#: include/contact_selectors.php:77
+msgid "OStatus"
+msgstr "Ostatus"
-#: include/event.php:499
-msgid "Aug"
-msgstr "Ago"
+#: include/contact_selectors.php:78
+msgid "RSS/Atom"
+msgstr "RSS / Atom"
-#: include/event.php:500
-msgid "Sept"
-msgstr "Set"
+#: include/contact_selectors.php:79 include/contact_selectors.php:86
+#: mod/admin.php:1612 mod/admin.php:1625 mod/admin.php:1638 mod/admin.php:1656
+msgid "Email"
+msgstr "Email"
-#: include/event.php:501
-msgid "Oct"
-msgstr "Ott"
+#: include/contact_selectors.php:80 mod/dfrn_request.php:889
+#: mod/settings.php:858
+msgid "Diaspora"
+msgstr "Diaspora"
-#: include/event.php:502
-msgid "Nov"
-msgstr "Nov"
+#: include/contact_selectors.php:81
+msgid "Facebook"
+msgstr "Facebook"
-#: include/event.php:503
-msgid "Dec"
-msgstr "Dic"
+#: include/contact_selectors.php:82
+msgid "Zot!"
+msgstr "Zot!"
-#: include/event.php:505 include/text.php:1202
-msgid "January"
-msgstr "Gennaio"
+#: include/contact_selectors.php:83
+msgid "LinkedIn"
+msgstr "LinkedIn"
-#: include/event.php:506 include/text.php:1202
-msgid "February"
-msgstr "Febbraio"
+#: include/contact_selectors.php:84
+msgid "XMPP/IM"
+msgstr "XMPP/IM"
-#: include/event.php:507 include/text.php:1202
-msgid "March"
-msgstr "Marzo"
+#: include/contact_selectors.php:85
+msgid "MySpace"
+msgstr "MySpace"
-#: include/event.php:508 include/text.php:1202
-msgid "April"
-msgstr "Aprile"
+#: include/contact_selectors.php:87
+msgid "Google+"
+msgstr "Google+"
-#: include/event.php:510 include/text.php:1202
-msgid "June"
-msgstr "Giugno"
+#: include/contact_selectors.php:88
+msgid "pump.io"
+msgstr "pump.io"
-#: include/event.php:511 include/text.php:1202
-msgid "July"
-msgstr "Luglio"
+#: include/contact_selectors.php:89
+msgid "Twitter"
+msgstr "Twitter"
-#: include/event.php:512 include/text.php:1202
-msgid "August"
-msgstr "Agosto"
+#: include/contact_selectors.php:90
+msgid "Diaspora Connector"
+msgstr "Connettore Diaspora"
-#: include/event.php:513 include/text.php:1202
-msgid "September"
-msgstr "Settembre"
+#: include/contact_selectors.php:91
+msgid "GNU Social Connector"
+msgstr "Connettore GNU Social"
-#: include/event.php:514 include/text.php:1202
-msgid "October"
-msgstr "Ottobre"
+#: include/contact_selectors.php:92
+msgid "pnut"
+msgstr "pnut"
-#: include/event.php:515 include/text.php:1202
-msgid "November"
-msgstr "Novembre"
+#: include/contact_selectors.php:93
+msgid "App.net"
+msgstr "App.net"
-#: include/event.php:516 include/text.php:1202
-msgid "December"
-msgstr "Dicembre"
+#: include/conversation.php:135 include/conversation.php:287
+#: include/like.php:185 include/text.php:1894
+msgid "event"
+msgstr "l'evento"
-#: include/event.php:518 mod/cal.php:278 mod/events.php:383
-msgid "today"
-msgstr "oggi"
+#: include/conversation.php:138 include/conversation.php:148
+#: include/conversation.php:290 include/conversation.php:299
+#: include/diaspora.php:1787 include/like.php:183 mod/subthread.php:90
+#: mod/tagger.php:65
+msgid "status"
+msgstr "stato"
-#: include/event.php:523
-msgid "No events to display"
-msgstr "Nessun evento da mostrare"
+#: include/conversation.php:143 include/conversation.php:295
+#: include/like.php:183 include/text.php:1896 mod/subthread.php:90
+#: mod/tagger.php:65
+msgid "photo"
+msgstr "foto"
-#: include/event.php:636
-msgid "l, F j"
-msgstr "l j F"
+#: include/conversation.php:155 include/diaspora.php:1783 include/like.php:32
+#, php-format
+msgid "%1$s likes %2$s's %3$s"
+msgstr "A %1$s piace %3$s di %2$s"
-#: include/event.php:658
-msgid "Edit event"
-msgstr "Modifica l'evento"
+#: include/conversation.php:158 include/like.php:36 include/like.php:41
+#, php-format
+msgid "%1$s doesn't like %2$s's %3$s"
+msgstr "A %1$s non piace %3$s di %2$s"
-#: include/event.php:659
-msgid "Delete event"
-msgstr "Elimina evento"
+#: include/conversation.php:161
+#, php-format
+msgid "%1$s attends %2$s's %3$s"
+msgstr "%1$s partecipa a %3$s di %2$s"
-#: include/event.php:685 include/text.php:1600 include/text.php:1607
-msgid "link to source"
-msgstr "Collegamento all'originale"
+#: include/conversation.php:164
+#, php-format
+msgid "%1$s doesn't attend %2$s's %3$s"
+msgstr "%1$s non partecipa a %3$s di %2$s"
-#: include/event.php:939
-msgid "Export"
-msgstr "Esporta"
+#: include/conversation.php:167
+#, php-format
+msgid "%1$s attends maybe %2$s's %3$s"
+msgstr "%1$s forse partecipa a %3$s di %2$s"
-#: include/event.php:940
-msgid "Export calendar as ical"
-msgstr "Esporta il calendario in formato ical"
+#: include/conversation.php:200 mod/dfrn_confirm.php:481
+#, php-format
+msgid "%1$s is now friends with %2$s"
+msgstr "%1$s e %2$s adesso sono amici"
-#: include/event.php:941
-msgid "Export calendar as csv"
-msgstr "Esporta il calendario in formato csv"
+#: include/conversation.php:241
+#, php-format
+msgid "%1$s poked %2$s"
+msgstr "%1$s ha stuzzicato %2$s"
-#: include/features.php:65
-msgid "General Features"
-msgstr "Funzionalità generali"
+#: include/conversation.php:262 mod/mood.php:66
+#, php-format
+msgid "%1$s is currently %2$s"
+msgstr "%1$s al momento è %2$s"
-#: include/features.php:67
-msgid "Multiple Profiles"
-msgstr "Profili multipli"
+#: include/conversation.php:309 mod/tagger.php:98
+#, php-format
+msgid "%1$s tagged %2$s's %3$s with %4$s"
+msgstr "%1$s ha taggato %3$s di %2$s con %4$s"
-#: include/features.php:67
-msgid "Ability to create multiple profiles"
-msgstr "Possibilità di creare profili multipli"
+#: include/conversation.php:336
+msgid "post/item"
+msgstr "post/elemento"
-#: include/features.php:68
-msgid "Photo Location"
-msgstr "Località Foto"
+#: include/conversation.php:337
+#, php-format
+msgid "%1$s marked %2$s's %3$s as favorite"
+msgstr "%1$s ha segnato il/la %3$s di %2$s come preferito"
-#: include/features.php:68
-msgid ""
-"Photo metadata is normally stripped. This extracts the location (if present)"
-" prior to stripping metadata and links it to a map."
-msgstr "I metadati delle foto vengono rimossi. Questa opzione estrae la località (se presenta) prima di rimuovere i metadati e la collega a una mappa."
+#: include/conversation.php:623 mod/photos.php:1639 mod/profiles.php:340
+msgid "Likes"
+msgstr "Mi piace"
-#: include/features.php:69
-msgid "Export Public Calendar"
-msgstr "Esporta calendario pubblico"
+#: include/conversation.php:623 mod/photos.php:1639 mod/profiles.php:344
+msgid "Dislikes"
+msgstr "Non mi piace"
-#: include/features.php:69
-msgid "Ability for visitors to download the public calendar"
-msgstr "Permesso ai visitatori di scaricare il calendario pubblico"
+#: include/conversation.php:624 include/conversation.php:1559
+#: mod/photos.php:1640
+msgid "Attending"
+msgid_plural "Attending"
+msgstr[0] "Partecipa"
+msgstr[1] "Partecipano"
-#: include/features.php:74
-msgid "Post Composition Features"
-msgstr "Funzionalità di composizione dei post"
-
-#: include/features.php:75
-msgid "Post Preview"
-msgstr "Anteprima dei post"
+#: include/conversation.php:624 mod/photos.php:1640
+msgid "Not attending"
+msgstr "Non partecipa"
-#: include/features.php:75
-msgid "Allow previewing posts and comments before publishing them"
-msgstr "Permetti di avere un'anteprima di messaggi e commenti prima di pubblicarli"
+#: include/conversation.php:624 mod/photos.php:1640
+msgid "Might attend"
+msgstr "Forse partecipa"
-#: include/features.php:76
-msgid "Auto-mention Forums"
-msgstr "Auto-cita i Forum"
+#: include/conversation.php:761 mod/photos.php:1705 object/Item.php:147
+msgid "Select"
+msgstr "Seleziona"
-#: include/features.php:76
-msgid ""
-"Add/remove mention when a forum page is selected/deselected in ACL window."
-msgstr "Aggiunge/rimuove una menzione quando una pagina forum è selezionata/deselezionata nella finestra dei permessi."
+#: include/conversation.php:762 mod/admin.php:1630 mod/contacts.php:838
+#: mod/contacts.php:1037 mod/photos.php:1706 mod/settings.php:754
+#: object/Item.php:148
+msgid "Delete"
+msgstr "Rimuovi"
-#: include/features.php:81
-msgid "Network Sidebar Widgets"
-msgstr "Widget della barra laterale nella pagina Rete"
+#: include/conversation.php:806 object/Item.php:350 object/Item.php:351
+#, php-format
+msgid "View %s's profile @ %s"
+msgstr "Vedi il profilo di %s @ %s"
-#: include/features.php:82
-msgid "Search by Date"
-msgstr "Cerca per data"
+#: include/conversation.php:818 object/Item.php:338
+msgid "Categories:"
+msgstr "Categorie:"
-#: include/features.php:82
-msgid "Ability to select posts by date ranges"
-msgstr "Permette di filtrare i post per data"
+#: include/conversation.php:819 object/Item.php:339
+msgid "Filed under:"
+msgstr "Archiviato in:"
-#: include/features.php:83 include/features.php:113
-msgid "List Forums"
-msgstr "Elenco forum"
+#: include/conversation.php:826 object/Item.php:364
+#, php-format
+msgid "%s from %s"
+msgstr "%s da %s"
-#: include/features.php:83
-msgid "Enable widget to display the forums your are connected with"
-msgstr "Abilita il widget che mostra i forum ai quali sei connesso"
+#: include/conversation.php:842
+msgid "View in context"
+msgstr "Vedi nel contesto"
-#: include/features.php:84
-msgid "Group Filter"
-msgstr "Filtra gruppi"
+#: include/conversation.php:844 include/conversation.php:1316
+#: mod/editpost.php:117 mod/message.php:337 mod/message.php:522
+#: mod/wallmessage.php:143 mod/photos.php:1604 object/Item.php:389
+msgid "Please wait"
+msgstr "Attendi"
-#: include/features.php:84
-msgid "Enable widget to display Network posts only from selected group"
-msgstr "Abilita il widget per filtrare i post solo per il gruppo selezionato"
+#: include/conversation.php:921
+msgid "remove"
+msgstr "rimuovi"
-#: include/features.php:85
-msgid "Network Filter"
-msgstr "Filtro reti"
+#: include/conversation.php:925
+msgid "Delete Selected Items"
+msgstr "Cancella elementi selezionati"
-#: include/features.php:85
-msgid "Enable widget to display Network posts only from selected network"
-msgstr "Abilita il widget per mostrare i post solo per la rete selezionata"
+#: include/conversation.php:1020 view/theme/frio/theme.php:347
+msgid "Follow Thread"
+msgstr "Segui la discussione"
-#: include/features.php:86 mod/network.php:206 mod/search.php:34
-msgid "Saved Searches"
-msgstr "Ricerche salvate"
+#: include/conversation.php:1157
+#, php-format
+msgid "%s likes this."
+msgstr "Piace a %s."
-#: include/features.php:86
-msgid "Save search terms for re-use"
-msgstr "Salva i termini cercati per riutilizzarli"
+#: include/conversation.php:1160
+#, php-format
+msgid "%s doesn't like this."
+msgstr "Non piace a %s."
-#: include/features.php:91
-msgid "Network Tabs"
-msgstr "Schede pagina Rete"
+#: include/conversation.php:1163
+#, php-format
+msgid "%s attends."
+msgstr "%s partecipa."
-#: include/features.php:92
-msgid "Network Personal Tab"
-msgstr "Scheda Personali"
+#: include/conversation.php:1166
+#, php-format
+msgid "%s doesn't attend."
+msgstr "%s non partecipa."
-#: include/features.php:92
-msgid "Enable tab to display only Network posts that you've interacted on"
-msgstr "Abilita la scheda per mostrare solo i post a cui hai partecipato"
+#: include/conversation.php:1169
+#, php-format
+msgid "%s attends maybe."
+msgstr "%s forse partecipa."
-#: include/features.php:93
-msgid "Network New Tab"
-msgstr "Scheda Nuovi"
+#: include/conversation.php:1180
+msgid "and"
+msgstr "e"
-#: include/features.php:93
-msgid "Enable tab to display only new Network posts (from the last 12 hours)"
-msgstr "Abilita la scheda per mostrare solo i post nuovi (nelle ultime 12 ore)"
+#: include/conversation.php:1186
+#, php-format
+msgid ", and %d other people"
+msgstr "e altre %d persone"
-#: include/features.php:94
-msgid "Network Shared Links Tab"
-msgstr "Scheda Link Condivisi"
+#: include/conversation.php:1195
+#, php-format
+msgid "<span %1$s>%2$d people</span> like this"
+msgstr "Piace a <span %1$s>%2$d persone</span>."
-#: include/features.php:94
-msgid "Enable tab to display only Network posts with links in them"
-msgstr "Abilita la scheda per mostrare solo i post che contengono link"
+#: include/conversation.php:1196
+#, php-format
+msgid "%s like this."
+msgstr "a %s piace."
-#: include/features.php:99
-msgid "Post/Comment Tools"
-msgstr "Strumenti per messaggi/commenti"
+#: include/conversation.php:1199
+#, php-format
+msgid "<span %1$s>%2$d people</span> don't like this"
+msgstr "Non piace a <span %1$s>%2$d persone</span>."
-#: include/features.php:100
-msgid "Multiple Deletion"
-msgstr "Eliminazione multipla"
+#: include/conversation.php:1200
+#, php-format
+msgid "%s don't like this."
+msgstr "a %s non piace."
-#: include/features.php:100
-msgid "Select and delete multiple posts/comments at once"
-msgstr "Seleziona ed elimina vari messaggi e commenti in una volta sola"
+#: include/conversation.php:1203
+#, php-format
+msgid "<span %1$s>%2$d people</span> attend"
+msgstr "<span %1$s>%2$d persone</span> partecipano"
-#: include/features.php:101
-msgid "Edit Sent Posts"
-msgstr "Modifica i post inviati"
+#: include/conversation.php:1204
+#, php-format
+msgid "%s attend."
+msgstr "%s partecipa."
-#: include/features.php:101
-msgid "Edit and correct posts and comments after sending"
-msgstr "Modifica e correggi messaggi e commenti dopo averli inviati"
+#: include/conversation.php:1207
+#, php-format
+msgid "<span %1$s>%2$d people</span> don't attend"
+msgstr "<span %1$s>%2$d persone</span> non partecipano"
-#: include/features.php:102
-msgid "Tagging"
-msgstr "Aggiunta tag"
+#: include/conversation.php:1208
+#, php-format
+msgid "%s don't attend."
+msgstr "%s non partecipa."
-#: include/features.php:102
-msgid "Ability to tag existing posts"
-msgstr "Permette di aggiungere tag ai post già esistenti"
+#: include/conversation.php:1211
+#, php-format
+msgid "<span %1$s>%2$d people</span> attend maybe"
+msgstr "<span %1$s>%2$d persone</span> forse partecipano"
-#: include/features.php:103
-msgid "Post Categories"
-msgstr "Categorie post"
+#: include/conversation.php:1212
+#, php-format
+msgid "%s anttend maybe."
+msgstr "%s forse partecipano."
-#: include/features.php:103
-msgid "Add categories to your posts"
-msgstr "Aggiungi categorie ai tuoi post"
+#: include/conversation.php:1241 include/conversation.php:1257
+msgid "Visible to <strong>everybody</strong>"
+msgstr "Visibile a <strong>tutti</strong>"
-#: include/features.php:104
-msgid "Ability to file posts under folders"
-msgstr "Permette di archiviare i post in cartelle"
+#: include/conversation.php:1242 include/conversation.php:1258
+#: mod/message.php:271 mod/message.php:278 mod/message.php:418
+#: mod/message.php:425 mod/wallmessage.php:117 mod/wallmessage.php:124
+msgid "Please enter a link URL:"
+msgstr "Inserisci l'indirizzo del link:"
-#: include/features.php:105
-msgid "Dislike Posts"
-msgstr "Non mi piace"
+#: include/conversation.php:1243 include/conversation.php:1259
+msgid "Please enter a video link/URL:"
+msgstr "Inserisci un collegamento video / URL:"
-#: include/features.php:105
-msgid "Ability to dislike posts/comments"
-msgstr "Permetti di inviare \"non mi piace\" ai messaggi"
+#: include/conversation.php:1244 include/conversation.php:1260
+msgid "Please enter an audio link/URL:"
+msgstr "Inserisci un collegamento audio / URL:"
-#: include/features.php:106
-msgid "Star Posts"
-msgstr "Post preferiti"
+#: include/conversation.php:1245 include/conversation.php:1261
+msgid "Tag term:"
+msgstr "Tag:"
-#: include/features.php:106
-msgid "Ability to mark special posts with a star indicator"
-msgstr "Permette di segnare i post preferiti con una stella"
+#: include/conversation.php:1246 include/conversation.php:1262
+#: mod/filer.php:31
+msgid "Save to Folder:"
+msgstr "Salva nella Cartella:"
-#: include/features.php:107
-msgid "Mute Post Notifications"
-msgstr "Silenzia le notifiche di nuovi post"
+#: include/conversation.php:1247 include/conversation.php:1263
+msgid "Where are you right now?"
+msgstr "Dove sei ora?"
-#: include/features.php:107
-msgid "Ability to mute notifications for a thread"
-msgstr "Permette di silenziare le notifiche di nuovi post in una discussione"
+#: include/conversation.php:1248
+msgid "Delete item(s)?"
+msgstr "Cancellare questo elemento/i?"
-#: include/features.php:112
-msgid "Advanced Profile Settings"
-msgstr "Impostazioni Avanzate Profilo"
+#: include/conversation.php:1297
+msgid "Share"
+msgstr "Condividi"
-#: include/features.php:113
-msgid "Show visitors public community forums at the Advanced Profile Page"
-msgstr "Mostra ai visitatori i forum nella pagina Profilo Avanzato"
+#: include/conversation.php:1298 mod/editpost.php:103 mod/message.php:335
+#: mod/message.php:519 mod/wallmessage.php:141
+msgid "Upload photo"
+msgstr "Carica foto"
-#: include/follow.php:81 mod/dfrn_request.php:512
-msgid "Disallowed profile URL."
-msgstr "Indirizzo profilo non permesso."
+#: include/conversation.php:1299 mod/editpost.php:104
+msgid "upload photo"
+msgstr "carica foto"
-#: include/follow.php:86 mod/dfrn_request.php:518 mod/friendica.php:114
-#: mod/admin.php:279 mod/admin.php:297
-msgid "Blocked domain"
-msgstr "Dominio bloccato"
+#: include/conversation.php:1300 mod/editpost.php:105
+msgid "Attach file"
+msgstr "Allega file"
-#: include/follow.php:91
-msgid "Connect URL missing."
-msgstr "URL di connessione mancante."
+#: include/conversation.php:1301 mod/editpost.php:106
+msgid "attach file"
+msgstr "allega file"
-#: include/follow.php:119
-msgid ""
-"This site is not configured to allow communications with other networks."
-msgstr "Questo sito non è configurato per permettere la comunicazione con altri network."
+#: include/conversation.php:1302 mod/editpost.php:107 mod/message.php:336
+#: mod/message.php:520 mod/wallmessage.php:142
+msgid "Insert web link"
+msgstr "Inserisci link"
-#: include/follow.php:120 include/follow.php:134
-msgid "No compatible communication protocols or feeds were discovered."
-msgstr "Non sono stati trovati protocolli di comunicazione o feed compatibili."
+#: include/conversation.php:1303 mod/editpost.php:108
+msgid "web link"
+msgstr "link web"
-#: include/follow.php:132
-msgid "The profile address specified does not provide adequate information."
-msgstr "L'indirizzo del profilo specificato non fornisce adeguate informazioni."
+#: include/conversation.php:1304 mod/editpost.php:109
+msgid "Insert video link"
+msgstr "Inserire collegamento video"
-#: include/follow.php:137
-msgid "An author or name was not found."
-msgstr "Non è stato trovato un nome o un autore"
+#: include/conversation.php:1305 mod/editpost.php:110
+msgid "video link"
+msgstr "link video"
-#: include/follow.php:140
-msgid "No browser URL could be matched to this address."
-msgstr "Nessun URL può essere associato a questo indirizzo."
+#: include/conversation.php:1306 mod/editpost.php:111
+msgid "Insert audio link"
+msgstr "Inserisci collegamento audio"
-#: include/follow.php:143
-msgid ""
-"Unable to match @-style Identity Address with a known protocol or email "
-"contact."
-msgstr "Impossibile l'indirizzo identità con un protocollo conosciuto o con un contatto email."
+#: include/conversation.php:1307 mod/editpost.php:112
+msgid "audio link"
+msgstr "link audio"
-#: include/follow.php:144
-msgid "Use mailto: in front of address to force email check."
-msgstr "Usa \"mailto:\" davanti all'indirizzo per forzare un controllo nelle email."
+#: include/conversation.php:1308 mod/editpost.php:113
+msgid "Set your location"
+msgstr "La tua posizione"
-#: include/follow.php:150
-msgid ""
-"The profile address specified belongs to a network which has been disabled "
-"on this site."
-msgstr "L'indirizzo del profilo specificato appartiene a un network che è stato disabilitato su questo sito."
+#: include/conversation.php:1309 mod/editpost.php:114
+msgid "set location"
+msgstr "posizione"
-#: include/follow.php:155
-msgid ""
-"Limited profile. This person will be unable to receive direct/personal "
-"notifications from you."
-msgstr "Profilo limitato. Questa persona non sarà in grado di ricevere notifiche personali da te."
+#: include/conversation.php:1310 mod/editpost.php:115
+msgid "Clear browser location"
+msgstr "Rimuovi la localizzazione data dal browser"
-#: include/follow.php:256
-msgid "Unable to retrieve contact information."
-msgstr "Impossibile recuperare informazioni sul contatto."
+#: include/conversation.php:1311 mod/editpost.php:116
+msgid "clear location"
+msgstr "canc. pos."
-#: include/group.php:25
-msgid ""
-"A deleted group with this name was revived. Existing item permissions "
-"<strong>may</strong> apply to this group and any future members. If this is "
-"not what you intended, please create another group with a different name."
-msgstr "Un gruppo eliminato con questo nome è stato ricreato. I permessi esistenti su un elemento <strong>possono</strong> essere applicati a questo gruppo e tutti i membri futuri. Se questo non è ciò che si intende, si prega di creare un altro gruppo con un nome diverso."
+#: include/conversation.php:1313 mod/editpost.php:130
+msgid "Set title"
+msgstr "Scegli un titolo"
-#: include/group.php:210
-msgid "Default privacy group for new contacts"
-msgstr "Gruppo predefinito per i nuovi contatti"
+#: include/conversation.php:1315 mod/editpost.php:132
+msgid "Categories (comma-separated list)"
+msgstr "Categorie (lista separata da virgola)"
-#: include/group.php:243
-msgid "Everybody"
-msgstr "Tutti"
+#: include/conversation.php:1317 mod/editpost.php:118
+msgid "Permission settings"
+msgstr "Impostazioni permessi"
-#: include/group.php:266
-msgid "edit"
-msgstr "modifica"
+#: include/conversation.php:1318 mod/editpost.php:147
+msgid "permissions"
+msgstr "permessi"
-#: include/group.php:287 mod/newmember.php:61
-msgid "Groups"
-msgstr "Gruppi"
+#: include/conversation.php:1326 mod/editpost.php:127
+msgid "Public post"
+msgstr "Messaggio pubblico"
-#: include/group.php:289
-msgid "Edit groups"
-msgstr "Modifica gruppi"
+#: include/conversation.php:1331 mod/editpost.php:138 mod/events.php:527
+#: mod/photos.php:1624 mod/photos.php:1666 mod/photos.php:1746
+#: object/Item.php:711
+msgid "Preview"
+msgstr "Anteprima"
-#: include/group.php:291
-msgid "Edit group"
-msgstr "Modifica gruppo"
+#: include/conversation.php:1335 include/items.php:2154
+#: mod/dfrn_request.php:895 mod/editpost.php:141 mod/follow.php:161
+#: mod/message.php:210 mod/tagrm.php:14 mod/tagrm.php:99 mod/suggest.php:35
+#: mod/fbrowser.php:104 mod/fbrowser.php:139 mod/unfollow.php:117
+#: mod/contacts.php:469 mod/photos.php:249 mod/photos.php:341
+#: mod/settings.php:692 mod/settings.php:718 mod/videos.php:136
+msgid "Cancel"
+msgstr "Annulla"
-#: include/group.php:292
-msgid "Create a new group"
-msgstr "Crea un nuovo gruppo"
+#: include/conversation.php:1341
+msgid "Post to Groups"
+msgstr "Invia ai Gruppi"
-#: include/group.php:293 mod/group.php:99 mod/group.php:196
-msgid "Group Name: "
-msgstr "Nome del gruppo:"
+#: include/conversation.php:1342
+msgid "Post to Contacts"
+msgstr "Invia ai Contatti"
-#: include/group.php:295
-msgid "Contacts not in any group"
-msgstr "Contatti in nessun gruppo."
+#: include/conversation.php:1343
+msgid "Private post"
+msgstr "Post privato"
-#: include/group.php:297 mod/network.php:207
-msgid "add"
-msgstr "aggiungi"
+#: include/conversation.php:1348 include/identity.php:268 mod/editpost.php:145
+msgid "Message"
+msgstr "Messaggio"
-#: include/identity.php:43
-msgid "Requested account is not available."
-msgstr "L'account richiesto non è disponibile."
+#: include/conversation.php:1349 mod/editpost.php:146
+msgid "Browser"
+msgstr "Browser"
-#: include/identity.php:52 mod/profile.php:21
-msgid "Requested profile is not available."
-msgstr "Profilo richiesto non disponibile."
+#: include/conversation.php:1531
+msgid "View all"
+msgstr "Mostra tutto"
-#: include/identity.php:96 include/identity.php:319 include/identity.php:740
-msgid "Edit profile"
-msgstr "Modifica il profilo"
+#: include/conversation.php:1553
+msgid "Like"
+msgid_plural "Likes"
+msgstr[0] "Mi piace"
+msgstr[1] "Mi piace"
-#: include/identity.php:259
-msgid "Atom feed"
-msgstr "Feed Atom"
+#: include/conversation.php:1556
+msgid "Dislike"
+msgid_plural "Dislikes"
+msgstr[0] "Non mi piace"
+msgstr[1] "Non mi piace"
-#: include/identity.php:290
-msgid "Manage/edit profiles"
-msgstr "Gestisci/modifica i profili"
+#: include/conversation.php:1562
+msgid "Not Attending"
+msgid_plural "Not Attending"
+msgstr[0] "Non partecipa"
+msgstr[1] "Non partecipano"
-#: include/identity.php:295 include/identity.php:321 mod/profiles.php:787
-msgid "Change profile photo"
-msgstr "Cambia la foto del profilo"
+#: include/dba.php:57
+#, php-format
+msgid "Cannot locate DNS info for database server '%s'"
+msgstr "Non trovo le informazioni DNS per il database server '%s'"
-#: include/identity.php:296 mod/profiles.php:788
-msgid "Create New Profile"
-msgstr "Crea un nuovo profilo"
+#: include/dbstructure.php:24
+msgid "There are no tables on MyISAM."
+msgstr "Non ci sono tabelle MyISAM"
-#: include/identity.php:306 mod/profiles.php:777
-msgid "Profile Image"
-msgstr "Immagine del Profilo"
+#: include/dbstructure.php:65
+#, php-format
+msgid ""
+"\n"
+"\t\t\tThe friendica developers released update %s recently,\n"
+"\t\t\tbut when I tried to install it, something went terribly wrong.\n"
+"\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n"
+"\t\t\tfriendica developer if you can not help me on your own. My database might be invalid."
+msgstr "\nGli sviluppatori di Friendica hanno rilasciato l'aggiornamento %s\nrecentemente, ma quando ho provato a installarlo, qualcosa è \nandato terribilmente storto.\nBisogna sistemare le cose e non posso farlo da solo.\nContatta uno sviluppatore se non puoi aiutarmi da solo. Il mio database potrebbe essere invalido."
-#: include/identity.php:309 mod/profiles.php:779
-msgid "visible to everybody"
-msgstr "visibile a tutti"
+#: include/dbstructure.php:70
+#, php-format
+msgid ""
+"The error message is\n"
+"[pre]%s[/pre]"
+msgstr "Il messaggio di errore è\n[pre]%s[/pre]"
-#: include/identity.php:310 mod/profiles.php:684 mod/profiles.php:780
-msgid "Edit visibility"
-msgstr "Modifica visibilità"
+#: include/dbstructure.php:192
+#, php-format
+msgid ""
+"\n"
+"Error %d occurred during database update:\n"
+"%s\n"
+msgstr "\nErrore %d durante l'aggiornamento del database:\n%s\n"
-#: include/identity.php:338 include/identity.php:633 mod/directory.php:141
-#: mod/notifications.php:250
-msgid "Gender:"
-msgstr "Genere:"
+#: include/dbstructure.php:195
+msgid "Errors encountered performing database changes: "
+msgstr "Errori riscontrati eseguendo le modifiche al database:"
-#: include/identity.php:341 include/identity.php:651 mod/directory.php:143
-msgid "Status:"
-msgstr "Stato:"
+#: include/dbstructure.php:203
+msgid ": Database update"
+msgstr ": Aggiornamento database"
-#: include/identity.php:343 include/identity.php:667 mod/directory.php:145
-msgid "Homepage:"
-msgstr "Homepage:"
+#: include/dbstructure.php:436
+#, php-format
+msgid "%s: updating %s table."
+msgstr "%s: aggiornando la tabella %s."
-#: include/identity.php:345 include/identity.php:687 mod/contacts.php:640
-#: mod/directory.php:147 mod/notifications.php:246
-msgid "About:"
-msgstr "Informazioni:"
+#: include/delivery.php:429
+msgid "(no subject)"
+msgstr "(nessun oggetto)"
-#: include/identity.php:347 mod/contacts.php:638
-msgid "XMPP:"
-msgstr "XMPP:"
+#: include/dfrn.php:1360
+#, php-format
+msgid "%s\\'s birthday"
+msgstr "compleanno di %s"
-#: include/identity.php:433 mod/contacts.php:55 mod/notifications.php:258
-msgid "Network:"
-msgstr "Rete:"
+#: include/diaspora.php:2351
+msgid "Sharing notification from Diaspora network"
+msgstr "Notifica di condivisione dal network Diaspora*"
-#: include/identity.php:462 include/identity.php:552
-msgid "g A l F d"
-msgstr "g A l d F"
+#: include/diaspora.php:3344
+msgid "Attachments:"
+msgstr "Allegati:"
-#: include/identity.php:463 include/identity.php:553
-msgid "F d"
-msgstr "d F"
+#: include/event.php:445
+msgid "all-day"
+msgstr "tutto il giorno"
-#: include/identity.php:514 include/identity.php:599
-msgid "[today]"
-msgstr "[oggi]"
+#: include/event.php:447
+msgid "Sun"
+msgstr "Dom"
-#: include/identity.php:526
-msgid "Birthday Reminders"
-msgstr "Promemoria compleanni"
+#: include/event.php:448 include/text.php:1220
+msgid "Mon"
+msgstr "Lun"
-#: include/identity.php:527
-msgid "Birthdays this week:"
-msgstr "Compleanni questa settimana:"
+#: include/event.php:449 include/text.php:1220
+msgid "Tue"
+msgstr "Mar"
-#: include/identity.php:586
-msgid "[No description]"
-msgstr "[Nessuna descrizione]"
+#: include/event.php:450 include/text.php:1220
+msgid "Wed"
+msgstr "Mer"
-#: include/identity.php:610
-msgid "Event Reminders"
-msgstr "Promemoria"
+#: include/event.php:451 include/text.php:1220
+msgid "Thu"
+msgstr "Gio"
-#: include/identity.php:611
-msgid "Events this week:"
-msgstr "Eventi di questa settimana:"
+#: include/event.php:452 include/text.php:1220
+msgid "Fri"
+msgstr "Ven"
-#: include/identity.php:631 mod/settings.php:1286
-msgid "Full Name:"
-msgstr "Nome completo:"
+#: include/event.php:453 include/text.php:1220
+msgid "Sat"
+msgstr "Sab"
-#: include/identity.php:636
-msgid "j F, Y"
-msgstr "j F Y"
+#: include/event.php:455 include/text.php:1202 mod/settings.php:986
+msgid "Sunday"
+msgstr "Domenica"
-#: include/identity.php:637
-msgid "j F"
-msgstr "j F"
+#: include/event.php:456 include/text.php:1202 mod/settings.php:986
+msgid "Monday"
+msgstr "Lunedì"
-#: include/identity.php:648
-msgid "Age:"
-msgstr "Età:"
+#: include/event.php:457 include/text.php:1202
+msgid "Tuesday"
+msgstr "Martedì"
-#: include/identity.php:659
-#, php-format
-msgid "for %1$d %2$s"
-msgstr "per %1$d %2$s"
+#: include/event.php:458 include/text.php:1202
+msgid "Wednesday"
+msgstr "Mercoledì"
-#: include/identity.php:663 mod/profiles.php:703
-msgid "Sexual Preference:"
-msgstr "Preferenze sessuali:"
+#: include/event.php:459 include/text.php:1202
+msgid "Thursday"
+msgstr "Giovedì"
-#: include/identity.php:671 mod/profiles.php:730
-msgid "Hometown:"
-msgstr "Paese natale:"
+#: include/event.php:460 include/text.php:1202
+msgid "Friday"
+msgstr "Venerdì"
-#: include/identity.php:675 mod/contacts.php:642 mod/follow.php:137
-#: mod/notifications.php:248
-msgid "Tags:"
-msgstr "Tag:"
+#: include/event.php:461 include/text.php:1202
+msgid "Saturday"
+msgstr "Sabato"
-#: include/identity.php:679 mod/profiles.php:731
-msgid "Political Views:"
-msgstr "Orientamento politico:"
+#: include/event.php:463 include/text.php:1223
+msgid "Jan"
+msgstr "Gen"
-#: include/identity.php:683
-msgid "Religion:"
-msgstr "Religione:"
+#: include/event.php:464 include/text.php:1223
+msgid "Feb"
+msgstr "Feb"
-#: include/identity.php:691
-msgid "Hobbies/Interests:"
-msgstr "Hobby/Interessi:"
+#: include/event.php:465 include/text.php:1223
+msgid "Mar"
+msgstr "Mar"
-#: include/identity.php:695 mod/profiles.php:735
-msgid "Likes:"
-msgstr "Mi piace:"
+#: include/event.php:466 include/text.php:1223
+msgid "Apr"
+msgstr "Apr"
-#: include/identity.php:699 mod/profiles.php:736
-msgid "Dislikes:"
-msgstr "Non mi piace:"
+#: include/event.php:467 include/event.php:480 include/text.php:1206
+#: include/text.php:1223
+msgid "May"
+msgstr "Maggio"
-#: include/identity.php:703
-msgid "Contact information and Social Networks:"
-msgstr "Informazioni su contatti e social network:"
+#: include/event.php:468
+msgid "Jun"
+msgstr "Giu"
-#: include/identity.php:707
-msgid "Musical interests:"
-msgstr "Interessi musicali:"
+#: include/event.php:469 include/text.php:1223
+msgid "Jul"
+msgstr "Lug"
-#: include/identity.php:711
-msgid "Books, literature:"
-msgstr "Libri, letteratura:"
+#: include/event.php:470 include/text.php:1223
+msgid "Aug"
+msgstr "Ago"
-#: include/identity.php:715
-msgid "Television:"
-msgstr "Televisione:"
+#: include/event.php:471
+msgid "Sept"
+msgstr "Set"
-#: include/identity.php:719
-msgid "Film/dance/culture/entertainment:"
-msgstr "Film/danza/cultura/intrattenimento:"
+#: include/event.php:472 include/text.php:1223
+msgid "Oct"
+msgstr "Ott"
-#: include/identity.php:723
-msgid "Love/Romance:"
-msgstr "Amore:"
+#: include/event.php:473 include/text.php:1223
+msgid "Nov"
+msgstr "Nov"
-#: include/identity.php:727
-msgid "Work/employment:"
-msgstr "Lavoro:"
+#: include/event.php:474 include/text.php:1223
+msgid "Dec"
+msgstr "Dic"
-#: include/identity.php:731
-msgid "School/education:"
-msgstr "Scuola:"
+#: include/event.php:476 include/text.php:1206
+msgid "January"
+msgstr "Gennaio"
-#: include/identity.php:736
-msgid "Forums:"
-msgstr "Forum:"
+#: include/event.php:477 include/text.php:1206
+msgid "February"
+msgstr "Febbraio"
-#: include/identity.php:745 mod/events.php:506
-msgid "Basic"
-msgstr "Base"
+#: include/event.php:478 include/text.php:1206
+msgid "March"
+msgstr "Marzo"
-#: include/identity.php:746 mod/contacts.php:878 mod/events.php:507
-#: mod/admin.php:1059
-msgid "Advanced"
-msgstr "Avanzate"
+#: include/event.php:479 include/text.php:1206
+msgid "April"
+msgstr "Aprile"
-#: include/identity.php:772 mod/contacts.php:844 mod/follow.php:145
-msgid "Status Messages and Posts"
-msgstr "Messaggi di stato e post"
+#: include/event.php:481 include/text.php:1206
+msgid "June"
+msgstr "Giugno"
-#: include/identity.php:780 mod/contacts.php:852
-msgid "Profile Details"
-msgstr "Dettagli del profilo"
+#: include/event.php:482 include/text.php:1206
+msgid "July"
+msgstr "Luglio"
-#: include/identity.php:788 mod/photos.php:93
-msgid "Photo Albums"
-msgstr "Album foto"
+#: include/event.php:483 include/text.php:1206
+msgid "August"
+msgstr "Agosto"
-#: include/identity.php:827 mod/notes.php:47
-msgid "Personal Notes"
-msgstr "Note personali"
+#: include/event.php:484 include/text.php:1206
+msgid "September"
+msgstr "Settembre"
-#: include/identity.php:830
-msgid "Only You Can See This"
-msgstr "Solo tu puoi vedere questo"
+#: include/event.php:485 include/text.php:1206
+msgid "October"
+msgstr "Ottobre"
-#: include/network.php:687
-msgid "view full size"
-msgstr "vedi a schermo intero"
+#: include/event.php:486 include/text.php:1206
+msgid "November"
+msgstr "Novembre"
-#: include/oembed.php:255
-msgid "Embedded content"
-msgstr "Contenuto incorporato"
+#: include/event.php:487 include/text.php:1206
+msgid "December"
+msgstr "Dicembre"
-#: include/oembed.php:263
-msgid "Embedding disabled"
-msgstr "Embed disabilitato"
+#: include/event.php:489 mod/cal.php:281 mod/events.php:392
+msgid "today"
+msgstr "oggi"
-#: include/photos.php:57 include/photos.php:66 mod/fbrowser.php:40
-#: mod/fbrowser.php:61 mod/photos.php:187 mod/photos.php:1123
-#: mod/photos.php:1256 mod/photos.php:1277 mod/photos.php:1839
-#: mod/photos.php:1853
-msgid "Contact Photos"
-msgstr "Foto dei contatti"
+#: include/event.php:494
+msgid "No events to display"
+msgstr "Nessun evento da mostrare"
-#: include/user.php:39 mod/settings.php:375
-msgid "Passwords do not match. Password unchanged."
-msgstr "Le password non corrispondono. Password non cambiata."
+#: include/event.php:608
+msgid "l, F j"
+msgstr "l j F"
-#: include/user.php:48
-msgid "An invitation is required."
-msgstr "E' richiesto un invito."
+#: include/event.php:629
+msgid "Edit event"
+msgstr "Modifica l'evento"
-#: include/user.php:53
-msgid "Invitation could not be verified."
-msgstr "L'invito non puo' essere verificato."
+#: include/event.php:630
+msgid "Duplicate event"
+msgstr "Duplica evento"
-#: include/user.php:61
-msgid "Invalid OpenID url"
-msgstr "Url OpenID non valido"
+#: include/event.php:631
+msgid "Delete event"
+msgstr "Elimina evento"
-#: include/user.php:82
-msgid "Please enter the required information."
-msgstr "Inserisci le informazioni richieste."
+#: include/event.php:658 include/text.php:1618 include/text.php:1625
+msgid "link to source"
+msgstr "Collegamento all'originale"
-#: include/user.php:96
-msgid "Please use a shorter name."
-msgstr "Usa un nome più corto."
+#: include/event.php:915
+msgid "Export"
+msgstr "Esporta"
-#: include/user.php:98
-msgid "Name too short."
-msgstr "Il nome è troppo corto."
+#: include/event.php:916
+msgid "Export calendar as ical"
+msgstr "Esporta il calendario in formato ical"
-#: include/user.php:106
-msgid "That doesn't appear to be your full (First Last) name."
-msgstr "Questo non sembra essere il tuo nome completo (Nome Cognome)."
+#: include/event.php:917
+msgid "Export calendar as csv"
+msgstr "Esporta il calendario in formato csv"
-#: include/user.php:111
-msgid "Your email domain is not among those allowed on this site."
-msgstr "Il dominio della tua email non è tra quelli autorizzati su questo sito."
+#: include/event.php:934
+msgid "D g:i A"
+msgstr ""
-#: include/user.php:114
-msgid "Not a valid email address."
-msgstr "L'indirizzo email non è valido."
+#: include/event.php:935
+msgid "g:i A"
+msgstr ""
-#: include/user.php:127
-msgid "Cannot use that email."
-msgstr "Non puoi usare quell'email."
+#: include/event.php:1004 include/event.php:1006
+msgid "Show map"
+msgstr "Mostra mappa"
-#: include/user.php:133
-msgid "Your \"nickname\" can only contain \"a-z\", \"0-9\" and \"_\"."
-msgstr "Il tuo nome utente può contenere solo \"a-z\", \"0-9\", e \"_\"."
+#: include/event.php:1005
+msgid "Hide map"
+msgstr "Nascondi mappa"
-#: include/user.php:140 include/user.php:228
-msgid "Nickname is already registered. Please choose another."
-msgstr "Nome utente già registrato. Scegline un altro."
+#: include/follow.php:87 mod/dfrn_request.php:515
+msgid "Disallowed profile URL."
+msgstr "Indirizzo profilo non permesso."
-#: include/user.php:150
-msgid ""
-"Nickname was once registered here and may not be re-used. Please choose "
-"another."
-msgstr "Questo nome utente stato già registrato. Per favore, sceglierne uno nuovo."
+#: include/follow.php:92 mod/dfrn_request.php:521 mod/friendica.php:116
+#: mod/admin.php:290 mod/admin.php:308
+msgid "Blocked domain"
+msgstr "Dominio bloccato"
-#: include/user.php:166
-msgid "SERIOUS ERROR: Generation of security keys failed."
-msgstr "ERRORE GRAVE: La generazione delle chiavi di sicurezza è fallita."
+#: include/follow.php:97
+msgid "Connect URL missing."
+msgstr "URL di connessione mancante."
-#: include/user.php:214
-msgid "An error occurred during registration. Please try again."
-msgstr "C'è stato un errore durante la registrazione. Prova ancora."
+#: include/follow.php:129
+msgid ""
+"This site is not configured to allow communications with other networks."
+msgstr "Questo sito non è configurato per permettere la comunicazione con altri network."
-#: include/user.php:239 view/theme/duepuntozero/config.php:43
-msgid "default"
-msgstr "default"
+#: include/follow.php:130 include/follow.php:144
+msgid "No compatible communication protocols or feeds were discovered."
+msgstr "Non sono stati trovati protocolli di comunicazione o feed compatibili."
-#: include/user.php:249
-msgid "An error occurred creating your default profile. Please try again."
-msgstr "C'è stato un errore nella creazione del tuo profilo. Prova ancora."
+#: include/follow.php:142
+msgid "The profile address specified does not provide adequate information."
+msgstr "L'indirizzo del profilo specificato non fornisce adeguate informazioni."
-#: include/user.php:309 include/user.php:317 include/user.php:325
-#: mod/profile_photo.php:74 mod/profile_photo.php:82 mod/profile_photo.php:90
-#: mod/profile_photo.php:215 mod/profile_photo.php:310
-#: mod/profile_photo.php:320 mod/photos.php:71 mod/photos.php:187
-#: mod/photos.php:774 mod/photos.php:1256 mod/photos.php:1277
-#: mod/photos.php:1863
-msgid "Profile Photos"
-msgstr "Foto del profilo"
+#: include/follow.php:147
+msgid "An author or name was not found."
+msgstr "Non è stato trovato un nome o un autore"
-#: include/user.php:400
-#, php-format
+#: include/follow.php:150
+msgid "No browser URL could be matched to this address."
+msgstr "Nessun URL può essere associato a questo indirizzo."
+
+#: include/follow.php:153
msgid ""
-"\n"
-"\t\tDear %1$s,\n"
-"\t\t\tThank you for registering at %2$s. Your account is pending for approval by the administrator.\n"
-"\t"
-msgstr "\nCaro %1$s,\n Grazie per la tua registrazione su %2$s. Il tuo account è in attesa di approvazione da parte di un amministratore.\n "
+"Unable to match @-style Identity Address with a known protocol or email "
+"contact."
+msgstr "Impossibile l'indirizzo identità con un protocollo conosciuto o con un contatto email."
-#: include/user.php:410
-#, php-format
-msgid "Registration at %s"
-msgstr "Registrazione su %s"
+#: include/follow.php:154
+msgid "Use mailto: in front of address to force email check."
+msgstr "Usa \"mailto:\" davanti all'indirizzo per forzare un controllo nelle email."
-#: include/user.php:420
-#, php-format
+#: include/follow.php:160
msgid ""
-"\n"
-"\t\tDear %1$s,\n"
-"\t\t\tThank you for registering at %2$s. Your account has been created.\n"
-"\t"
-msgstr "\nGentile %1$s,\nGrazie per esserti registrato su %2$s. Il tuo account è stato creato."
+"The profile address specified belongs to a network which has been disabled "
+"on this site."
+msgstr "L'indirizzo del profilo specificato appartiene a un network che è stato disabilitato su questo sito."
-#: include/user.php:424
-#, php-format
+#: include/follow.php:165
msgid ""
-"\n"
-"\t\tThe login details are as follows:\n"
-"\t\t\tSite Location:\t%3$s\n"
-"\t\t\tLogin Name:\t%1$s\n"
-"\t\t\tPassword:\t%5$s\n"
-"\n"
-"\t\tYou may change your password from your account \"Settings\" page after logging\n"
-"\t\tin.\n"
-"\n"
-"\t\tPlease take a few moments to review the other account settings on that page.\n"
-"\n"
-"\t\tYou may also wish to add some basic information to your default profile\n"
-"\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
-"\n"
-"\t\tWe recommend setting your full name, adding a profile photo,\n"
-"\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n"
-"\t\tperhaps what country you live in; if you do not wish to be more specific\n"
-"\t\tthan that.\n"
-"\n"
-"\t\tWe fully respect your right to privacy, and none of these items are necessary.\n"
-"\t\tIf you are new and do not know anybody here, they may help\n"
-"\t\tyou to make some new and interesting friends.\n"
-"\n"
-"\n"
-"\t\tThank you and welcome to %2$s."
-msgstr "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %3$s\n Nome utente: %1$s\n Password: %5$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %2$s"
+"Limited profile. This person will be unable to receive direct/personal "
+"notifications from you."
+msgstr "Profilo limitato. Questa persona non sarà in grado di ricevere notifiche personali da te."
-#: include/user.php:456 mod/admin.php:1308
-#, php-format
-msgid "Registration details for %s"
-msgstr "Dettagli della registrazione di %s"
+#: include/follow.php:236
+msgid "Unable to retrieve contact information."
+msgstr "Impossibile recuperare informazioni sul contatto."
-#: include/dbstructure.php:20
-msgid "There are no tables on MyISAM."
-msgstr "Non ci sono tabelle MyISAM"
+#: include/identity.php:47
+msgid "Requested account is not available."
+msgstr "L'account richiesto non è disponibile."
-#: include/dbstructure.php:61
-#, php-format
-msgid ""
-"\n"
-"\t\t\tThe friendica developers released update %s recently,\n"
-"\t\t\tbut when I tried to install it, something went terribly wrong.\n"
-"\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n"
-"\t\t\tfriendica developer if you can not help me on your own. My database might be invalid."
-msgstr "\nGli sviluppatori di Friendica hanno rilasciato l'aggiornamento %s\nrecentemente, ma quando ho provato a installarlo, qualcosa è \nandato terribilmente storto.\nBisogna sistemare le cose e non posso farlo da solo.\nContatta uno sviluppatore se non puoi aiutarmi da solo. Il mio database potrebbe essere invalido."
+#: include/identity.php:56 mod/profile.php:23
+msgid "Requested profile is not available."
+msgstr "Profilo richiesto non disponibile."
-#: include/dbstructure.php:66
-#, php-format
-msgid ""
-"The error message is\n"
-"[pre]%s[/pre]"
-msgstr "Il messaggio di errore è\n[pre]%s[/pre]"
+#: include/identity.php:100 include/identity.php:323 include/identity.php:756
+msgid "Edit profile"
+msgstr "Modifica il profilo"
-#: include/dbstructure.php:190
-#, php-format
-msgid ""
-"\n"
-"Error %d occurred during database update:\n"
-"%s\n"
-msgstr "\nErrore %d durante l'aggiornamento del database:\n%s\n"
+#: include/identity.php:263
+msgid "Atom feed"
+msgstr "Feed Atom"
-#: include/dbstructure.php:193
-msgid "Errors encountered performing database changes: "
-msgstr "Errori riscontrati eseguendo le modifiche al database:"
+#: include/identity.php:294
+msgid "Manage/edit profiles"
+msgstr "Gestisci/modifica i profili"
-#: include/dbstructure.php:201
-msgid ": Database update"
-msgstr ": Aggiornamento database"
+#: include/identity.php:299 include/identity.php:325 mod/profiles.php:786
+msgid "Change profile photo"
+msgstr "Cambia la foto del profilo"
-#: include/dbstructure.php:425
-#, php-format
-msgid "%s: updating %s table."
-msgstr "%s: aggiornando la tabella %s."
+#: include/identity.php:300 mod/profiles.php:787
+msgid "Create New Profile"
+msgstr "Crea un nuovo profilo"
-#: include/dfrn.php:1251
-#, php-format
-msgid "%s\\'s birthday"
-msgstr "compleanno di %s"
+#: include/identity.php:310 mod/profiles.php:776
+msgid "Profile Image"
+msgstr "Immagine del Profilo"
-#: include/diaspora.php:2137
-msgid "Sharing notification from Diaspora network"
-msgstr "Notifica di condivisione dal network Diaspora*"
+#: include/identity.php:313 mod/profiles.php:778
+msgid "visible to everybody"
+msgstr "visibile a tutti"
-#: include/diaspora.php:3146
-msgid "Attachments:"
-msgstr "Allegati:"
+#: include/identity.php:314 mod/profiles.php:683 mod/profiles.php:779
+msgid "Edit visibility"
+msgstr "Modifica visibilità"
+
+#: include/identity.php:342 include/identity.php:643 mod/notifications.php:253
+#: mod/directory.php:135
+msgid "Gender:"
+msgstr "Genere:"
+
+#: include/identity.php:345 include/identity.php:666 mod/directory.php:137
+msgid "Status:"
+msgstr "Stato:"
+
+#: include/identity.php:347 include/identity.php:683 mod/directory.php:139
+msgid "Homepage:"
+msgstr "Homepage:"
+
+#: include/identity.php:349 include/identity.php:703 mod/notifications.php:249
+#: mod/directory.php:141 mod/contacts.php:662
+msgid "About:"
+msgstr "Informazioni:"
+
+#: include/identity.php:351 mod/contacts.php:660
+msgid "XMPP:"
+msgstr "XMPP:"
+
+#: include/identity.php:437 mod/notifications.php:261 mod/contacts.php:60
+msgid "Network:"
+msgstr "Rete:"
+
+#: include/identity.php:466 include/identity.php:557
+msgid "g A l F d"
+msgstr "g A l d F"
+
+#: include/identity.php:467 include/identity.php:558
+msgid "F d"
+msgstr "d F"
+
+#: include/identity.php:519 include/identity.php:605
+msgid "[today]"
+msgstr "[oggi]"
+
+#: include/identity.php:531
+msgid "Birthday Reminders"
+msgstr "Promemoria compleanni"
+
+#: include/identity.php:532
+msgid "Birthdays this week:"
+msgstr "Compleanni questa settimana:"
+
+#: include/identity.php:592
+msgid "[No description]"
+msgstr "[Nessuna descrizione]"
+
+#: include/identity.php:619
+msgid "Event Reminders"
+msgstr "Promemoria"
+
+#: include/identity.php:620
+msgid "Events this week:"
+msgstr "Eventi di questa settimana:"
+
+#: include/identity.php:640 mod/settings.php:1273
+msgid "Full Name:"
+msgstr "Nome completo:"
+
+#: include/identity.php:647
+msgid "j F, Y"
+msgstr "j F Y"
+
+#: include/identity.php:648
+msgid "j F"
+msgstr "j F"
+
+#: include/identity.php:662
+msgid "Age:"
+msgstr "Età:"
+
+#: include/identity.php:675
+#, php-format
+msgid "for %1$d %2$s"
+msgstr "per %1$d %2$s"
+
+#: include/identity.php:679 mod/profiles.php:702
+msgid "Sexual Preference:"
+msgstr "Preferenze sessuali:"
+
+#: include/identity.php:687 mod/profiles.php:729
+msgid "Hometown:"
+msgstr "Paese natale:"
+
+#: include/identity.php:691 mod/follow.php:174 mod/notifications.php:251
+#: mod/contacts.php:664
+msgid "Tags:"
+msgstr "Tag:"
+
+#: include/identity.php:695 mod/profiles.php:730
+msgid "Political Views:"
+msgstr "Orientamento politico:"
+
+#: include/identity.php:699
+msgid "Religion:"
+msgstr "Religione:"
+
+#: include/identity.php:707
+msgid "Hobbies/Interests:"
+msgstr "Hobby/Interessi:"
+
+#: include/identity.php:711 mod/profiles.php:734
+msgid "Likes:"
+msgstr "Mi piace:"
+
+#: include/identity.php:715 mod/profiles.php:735
+msgid "Dislikes:"
+msgstr "Non mi piace:"
+
+#: include/identity.php:719
+msgid "Contact information and Social Networks:"
+msgstr "Informazioni su contatti e social network:"
+
+#: include/identity.php:723
+msgid "Musical interests:"
+msgstr "Interessi musicali:"
+
+#: include/identity.php:727
+msgid "Books, literature:"
+msgstr "Libri, letteratura:"
+
+#: include/identity.php:731
+msgid "Television:"
+msgstr "Televisione:"
+
+#: include/identity.php:735
+msgid "Film/dance/culture/entertainment:"
+msgstr "Film/danza/cultura/intrattenimento:"
+
+#: include/identity.php:739
+msgid "Love/Romance:"
+msgstr "Amore:"
+
+#: include/identity.php:743
+msgid "Work/employment:"
+msgstr "Lavoro:"
+
+#: include/identity.php:747
+msgid "School/education:"
+msgstr "Scuola:"
+
+#: include/identity.php:752
+msgid "Forums:"
+msgstr "Forum:"
+
+#: include/identity.php:761 mod/events.php:530
+msgid "Basic"
+msgstr "Base"
-#: include/items.php:1738 mod/dfrn_confirm.php:736 mod/dfrn_request.php:759
+#: include/identity.php:762 mod/admin.php:1181 mod/contacts.php:900
+#: mod/events.php:531
+msgid "Advanced"
+msgstr "Avanzate"
+
+#: include/identity.php:788 mod/follow.php:182 mod/unfollow.php:133
+#: mod/contacts.php:866
+msgid "Status Messages and Posts"
+msgstr "Messaggi di stato e post"
+
+#: include/identity.php:796 mod/contacts.php:874
+msgid "Profile Details"
+msgstr "Dettagli del profilo"
+
+#: include/identity.php:804 mod/photos.php:97
+msgid "Photo Albums"
+msgstr "Album foto"
+
+#: include/identity.php:843 mod/notes.php:49
+msgid "Personal Notes"
+msgstr "Note personali"
+
+#: include/identity.php:846
+msgid "Only You Can See This"
+msgstr "Solo tu puoi vedere questo"
+
+#: include/items.php:1731 mod/dfrn_request.php:760 mod/dfrn_confirm.php:739
msgid "[Name Withheld]"
msgstr "[Nome Nascosto]"
-#: include/items.php:2123 mod/display.php:103 mod/display.php:279
-#: mod/display.php:484 mod/notice.php:15 mod/viewsrc.php:15 mod/admin.php:247
-#: mod/admin.php:1565 mod/admin.php:1816
+#: include/items.php:2106 mod/viewsrc.php:16 mod/notice.php:18
+#: mod/admin.php:258 mod/admin.php:1687 mod/admin.php:1938 mod/display.php:106
+#: mod/display.php:279 mod/display.php:487
msgid "Item not found."
msgstr "Elemento non trovato."
-#: include/items.php:2162
+#: include/items.php:2149
msgid "Do you really want to delete this item?"
msgstr "Vuoi veramente cancellare questo elemento?"
-#: include/items.php:2164 mod/api.php:105 mod/contacts.php:452
-#: mod/suggest.php:29 mod/dfrn_request.php:880 mod/follow.php:113
-#: mod/message.php:206 mod/profiles.php:640 mod/profiles.php:643
-#: mod/profiles.php:670 mod/register.php:245 mod/settings.php:1171
-#: mod/settings.php:1177 mod/settings.php:1184 mod/settings.php:1188
-#: mod/settings.php:1193 mod/settings.php:1198 mod/settings.php:1203
-#: mod/settings.php:1208 mod/settings.php:1234 mod/settings.php:1235
-#: mod/settings.php:1236 mod/settings.php:1237 mod/settings.php:1238
+#: include/items.php:2151 mod/api.php:107 mod/dfrn_request.php:881
+#: mod/follow.php:150 mod/message.php:207 mod/suggest.php:32
+#: mod/contacts.php:466 mod/profiles.php:639 mod/profiles.php:642
+#: mod/profiles.php:669 mod/register.php:250 mod/settings.php:1158
+#: mod/settings.php:1164 mod/settings.php:1171 mod/settings.php:1175
+#: mod/settings.php:1180 mod/settings.php:1185 mod/settings.php:1190
+#: mod/settings.php:1195 mod/settings.php:1221 mod/settings.php:1222
+#: mod/settings.php:1223 mod/settings.php:1224 mod/settings.php:1225
msgid "Yes"
msgstr "Si"
-#: include/items.php:2327 mod/allfriends.php:12 mod/api.php:26 mod/api.php:31
-#: mod/attach.php:33 mod/common.php:18 mod/contacts.php:360
-#: mod/crepair.php:102 mod/delegate.php:12 mod/display.php:481
-#: mod/editpost.php:10 mod/fsuggest.php:79 mod/invite.php:15
-#: mod/invite.php:103 mod/mood.php:115 mod/nogroup.php:27 mod/notes.php:23
-#: mod/ostatus_subscribe.php:9 mod/poke.php:154 mod/profile_photo.php:19
-#: mod/profile_photo.php:180 mod/profile_photo.php:191
-#: mod/profile_photo.php:204 mod/regmod.php:113 mod/repair_ostatus.php:9
-#: mod/suggest.php:58 mod/uimport.php:24 mod/viewcontacts.php:46
-#: mod/wall_attach.php:67 mod/wall_attach.php:70 mod/wallmessage.php:9
-#: mod/wallmessage.php:33 mod/wallmessage.php:73 mod/wallmessage.php:97
-#: mod/cal.php:299 mod/dfrn_confirm.php:61 mod/dirfind.php:11
-#: mod/events.php:185 mod/follow.php:11 mod/follow.php:74 mod/follow.php:158
-#: mod/group.php:19 mod/manage.php:102 mod/message.php:46 mod/message.php:171
-#: mod/network.php:4 mod/photos.php:166 mod/photos.php:1109
-#: mod/profiles.php:168 mod/profiles.php:607 mod/register.php:42
-#: mod/settings.php:22 mod/settings.php:130 mod/settings.php:668
-#: mod/wall_upload.php:101 mod/wall_upload.php:104 mod/item.php:196
-#: mod/item.php:208 mod/notifications.php:71 index.php:407
+#: include/items.php:2290 mod/api.php:28 mod/api.php:33 mod/attach.php:35
+#: mod/common.php:20 mod/crepair.php:105 mod/nogroup.php:29
+#: mod/viewcontacts.php:49 mod/uimport.php:26 mod/allfriends.php:15
+#: mod/cal.php:302 mod/editpost.php:13 mod/follow.php:14 mod/follow.php:55
+#: mod/follow.php:118 mod/group.php:21 mod/invite.php:18 mod/invite.php:106
+#: mod/manage.php:104 mod/message.php:49 mod/message.php:172
+#: mod/notifications.php:74 mod/repair_ostatus.php:12 mod/wallmessage.php:12
+#: mod/wallmessage.php:36 mod/wallmessage.php:76 mod/wallmessage.php:100
+#: mod/delegate.php:15 mod/suggest.php:58 mod/unfollow.php:14
+#: mod/unfollow.php:57 mod/unfollow.php:90 mod/contacts.php:374
+#: mod/dfrn_confirm.php:65 mod/dirfind.php:17 mod/display.php:484
+#: mod/events.php:190 mod/fsuggest.php:81 mod/item.php:199 mod/item.php:211
+#: mod/mood.php:118 mod/network.php:17 mod/notes.php:25
+#: mod/ostatus_subscribe.php:12 mod/photos.php:170 mod/photos.php:1095
+#: mod/poke.php:157 mod/profile_photo.php:21 mod/profile_photo.php:181
+#: mod/profile_photo.php:192 mod/profile_photo.php:205 mod/profiles.php:168
+#: mod/profiles.php:606 mod/register.php:47 mod/regmod.php:108
+#: mod/settings.php:28 mod/settings.php:130 mod/settings.php:678
+#: mod/wall_attach.php:69 mod/wall_attach.php:72 mod/wall_upload.php:102
+#: mod/wall_upload.php:105 index.php:412
msgid "Permission denied."
msgstr "Permesso negato."
-#: include/items.php:2444
+#: include/items.php:2407
msgid "Archives"
msgstr "Archivi"
-#: include/ostatus.php:1947
+#: include/like.php:46
+#, php-format
+msgid "%1$s is attending %2$s's %3$s"
+msgstr "%1$s parteciperà a %3$s di %2$s"
+
+#: include/like.php:51
+#, php-format
+msgid "%1$s is not attending %2$s's %3$s"
+msgstr "%1$s non parteciperà a %3$s di %2$s"
+
+#: include/like.php:56
+#, php-format
+msgid "%1$s may attend %2$s's %3$s"
+msgstr "%1$s forse parteciperà a %3$s di %2$s"
+
+#: include/message.php:16 include/message.php:162
+msgid "[no subject]"
+msgstr "[nessun oggetto]"
+
+#: include/network.php:714
+msgid "view full size"
+msgstr "vedi a schermo intero"
+
+#: include/ostatus.php:1713
#, php-format
msgid "%s is now following %s."
msgstr "%s sta seguendo %s"
-#: include/ostatus.php:1948
+#: include/ostatus.php:1714
msgid "following"
msgstr "segue"
-#: include/ostatus.php:1951
+#: include/ostatus.php:1717
#, php-format
msgid "%s stopped following %s."
msgstr "%s ha smesso di seguire %s"
-#: include/ostatus.php:1952
+#: include/ostatus.php:1718
msgid "stopped following"
msgstr "tolto dai seguiti"
-#: include/text.php:307
+#: include/text.php:315
msgid "newer"
msgstr "nuovi"
-#: include/text.php:308
+#: include/text.php:316
msgid "older"
msgstr "vecchi"
-#: include/text.php:313
+#: include/text.php:321
msgid "first"
msgstr "primo"
-#: include/text.php:314
+#: include/text.php:322
msgid "prev"
msgstr "prec"
-#: include/text.php:348
+#: include/text.php:356
msgid "next"
msgstr "succ"
-#: include/text.php:349
+#: include/text.php:357
msgid "last"
msgstr "ultimo"
-#: include/text.php:403
+#: include/text.php:411
msgid "Loading more entries..."
msgstr "Carico più elementi..."
-#: include/text.php:404
+#: include/text.php:412
msgid "The end"
msgstr "Fine"
-#: include/text.php:955
+#: include/text.php:961
msgid "No contacts"
msgstr "Nessun contatto"
-#: include/text.php:980
+#: include/text.php:985
#, php-format
msgid "%d Contact"
msgid_plural "%d Contacts"
msgstr[0] "%d contatto"
msgstr[1] "%d contatti"
-#: include/text.php:993
+#: include/text.php:998
msgid "View Contacts"
msgstr "Visualizza i contatti"
-#: include/text.php:1081 mod/editpost.php:99 mod/filer.php:31 mod/notes.php:62
+#: include/text.php:1088 mod/filer.php:32 mod/editpost.php:102
+#: mod/notes.php:64
msgid "Save"
msgstr "Salva"
-#: include/text.php:1144
+#: include/text.php:1149
msgid "poke"
msgstr "stuzzica"
-#: include/text.php:1144
+#: include/text.php:1149
msgid "poked"
msgstr "ha stuzzicato"
-#: include/text.php:1145
+#: include/text.php:1150
msgid "ping"
msgstr "invia un ping"
-#: include/text.php:1145
+#: include/text.php:1150
msgid "pinged"
msgstr "ha inviato un ping"
-#: include/text.php:1146
+#: include/text.php:1151
msgid "prod"
msgstr "pungola"
-#: include/text.php:1146
+#: include/text.php:1151
msgid "prodded"
msgstr "ha pungolato"
-#: include/text.php:1147
+#: include/text.php:1152
msgid "slap"
msgstr "schiaffeggia"
-#: include/text.php:1147
+#: include/text.php:1152
msgid "slapped"
msgstr "ha schiaffeggiato"
-#: include/text.php:1148
+#: include/text.php:1153
msgid "finger"
msgstr "tocca"
-#: include/text.php:1148
+#: include/text.php:1153
msgid "fingered"
msgstr "ha toccato"
-#: include/text.php:1149
+#: include/text.php:1154
msgid "rebuff"
msgstr "respingi"
-#: include/text.php:1149
+#: include/text.php:1154
msgid "rebuffed"
msgstr "ha respinto"
-#: include/text.php:1163
+#: include/text.php:1168
msgid "happy"
msgstr "felice"
-#: include/text.php:1164
+#: include/text.php:1169
msgid "sad"
msgstr "triste"
-#: include/text.php:1165
+#: include/text.php:1170
msgid "mellow"
msgstr "rilassato"
-#: include/text.php:1166
+#: include/text.php:1171
msgid "tired"
msgstr "stanco"
-#: include/text.php:1167
+#: include/text.php:1172
msgid "perky"
msgstr "vivace"
-#: include/text.php:1168
+#: include/text.php:1173
msgid "angry"
msgstr "arrabbiato"
-#: include/text.php:1169
+#: include/text.php:1174
msgid "stupified"
msgstr "stupefatto"
-#: include/text.php:1170
+#: include/text.php:1175
msgid "puzzled"
msgstr "confuso"
-#: include/text.php:1171
+#: include/text.php:1176
msgid "interested"
msgstr "interessato"
-#: include/text.php:1172
+#: include/text.php:1177
msgid "bitter"
msgstr "risentito"
-#: include/text.php:1173
+#: include/text.php:1178
msgid "cheerful"
msgstr "giocoso"
-#: include/text.php:1174
+#: include/text.php:1179
msgid "alive"
msgstr "vivo"
-#: include/text.php:1175
+#: include/text.php:1180
msgid "annoyed"
msgstr "annoiato"
-#: include/text.php:1176
+#: include/text.php:1181
msgid "anxious"
msgstr "ansioso"
-#: include/text.php:1177
+#: include/text.php:1182
msgid "cranky"
msgstr "irritabile"
-#: include/text.php:1178
+#: include/text.php:1183
msgid "disturbed"
msgstr "disturbato"
-#: include/text.php:1179
+#: include/text.php:1184
msgid "frustrated"
msgstr "frustato"
-#: include/text.php:1180
+#: include/text.php:1185
msgid "motivated"
msgstr "motivato"
-#: include/text.php:1181
+#: include/text.php:1186
msgid "relaxed"
msgstr "rilassato"
-#: include/text.php:1182
+#: include/text.php:1187
msgid "surprised"
msgstr "sorpreso"
-#: include/text.php:1392 mod/videos.php:386
+#: include/text.php:1220
+msgid "Sund"
+msgstr "Dom"
+
+#: include/text.php:1223
+msgid "Sep"
+msgstr "Set"
+
+#: include/text.php:1421 mod/videos.php:390
msgid "View Video"
msgstr "Guarda Video"
-#: include/text.php:1424
+#: include/text.php:1438
msgid "bytes"
msgstr "bytes"
-#: include/text.php:1456 include/text.php:1468
+#: include/text.php:1473 include/text.php:1484
msgid "Click to open/close"
msgstr "Clicca per aprire/chiudere"
-#: include/text.php:1594
+#: include/text.php:1612
msgid "View on separate page"
msgstr "Vedi in una pagina separata"
-#: include/text.php:1595
+#: include/text.php:1613
msgid "view on separate page"
msgstr "vedi in una pagina separata"
-#: include/text.php:1874
+#: include/text.php:1898
msgid "activity"
msgstr "attività"
-#: include/text.php:1876 mod/content.php:623 object/Item.php:419
-#: object/Item.php:431
+#: include/text.php:1900 object/Item.php:416 object/Item.php:428
msgid "comment"
msgid_plural "comments"
-msgstr[0] ""
-msgstr[1] "commento"
+msgstr[0] "commento "
+msgstr[1] "commenti"
-#: include/text.php:1877
+#: include/text.php:1903
msgid "post"
msgstr "messaggio"
-#: include/text.php:2045
+#: include/text.php:2069
msgid "Item filed"
msgstr "Messaggio salvato"
-#: mod/allfriends.php:46
-msgid "No friends to display."
-msgstr "Nessun amico da visualizzare."
+#: include/uimport.php:81
+msgid "Error decoding account file"
+msgstr "Errore decodificando il file account"
-#: mod/api.php:76 mod/api.php:102
-msgid "Authorize application connection"
-msgstr "Autorizza la connessione dell'applicazione"
+#: include/uimport.php:87
+msgid "Error! No version data in file! This is not a Friendica account file?"
+msgstr "Errore! Nessuna informazione di versione nel file! Potrebbe non essere un file account di Friendica?"
-#: mod/api.php:77
-msgid "Return to your app and insert this Securty Code:"
-msgstr "Torna alla tua applicazione e inserisci questo codice di sicurezza:"
+#: include/uimport.php:104 include/uimport.php:115
+msgid "Error! Cannot check nickname"
+msgstr "Errore! Non posso controllare il nickname"
-#: mod/api.php:89
-msgid "Please login to continue."
-msgstr "Effettua il login per continuare."
+#: include/uimport.php:108 include/uimport.php:119
+#, php-format
+msgid "User '%s' already exists on this server!"
+msgstr "L'utente '%s' esiste già su questo server!"
-#: mod/api.php:104
-msgid ""
-"Do you want to authorize this application to access your posts and contacts,"
-" and/or create new posts for you?"
-msgstr "Vuoi autorizzare questa applicazione per accedere ai messaggi e ai contatti, e / o creare nuovi messaggi per te?"
+#: include/uimport.php:151
+msgid "User creation error"
+msgstr "Errore creando l'utente"
-#: mod/api.php:106 mod/dfrn_request.php:880 mod/follow.php:113
-#: mod/profiles.php:640 mod/profiles.php:644 mod/profiles.php:670
-#: mod/register.php:246 mod/settings.php:1171 mod/settings.php:1177
-#: mod/settings.php:1184 mod/settings.php:1188 mod/settings.php:1193
-#: mod/settings.php:1198 mod/settings.php:1203 mod/settings.php:1208
-#: mod/settings.php:1234 mod/settings.php:1235 mod/settings.php:1236
-#: mod/settings.php:1237 mod/settings.php:1238
-msgid "No"
-msgstr "No"
+#: include/uimport.php:174
+msgid "User profile creation error"
+msgstr "Errore creando il profilo dell'utente"
-#: mod/apps.php:7 index.php:254
-msgid "You must be logged in to use addons. "
-msgstr "Devi aver effettuato il login per usare i componenti aggiuntivi."
+#: include/uimport.php:224
+#, php-format
+msgid "%d contact not imported"
+msgid_plural "%d contacts not imported"
+msgstr[0] "%d contatto non importato"
+msgstr[1] "%d contatti non importati"
-#: mod/apps.php:11
-msgid "Applications"
-msgstr "Applicazioni"
+#: include/uimport.php:290
+msgid "Done. You can now login with your username and password"
+msgstr "Fatto. Ora puoi entrare con il tuo nome utente e la tua password"
-#: mod/apps.php:14
-msgid "No installed applications."
-msgstr "Nessuna applicazione installata."
+#: include/user.php:41 mod/settings.php:373
+msgid "Passwords do not match. Password unchanged."
+msgstr "Le password non corrispondono. Password non cambiata."
-#: mod/attach.php:8
-msgid "Item not available."
-msgstr "Oggetto non disponibile."
+#: include/user.php:50
+msgid "An invitation is required."
+msgstr "E' richiesto un invito."
-#: mod/attach.php:20
-msgid "Item was not found."
-msgstr "Oggetto non trovato."
+#: include/user.php:55
+msgid "Invitation could not be verified."
+msgstr "L'invito non puo' essere verificato."
-#: mod/bookmarklet.php:41
-msgid "The post was created"
-msgstr "Il messaggio è stato creato"
+#: include/user.php:63
+msgid "Invalid OpenID url"
+msgstr "Url OpenID non valido"
-#: mod/common.php:91
-msgid "No contacts in common."
-msgstr "Nessun contatto in comune."
+#: include/user.php:84
+msgid "Please enter the required information."
+msgstr "Inserisci le informazioni richieste."
-#: mod/common.php:141 mod/contacts.php:871
-msgid "Common Friends"
-msgstr "Amici in comune"
+#: include/user.php:98
+msgid "Please use a shorter name."
+msgstr "Usa un nome più corto."
-#: mod/contacts.php:134
-#, php-format
-msgid "%d contact edited."
-msgid_plural "%d contacts edited."
-msgstr[0] "%d contatto modificato."
-msgstr[1] "%d contatti modificati"
+#: include/user.php:100
+msgid "Name too short."
+msgstr "Il nome è troppo corto."
-#: mod/contacts.php:169 mod/contacts.php:378
-msgid "Could not access contact record."
-msgstr "Non è possibile accedere al contatto."
+#: include/user.php:108
+msgid "That doesn't appear to be your full (First Last) name."
+msgstr "Questo non sembra essere il tuo nome completo (Nome Cognome)."
-#: mod/contacts.php:183
-msgid "Could not locate selected profile."
-msgstr "Non riesco a trovare il profilo selezionato."
+#: include/user.php:113
+msgid "Your email domain is not among those allowed on this site."
+msgstr "Il dominio della tua email non è tra quelli autorizzati su questo sito."
-#: mod/contacts.php:216
-msgid "Contact updated."
-msgstr "Contatto aggiornato."
+#: include/user.php:116
+msgid "Not a valid email address."
+msgstr "L'indirizzo email non è valido."
-#: mod/contacts.php:218 mod/dfrn_request.php:593
-msgid "Failed to update contact record."
-msgstr "Errore nell'aggiornamento del contatto."
+#: include/user.php:129
+msgid "Cannot use that email."
+msgstr "Non puoi usare quell'email."
-#: mod/contacts.php:399
-msgid "Contact has been blocked"
-msgstr "Il contatto è stato bloccato"
+#: include/user.php:135
+msgid "Your \"nickname\" can only contain \"a-z\", \"0-9\" and \"_\"."
+msgstr "Il tuo nome utente può contenere solo \"a-z\", \"0-9\", e \"_\"."
-#: mod/contacts.php:399
-msgid "Contact has been unblocked"
-msgstr "Il contatto è stato sbloccato"
+#: include/user.php:142 include/user.php:224
+msgid "Nickname is already registered. Please choose another."
+msgstr "Nome utente già registrato. Scegline un altro."
-#: mod/contacts.php:410
-msgid "Contact has been ignored"
-msgstr "Il contatto è ignorato"
+#: include/user.php:152
+msgid ""
+"Nickname was once registered here and may not be re-used. Please choose "
+"another."
+msgstr "Questo nome utente stato già registrato. Per favore, sceglierne uno nuovo."
-#: mod/contacts.php:410
-msgid "Contact has been unignored"
-msgstr "Il contatto non è più ignorato"
+#: include/user.php:168
+msgid "SERIOUS ERROR: Generation of security keys failed."
+msgstr "ERRORE GRAVE: La generazione delle chiavi di sicurezza è fallita."
-#: mod/contacts.php:422
-msgid "Contact has been archived"
-msgstr "Il contatto è stato archiviato"
+#: include/user.php:210
+msgid "An error occurred during registration. Please try again."
+msgstr "C'è stato un errore durante la registrazione. Prova ancora."
-#: mod/contacts.php:422
-msgid "Contact has been unarchived"
-msgstr "Il contatto è stato dearchiviato"
+#: include/user.php:233 view/theme/duepuntozero/config.php:47
+msgid "default"
+msgstr "default"
-#: mod/contacts.php:447
-msgid "Drop contact"
-msgstr "Cancella contatto"
+#: include/user.php:243
+msgid "An error occurred creating your default profile. Please try again."
+msgstr "C'è stato un errore nella creazione del tuo profilo. Prova ancora."
-#: mod/contacts.php:450 mod/contacts.php:809
-msgid "Do you really want to delete this contact?"
-msgstr "Vuoi veramente cancellare questo contatto?"
+#: include/user.php:393
+#, php-format
+msgid ""
+"\n"
+"\t\tDear %1$s,\n"
+"\t\t\tThank you for registering at %2$s. Your account is pending for approval by the administrator.\n"
+"\t"
+msgstr "\nCaro %1$s,\n Grazie per la tua registrazione su %2$s. Il tuo account è in attesa di approvazione da parte di un amministratore.\n "
-#: mod/contacts.php:469
-msgid "Contact has been removed."
-msgstr "Il contatto è stato rimosso."
+#: include/user.php:403
+#, php-format
+msgid "Registration at %s"
+msgstr "Registrazione su %s"
-#: mod/contacts.php:506
+#: include/user.php:413
#, php-format
-msgid "You are mutual friends with %s"
-msgstr "Sei amico reciproco con %s"
+msgid ""
+"\n"
+"\t\tDear %1$s,\n"
+"\t\t\tThank you for registering at %2$s. Your account has been created.\n"
+"\t"
+msgstr "\nGentile %1$s,\nGrazie per esserti registrato su %2$s. Il tuo account è stato creato."
-#: mod/contacts.php:510
+#: include/user.php:417
#, php-format
-msgid "You are sharing with %s"
-msgstr "Stai condividendo con %s"
+msgid ""
+"\n"
+"\t\tThe login details are as follows:\n"
+"\t\t\tSite Location:\t%3$s\n"
+"\t\t\tLogin Name:\t%1$s\n"
+"\t\t\tPassword:\t%5$s\n"
+"\n"
+"\t\tYou may change your password from your account \"Settings\" page after logging\n"
+"\t\tin.\n"
+"\n"
+"\t\tPlease take a few moments to review the other account settings on that page.\n"
+"\n"
+"\t\tYou may also wish to add some basic information to your default profile\n"
+"\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
+"\n"
+"\t\tWe recommend setting your full name, adding a profile photo,\n"
+"\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n"
+"\t\tperhaps what country you live in; if you do not wish to be more specific\n"
+"\t\tthan that.\n"
+"\n"
+"\t\tWe fully respect your right to privacy, and none of these items are necessary.\n"
+"\t\tIf you are new and do not know anybody here, they may help\n"
+"\t\tyou to make some new and interesting friends.\n"
+"\n"
+"\n"
+"\t\tThank you and welcome to %2$s."
+msgstr "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %3$s\n Nome utente: %1$s\n Password: %5$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %2$s"
-#: mod/contacts.php:515
+#: include/user.php:449 mod/admin.php:1430
#, php-format
-msgid "%s is sharing with you"
-msgstr "%s sta condividendo con te"
+msgid "Registration details for %s"
+msgstr "Dettagli della registrazione di %s"
-#: mod/contacts.php:535
-msgid "Private communications are not available for this contact."
-msgstr "Le comunicazioni private non sono disponibili per questo contatto."
+#: mod/api.php:78 mod/api.php:104
+msgid "Authorize application connection"
+msgstr "Autorizza la connessione dell'applicazione"
-#: mod/contacts.php:538 mod/admin.php:978
-msgid "Never"
-msgstr "Mai"
+#: mod/api.php:79
+msgid "Return to your app and insert this Securty Code:"
+msgstr "Torna alla tua applicazione e inserisci questo codice di sicurezza:"
-#: mod/contacts.php:542
-msgid "(Update was successful)"
-msgstr "(L'aggiornamento è stato completato)"
+#: mod/api.php:91
+msgid "Please login to continue."
+msgstr "Effettua il login per continuare."
-#: mod/contacts.php:542
-msgid "(Update was not successful)"
-msgstr "(L'aggiornamento non è stato completato)"
+#: mod/api.php:106
+msgid ""
+"Do you want to authorize this application to access your posts and contacts,"
+" and/or create new posts for you?"
+msgstr "Vuoi autorizzare questa applicazione per accedere ai messaggi e ai contatti, e / o creare nuovi messaggi per te?"
-#: mod/contacts.php:544 mod/contacts.php:972
-msgid "Suggest friends"
-msgstr "Suggerisci amici"
+#: mod/api.php:108 mod/dfrn_request.php:881 mod/follow.php:150
+#: mod/profiles.php:639 mod/profiles.php:643 mod/profiles.php:669
+#: mod/register.php:251 mod/settings.php:1158 mod/settings.php:1164
+#: mod/settings.php:1171 mod/settings.php:1175 mod/settings.php:1180
+#: mod/settings.php:1185 mod/settings.php:1190 mod/settings.php:1195
+#: mod/settings.php:1221 mod/settings.php:1222 mod/settings.php:1223
+#: mod/settings.php:1224 mod/settings.php:1225
+msgid "No"
+msgstr "No"
-#: mod/contacts.php:548
-#, php-format
-msgid "Network type: %s"
-msgstr "Tipo di rete: %s"
+#: mod/apps.php:9 index.php:259
+msgid "You must be logged in to use addons. "
+msgstr "Devi aver effettuato il login per usare i componenti aggiuntivi."
-#: mod/contacts.php:561
-msgid "Communications lost with this contact!"
-msgstr "Comunicazione con questo contatto persa!"
+#: mod/apps.php:14
+msgid "Applications"
+msgstr "Applicazioni"
-#: mod/contacts.php:564
-msgid "Fetch further information for feeds"
-msgstr "Recupera maggiori informazioni per i feed"
+#: mod/apps.php:17
+msgid "No installed applications."
+msgstr "Nessuna applicazione installata."
-#: mod/contacts.php:565 mod/admin.php:987
-msgid "Disabled"
-msgstr "Disabilitato"
+#: mod/attach.php:10
+msgid "Item not available."
+msgstr "Oggetto non disponibile."
-#: mod/contacts.php:565
-msgid "Fetch information"
-msgstr "Recupera informazioni"
+#: mod/attach.php:22
+msgid "Item was not found."
+msgstr "Oggetto non trovato."
-#: mod/contacts.php:565
-msgid "Fetch information and keywords"
-msgstr "Recupera informazioni e parole chiave"
+#: mod/babel.php:18
+msgid "Source (bbcode) text:"
+msgstr "Testo sorgente (bbcode):"
-#: mod/contacts.php:583
-msgid "Contact"
-msgstr "Contatto"
+#: mod/babel.php:25
+msgid "Source (Diaspora) text to convert to BBcode:"
+msgstr "Testo sorgente (da Diaspora) da convertire in BBcode:"
-#: mod/contacts.php:585 mod/content.php:728 mod/crepair.php:156
-#: mod/fsuggest.php:108 mod/invite.php:142 mod/localtime.php:45
-#: mod/mood.php:138 mod/poke.php:203 mod/events.php:505 mod/manage.php:155
-#: mod/message.php:338 mod/message.php:521 mod/photos.php:1141
-#: mod/photos.php:1271 mod/photos.php:1597 mod/photos.php:1646
-#: mod/photos.php:1688 mod/photos.php:1768 mod/profiles.php:681
-#: mod/install.php:242 mod/install.php:282 object/Item.php:705
-#: view/theme/duepuntozero/config.php:61 view/theme/frio/config.php:64
-#: view/theme/quattro/config.php:67 view/theme/vier/config.php:112
-msgid "Submit"
-msgstr "Invia"
+#: mod/babel.php:33
+msgid "Source input: "
+msgstr "Sorgente:"
-#: mod/contacts.php:586
-msgid "Profile Visibility"
-msgstr "Visibilità del profilo"
+#: mod/babel.php:37
+msgid "bb2html (raw HTML): "
+msgstr "bb2html (HTML grezzo):"
-#: mod/contacts.php:587
-#, php-format
-msgid ""
-"Please choose the profile you would like to display to %s when viewing your "
-"profile securely."
-msgstr "Seleziona il profilo che vuoi mostrare a %s quando visita il tuo profilo in modo sicuro."
+#: mod/babel.php:41
+msgid "bb2html: "
+msgstr "bb2html:"
-#: mod/contacts.php:588
-msgid "Contact Information / Notes"
-msgstr "Informazioni / Note sul contatto"
+#: mod/babel.php:45
+msgid "bb2html2bb: "
+msgstr "bb2html2bb: "
-#: mod/contacts.php:589
-msgid "Edit contact notes"
-msgstr "Modifica note contatto"
+#: mod/babel.php:49
+msgid "bb2md: "
+msgstr "bb2md: "
-#: mod/contacts.php:594 mod/contacts.php:938 mod/nogroup.php:43
-#: mod/viewcontacts.php:102
-#, php-format
-msgid "Visit %s's profile [%s]"
-msgstr "Visita il profilo di %s [%s]"
+#: mod/babel.php:53
+msgid "bb2md2html: "
+msgstr "bb2md2html: "
-#: mod/contacts.php:595
-msgid "Block/Unblock contact"
-msgstr "Blocca/Sblocca contatto"
+#: mod/babel.php:57
+msgid "bb2dia2bb: "
+msgstr "bb2dia2bb: "
-#: mod/contacts.php:596
-msgid "Ignore contact"
-msgstr "Ignora il contatto"
+#: mod/babel.php:61
+msgid "bb2md2html2bb: "
+msgstr "bb2md2html2bb: "
-#: mod/contacts.php:597
-msgid "Repair URL settings"
-msgstr "Impostazioni riparazione URL"
+#: mod/babel.php:67
+msgid "Source input (Diaspora format): "
+msgstr "Sorgente (formato Diaspora):"
-#: mod/contacts.php:598
-msgid "View conversations"
-msgstr "Vedi conversazioni"
+#: mod/babel.php:71
+msgid "diaspora2bb: "
+msgstr "diaspora2bb: "
-#: mod/contacts.php:604
-msgid "Last update:"
-msgstr "Ultimo aggiornamento:"
+#: mod/common.php:93
+msgid "No contacts in common."
+msgstr "Nessun contatto in comune."
-#: mod/contacts.php:606
-msgid "Update public posts"
-msgstr "Aggiorna messaggi pubblici"
+#: mod/common.php:143 mod/contacts.php:893
+msgid "Common Friends"
+msgstr "Amici in comune"
-#: mod/contacts.php:608 mod/contacts.php:982
-msgid "Update now"
-msgstr "Aggiorna adesso"
+#: mod/credits.php:19
+msgid "Credits"
+msgstr "Crediti"
-#: mod/contacts.php:613 mod/contacts.php:813 mod/contacts.php:991
-#: mod/admin.php:1510
-msgid "Unblock"
-msgstr "Sblocca"
+#: mod/credits.php:20
+msgid ""
+"Friendica is a community project, that would not be possible without the "
+"help of many people. Here is a list of those who have contributed to the "
+"code or the translation of Friendica. Thank you all!"
+msgstr "Friendica è un progetto comunitario, che non sarebbe stato possibile realizzare senza l'aiuto di molte persone.\nQuesta è una lista di chi ha contribuito al codice o alle traduzioni di Friendica. Grazie a tutti!"
-#: mod/contacts.php:613 mod/contacts.php:813 mod/contacts.php:991
-#: mod/admin.php:1509
-msgid "Block"
-msgstr "Blocca"
+#: mod/crepair.php:92
+msgid "Contact settings applied."
+msgstr "Contatto modificato."
-#: mod/contacts.php:614 mod/contacts.php:814 mod/contacts.php:999
-msgid "Unignore"
-msgstr "Non ignorare"
+#: mod/crepair.php:94
+msgid "Contact update failed."
+msgstr "Le modifiche al contatto non sono state salvate."
-#: mod/contacts.php:614 mod/contacts.php:814 mod/contacts.php:999
-#: mod/notifications.php:60 mod/notifications.php:179
-#: mod/notifications.php:263
-msgid "Ignore"
-msgstr "Ignora"
+#: mod/crepair.php:119 mod/dfrn_confirm.php:130 mod/fsuggest.php:23
+#: mod/fsuggest.php:95
+msgid "Contact not found."
+msgstr "Contatto non trovato."
-#: mod/contacts.php:618
-msgid "Currently blocked"
-msgstr "Bloccato"
+#: mod/crepair.php:125
+msgid ""
+"<strong>WARNING: This is highly advanced</strong> and if you enter incorrect"
+" information your communications with this contact may stop working."
+msgstr "<strong>ATTENZIONE: Queste sono impostazioni avanzate</strong> e se inserisci informazioni errate le tue comunicazioni con questo contatto potrebbero non funzionare più"
-#: mod/contacts.php:619
-msgid "Currently ignored"
-msgstr "Ignorato"
+#: mod/crepair.php:126
+msgid ""
+"Please use your browser 'Back' button <strong>now</strong> if you are "
+"uncertain what to do on this page."
+msgstr "Usa <strong>ora</strong> il tasto 'Indietro' del tuo browser se non sei sicuro di cosa fare in questa pagina."
-#: mod/contacts.php:620
-msgid "Currently archived"
-msgstr "Al momento archiviato"
+#: mod/crepair.php:139 mod/crepair.php:141
+msgid "No mirroring"
+msgstr "Non duplicare"
-#: mod/contacts.php:621 mod/notifications.php:172 mod/notifications.php:251
-msgid "Hide this contact from others"
-msgstr "Nascondi questo contatto agli altri"
+#: mod/crepair.php:139
+msgid "Mirror as forwarded posting"
+msgstr "Duplica come messaggi ricondivisi"
-#: mod/contacts.php:621
-msgid ""
-"Replies/likes to your public posts <strong>may</strong> still be visible"
-msgstr "Risposte ai tuoi post pubblici <strong>possono</strong> essere comunque visibili"
+#: mod/crepair.php:139 mod/crepair.php:141
+msgid "Mirror as my own posting"
+msgstr "Duplica come miei messaggi"
-#: mod/contacts.php:622
-msgid "Notification for new posts"
-msgstr "Notifica per i nuovi messaggi"
+#: mod/crepair.php:155
+msgid "Return to contact editor"
+msgstr "Ritorna alla modifica contatto"
-#: mod/contacts.php:622
-msgid "Send a notification of every new post of this contact"
-msgstr "Invia una notifica per ogni nuovo messaggio di questo contatto"
+#: mod/crepair.php:157
+msgid "Refetch contact data"
+msgstr "Ricarica dati contatto"
-#: mod/contacts.php:625
-msgid "Blacklisted keywords"
-msgstr "Parole chiave in blacklist"
+#: mod/crepair.php:159 mod/invite.php:150 mod/localtime.php:47
+#: mod/manage.php:157 mod/message.php:338 mod/message.php:521
+#: mod/install.php:243 mod/install.php:283 mod/contacts.php:605
+#: mod/events.php:529 mod/fsuggest.php:110 mod/mood.php:141
+#: mod/photos.php:1127 mod/photos.php:1248 mod/photos.php:1574
+#: mod/photos.php:1623 mod/photos.php:1665 mod/photos.php:1745
+#: mod/poke.php:206 mod/profiles.php:680 object/Item.php:702
+#: view/theme/duepuntozero/config.php:65 view/theme/frio/config.php:108
+#: view/theme/quattro/config.php:71 view/theme/vier/config.php:114
+msgid "Submit"
+msgstr "Invia"
-#: mod/contacts.php:625
-msgid ""
-"Comma separated list of keywords that should not be converted to hashtags, "
-"when \"Fetch information and keywords\" is selected"
-msgstr "Lista separata da virgola di parole chiave che non dovranno essere convertite in hashtag, quando \"Recupera informazioni e parole chiave\" è selezionato"
+#: mod/crepair.php:161
+msgid "Remote Self"
+msgstr "Io remoto"
-#: mod/contacts.php:632 mod/follow.php:129 mod/notifications.php:255
-msgid "Profile URL"
-msgstr "URL Profilo"
+#: mod/crepair.php:164
+msgid "Mirror postings from this contact"
+msgstr "Ripeti i messaggi di questo contatto"
-#: mod/contacts.php:643
-msgid "Actions"
-msgstr "Azioni"
+#: mod/crepair.php:166
+msgid ""
+"Mark this contact as remote_self, this will cause friendica to repost new "
+"entries from this contact."
+msgstr "Imposta questo contatto come 'io remoto', questo farà si che friendica re invii i nuovi messaggi da questo contatto."
-#: mod/contacts.php:646
-msgid "Contact Settings"
-msgstr "Impostazioni Contatto"
+#: mod/crepair.php:170 mod/admin.php:1612 mod/admin.php:1625
+#: mod/admin.php:1638 mod/admin.php:1654 mod/settings.php:693
+#: mod/settings.php:719
+msgid "Name"
+msgstr "Nome"
-#: mod/contacts.php:692
-msgid "Suggestions"
-msgstr "Suggerimenti"
+#: mod/crepair.php:171
+msgid "Account Nickname"
+msgstr "Nome utente"
-#: mod/contacts.php:695
-msgid "Suggest potential friends"
-msgstr "Suggerisci potenziali amici"
+#: mod/crepair.php:172
+msgid "@Tagname - overrides Name/Nickname"
+msgstr "@TagName - al posto del nome utente"
-#: mod/contacts.php:700 mod/group.php:212
-msgid "All Contacts"
-msgstr "Tutti i contatti"
+#: mod/crepair.php:173
+msgid "Account URL"
+msgstr "URL dell'utente"
-#: mod/contacts.php:703
-msgid "Show all contacts"
-msgstr "Mostra tutti i contatti"
+#: mod/crepair.php:174
+msgid "Friend Request URL"
+msgstr "URL Richiesta Amicizia"
-#: mod/contacts.php:708
-msgid "Unblocked"
-msgstr "Sbloccato"
+#: mod/crepair.php:175
+msgid "Friend Confirm URL"
+msgstr "URL Conferma Amicizia"
-#: mod/contacts.php:711
-msgid "Only show unblocked contacts"
-msgstr "Mostra solo contatti non bloccati"
+#: mod/crepair.php:176
+msgid "Notification Endpoint URL"
+msgstr "URL Notifiche"
-#: mod/contacts.php:717
-msgid "Blocked"
-msgstr "Bloccato"
+#: mod/crepair.php:177
+msgid "Poll/Feed URL"
+msgstr "URL Feed"
-#: mod/contacts.php:720
-msgid "Only show blocked contacts"
-msgstr "Mostra solo contatti bloccati"
+#: mod/crepair.php:178
+msgid "New photo from this URL"
+msgstr "Nuova foto da questo URL"
-#: mod/contacts.php:726
-msgid "Ignored"
-msgstr "Ignorato"
+#: mod/filer.php:31
+msgid "- select -"
+msgstr "- seleziona -"
-#: mod/contacts.php:729
-msgid "Only show ignored contacts"
-msgstr "Mostra solo contatti ignorati"
+#: mod/lockview.php:33 mod/lockview.php:41
+msgid "Remote privacy information not available."
+msgstr "Informazioni remote sulla privacy non disponibili."
-#: mod/contacts.php:735
-msgid "Archived"
-msgstr "Archiviato"
+#: mod/lockview.php:50
+msgid "Visible to:"
+msgstr "Visibile a:"
-#: mod/contacts.php:738
-msgid "Only show archived contacts"
-msgstr "Mostra solo contatti archiviati"
+#: mod/maintenance.php:21
+msgid "System down for maintenance"
+msgstr "Sistema in manutenzione"
-#: mod/contacts.php:744
-msgid "Hidden"
-msgstr "Nascosto"
+#: mod/newmember.php:7
+msgid "Welcome to Friendica"
+msgstr "Benvenuto su Friendica"
-#: mod/contacts.php:747
-msgid "Only show hidden contacts"
-msgstr "Mostra solo contatti nascosti"
+#: mod/newmember.php:8
+msgid "New Member Checklist"
+msgstr "Cose da fare per i Nuovi Utenti"
-#: mod/contacts.php:804
-msgid "Search your contacts"
-msgstr "Cerca nei tuoi contatti"
+#: mod/newmember.php:10
+msgid ""
+"We would like to offer some tips and links to help make your experience "
+"enjoyable. Click any item to visit the relevant page. A link to this page "
+"will be visible from your home page for two weeks after your initial "
+"registration and then will quietly disappear."
+msgstr "Vorremmo offrirti qualche trucco e dei link alla guida per aiutarti ad avere un'esperienza divertente. Clicca su un qualsiasi elemento per visitare la relativa pagina. Un link a questa pagina sarà visibile nella tua home per due settimane dopo la tua registrazione."
-#: mod/contacts.php:805 mod/network.php:151 mod/search.php:227
-#, php-format
-msgid "Results for: %s"
-msgstr "Risultati per: %s"
+#: mod/newmember.php:11
+msgid "Getting Started"
+msgstr "Come Iniziare"
-#: mod/contacts.php:812 mod/settings.php:160 mod/settings.php:707
-msgid "Update"
-msgstr "Aggiorna"
+#: mod/newmember.php:13
+msgid "Friendica Walk-Through"
+msgstr "Friendica Passo-Passo"
-#: mod/contacts.php:815 mod/contacts.php:1007
-msgid "Archive"
-msgstr "Archivia"
+#: mod/newmember.php:13
+msgid ""
+"On your <em>Quick Start</em> page - find a brief introduction to your "
+"profile and network tabs, make some new connections, and find some groups to"
+" join."
+msgstr "Sulla tua pagina <em>Quick Start</em> - veloce introduzione alla tua pagina profilo e alla pagina Rete, fai qualche nuova amicizia, e trova qualche gruppo a cui unirti."
-#: mod/contacts.php:815 mod/contacts.php:1007
-msgid "Unarchive"
-msgstr "Dearchivia"
+#: mod/newmember.php:17
+msgid "Go to Your Settings"
+msgstr "Vai alle tue Impostazioni"
-#: mod/contacts.php:818
-msgid "Batch Actions"
-msgstr "Azioni Batch"
+#: mod/newmember.php:17
+msgid ""
+"On your <em>Settings</em> page - change your initial password. Also make a "
+"note of your Identity Address. This looks just like an email address - and "
+"will be useful in making friends on the free social web."
+msgstr "Nella tua pagina <em>Impostazioni</em> - cambia la tua password iniziale. Prendi anche nota del tuo Indirizzo Identità. Assomiglia a un indirizzo email e sarà utile per stringere amicizie nel web sociale libero."
-#: mod/contacts.php:864
-msgid "View all contacts"
-msgstr "Vedi tutti i contatti"
+#: mod/newmember.php:18
+msgid ""
+"Review the other settings, particularly the privacy settings. An unpublished"
+" directory listing is like having an unlisted phone number. In general, you "
+"should probably publish your listing - unless all of your friends and "
+"potential friends know exactly how to find you."
+msgstr "Guarda le altre impostazioni, in particolare le impostazioni della privacy. Un profilo non pubblicato è come un numero di telefono non in elenco. In genere, dovresti pubblicare il tuo profilo - a meno che tutti i tuoi amici e potenziali tali sappiano esattamente come trovarti."
-#: mod/contacts.php:874
-msgid "View all common friends"
-msgstr "Vedi tutti gli amici in comune"
+#: mod/newmember.php:22 mod/profile_photo.php:257 mod/profiles.php:699
+msgid "Upload Profile Photo"
+msgstr "Carica la foto del profilo"
-#: mod/contacts.php:881
-msgid "Advanced Contact Settings"
-msgstr "Impostazioni avanzate Contatto"
+#: mod/newmember.php:22
+msgid ""
+"Upload a profile photo if you have not done so already. Studies have shown "
+"that people with real photos of themselves are ten times more likely to make"
+" friends than people who do not."
+msgstr "Carica una foto del profilo se non l'hai ancora fatto. Studi hanno mostrato che persone che hanno vere foto di se stessi hanno dieci volte più probabilità di fare amicizie rispetto alle persone che non ce l'hanno."
-#: mod/contacts.php:915
-msgid "Mutual Friendship"
-msgstr "Amicizia reciproca"
+#: mod/newmember.php:23
+msgid "Edit Your Profile"
+msgstr "Modifica il tuo Profilo"
-#: mod/contacts.php:919
-msgid "is a fan of yours"
-msgstr "è un tuo fan"
+#: mod/newmember.php:23
+msgid ""
+"Edit your <strong>default</strong> profile to your liking. Review the "
+"settings for hiding your list of friends and hiding the profile from unknown"
+" visitors."
+msgstr "Modifica il tuo profilo <strong>predefinito</strong> a piacimento. Rivedi le impostazioni per nascondere la tua lista di amici e nascondere il profilo ai visitatori sconosciuti."
-#: mod/contacts.php:923
-msgid "you are a fan of"
-msgstr "sei un fan di"
+#: mod/newmember.php:24
+msgid "Profile Keywords"
+msgstr "Parole chiave del profilo"
-#: mod/contacts.php:939 mod/nogroup.php:44
-msgid "Edit contact"
-msgstr "Modifica contatto"
+#: mod/newmember.php:24
+msgid ""
+"Set some public keywords for your default profile which describe your "
+"interests. We may be able to find other people with similar interests and "
+"suggest friendships."
+msgstr "Inserisci qualche parola chiave pubblica nel tuo profilo predefinito che descriva i tuoi interessi. Potremmo essere in grado di trovare altre persone con interessi similari e suggerirti delle amicizie."
-#: mod/contacts.php:993
-msgid "Toggle Blocked status"
-msgstr "Inverti stato \"Blocca\""
+#: mod/newmember.php:26
+msgid "Connecting"
+msgstr "Collegarsi"
-#: mod/contacts.php:1001
-msgid "Toggle Ignored status"
-msgstr "Inverti stato \"Ignora\""
+#: mod/newmember.php:32
+msgid "Importing Emails"
+msgstr "Importare le Email"
-#: mod/contacts.php:1009
-msgid "Toggle Archive status"
-msgstr "Inverti stato \"Archiviato\""
+#: mod/newmember.php:32
+msgid ""
+"Enter your email access information on your Connector Settings page if you "
+"wish to import and interact with friends or mailing lists from your email "
+"INBOX"
+msgstr "Inserisci i tuoi dati di accesso all'email nella tua pagina Impostazioni Connettori se vuoi importare e interagire con amici o mailing list dalla tua casella di posta in arrivo"
-#: mod/contacts.php:1017
-msgid "Delete contact"
-msgstr "Rimuovi contatto"
+#: mod/newmember.php:35
+msgid "Go to Your Contacts Page"
+msgstr "Vai alla tua pagina Contatti"
-#: mod/content.php:119 mod/network.php:475
-msgid "No such group"
-msgstr "Nessun gruppo"
+#: mod/newmember.php:35
+msgid ""
+"Your Contacts page is your gateway to managing friendships and connecting "
+"with friends on other networks. Typically you enter their address or site "
+"URL in the <em>Add New Contact</em> dialog."
+msgstr "La tua pagina Contatti è il mezzo per gestire le amicizie e collegarsi con amici su altre reti. Di solito, basta inserire l'indirizzo nel campo <em>Aggiungi Nuovo Contatto</em>"
-#: mod/content.php:130 mod/group.php:213 mod/network.php:502
-msgid "Group is empty"
-msgstr "Il gruppo è vuoto"
+#: mod/newmember.php:36
+msgid "Go to Your Site's Directory"
+msgstr "Vai all'Elenco del tuo sito"
-#: mod/content.php:135 mod/network.php:506
-#, php-format
-msgid "Group: %s"
-msgstr "Gruppo: %s"
+#: mod/newmember.php:36
+msgid ""
+"The Directory page lets you find other people in this network or other "
+"federated sites. Look for a <em>Connect</em> or <em>Follow</em> link on "
+"their profile page. Provide your own Identity Address if requested."
+msgstr "La pagina Elenco ti permette di trovare altre persone in questa rete o in altri siti. Cerca un link <em>Connetti</em> o <em>Segui</em> nella loro pagina del profilo. Inserisci il tuo Indirizzo Identità, se richiesto."
-#: mod/content.php:325 object/Item.php:96
-msgid "This entry was edited"
-msgstr "Questa voce è stata modificata"
+#: mod/newmember.php:37
+msgid "Finding New People"
+msgstr "Trova nuove persone"
-#: mod/content.php:621 object/Item.php:417
-#, php-format
-msgid "%d comment"
-msgid_plural "%d comments"
-msgstr[0] "%d commento"
-msgstr[1] "%d commenti"
+#: mod/newmember.php:37
+msgid ""
+"On the side panel of the Contacts page are several tools to find new "
+"friends. We can match people by interest, look up people by name or "
+"interest, and provide suggestions based on network relationships. On a brand"
+" new site, friend suggestions will usually begin to be populated within 24 "
+"hours."
+msgstr "Nel pannello laterale nella pagina \"Contatti\", ci sono diversi strumenti per trovare nuovi amici. Possiamo confrontare le persone per interessi, cercare le persone per nome e fornire suggerimenti basati sui tuoi contatti esistenti. Su un sito nuovo, i suggerimenti sono di solito presenti dopo 24 ore."
-#: mod/content.php:638 mod/photos.php:1429 object/Item.php:117
-msgid "Private Message"
-msgstr "Messaggio privato"
+#: mod/newmember.php:41
+msgid "Group Your Contacts"
+msgstr "Raggruppa i tuoi contatti"
-#: mod/content.php:702 mod/photos.php:1625 object/Item.php:274
-msgid "I like this (toggle)"
-msgstr "Mi piace (clic per cambiare)"
+#: mod/newmember.php:41
+msgid ""
+"Once you have made some friends, organize them into private conversation "
+"groups from the sidebar of your Contacts page and then you can interact with"
+" each group privately on your Network page."
+msgstr "Quando avrai alcuni amici, organizzali in gruppi di conversazioni private dalla barra laterale della tua pagina Contatti. Potrai interagire privatamente con ogni gruppo nella tua pagina Rete"
-#: mod/content.php:702 object/Item.php:274
-msgid "like"
-msgstr "mi piace"
+#: mod/newmember.php:44
+msgid "Why Aren't My Posts Public?"
+msgstr "Perché i miei post non sono pubblici?"
-#: mod/content.php:703 mod/photos.php:1626 object/Item.php:275
-msgid "I don't like this (toggle)"
-msgstr "Non mi piace (clic per cambiare)"
+#: mod/newmember.php:44
+msgid ""
+"Friendica respects your privacy. By default, your posts will only show up to"
+" people you've added as friends. For more information, see the help section "
+"from the link above."
+msgstr "Friendica rispetta la tua privacy. Per impostazione predefinita, i tuoi post sono mostrati solo alle persone che hai aggiunto come amici. Per maggiori informazioni guarda la sezione della guida dal link qui sopra."
-#: mod/content.php:703 object/Item.php:275
-msgid "dislike"
-msgstr "non mi piace"
+#: mod/newmember.php:48
+msgid "Getting Help"
+msgstr "Ottenere Aiuto"
-#: mod/content.php:705 object/Item.php:278
-msgid "Share this"
-msgstr "Condividi questo"
+#: mod/newmember.php:50
+msgid "Go to the Help Section"
+msgstr "Vai alla sezione Guida"
-#: mod/content.php:705 object/Item.php:278
-msgid "share"
-msgstr "condividi"
+#: mod/newmember.php:50
+msgid ""
+"Our <strong>help</strong> pages may be consulted for detail on other program"
+" features and resources."
+msgstr "Le nostre pagine della <strong>guida</strong> possono essere consultate per avere dettagli su altre caratteristiche del programma e altre risorse."
-#: mod/content.php:725 mod/photos.php:1643 mod/photos.php:1685
-#: mod/photos.php:1765 object/Item.php:702
-msgid "This is you"
-msgstr "Questo sei tu"
+#: mod/nogroup.php:45 mod/viewcontacts.php:105 mod/contacts.php:616
+#: mod/contacts.php:960
+#, php-format
+msgid "Visit %s's profile [%s]"
+msgstr "Visita il profilo di %s [%s]"
-#: mod/content.php:727 mod/content.php:950 mod/photos.php:1645
-#: mod/photos.php:1687 mod/photos.php:1767 object/Item.php:392
-#: object/Item.php:704
-msgid "Comment"
-msgstr "Commento"
+#: mod/nogroup.php:46 mod/contacts.php:961
+msgid "Edit contact"
+msgstr "Modifica contatto"
-#: mod/content.php:729 object/Item.php:706
-msgid "Bold"
-msgstr "Grassetto"
+#: mod/nogroup.php:67
+msgid "Contacts who are not members of a group"
+msgstr "Contatti che non sono membri di un gruppo"
-#: mod/content.php:730 object/Item.php:707
-msgid "Italic"
-msgstr "Corsivo"
+#: mod/profperm.php:22 mod/group.php:78 index.php:411
+msgid "Permission denied"
+msgstr "Permesso negato"
-#: mod/content.php:731 object/Item.php:708
-msgid "Underline"
-msgstr "Sottolineato"
+#: mod/profperm.php:28 mod/profperm.php:59
+msgid "Invalid profile identifier."
+msgstr "Identificativo del profilo non valido."
-#: mod/content.php:732 object/Item.php:709
-msgid "Quote"
-msgstr "Citazione"
+#: mod/profperm.php:105
+msgid "Profile Visibility Editor"
+msgstr "Modifica visibilità del profilo"
-#: mod/content.php:733 object/Item.php:710
-msgid "Code"
-msgstr "Codice"
+#: mod/profperm.php:109 mod/group.php:264
+msgid "Click on a contact to add or remove."
+msgstr "Clicca su un contatto per aggiungerlo o rimuoverlo."
-#: mod/content.php:734 object/Item.php:711
-msgid "Image"
-msgstr "Immagine"
+#: mod/profperm.php:118
+msgid "Visible To"
+msgstr "Visibile a"
-#: mod/content.php:735 object/Item.php:712
-msgid "Link"
-msgstr "Link"
+#: mod/profperm.php:134
+msgid "All Contacts (with secure profile access)"
+msgstr "Tutti i contatti (con profilo ad accesso sicuro)"
-#: mod/content.php:736 object/Item.php:713
-msgid "Video"
-msgstr "Video"
+#: mod/update_community.php:21 mod/update_display.php:25
+#: mod/update_notes.php:38 mod/update_profile.php:37 mod/update_network.php:29
+msgid "[Embedded content - reload page to view]"
+msgstr "[Contenuto incorporato - ricarica la pagina per visualizzarlo correttamente]"
-#: mod/content.php:746 mod/settings.php:743 object/Item.php:122
-#: object/Item.php:124
-msgid "Edit"
-msgstr "Modifica"
+#: mod/viewcontacts.php:39 mod/webfinger.php:10 mod/probe.php:9
+#: mod/community.php:17 mod/dfrn_request.php:805 mod/directory.php:31
+#: mod/search.php:89 mod/search.php:95 mod/display.php:202 mod/photos.php:965
+#: mod/videos.php:202
+msgid "Public access denied."
+msgstr "Accesso negato."
-#: mod/content.php:772 object/Item.php:238
-msgid "add star"
-msgstr "aggiungi a speciali"
+#: mod/viewcontacts.php:78
+msgid "No contacts."
+msgstr "Nessun contatto."
-#: mod/content.php:773 object/Item.php:239
-msgid "remove star"
-msgstr "rimuovi da speciali"
+#: mod/viewsrc.php:8
+msgid "Access denied."
+msgstr "Accesso negato."
-#: mod/content.php:774 object/Item.php:240
-msgid "toggle star status"
-msgstr "Inverti stato preferito"
+#: mod/webfinger.php:11 mod/probe.php:10
+msgid "Only logged in users are permitted to perform a probing."
+msgstr "Solo agli utenti loggati è permesso effettuare un probe."
-#: mod/content.php:777 object/Item.php:243
-msgid "starred"
-msgstr "preferito"
+#: mod/uimport.php:53 mod/register.php:203
+msgid ""
+"This site has exceeded the number of allowed daily account registrations. "
+"Please try again tomorrow."
+msgstr "Questo sito ha superato il numero di registrazioni giornaliere consentite. Prova di nuovo domani."
-#: mod/content.php:778 mod/content.php:800 object/Item.php:263
-msgid "add tag"
-msgstr "aggiungi tag"
+#: mod/uimport.php:68 mod/register.php:300
+msgid "Import"
+msgstr "Importa"
-#: mod/content.php:789 object/Item.php:251
-msgid "ignore thread"
-msgstr "ignora la discussione"
+#: mod/uimport.php:70
+msgid "Move account"
+msgstr "Muovi account"
-#: mod/content.php:790 object/Item.php:252
-msgid "unignore thread"
-msgstr "non ignorare la discussione"
+#: mod/uimport.php:71
+msgid "You can import an account from another Friendica server."
+msgstr "Puoi importare un account da un altro server Friendica."
-#: mod/content.php:791 object/Item.php:253
-msgid "toggle ignore status"
-msgstr "inverti stato \"Ignora\""
+#: mod/uimport.php:72
+msgid ""
+"You need to export your account from the old server and upload it here. We "
+"will recreate your old account here with all your contacts. We will try also"
+" to inform your friends that you moved here."
+msgstr "Devi esportare il tuo account dal vecchio server e caricarlo qui. Noi ricreeremo il tuo vecchio account qui, con tutti i tuoi contatti. Proveremo anche a informare i tuoi amici che ti sei spostato qui."
-#: mod/content.php:794 mod/ostatus_subscribe.php:73 object/Item.php:256
-msgid "ignored"
-msgstr "ignorato"
+#: mod/uimport.php:73
+msgid ""
+"This feature is experimental. We can't import contacts from the OStatus "
+"network (GNU Social/Statusnet) or from Diaspora"
+msgstr "Questa funzione è sperimentale. Non possiamo importare i contatti dalla rete OStatus (GNU Social/Statusnet) o da Diaspora"
-#: mod/content.php:805 object/Item.php:141
-msgid "save to folder"
-msgstr "salva nella cartella"
+#: mod/uimport.php:74
+msgid "Account file"
+msgstr "File account"
-#: mod/content.php:853 object/Item.php:212
-msgid "I will attend"
-msgstr "Parteciperò"
+#: mod/uimport.php:74
+msgid ""
+"To export your account, go to \"Settings->Export your personal data\" and "
+"select \"Export account\""
+msgstr "Per esportare il tuo account, vai su \"Impostazioni -> Esporta i tuoi dati personali\" e seleziona \"Esporta account\""
-#: mod/content.php:853 object/Item.php:212
-msgid "I will not attend"
-msgstr "Non parteciperò"
+#: mod/community.php:22
+msgid "Not available."
+msgstr "Non disponibile."
-#: mod/content.php:853 object/Item.php:212
-msgid "I might attend"
-msgstr "Forse parteciperò"
+#: mod/community.php:49 mod/search.php:215
+msgid "No results."
+msgstr "Nessun risultato."
-#: mod/content.php:917 object/Item.php:358
-msgid "to"
-msgstr "a"
+#: mod/allfriends.php:49
+msgid "No friends to display."
+msgstr "Nessun amico da visualizzare."
-#: mod/content.php:918 object/Item.php:360
-msgid "Wall-to-Wall"
-msgstr "Da bacheca a bacheca"
+#: mod/bookmarklet.php:44
+msgid "The post was created"
+msgstr "Il messaggio è stato creato"
-#: mod/content.php:919 object/Item.php:361
-msgid "via Wall-To-Wall:"
-msgstr "da bacheca a bacheca"
+#: mod/cal.php:146 mod/profile.php:157 mod/display.php:339
+msgid "Access to this profile has been restricted."
+msgstr "L'accesso a questo profilo è stato limitato."
-#: mod/credits.php:16
-msgid "Credits"
-msgstr "Crediti"
+#: mod/cal.php:274 mod/events.php:384
+msgid "View"
+msgstr "Mostra"
-#: mod/credits.php:17
-msgid ""
-"Friendica is a community project, that would not be possible without the "
-"help of many people. Here is a list of those who have contributed to the "
-"code or the translation of Friendica. Thank you all!"
-msgstr "Friendica è un progetto comunitario, che non sarebbe stato possibile realizzare senza l'aiuto di molte persone.\nQuesta è una lista di chi ha contribuito al codice o alle traduzioni di Friendica. Grazie a tutti!"
+#: mod/cal.php:275 mod/events.php:386
+msgid "Previous"
+msgstr "Precedente"
-#: mod/crepair.php:89
-msgid "Contact settings applied."
-msgstr "Contatto modificato."
+#: mod/cal.php:276 mod/install.php:202 mod/events.php:387
+msgid "Next"
+msgstr "Successivo"
-#: mod/crepair.php:91
-msgid "Contact update failed."
-msgstr "Le modifiche al contatto non sono state salvate."
+#: mod/cal.php:285 mod/events.php:396
+msgid "list"
+msgstr "lista"
-#: mod/crepair.php:116 mod/fsuggest.php:21 mod/fsuggest.php:93
-#: mod/dfrn_confirm.php:126
-msgid "Contact not found."
-msgstr "Contatto non trovato."
+#: mod/cal.php:295
+msgid "User not found"
+msgstr "Utente non trovato"
-#: mod/crepair.php:122
-msgid ""
-"<strong>WARNING: This is highly advanced</strong> and if you enter incorrect"
-" information your communications with this contact may stop working."
-msgstr "<strong>ATTENZIONE: Queste sono impostazioni avanzate</strong> e se inserisci informazioni errate le tue comunicazioni con questo contatto potrebbero non funzionare più"
+#: mod/cal.php:311
+msgid "This calendar format is not supported"
+msgstr "Questo formato di calendario non è supportato"
-#: mod/crepair.php:123
-msgid ""
-"Please use your browser 'Back' button <strong>now</strong> if you are "
-"uncertain what to do on this page."
-msgstr "Usa <strong>ora</strong> il tasto 'Indietro' del tuo browser se non sei sicuro di cosa fare in questa pagina."
+#: mod/cal.php:313
+msgid "No exportable data found"
+msgstr "Nessun dato esportabile trovato"
-#: mod/crepair.php:136 mod/crepair.php:138
-msgid "No mirroring"
-msgstr "Non duplicare"
+#: mod/cal.php:328
+msgid "calendar"
+msgstr "calendario"
-#: mod/crepair.php:136
-msgid "Mirror as forwarded posting"
-msgstr "Duplica come messaggi ricondivisi"
+#: mod/dfrn_poll.php:114 mod/dfrn_poll.php:550
+#, php-format
+msgid "%1$s welcomes %2$s"
+msgstr "%s dà il benvenuto a %s"
-#: mod/crepair.php:136 mod/crepair.php:138
-msgid "Mirror as my own posting"
-msgstr "Duplica come miei messaggi"
+#: mod/dfrn_request.php:104
+msgid "This introduction has already been accepted."
+msgstr "Questa presentazione è già stata accettata."
-#: mod/crepair.php:152
-msgid "Return to contact editor"
-msgstr "Ritorna alla modifica contatto"
+#: mod/dfrn_request.php:127 mod/dfrn_request.php:529
+msgid "Profile location is not valid or does not contain profile information."
+msgstr "L'indirizzo del profilo non è valido o non contiene un profilo."
-#: mod/crepair.php:154
-msgid "Refetch contact data"
-msgstr "Ricarica dati contatto"
+#: mod/dfrn_request.php:132 mod/dfrn_request.php:534
+msgid "Warning: profile location has no identifiable owner name."
+msgstr "Attenzione: l'indirizzo del profilo non riporta il nome del proprietario."
-#: mod/crepair.php:158
-msgid "Remote Self"
-msgstr "Io remoto"
+#: mod/dfrn_request.php:135 mod/dfrn_request.php:537
+msgid "Warning: profile location has no profile photo."
+msgstr "Attenzione: l'indirizzo del profilo non ha una foto."
-#: mod/crepair.php:161
-msgid "Mirror postings from this contact"
-msgstr "Ripeti i messaggi di questo contatto"
+#: mod/dfrn_request.php:139 mod/dfrn_request.php:541
+#, php-format
+msgid "%d required parameter was not found at the given location"
+msgid_plural "%d required parameters were not found at the given location"
+msgstr[0] "%d parametro richiesto non è stato trovato all'indirizzo dato"
+msgstr[1] "%d parametri richiesti non sono stati trovati all'indirizzo dato"
-#: mod/crepair.php:163
-msgid ""
-"Mark this contact as remote_self, this will cause friendica to repost new "
-"entries from this contact."
-msgstr "Imposta questo contatto come 'io remoto', questo farà si che friendica re invii i nuovi messaggi da questo contatto."
+#: mod/dfrn_request.php:183
+msgid "Introduction complete."
+msgstr "Presentazione completa."
-#: mod/crepair.php:167 mod/settings.php:683 mod/settings.php:709
-#: mod/admin.php:1490 mod/admin.php:1503 mod/admin.php:1516 mod/admin.php:1532
-msgid "Name"
-msgstr "Nome"
+#: mod/dfrn_request.php:228
+msgid "Unrecoverable protocol error."
+msgstr "Errore di comunicazione."
-#: mod/crepair.php:168
-msgid "Account Nickname"
-msgstr "Nome utente"
+#: mod/dfrn_request.php:256
+msgid "Profile unavailable."
+msgstr "Profilo non disponibile."
-#: mod/crepair.php:169
-msgid "@Tagname - overrides Name/Nickname"
-msgstr "@TagName - al posto del nome utente"
+#: mod/dfrn_request.php:283
+#, php-format
+msgid "%s has received too many connection requests today."
+msgstr "%s ha ricevuto troppe richieste di connessione per oggi."
-#: mod/crepair.php:170
-msgid "Account URL"
-msgstr "URL dell'utente"
+#: mod/dfrn_request.php:284
+msgid "Spam protection measures have been invoked."
+msgstr "Sono state attivate le misure di protezione contro lo spam."
-#: mod/crepair.php:171
-msgid "Friend Request URL"
-msgstr "URL Richiesta Amicizia"
+#: mod/dfrn_request.php:285
+msgid "Friends are advised to please try again in 24 hours."
+msgstr "Gli amici sono pregati di riprovare tra 24 ore."
-#: mod/crepair.php:172
-msgid "Friend Confirm URL"
-msgstr "URL Conferma Amicizia"
+#: mod/dfrn_request.php:347
+msgid "Invalid locator"
+msgstr "Indirizzo non valido"
-#: mod/crepair.php:173
-msgid "Notification Endpoint URL"
-msgstr "URL Notifiche"
+#: mod/dfrn_request.php:356
+msgid "Invalid email address."
+msgstr "Indirizzo email non valido."
-#: mod/crepair.php:174
-msgid "Poll/Feed URL"
-msgstr "URL Feed"
+#: mod/dfrn_request.php:381
+msgid "This account has not been configured for email. Request failed."
+msgstr "Questo account non è stato configurato per l'email. Richiesta fallita."
-#: mod/crepair.php:175
-msgid "New photo from this URL"
-msgstr "Nuova foto da questo URL"
+#: mod/dfrn_request.php:484
+msgid "You have already introduced yourself here."
+msgstr "Ti sei già presentato qui."
-#: mod/delegate.php:101
-msgid "No potential page delegates located."
-msgstr "Nessun potenziale delegato per la pagina è stato trovato."
+#: mod/dfrn_request.php:488
+#, php-format
+msgid "Apparently you are already friends with %s."
+msgstr "Pare che tu e %s siate già amici."
-#: mod/delegate.php:132
+#: mod/dfrn_request.php:509
+msgid "Invalid profile URL."
+msgstr "Indirizzo profilo non valido."
+
+#: mod/dfrn_request.php:594 mod/contacts.php:223
+msgid "Failed to update contact record."
+msgstr "Errore nell'aggiornamento del contatto."
+
+#: mod/dfrn_request.php:615
+msgid "Your introduction has been sent."
+msgstr "La tua presentazione è stata inviata."
+
+#: mod/dfrn_request.php:657
msgid ""
-"Delegates are able to manage all aspects of this account/page except for "
-"basic account settings. Please do not delegate your personal account to "
-"anybody that you do not trust completely."
-msgstr "I Delegati sono in grado di gestire tutti gli aspetti di questa pagina, tranne per le impostazioni di base dell'account. Non delegare il tuo account personale a nessuno di cui non ti fidi ciecamente."
+"Remote subscription can't be done for your network. Please subscribe "
+"directly on your system."
+msgstr "La richiesta di connessione remota non può essere effettuata per la tua rete. Invia la richiesta direttamente sul nostro sistema."
-#: mod/delegate.php:133
-msgid "Existing Page Managers"
-msgstr "Gestori Pagina Esistenti"
+#: mod/dfrn_request.php:678
+msgid "Please login to confirm introduction."
+msgstr "Accedi per confermare la presentazione."
-#: mod/delegate.php:135
-msgid "Existing Page Delegates"
-msgstr "Delegati Pagina Esistenti"
+#: mod/dfrn_request.php:688
+msgid ""
+"Incorrect identity currently logged in. Please login to "
+"<strong>this</strong> profile."
+msgstr "Non hai fatto accesso con l'identità corretta. Accedi a <strong>questo</strong> profilo."
-#: mod/delegate.php:137
-msgid "Potential Delegates"
-msgstr "Delegati Potenziali"
+#: mod/dfrn_request.php:702 mod/dfrn_request.php:719
+msgid "Confirm"
+msgstr "Conferma"
-#: mod/delegate.php:139 mod/tagrm.php:95
-msgid "Remove"
-msgstr "Rimuovi"
+#: mod/dfrn_request.php:714
+msgid "Hide this contact"
+msgstr "Nascondi questo contatto"
-#: mod/delegate.php:140
-msgid "Add"
-msgstr "Aggiungi"
+#: mod/dfrn_request.php:717
+#, php-format
+msgid "Welcome home %s."
+msgstr "Bentornato a casa %s."
-#: mod/delegate.php:141
-msgid "No entries."
-msgstr "Nessuna voce."
+#: mod/dfrn_request.php:718
+#, php-format
+msgid "Please confirm your introduction/connection request to %s."
+msgstr "Conferma la tua richiesta di connessione con %s."
-#: mod/dfrn_poll.php:104 mod/dfrn_poll.php:539
+#: mod/dfrn_request.php:849
+msgid ""
+"Please enter your 'Identity Address' from one of the following supported "
+"communications networks:"
+msgstr "Inserisci il tuo 'Indirizzo Identità' da uno dei seguenti network supportati:"
+
+#: mod/dfrn_request.php:873
#, php-format
-msgid "%1$s welcomes %2$s"
-msgstr "%s dà il benvenuto a %s"
+msgid ""
+"If you are not yet a member of the free social web, <a "
+"href=\"%s/siteinfo\">follow this link to find a public Friendica site and "
+"join us today</a>."
+msgstr "Se non sei un membro del web sociale libero, <a href=\"%s/siteinfo\">segui questo link per trovare un sito Friendica pubblico e unisciti a noi oggi</a>"
-#: mod/directory.php:37 mod/display.php:200 mod/viewcontacts.php:36
-#: mod/community.php:18 mod/dfrn_request.php:804 mod/photos.php:979
-#: mod/probe.php:9 mod/search.php:93 mod/search.php:99 mod/videos.php:198
-#: mod/webfinger.php:8
-msgid "Public access denied."
-msgstr "Accesso negato."
+#: mod/dfrn_request.php:878
+msgid "Friend/Connection Request"
+msgstr "Richieste di amicizia/connessione"
-#: mod/directory.php:199 view/theme/vier/theme.php:199
-msgid "Global Directory"
-msgstr "Elenco globale"
+#: mod/dfrn_request.php:879
+msgid ""
+"Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, "
+"testuser@identi.ca"
+msgstr "Esempi: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, testuser@identi.ca"
-#: mod/directory.php:201
-msgid "Find on this site"
-msgstr "Cerca nel sito"
+#: mod/dfrn_request.php:880 mod/follow.php:149
+msgid "Please answer the following:"
+msgstr "Rispondi:"
-#: mod/directory.php:203
-msgid "Results for:"
-msgstr "Risultati per:"
+#: mod/dfrn_request.php:881 mod/follow.php:150
+#, php-format
+msgid "Does %s know you?"
+msgstr "%s ti conosce?"
-#: mod/directory.php:205
-msgid "Site Directory"
-msgstr "Elenco del sito"
+#: mod/dfrn_request.php:885 mod/follow.php:151
+msgid "Add a personal note:"
+msgstr "Aggiungi una nota personale:"
-#: mod/directory.php:212
-msgid "No entries (some entries may be hidden)."
-msgstr "Nessuna voce (qualche voce potrebbe essere nascosta)."
+#: mod/dfrn_request.php:888
+msgid "StatusNet/Federated Social Web"
+msgstr "StatusNet/Federated Social Web"
-#: mod/display.php:328 mod/cal.php:143 mod/profile.php:155
-msgid "Access to this profile has been restricted."
-msgstr "L'accesso a questo profilo è stato limitato."
+#: mod/dfrn_request.php:890
+#, php-format
+msgid ""
+" - please do not use this form. Instead, enter %s into your Diaspora search"
+" bar."
+msgstr " - per favore non usare questa form. Invece, inserisci %s nella tua barra di ricerca su Diaspora."
-#: mod/display.php:479
-msgid "Item has been removed."
-msgstr "L'oggetto è stato rimosso."
+#: mod/dfrn_request.php:891 mod/follow.php:157 mod/unfollow.php:113
+msgid "Your Identity Address:"
+msgstr "L'indirizzo della tua identità:"
+
+#: mod/dfrn_request.php:894 mod/follow.php:63 mod/unfollow.php:65
+msgid "Submit Request"
+msgstr "Invia richiesta"
-#: mod/editpost.php:17 mod/editpost.php:27
+#: mod/editpost.php:20 mod/editpost.php:30
msgid "Item not found"
msgstr "Oggetto non trovato"
-#: mod/editpost.php:32
+#: mod/editpost.php:35
msgid "Edit post"
msgstr "Modifica messaggio"
-#: mod/fbrowser.php:132
-msgid "Files"
-msgstr "File"
-
-#: mod/fetch.php:12 mod/fetch.php:39 mod/fetch.php:48 mod/help.php:53
-#: mod/p.php:16 mod/p.php:43 mod/p.php:52 index.php:298
+#: mod/fetch.php:16 mod/fetch.php:43 mod/fetch.php:52 mod/help.php:57
+#: mod/p.php:20 mod/p.php:47 mod/p.php:56 index.php:303
msgid "Not Found"
msgstr "Non trovato"
-#: mod/filer.php:30
-msgid "- select -"
-msgstr "- seleziona -"
+#: mod/follow.php:42
+msgid "Contact added"
+msgstr "Contatto aggiunto"
-#: mod/fsuggest.php:64
-msgid "Friend suggestion sent."
-msgstr "Suggerimento di amicizia inviato."
+#: mod/follow.php:74
+msgid "You already added this contact."
+msgstr "Hai già aggiunto questo contatto."
-#: mod/fsuggest.php:98
-msgid "Suggest Friends"
-msgstr "Suggerisci amici"
+#: mod/follow.php:83
+msgid "Diaspora support isn't enabled. Contact can't be added."
+msgstr "Il supporto Diaspora non è abilitato. Il contatto non può essere aggiunto."
-#: mod/fsuggest.php:100
-#, php-format
-msgid "Suggest a friend for %s"
-msgstr "Suggerisci un amico a %s"
+#: mod/follow.php:90
+msgid "OStatus support is disabled. Contact can't be added."
+msgstr "Il supporto OStatus non è abilitato. Il contatto non può essere aggiunto."
+
+#: mod/follow.php:97
+msgid "The network type couldn't be detected. Contact can't be added."
+msgstr "Non è possibile rilevare il tipo di rete. Il contatto non può essere aggiunto."
+
+#: mod/follow.php:166 mod/notifications.php:258 mod/unfollow.php:122
+#: mod/contacts.php:654
+msgid "Profile URL"
+msgstr "URL Profilo"
+
+#: mod/group.php:31
+msgid "Group created."
+msgstr "Gruppo creato."
+
+#: mod/group.php:37
+msgid "Could not create group."
+msgstr "Impossibile creare il gruppo."
+
+#: mod/group.php:51 mod/group.php:156
+msgid "Group not found."
+msgstr "Gruppo non trovato."
+
+#: mod/group.php:65
+msgid "Group name changed."
+msgstr "Il nome del gruppo è cambiato."
+
+#: mod/group.php:95
+msgid "Save Group"
+msgstr "Salva gruppo"
+
+#: mod/group.php:100
+msgid "Create a group of contacts/friends."
+msgstr "Crea un gruppo di amici/contatti."
+
+#: mod/group.php:125
+msgid "Group removed."
+msgstr "Gruppo rimosso."
+
+#: mod/group.php:127
+msgid "Unable to remove group."
+msgstr "Impossibile rimuovere il gruppo."
+
+#: mod/group.php:191
+msgid "Delete Group"
+msgstr "Elimina Gruppo"
+
+#: mod/group.php:197
+msgid "Group Editor"
+msgstr "Modifica gruppo"
+
+#: mod/group.php:202
+msgid "Edit Group Name"
+msgstr "Modifica Nome Gruppo"
+
+#: mod/group.php:212
+msgid "Members"
+msgstr "Membri"
+
+#: mod/group.php:214 mod/contacts.php:722
+msgid "All Contacts"
+msgstr "Tutti i contatti"
+
+#: mod/group.php:215 mod/network.php:655
+msgid "Group is empty"
+msgstr "Il gruppo è vuoto"
+
+#: mod/group.php:228
+msgid "Remove Contact"
+msgstr "Rimuovi Contatto"
+
+#: mod/group.php:252
+msgid "Add Contact"
+msgstr "Aggiungi Contatto"
-#: mod/hcard.php:11
+#: mod/hcard.php:14
msgid "No profile"
msgstr "Nessun profilo"
-#: mod/help.php:41
+#: mod/help.php:45
msgid "Help:"
msgstr "Guida:"
-#: mod/help.php:56 index.php:301
+#: mod/help.php:60 index.php:306
msgid "Page not found."
msgstr "Pagina non trovata."
-#: mod/home.php:39
+#: mod/home.php:42
#, php-format
msgid "Welcome to %s"
msgstr "Benvenuto su %s"
-#: mod/invite.php:28
+#: mod/invite.php:31
msgid "Total invitation limit exceeded."
msgstr "Limite totale degli inviti superato."
-#: mod/invite.php:51
+#: mod/invite.php:54
#, php-format
msgid "%s : Not a valid email address."
msgstr "%s: non è un indirizzo email valido."
-#: mod/invite.php:76
+#: mod/invite.php:79
msgid "Please join us on Friendica"
msgstr "Unisciti a noi su Friendica"
-#: mod/invite.php:87
+#: mod/invite.php:90
msgid "Invitation limit exceeded. Please contact your site administrator."
msgstr "Limite degli inviti superato. Contatta l'amministratore del tuo sito."
-#: mod/invite.php:91
+#: mod/invite.php:94
#, php-format
msgid "%s : Message delivery failed."
msgstr "%s: la consegna del messaggio fallita."
-#: mod/invite.php:95
+#: mod/invite.php:98
#, php-format
msgid "%d message sent."
msgid_plural "%d messages sent."
msgstr[0] "%d messaggio inviato."
msgstr[1] "%d messaggi inviati."
-#: mod/invite.php:114
+#: mod/invite.php:117
msgid "You have no more invitations available"
msgstr "Non hai altri inviti disponibili"
-#: mod/invite.php:122
+#: mod/invite.php:125
#, php-format
msgid ""
"Visit %s for a list of public sites that you can join. Friendica members on "
" other social networks."
msgstr "Visita %s per una lista di siti pubblici a cui puoi iscriverti. I membri Friendica su altri siti possono collegarsi uno con l'altro, come con membri di molti altri social network."
-#: mod/invite.php:124
+#: mod/invite.php:127
#, php-format
msgid ""
"To accept this invitation, please visit and register at %s or any other "
"public Friendica website."
msgstr "Per accettare questo invito, visita e registrati su %s o su un'altro sito web Friendica aperto al pubblico."
-#: mod/invite.php:125
+#: mod/invite.php:128
#, php-format
msgid ""
"Friendica sites all inter-connect to create a huge privacy-enhanced social "
"sites you can join."
msgstr "I siti Friendica son tutti collegati tra loro per creare una grossa rete sociale rispettosa della privacy, posseduta e controllata dai suoi membri. I siti Friendica possono anche collegarsi a molti altri social network tradizionali. Vai su %s per una lista di siti Friendica alternativi a cui puoi iscriverti."
-#: mod/invite.php:128
+#: mod/invite.php:132
msgid ""
"Our apologies. This system is not currently configured to connect with other"
" public sites or invite members."
msgstr "Ci scusiamo, questo sistema non è configurato per collegarsi con altri siti pubblici o per invitare membri."
-#: mod/invite.php:134
+#: mod/invite.php:135
+#, php-format
+msgid "To accept this invitation, please visit and register at %s."
+msgstr "Per accettare questo invito, visita e registrati su %s"
+
+#: mod/invite.php:136
+msgid ""
+"Friendica sites all inter-connect to create a huge privacy-enhanced social "
+"web that is owned and controlled by its members. They can also connect with "
+"many traditional social networks."
+msgstr ""
+
+#: mod/invite.php:142
msgid "Send invitations"
msgstr "Invia inviti"
-#: mod/invite.php:135
+#: mod/invite.php:143
msgid "Enter email addresses, one per line:"
msgstr "Inserisci gli indirizzi email, uno per riga:"
-#: mod/invite.php:136 mod/wallmessage.php:135 mod/message.php:332
-#: mod/message.php:515
+#: mod/invite.php:144 mod/message.php:332 mod/message.php:515
+#: mod/wallmessage.php:138
msgid "Your message:"
msgstr "Il tuo messaggio:"
-#: mod/invite.php:137
+#: mod/invite.php:145
msgid ""
"You are cordially invited to join me and other close friends on Friendica - "
"and help us to create a better social web."
msgstr "Sei cordialmente invitato/a ad unirti a me e ad altri amici su Friendica, e ad aiutarci a creare una rete sociale migliore."
-#: mod/invite.php:139
+#: mod/invite.php:147
msgid "You will need to supply this invitation code: $invite_code"
msgstr "Sarà necessario fornire questo codice invito: $invite_code"
-#: mod/invite.php:139
+#: mod/invite.php:147
msgid ""
"Once you have registered, please connect with me via my profile page at:"
msgstr "Una volta registrato, connettiti con me dal mio profilo:"
-#: mod/invite.php:141
+#: mod/invite.php:149
msgid ""
"For more information about the Friendica project and why we feel it is "
-"important, please visit http://friendica.com"
-msgstr "Per maggiori informazioni sul progetto Friendica e perché pensiamo sia importante, visita http://friendica.com"
+"important, please visit http://friendi.ca"
+msgstr "Per maggiori informazioni sul progetto Friendica e perchè pensiamo sia importante, visita http://friendi.ca "
-#: mod/localtime.php:24
+#: mod/localtime.php:26
msgid "Time Conversion"
msgstr "Conversione Ora"
-#: mod/localtime.php:26
+#: mod/localtime.php:28
msgid ""
"Friendica provides this service for sharing events with other networks and "
"friends in unknown timezones."
msgstr "Friendica fornisce questo servizio per la condivisione di eventi con altre reti e amici in fusi orari sconosciuti."
-#: mod/localtime.php:30
+#: mod/localtime.php:32
#, php-format
msgid "UTC time: %s"
msgstr "Ora UTC: %s"
-#: mod/localtime.php:33
+#: mod/localtime.php:35
#, php-format
msgid "Current timezone: %s"
msgstr "Fuso orario corrente: %s"
-#: mod/localtime.php:36
+#: mod/localtime.php:38
#, php-format
msgid "Converted localtime: %s"
msgstr "Ora locale convertita: %s"
-#: mod/localtime.php:41
+#: mod/localtime.php:43
msgid "Please select your timezone:"
msgstr "Selezionare il tuo fuso orario:"
-#: mod/lockview.php:32 mod/lockview.php:40
-msgid "Remote privacy information not available."
-msgstr "Informazioni remote sulla privacy non disponibili."
-
-#: mod/lockview.php:49
-msgid "Visible to:"
-msgstr "Visibile a:"
-
-#: mod/lostpass.php:19
+#: mod/lostpass.php:22
msgid "No valid account found."
msgstr "Nessun account valido trovato."
-#: mod/lostpass.php:35
+#: mod/lostpass.php:38
msgid "Password reset request issued. Check your email."
msgstr "La richiesta per reimpostare la password è stata inviata. Controlla la tua email."
-#: mod/lostpass.php:41
+#: mod/lostpass.php:44
#, php-format
msgid ""
"\n"
"\t\tissued this request."
msgstr "\nGentile %1$s,\n abbiamo ricevuto su \"%2$s\" una richiesta di resettare la password del tuo account. Per confermare questa richiesta, selezionate il link di conferma qui sotto o incollatelo nella barra indirizzo del vostro browser.\n\nSe NON hai richiesto questa modifica, NON selezionare il link e ignora o cancella questa email.\n\nLa tua password non verrà modificata a meno che non possiamo verificare che tu abbia effettivamente richiesto la modifica."
-#: mod/lostpass.php:52
+#: mod/lostpass.php:55
#, php-format
msgid ""
"\n"
"\t\tLogin Name:\t%3$s"
msgstr "\nSegui questo link per verificare la tua identità:\n\n%1$s\n\nRiceverai in un successivo messaggio la nuova password.\nPotrai cambiarla dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato.\n\nI dettagli del tuo account sono:\n Indirizzo del sito: %2$s\n Nome utente: %3$s"
-#: mod/lostpass.php:71
+#: mod/lostpass.php:74
#, php-format
msgid "Password reset requested at %s"
msgstr "Richiesta reimpostazione password su %s"
-#: mod/lostpass.php:91
+#: mod/lostpass.php:94
msgid ""
"Request could not be verified. (You may have previously submitted it.) "
"Password reset failed."
msgstr "La richiesta non può essere verificata. (Puoi averla già richiesta precedentemente). Reimpostazione password fallita."
-#: mod/lostpass.php:110 boot.php:1882
+#: mod/lostpass.php:113 boot.php:889
msgid "Password Reset"
msgstr "Reimpostazione password"
-#: mod/lostpass.php:111
+#: mod/lostpass.php:114
msgid "Your password has been reset as requested."
msgstr "La tua password è stata reimpostata come richiesto."
-#: mod/lostpass.php:112
+#: mod/lostpass.php:115
msgid "Your new password is"
msgstr "La tua nuova password è"
-#: mod/lostpass.php:113
+#: mod/lostpass.php:116
msgid "Save or copy your new password - and then"
msgstr "Salva o copia la tua nuova password, quindi"
-#: mod/lostpass.php:114
+#: mod/lostpass.php:117
msgid "click here to login"
msgstr "clicca qui per entrare"
-#: mod/lostpass.php:115
+#: mod/lostpass.php:118
msgid ""
"Your password may be changed from the <em>Settings</em> page after "
"successful login."
msgstr "Puoi cambiare la tua password dalla pagina <em>Impostazioni</em> dopo aver effettuato l'accesso."
-#: mod/lostpass.php:125
+#: mod/lostpass.php:128
#, php-format
msgid ""
"\n"
"\t\t\t"
msgstr "\nGentile %1$s,\n La tua password è stata modificata come richiesto.\nSalva questa password, o sostituiscila immediatamente con qualcosa che puoi ricordare."
-#: mod/lostpass.php:131
+#: mod/lostpass.php:134
#, php-format
msgid ""
"\n"
"\t\t\t"
msgstr "\nI dettagli del tuo account sono:\n\n Indirizzo del sito: %1$s\n Nome utente: %2$s\n Password: %3$s\n\nPuoi cambiare questa password dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato."
-#: mod/lostpass.php:147
+#: mod/lostpass.php:150
#, php-format
msgid "Your password has been changed at %s"
msgstr "La tua password presso %s è stata cambiata"
-#: mod/lostpass.php:159
+#: mod/lostpass.php:162
msgid "Forgot your Password?"
msgstr "Hai dimenticato la password?"
-#: mod/lostpass.php:160
+#: mod/lostpass.php:163
msgid ""
"Enter your email address and submit to have your password reset. Then check "
"your email for further instructions."
msgstr "Inserisci il tuo indirizzo email per reimpostare la password."
-#: mod/lostpass.php:161 boot.php:1870
+#: mod/lostpass.php:164 boot.php:877
msgid "Nickname or Email: "
msgstr "Nome utente o email: "
-#: mod/lostpass.php:162
+#: mod/lostpass.php:165
msgid "Reset"
msgstr "Reimposta"
-#: mod/maintenance.php:20
-msgid "System down for maintenance"
-msgstr "Sistema in manutenzione"
+#: mod/manage.php:153
+msgid "Manage Identities and/or Pages"
+msgstr "Gestisci identità e/o pagine"
+
+#: mod/manage.php:154
+msgid ""
+"Toggle between different identities or community/group pages which share "
+"your account details or which you have been granted \"manage\" permissions"
+msgstr "Cambia tra differenti identità o pagine comunità/gruppi che condividono il tuo account o per cui hai i permessi di gestione"
+
+#: mod/manage.php:155
+msgid "Select an identity to manage: "
+msgstr "Seleziona un'identità da gestire:"
-#: mod/match.php:35
+#: mod/match.php:39
msgid "No keywords to match. Please add keywords to your default profile."
msgstr "Nessuna parola chiave per l'abbinamento. Aggiungi parole chiave al tuo profilo predefinito."
-#: mod/match.php:88
+#: mod/match.php:92
msgid "is interested in:"
msgstr "è interessato a:"
-#: mod/match.php:102
+#: mod/match.php:106
msgid "Profile Match"
msgstr "Profili corrispondenti"
-#: mod/match.php:109 mod/dirfind.php:245
+#: mod/match.php:113 mod/dirfind.php:249
msgid "No matches"
msgstr "Nessun risultato"
-#: mod/mood.php:134
-msgid "Mood"
-msgstr "Umore"
+#: mod/message.php:63 mod/wallmessage.php:53
+msgid "No recipient selected."
+msgstr "Nessun destinatario selezionato."
-#: mod/mood.php:135
-msgid "Set your current mood and tell your friends"
-msgstr "Condividi il tuo umore con i tuoi amici"
+#: mod/message.php:67
+msgid "Unable to locate contact information."
+msgstr "Impossibile trovare le informazioni del contatto."
-#: mod/newmember.php:6
-msgid "Welcome to Friendica"
-msgstr "Benvenuto su Friendica"
+#: mod/message.php:70 mod/wallmessage.php:59
+msgid "Message could not be sent."
+msgstr "Il messaggio non può essere inviato."
-#: mod/newmember.php:8
-msgid "New Member Checklist"
-msgstr "Cose da fare per i Nuovi Utenti"
-
-#: mod/newmember.php:12
-msgid ""
-"We would like to offer some tips and links to help make your experience "
-"enjoyable. Click any item to visit the relevant page. A link to this page "
-"will be visible from your home page for two weeks after your initial "
-"registration and then will quietly disappear."
-msgstr "Vorremmo offrirti qualche trucco e dei link alla guida per aiutarti ad avere un'esperienza divertente. Clicca su un qualsiasi elemento per visitare la relativa pagina. Un link a questa pagina sarà visibile nella tua home per due settimane dopo la tua registrazione."
+#: mod/message.php:73 mod/wallmessage.php:62
+msgid "Message collection failure."
+msgstr "Errore recuperando il messaggio."
-#: mod/newmember.php:14
-msgid "Getting Started"
-msgstr "Come Iniziare"
+#: mod/message.php:76 mod/wallmessage.php:65
+msgid "Message sent."
+msgstr "Messaggio inviato."
-#: mod/newmember.php:18
-msgid "Friendica Walk-Through"
-msgstr "Friendica Passo-Passo"
+#: mod/message.php:205
+msgid "Do you really want to delete this message?"
+msgstr "Vuoi veramente cancellare questo messaggio?"
-#: mod/newmember.php:18
-msgid ""
-"On your <em>Quick Start</em> page - find a brief introduction to your "
-"profile and network tabs, make some new connections, and find some groups to"
-" join."
-msgstr "Sulla tua pagina <em>Quick Start</em> - veloce introduzione alla tua pagina profilo e alla pagina Rete, fai qualche nuova amicizia, e trova qualche gruppo a cui unirti."
+#: mod/message.php:225
+msgid "Message deleted."
+msgstr "Messaggio eliminato."
-#: mod/newmember.php:26
-msgid "Go to Your Settings"
-msgstr "Vai alle tue Impostazioni"
+#: mod/message.php:255
+msgid "Conversation removed."
+msgstr "Conversazione rimossa."
-#: mod/newmember.php:26
-msgid ""
-"On your <em>Settings</em> page - change your initial password. Also make a "
-"note of your Identity Address. This looks just like an email address - and "
-"will be useful in making friends on the free social web."
-msgstr "Nella tua pagina <em>Impostazioni</em> - cambia la tua password iniziale. Prendi anche nota del tuo Indirizzo Identità. Assomiglia a un indirizzo email e sarà utile per stringere amicizie nel web sociale libero."
+#: mod/message.php:322 mod/wallmessage.php:129
+msgid "Send Private Message"
+msgstr "Invia un messaggio privato"
-#: mod/newmember.php:28
-msgid ""
-"Review the other settings, particularly the privacy settings. An unpublished"
-" directory listing is like having an unlisted phone number. In general, you "
-"should probably publish your listing - unless all of your friends and "
-"potential friends know exactly how to find you."
-msgstr "Guarda le altre impostazioni, in particolare le impostazioni della privacy. Un profilo non pubblicato è come un numero di telefono non in elenco. In genere, dovresti pubblicare il tuo profilo - a meno che tutti i tuoi amici e potenziali tali sappiano esattamente come trovarti."
+#: mod/message.php:323 mod/message.php:510 mod/wallmessage.php:131
+msgid "To:"
+msgstr "A:"
-#: mod/newmember.php:36 mod/profile_photo.php:256 mod/profiles.php:700
-msgid "Upload Profile Photo"
-msgstr "Carica la foto del profilo"
+#: mod/message.php:328 mod/message.php:512 mod/wallmessage.php:132
+msgid "Subject:"
+msgstr "Oggetto:"
-#: mod/newmember.php:36
-msgid ""
-"Upload a profile photo if you have not done so already. Studies have shown "
-"that people with real photos of themselves are ten times more likely to make"
-" friends than people who do not."
-msgstr "Carica una foto del profilo se non l'hai ancora fatto. Studi hanno mostrato che persone che hanno vere foto di se stessi hanno dieci volte più probabilità di fare amicizie rispetto alle persone che non ce l'hanno."
+#: mod/message.php:364
+msgid "No messages."
+msgstr "Nessun messaggio."
-#: mod/newmember.php:38
-msgid "Edit Your Profile"
-msgstr "Modifica il tuo Profilo"
+#: mod/message.php:403
+msgid "Message not available."
+msgstr "Messaggio non disponibile."
-#: mod/newmember.php:38
-msgid ""
-"Edit your <strong>default</strong> profile to your liking. Review the "
-"settings for hiding your list of friends and hiding the profile from unknown"
-" visitors."
-msgstr "Modifica il tuo profilo <strong>predefinito</strong> a piacimento. Rivedi le impostazioni per nascondere la tua lista di amici e nascondere il profilo ai visitatori sconosciuti."
+#: mod/message.php:478
+msgid "Delete message"
+msgstr "Elimina il messaggio"
-#: mod/newmember.php:40
-msgid "Profile Keywords"
-msgstr "Parole chiave del profilo"
+#: mod/message.php:503 mod/message.php:591
+msgid "Delete conversation"
+msgstr "Elimina la conversazione"
-#: mod/newmember.php:40
+#: mod/message.php:505
msgid ""
-"Set some public keywords for your default profile which describe your "
-"interests. We may be able to find other people with similar interests and "
-"suggest friendships."
-msgstr "Inserisci qualche parola chiave pubblica nel tuo profilo predefinito che descriva i tuoi interessi. Potremmo essere in grado di trovare altre persone con interessi similari e suggerirti delle amicizie."
+"No secure communications available. You <strong>may</strong> be able to "
+"respond from the sender's profile page."
+msgstr "Nessuna comunicazione sicura disponibile, <strong>Potresti</strong> essere in grado di rispondere dalla pagina del profilo del mittente."
-#: mod/newmember.php:44
-msgid "Connecting"
-msgstr "Collegarsi"
+#: mod/message.php:509
+msgid "Send Reply"
+msgstr "Invia la risposta"
-#: mod/newmember.php:51
-msgid "Importing Emails"
-msgstr "Importare le Email"
+#: mod/message.php:561
+#, php-format
+msgid "Unknown sender - %s"
+msgstr "Mittente sconosciuto - %s"
-#: mod/newmember.php:51
-msgid ""
-"Enter your email access information on your Connector Settings page if you "
-"wish to import and interact with friends or mailing lists from your email "
-"INBOX"
-msgstr "Inserisci i tuoi dati di accesso all'email nella tua pagina Impostazioni Connettori se vuoi importare e interagire con amici o mailing list dalla tua casella di posta in arrivo"
+#: mod/message.php:563
+#, php-format
+msgid "You and %s"
+msgstr "Tu e %s"
-#: mod/newmember.php:53
-msgid "Go to Your Contacts Page"
-msgstr "Vai alla tua pagina Contatti"
+#: mod/message.php:565
+#, php-format
+msgid "%s and You"
+msgstr "%s e Tu"
-#: mod/newmember.php:53
-msgid ""
-"Your Contacts page is your gateway to managing friendships and connecting "
-"with friends on other networks. Typically you enter their address or site "
-"URL in the <em>Add New Contact</em> dialog."
-msgstr "La tua pagina Contatti è il mezzo per gestire le amicizie e collegarsi con amici su altre reti. Di solito, basta inserire l'indirizzo nel campo <em>Aggiungi Nuovo Contatto</em>"
+#: mod/message.php:594
+msgid "D, d M Y - g:i A"
+msgstr "D d M Y - G:i"
-#: mod/newmember.php:55
-msgid "Go to Your Site's Directory"
-msgstr "Vai all'Elenco del tuo sito"
+#: mod/message.php:597
+#, php-format
+msgid "%d message"
+msgid_plural "%d messages"
+msgstr[0] "%d messaggio"
+msgstr[1] "%d messaggi"
-#: mod/newmember.php:55
-msgid ""
-"The Directory page lets you find other people in this network or other "
-"federated sites. Look for a <em>Connect</em> or <em>Follow</em> link on "
-"their profile page. Provide your own Identity Address if requested."
-msgstr "La pagina Elenco ti permette di trovare altre persone in questa rete o in altri siti. Cerca un link <em>Connetti</em> o <em>Segui</em> nella loro pagina del profilo. Inserisci il tuo Indirizzo Identità, se richiesto."
+#: mod/notifications.php:38
+msgid "Invalid request identifier."
+msgstr "L'identificativo della richiesta non è valido."
-#: mod/newmember.php:57
-msgid "Finding New People"
-msgstr "Trova nuove persone"
+#: mod/notifications.php:47 mod/notifications.php:183
+#: mod/notifications.php:230
+msgid "Discard"
+msgstr "Scarta"
-#: mod/newmember.php:57
-msgid ""
-"On the side panel of the Contacts page are several tools to find new "
-"friends. We can match people by interest, look up people by name or "
-"interest, and provide suggestions based on network relationships. On a brand"
-" new site, friend suggestions will usually begin to be populated within 24 "
-"hours."
-msgstr "Nel pannello laterale nella pagina \"Contatti\", ci sono diversi strumenti per trovare nuovi amici. Possiamo confrontare le persone per interessi, cercare le persone per nome e fornire suggerimenti basati sui tuoi contatti esistenti. Su un sito nuovo, i suggerimenti sono di solito presenti dopo 24 ore."
+#: mod/notifications.php:63 mod/notifications.php:182
+#: mod/notifications.php:266 mod/contacts.php:636 mod/contacts.php:836
+#: mod/contacts.php:1021
+msgid "Ignore"
+msgstr "Ignora"
-#: mod/newmember.php:65
-msgid "Group Your Contacts"
-msgstr "Raggruppa i tuoi contatti"
+#: mod/notifications.php:108
+msgid "Network Notifications"
+msgstr "Notifiche dalla rete"
-#: mod/newmember.php:65
-msgid ""
-"Once you have made some friends, organize them into private conversation "
-"groups from the sidebar of your Contacts page and then you can interact with"
-" each group privately on your Network page."
-msgstr "Quando avrai alcuni amici, organizzali in gruppi di conversazioni private dalla barra laterale della tua pagina Contatti. Potrai interagire privatamente con ogni gruppo nella tua pagina Rete"
+#: mod/notifications.php:114 mod/notify.php:73
+msgid "System Notifications"
+msgstr "Notifiche di sistema"
-#: mod/newmember.php:68
-msgid "Why Aren't My Posts Public?"
-msgstr "Perché i miei post non sono pubblici?"
+#: mod/notifications.php:120
+msgid "Personal Notifications"
+msgstr "Notifiche personali"
-#: mod/newmember.php:68
-msgid ""
-"Friendica respects your privacy. By default, your posts will only show up to"
-" people you've added as friends. For more information, see the help section "
-"from the link above."
-msgstr "Friendica rispetta la tua privacy. Per impostazione predefinita, i tuoi post sono mostrati solo alle persone che hai aggiunto come amici. Per maggiori informazioni guarda la sezione della guida dal link qui sopra."
+#: mod/notifications.php:126
+msgid "Home Notifications"
+msgstr "Notifiche bacheca"
-#: mod/newmember.php:73
-msgid "Getting Help"
-msgstr "Ottenere Aiuto"
+#: mod/notifications.php:155
+msgid "Show Ignored Requests"
+msgstr "Mostra richieste ignorate"
-#: mod/newmember.php:77
-msgid "Go to the Help Section"
-msgstr "Vai alla sezione Guida"
+#: mod/notifications.php:155
+msgid "Hide Ignored Requests"
+msgstr "Nascondi richieste ignorate"
-#: mod/newmember.php:77
-msgid ""
-"Our <strong>help</strong> pages may be consulted for detail on other program"
-" features and resources."
-msgstr "Le nostre pagine della <strong>guida</strong> possono essere consultate per avere dettagli su altre caratteristiche del programma e altre risorse."
+#: mod/notifications.php:167 mod/notifications.php:237
+msgid "Notification type: "
+msgstr "Tipo di notifica: "
-#: mod/nogroup.php:65
-msgid "Contacts who are not members of a group"
-msgstr "Contatti che non sono membri di un gruppo"
+#: mod/notifications.php:170
+#, php-format
+msgid "suggested by %s"
+msgstr "suggerito da %s"
-#: mod/notify.php:65
-msgid "No more system notifications."
-msgstr "Nessuna nuova notifica di sistema."
+#: mod/notifications.php:175 mod/notifications.php:254 mod/contacts.php:643
+msgid "Hide this contact from others"
+msgstr "Nascondi questo contatto agli altri"
-#: mod/notify.php:69 mod/notifications.php:111
-msgid "System Notifications"
-msgstr "Notifiche di sistema"
+#: mod/notifications.php:176 mod/notifications.php:255
+msgid "Post a new friend activity"
+msgstr "Invia una attività \"è ora amico con\""
-#: mod/oexchange.php:21
-msgid "Post successful."
-msgstr "Inviato!"
+#: mod/notifications.php:176 mod/notifications.php:255
+msgid "if applicable"
+msgstr "se applicabile"
-#: mod/ostatus_subscribe.php:14
-msgid "Subscribing to OStatus contacts"
-msgstr "Iscrizione a contatti OStatus"
+#: mod/notifications.php:179 mod/notifications.php:264 mod/admin.php:1628
+msgid "Approve"
+msgstr "Approva"
-#: mod/ostatus_subscribe.php:25
-msgid "No contact provided."
-msgstr "Nessun contatto disponibile."
+#: mod/notifications.php:198
+msgid "Claims to be known to you: "
+msgstr "Dice di conoscerti: "
-#: mod/ostatus_subscribe.php:31
-msgid "Couldn't fetch information for contact."
-msgstr "Non è stato possibile recuperare le informazioni del contatto."
+#: mod/notifications.php:199
+msgid "yes"
+msgstr "si"
-#: mod/ostatus_subscribe.php:40
-msgid "Couldn't fetch friends for contact."
-msgstr "Non è stato possibile recuperare gli amici del contatto."
+#: mod/notifications.php:199
+msgid "no"
+msgstr "no"
-#: mod/ostatus_subscribe.php:54 mod/repair_ostatus.php:44
-msgid "Done"
-msgstr "Fatto"
+#: mod/notifications.php:200 mod/notifications.php:205
+msgid "Shall your connection be bidirectional or not?"
+msgstr "La connessione dovrà essere bidirezionale o no?"
-#: mod/ostatus_subscribe.php:68
-msgid "success"
-msgstr "successo"
+#: mod/notifications.php:201 mod/notifications.php:206
+#, php-format
+msgid ""
+"Accepting %s as a friend allows %s to subscribe to your posts, and you will "
+"also receive updates from them in your news feed."
+msgstr "Accettando %s come amico permette a %s di seguire i tuoi post, e a te di riceverne gli aggiornamenti."
-#: mod/ostatus_subscribe.php:70
-msgid "failed"
-msgstr "fallito"
+#: mod/notifications.php:202
+#, php-format
+msgid ""
+"Accepting %s as a subscriber allows them to subscribe to your posts, but you"
+" will not receive updates from them in your news feed."
+msgstr "Accentrando %s come abbonato gli permette di abbonarsi ai tuoi messaggi, ma tu non riceverai aggiornamenti da lui."
-#: mod/ostatus_subscribe.php:78 mod/repair_ostatus.php:50
-msgid "Keep this window open until done."
-msgstr "Tieni questa finestra aperta fino a che ha finito."
+#: mod/notifications.php:207
+#, php-format
+msgid ""
+"Accepting %s as a sharer allows them to subscribe to your posts, but you "
+"will not receive updates from them in your news feed."
+msgstr "Accentando %s come condivisore, gli permetti di abbonarsi ai tuoi messaggi, ma tu non riceverai nessun aggiornamento da loro."
-#: mod/p.php:9
-msgid "Not Extended"
-msgstr "Not Extended"
+#: mod/notifications.php:218
+msgid "Friend"
+msgstr "Amico"
-#: mod/poke.php:196
-msgid "Poke/Prod"
-msgstr "Tocca/Pungola"
+#: mod/notifications.php:219
+msgid "Sharer"
+msgstr "Condivisore"
-#: mod/poke.php:197
-msgid "poke, prod or do other things to somebody"
-msgstr "tocca, pungola o fai altre cose a qualcuno"
-
-#: mod/poke.php:198
-msgid "Recipient"
-msgstr "Destinatario"
-
-#: mod/poke.php:199
-msgid "Choose what you wish to do to recipient"
-msgstr "Scegli cosa vuoi fare al destinatario"
-
-#: mod/poke.php:202
-msgid "Make this post private"
-msgstr "Rendi questo post privato"
-
-#: mod/profile_photo.php:44
-msgid "Image uploaded but image cropping failed."
-msgstr "L'immagine è stata caricata, ma il non è stato possibile ritagliarla."
+#: mod/notifications.php:219
+msgid "Subscriber"
+msgstr "Abbonato"
-#: mod/profile_photo.php:77 mod/profile_photo.php:85 mod/profile_photo.php:93
-#: mod/profile_photo.php:323
-#, php-format
-msgid "Image size reduction [%s] failed."
-msgstr "Il ridimensionamento dell'immagine [%s] è fallito."
+#: mod/notifications.php:275
+msgid "No introductions."
+msgstr "Nessuna presentazione."
-#: mod/profile_photo.php:127
-msgid ""
-"Shift-reload the page or clear browser cache if the new photo does not "
-"display immediately."
-msgstr "Ricarica la pagina con shift+F5 o cancella la cache del browser se la nuova foto non viene mostrata immediatamente."
+#: mod/notifications.php:316
+msgid "Show unread"
+msgstr "Mostra non letti"
-#: mod/profile_photo.php:137
-msgid "Unable to process image"
-msgstr "Impossibile elaborare l'immagine"
+#: mod/notifications.php:316
+msgid "Show all"
+msgstr "Mostra tutti"
-#: mod/profile_photo.php:156 mod/photos.php:813 mod/wall_upload.php:181
+#: mod/notifications.php:322
#, php-format
-msgid "Image exceeds size limit of %s"
-msgstr "La dimensione dell'immagine supera il limite di %s"
-
-#: mod/profile_photo.php:165 mod/photos.php:854 mod/wall_upload.php:218
-msgid "Unable to process image."
-msgstr "Impossibile caricare l'immagine."
-
-#: mod/profile_photo.php:254
-msgid "Upload File:"
-msgstr "Carica un file:"
-
-#: mod/profile_photo.php:255
-msgid "Select a profile:"
-msgstr "Seleziona un profilo:"
-
-#: mod/profile_photo.php:257
-msgid "Upload"
-msgstr "Carica"
-
-#: mod/profile_photo.php:260
-msgid "or"
-msgstr "o"
-
-#: mod/profile_photo.php:260
-msgid "skip this step"
-msgstr "salta questo passaggio"
-
-#: mod/profile_photo.php:260
-msgid "select a photo from your photo albums"
-msgstr "seleziona una foto dai tuoi album"
-
-#: mod/profile_photo.php:274
-msgid "Crop Image"
-msgstr "Ritaglia immagine"
-
-#: mod/profile_photo.php:275
-msgid "Please adjust the image cropping for optimum viewing."
-msgstr "Ritaglia l'immagine per una visualizzazione migliore."
-
-#: mod/profile_photo.php:277
-msgid "Done Editing"
-msgstr "Finito"
-
-#: mod/profile_photo.php:313
-msgid "Image uploaded successfully."
-msgstr "Immagine caricata con successo."
-
-#: mod/profile_photo.php:315 mod/photos.php:883 mod/wall_upload.php:257
-msgid "Image upload failed."
-msgstr "Caricamento immagine fallito."
-
-#: mod/profperm.php:20 mod/group.php:76 index.php:406
-msgid "Permission denied"
-msgstr "Permesso negato"
-
-#: mod/profperm.php:26 mod/profperm.php:57
-msgid "Invalid profile identifier."
-msgstr "Identificativo del profilo non valido."
-
-#: mod/profperm.php:103
-msgid "Profile Visibility Editor"
-msgstr "Modifica visibilità del profilo"
+msgid "No more %s notifications."
+msgstr "Nessun'altra notifica %s."
-#: mod/profperm.php:107 mod/group.php:262
-msgid "Click on a contact to add or remove."
-msgstr "Clicca su un contatto per aggiungerlo o rimuoverlo."
+#: mod/notify.php:69
+msgid "No more system notifications."
+msgstr "Nessuna nuova notifica di sistema."
-#: mod/profperm.php:116
-msgid "Visible To"
-msgstr "Visibile a"
+#: mod/oexchange.php:25
+msgid "Post successful."
+msgstr "Inviato!"
-#: mod/profperm.php:132
-msgid "All Contacts (with secure profile access)"
-msgstr "Tutti i contatti (con profilo ad accesso sicuro)"
+#: mod/openid.php:25
+msgid "OpenID protocol error. No ID returned."
+msgstr "Errore protocollo OpenID. Nessun ID ricevuto."
-#: mod/regmod.php:58
-msgid "Account approved."
-msgstr "Account approvato."
+#: mod/openid.php:61
+msgid ""
+"Account not found and OpenID registration is not permitted on this site."
+msgstr "L'account non è stato trovato, e la registrazione via OpenID non è permessa su questo sito."
-#: mod/regmod.php:95
-#, php-format
-msgid "Registration revoked for %s"
-msgstr "Registrazione revocata per %s"
+#: mod/p.php:13
+msgid "Not Extended"
+msgstr "Not Extended"
-#: mod/regmod.php:107
-msgid "Please login."
-msgstr "Accedi."
+#: mod/profile.php:177
+msgid "Tips for New Members"
+msgstr "Consigli per i Nuovi Utenti"
-#: mod/removeme.php:52 mod/removeme.php:55
+#: mod/removeme.php:55 mod/removeme.php:58
msgid "Remove My Account"
msgstr "Rimuovi il mio account"
-#: mod/removeme.php:53
+#: mod/removeme.php:56
msgid ""
"This will completely remove your account. Once this has been done it is not "
"recoverable."
msgstr "Questo comando rimuoverà completamente il tuo account. Una volta rimosso non potrai più recuperarlo."
-#: mod/removeme.php:54
+#: mod/removeme.php:57
msgid "Please enter your password for verification:"
msgstr "Inserisci la tua password per verifica:"
-#: mod/repair_ostatus.php:14
+#: mod/repair_ostatus.php:17
msgid "Resubscribing to OStatus contacts"
msgstr "Risottoscrivi i contatti OStatus"
-#: mod/repair_ostatus.php:30
+#: mod/repair_ostatus.php:33
msgid "Error"
msgstr "Errore"
-#: mod/subthread.php:104
+#: mod/repair_ostatus.php:47 mod/ostatus_subscribe.php:57
+msgid "Done"
+msgstr "Fatto"
+
+#: mod/repair_ostatus.php:53 mod/ostatus_subscribe.php:81
+msgid "Keep this window open until done."
+msgstr "Tieni questa finestra aperta fino a che ha finito."
+
+#: mod/subthread.php:106
#, php-format
msgid "%1$s is following %2$s's %3$s"
msgstr "%1$s sta seguendo %3$s di %2$s"
-#: mod/suggest.php:27
-msgid "Do you really want to delete this suggestion?"
-msgstr "Vuoi veramente cancellare questo suggerimento?"
-
-#: mod/suggest.php:71
-msgid ""
-"No suggestions available. If this is a new site, please try again in 24 "
-"hours."
-msgstr "Nessun suggerimento disponibile. Se questo è un sito nuovo, riprova tra 24 ore."
-
-#: mod/suggest.php:84 mod/suggest.php:104
-msgid "Ignore/Hide"
-msgstr "Ignora / Nascondi"
-
-#: mod/tagrm.php:43
+#: mod/tagrm.php:46
msgid "Tag removed"
msgstr "Tag rimosso"
-#: mod/tagrm.php:82
+#: mod/tagrm.php:85
msgid "Remove Item Tag"
msgstr "Rimuovi il tag"
-#: mod/tagrm.php:84
+#: mod/tagrm.php:87
msgid "Select a tag to remove: "
msgstr "Seleziona un tag da rimuovere: "
-#: mod/uimport.php:51 mod/register.php:198
-msgid ""
-"This site has exceeded the number of allowed daily account registrations. "
-"Please try again tomorrow."
-msgstr "Questo sito ha superato il numero di registrazioni giornaliere consentite. Prova di nuovo domani."
-
-#: mod/uimport.php:66 mod/register.php:295
-msgid "Import"
-msgstr "Importa"
-
-#: mod/uimport.php:68
-msgid "Move account"
-msgstr "Muovi account"
-
-#: mod/uimport.php:69
-msgid "You can import an account from another Friendica server."
-msgstr "Puoi importare un account da un altro server Friendica."
+#: mod/tagrm.php:98 mod/delegate.php:139
+msgid "Remove"
+msgstr "Rimuovi"
-#: mod/uimport.php:70
-msgid ""
-"You need to export your account from the old server and upload it here. We "
-"will recreate your old account here with all your contacts. We will try also"
-" to inform your friends that you moved here."
-msgstr "Devi esportare il tuo account dal vecchio server e caricarlo qui. Noi ricreeremo il tuo vecchio account qui, con tutti i tuoi contatti. Proveremo anche a informare i tuoi amici che ti sei spostato qui."
+#: mod/uexport.php:39
+msgid "Export account"
+msgstr "Esporta account"
-#: mod/uimport.php:71
+#: mod/uexport.php:39
msgid ""
-"This feature is experimental. We can't import contacts from the OStatus "
-"network (GNU Social/Statusnet) or from Diaspora"
-msgstr "Questa funzione è sperimentale. Non possiamo importare i contatti dalla rete OStatus (GNU Social/Statusnet) o da Diaspora"
+"Export your account info and contacts. Use this to make a backup of your "
+"account and/or to move it to another server."
+msgstr "Esporta le informazioni del tuo account e dei contatti. Usa questa funzione per fare un backup del tuo account o per spostarlo in un altro server."
-#: mod/uimport.php:72
-msgid "Account file"
-msgstr "File account"
+#: mod/uexport.php:40
+msgid "Export all"
+msgstr "Esporta tutto"
-#: mod/uimport.php:72
+#: mod/uexport.php:40
msgid ""
-"To export your account, go to \"Settings->Export your personal data\" and "
-"select \"Export account\""
-msgstr "Per esportare il tuo account, vai su \"Impostazioni -> Esporta i tuoi dati personali\" e seleziona \"Esporta account\""
-
-#: mod/update_community.php:19 mod/update_display.php:23
-#: mod/update_network.php:27 mod/update_notes.php:36 mod/update_profile.php:35
-msgid "[Embedded content - reload page to view]"
-msgstr "[Contenuto incorporato - ricarica la pagina per visualizzarlo correttamente]"
-
-#: mod/viewcontacts.php:75
-msgid "No contacts."
-msgstr "Nessun contatto."
-
-#: mod/viewsrc.php:7
-msgid "Access denied."
-msgstr "Accesso negato."
-
-#: mod/wall_attach.php:17 mod/wall_attach.php:25 mod/wall_attach.php:76
-#: mod/wall_upload.php:36 mod/wall_upload.php:52 mod/wall_upload.php:110
-#: mod/wall_upload.php:150 mod/wall_upload.php:153
-msgid "Invalid request."
-msgstr "Richiesta non valida."
-
-#: mod/wall_attach.php:94
-msgid "Sorry, maybe your upload is bigger than the PHP configuration allows"
-msgstr "Mi spiace, forse il file che stai caricando è più grosso di quanto la configurazione di PHP permetta"
-
-#: mod/wall_attach.php:94
-msgid "Or - did you try to upload an empty file?"
-msgstr "O.. non avrai provato a caricare un file vuoto?"
-
-#: mod/wall_attach.php:105
-#, php-format
-msgid "File exceeds size limit of %s"
-msgstr "Il file supera la dimensione massima di %s"
+"Export your accout info, contacts and all your items as json. Could be a "
+"very big file, and could take a lot of time. Use this to make a full backup "
+"of your account (photos are not exported)"
+msgstr "Esporta le informazioni del tuo account, i tuoi contatti e tutti i tuoi elementi in json. Può diventare un file veramente molto grosso e metterci un sacco di tempo. Usa questa funzione per fare un backup completo del tuo account (le foto non sono esportate)"
-#: mod/wall_attach.php:158 mod/wall_attach.php:174
-msgid "File upload failed."
-msgstr "Caricamento del file non riuscito."
+#: mod/uexport.php:47 mod/settings.php:95
+msgid "Export personal data"
+msgstr "Esporta dati personali"
-#: mod/wallmessage.php:42 mod/wallmessage.php:106
+#: mod/wallmessage.php:45 mod/wallmessage.php:109
#, php-format
msgid "Number of daily wall messages for %s exceeded. Message failed."
msgstr "Numero giornaliero di messaggi per %s superato. Invio fallito."
-#: mod/wallmessage.php:50 mod/message.php:60
-msgid "No recipient selected."
-msgstr "Nessun destinatario selezionato."
-
-#: mod/wallmessage.php:53
+#: mod/wallmessage.php:56
msgid "Unable to check your home location."
msgstr "Impossibile controllare la tua posizione di origine."
-#: mod/wallmessage.php:56 mod/message.php:67
-msgid "Message could not be sent."
-msgstr "Il messaggio non può essere inviato."
-
-#: mod/wallmessage.php:59 mod/message.php:70
-msgid "Message collection failure."
-msgstr "Errore recuperando il messaggio."
-
-#: mod/wallmessage.php:62 mod/message.php:73
-msgid "Message sent."
-msgstr "Messaggio inviato."
-
-#: mod/wallmessage.php:80 mod/wallmessage.php:89
+#: mod/wallmessage.php:83 mod/wallmessage.php:92
msgid "No recipient."
msgstr "Nessun destinatario."
-#: mod/wallmessage.php:126 mod/message.php:322
-msgid "Send Private Message"
-msgstr "Invia un messaggio privato"
-
-#: mod/wallmessage.php:127
+#: mod/wallmessage.php:130
#, php-format
msgid ""
"If you wish for %s to respond, please check that the privacy settings on "
"your site allow private mail from unknown senders."
msgstr "Se vuoi che %s ti risponda, controlla che le tue impostazioni di privacy permettano la ricezione di messaggi privati da mittenti sconosciuti."
-#: mod/wallmessage.php:128 mod/message.php:323 mod/message.php:510
-msgid "To:"
-msgstr "A:"
-
-#: mod/wallmessage.php:129 mod/message.php:328 mod/message.php:512
-msgid "Subject:"
-msgstr "Oggetto:"
+#: mod/delegate.php:101
+msgid "No potential page delegates located."
+msgstr "Nessun potenziale delegato per la pagina è stato trovato."
-#: mod/babel.php:16
-msgid "Source (bbcode) text:"
-msgstr "Testo sorgente (bbcode):"
+#: mod/delegate.php:132
+msgid ""
+"Delegates are able to manage all aspects of this account/page except for "
+"basic account settings. Please do not delegate your personal account to "
+"anybody that you do not trust completely."
+msgstr "I Delegati sono in grado di gestire tutti gli aspetti di questa pagina, tranne per le impostazioni di base dell'account. Non delegare il tuo account personale a nessuno di cui non ti fidi ciecamente."
-#: mod/babel.php:23
-msgid "Source (Diaspora) text to convert to BBcode:"
-msgstr "Testo sorgente (da Diaspora) da convertire in BBcode:"
+#: mod/delegate.php:133
+msgid "Existing Page Managers"
+msgstr "Gestori Pagina Esistenti"
-#: mod/babel.php:31
-msgid "Source input: "
-msgstr "Sorgente:"
+#: mod/delegate.php:135
+msgid "Existing Page Delegates"
+msgstr "Delegati Pagina Esistenti"
-#: mod/babel.php:35
-msgid "bb2html (raw HTML): "
-msgstr "bb2html (HTML grezzo):"
+#: mod/delegate.php:137
+msgid "Potential Delegates"
+msgstr "Delegati Potenziali"
-#: mod/babel.php:39
-msgid "bb2html: "
-msgstr "bb2html:"
+#: mod/delegate.php:140
+msgid "Add"
+msgstr "Aggiungi"
-#: mod/babel.php:43
-msgid "bb2html2bb: "
-msgstr "bb2html2bb: "
+#: mod/delegate.php:141
+msgid "No entries."
+msgstr "Nessuna voce."
-#: mod/babel.php:47
-msgid "bb2md: "
-msgstr "bb2md: "
+#: mod/suggest.php:30
+msgid "Do you really want to delete this suggestion?"
+msgstr "Vuoi veramente cancellare questo suggerimento?"
-#: mod/babel.php:51
-msgid "bb2md2html: "
-msgstr "bb2md2html: "
-
-#: mod/babel.php:55
-msgid "bb2dia2bb: "
-msgstr "bb2dia2bb: "
+#: mod/suggest.php:71
+msgid ""
+"No suggestions available. If this is a new site, please try again in 24 "
+"hours."
+msgstr "Nessun suggerimento disponibile. Se questo è un sito nuovo, riprova tra 24 ore."
-#: mod/babel.php:59
-msgid "bb2md2html2bb: "
-msgstr "bb2md2html2bb: "
+#: mod/suggest.php:84 mod/suggest.php:104
+msgid "Ignore/Hide"
+msgstr "Ignora / Nascondi"
-#: mod/babel.php:65
-msgid "Source input (Diaspora format): "
-msgstr "Sorgente (formato Diaspora):"
+#: mod/directory.php:193 view/theme/vier/theme.php:194
+msgid "Global Directory"
+msgstr "Elenco globale"
-#: mod/babel.php:69
-msgid "diaspora2bb: "
-msgstr "diaspora2bb: "
+#: mod/directory.php:195
+msgid "Find on this site"
+msgstr "Cerca nel sito"
-#: mod/cal.php:271 mod/events.php:375
-msgid "View"
-msgstr "Mostra"
+#: mod/directory.php:197
+msgid "Results for:"
+msgstr "Risultati per:"
-#: mod/cal.php:272 mod/events.php:377
-msgid "Previous"
-msgstr "Precedente"
+#: mod/directory.php:199
+msgid "Site Directory"
+msgstr "Elenco del sito"
-#: mod/cal.php:273 mod/events.php:378 mod/install.php:201
-msgid "Next"
-msgstr "Successivo"
+#: mod/directory.php:206
+msgid "No entries (some entries may be hidden)."
+msgstr "Nessuna voce (qualche voce potrebbe essere nascosta)."
-#: mod/cal.php:282 mod/events.php:387
-msgid "list"
-msgstr "lista"
+#: mod/fbrowser.php:136
+msgid "Files"
+msgstr "File"
-#: mod/cal.php:292
-msgid "User not found"
-msgstr "Utente non trovato"
+#: mod/friendica.php:70
+msgid "This is Friendica, version"
+msgstr "Questo è Friendica, versione"
-#: mod/cal.php:308
-msgid "This calendar format is not supported"
-msgstr "Questo formato di calendario non è supportato"
+#: mod/friendica.php:71
+msgid "running at web location"
+msgstr "in esecuzione all'indirizzo web"
-#: mod/cal.php:310
-msgid "No exportable data found"
-msgstr "Nessun dato esportabile trovato"
+#: mod/friendica.php:75
+msgid ""
+"Please visit <a href=\"https://friendi.ca\">Friendi.ca</a> to learn more "
+"about the Friendica project."
+msgstr "Visita <a href=\"https://friendi.ca\">Friendi.ca</a> per saperne di più sul progetto Friendica."
-#: mod/cal.php:325
-msgid "calendar"
-msgstr "calendario"
+#: mod/friendica.php:79
+msgid "Bug reports and issues: please visit"
+msgstr "Segnalazioni di bug e problemi: visita"
-#: mod/community.php:23
-msgid "Not available."
-msgstr "Non disponibile."
+#: mod/friendica.php:79
+msgid "the bugtracker at github"
+msgstr "il bugtracker su github"
-#: mod/community.php:50 mod/search.php:219
-msgid "No results."
-msgstr "Nessun risultato."
+#: mod/friendica.php:82
+msgid ""
+"Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - "
+"dot com"
+msgstr "Suggerimenti, lodi, donazioni, ecc - e-mail a \"Info\" at Friendica punto com"
-#: mod/dfrn_confirm.php:70 mod/profiles.php:19 mod/profiles.php:135
-#: mod/profiles.php:182 mod/profiles.php:619
-msgid "Profile not found."
-msgstr "Profilo non trovato."
+#: mod/friendica.php:96
+msgid "Installed plugins/addons/apps:"
+msgstr "Plugin/componenti aggiuntivi/applicazioni installate"
-#: mod/dfrn_confirm.php:127
-msgid ""
-"This may occasionally happen if contact was requested by both persons and it"
-" has already been approved."
-msgstr "Questo può accadere occasionalmente se la richiesta di contatto era stata inviata da entrambe le persone e già approvata."
+#: mod/friendica.php:110
+msgid "No installed plugins/addons/apps"
+msgstr "Nessun plugin/componente aggiuntivo/applicazione installata"
-#: mod/dfrn_confirm.php:244
-msgid "Response from remote site was not understood."
-msgstr "Errore di comunicazione con l'altro sito."
+#: mod/friendica.php:115
+msgid "On this server the following remote servers are blocked."
+msgstr "In questo server i seguenti server remoti sono bloccati."
-#: mod/dfrn_confirm.php:253 mod/dfrn_confirm.php:258
-msgid "Unexpected response from remote site: "
-msgstr "La risposta dell'altro sito non può essere gestita: "
+#: mod/friendica.php:116 mod/admin.php:291 mod/admin.php:309
+msgid "Reason for the block"
+msgstr "Motivazione del blocco"
-#: mod/dfrn_confirm.php:267
-msgid "Confirmation completed successfully."
-msgstr "Conferma completata con successo."
+#: mod/install.php:107
+msgid "Friendica Communications Server - Setup"
+msgstr "Friendica Comunicazione Server - Impostazioni"
-#: mod/dfrn_confirm.php:269 mod/dfrn_confirm.php:283 mod/dfrn_confirm.php:290
-msgid "Remote site reported: "
-msgstr "Il sito remoto riporta: "
+#: mod/install.php:113
+msgid "Could not connect to database."
+msgstr " Impossibile collegarsi con il database."
-#: mod/dfrn_confirm.php:281
-msgid "Temporary failure. Please wait and try again."
-msgstr "Problema temporaneo. Attendi e riprova."
+#: mod/install.php:117
+msgid "Could not create table."
+msgstr "Impossibile creare le tabelle."
-#: mod/dfrn_confirm.php:288
-msgid "Introduction failed or was revoked."
-msgstr "La presentazione ha generato un errore o è stata revocata."
+#: mod/install.php:123
+msgid "Your Friendica site database has been installed."
+msgstr "Il tuo Friendica è stato installato."
-#: mod/dfrn_confirm.php:418
-msgid "Unable to set contact photo."
-msgstr "Impossibile impostare la foto del contatto."
+#: mod/install.php:128
+msgid ""
+"You may need to import the file \"database.sql\" manually using phpmyadmin "
+"or mysql."
+msgstr "Potresti dover importare il file \"database.sql\" manualmente con phpmyadmin o mysql"
-#: mod/dfrn_confirm.php:559
-#, php-format
-msgid "No user record found for '%s' "
-msgstr "Nessun utente trovato '%s'"
+#: mod/install.php:129 mod/install.php:201 mod/install.php:548
+msgid "Please see the file \"INSTALL.txt\"."
+msgstr "Leggi il file \"INSTALL.txt\"."
-#: mod/dfrn_confirm.php:569
-msgid "Our site encryption key is apparently messed up."
-msgstr "La nostra chiave di criptazione del sito sembra essere corrotta."
+#: mod/install.php:141
+msgid "Database already in use."
+msgstr "Database già in uso."
-#: mod/dfrn_confirm.php:580
-msgid "Empty site URL was provided or URL could not be decrypted by us."
-msgstr "E' stato fornito un indirizzo vuoto o non possiamo decrittare l'indirizzo."
+#: mod/install.php:198
+msgid "System check"
+msgstr "Controllo sistema"
-#: mod/dfrn_confirm.php:602
-msgid "Contact record was not found for you on our site."
-msgstr "Il contatto non è stato trovato sul nostro sito."
+#: mod/install.php:203
+msgid "Check again"
+msgstr "Controlla ancora"
-#: mod/dfrn_confirm.php:616
-#, php-format
-msgid "Site public key not available in contact record for URL %s."
-msgstr "La chiave pubblica del sito non è disponibile per l'URL %s"
+#: mod/install.php:222
+msgid "Database connection"
+msgstr "Connessione al database"
-#: mod/dfrn_confirm.php:636
+#: mod/install.php:223
msgid ""
-"The ID provided by your system is a duplicate on our system. It should work "
-"if you try again."
-msgstr "L'ID fornito dal tuo sistema è duplicato sul nostro sistema. Se riprovi dovrebbe funzionare."
+"In order to install Friendica we need to know how to connect to your "
+"database."
+msgstr "Per installare Friendica dobbiamo sapere come collegarci al tuo database."
-#: mod/dfrn_confirm.php:647
-msgid "Unable to set your contact credentials on our system."
-msgstr "Impossibile impostare le credenziali del tuo contatto sul nostro sistema."
+#: mod/install.php:224
+msgid ""
+"Please contact your hosting provider or site administrator if you have "
+"questions about these settings."
+msgstr "Contatta il tuo fornitore di hosting o l'amministratore del sito se hai domande su queste impostazioni."
-#: mod/dfrn_confirm.php:709
-msgid "Unable to update your contact profile details on our system"
-msgstr "Impossibile aggiornare i dettagli del tuo contatto sul nostro sistema"
+#: mod/install.php:225
+msgid ""
+"The database you specify below should already exist. If it does not, please "
+"create it before continuing."
+msgstr "Il database dovrà già esistere. Se non esiste, crealo prima di continuare."
-#: mod/dfrn_confirm.php:781
-#, php-format
-msgid "%1$s has joined %2$s"
-msgstr "%1$s si è unito a %2$s"
+#: mod/install.php:229
+msgid "Database Server Name"
+msgstr "Nome del database server"
-#: mod/dfrn_request.php:101
-msgid "This introduction has already been accepted."
-msgstr "Questa presentazione è già stata accettata."
+#: mod/install.php:230
+msgid "Database Login Name"
+msgstr "Nome utente database"
-#: mod/dfrn_request.php:124 mod/dfrn_request.php:528
-msgid "Profile location is not valid or does not contain profile information."
-msgstr "L'indirizzo del profilo non è valido o non contiene un profilo."
+#: mod/install.php:231
+msgid "Database Login Password"
+msgstr "Password utente database"
-#: mod/dfrn_request.php:129 mod/dfrn_request.php:533
-msgid "Warning: profile location has no identifiable owner name."
-msgstr "Attenzione: l'indirizzo del profilo non riporta il nome del proprietario."
+#: mod/install.php:231
+msgid "For security reasons the password must not be empty"
+msgstr "Per motivi di sicurezza la password non puo' essere vuota."
-#: mod/dfrn_request.php:132 mod/dfrn_request.php:536
-msgid "Warning: profile location has no profile photo."
-msgstr "Attenzione: l'indirizzo del profilo non ha una foto."
+#: mod/install.php:232
+msgid "Database Name"
+msgstr "Nome database"
-#: mod/dfrn_request.php:136 mod/dfrn_request.php:540
-#, php-format
-msgid "%d required parameter was not found at the given location"
-msgid_plural "%d required parameters were not found at the given location"
-msgstr[0] "%d parametro richiesto non è stato trovato all'indirizzo dato"
-msgstr[1] "%d parametri richiesti non sono stati trovati all'indirizzo dato"
+#: mod/install.php:233 mod/install.php:274
+msgid "Site administrator email address"
+msgstr "Indirizzo email dell'amministratore del sito"
-#: mod/dfrn_request.php:180
-msgid "Introduction complete."
-msgstr "Presentazione completa."
+#: mod/install.php:233 mod/install.php:274
+msgid ""
+"Your account email address must match this in order to use the web admin "
+"panel."
+msgstr "Il tuo indirizzo email deve corrispondere a questo per poter usare il pannello di amministrazione web."
-#: mod/dfrn_request.php:225
-msgid "Unrecoverable protocol error."
-msgstr "Errore di comunicazione."
+#: mod/install.php:237 mod/install.php:277
+msgid "Please select a default timezone for your website"
+msgstr "Seleziona il fuso orario predefinito per il tuo sito web"
-#: mod/dfrn_request.php:253
-msgid "Profile unavailable."
-msgstr "Profilo non disponibile."
+#: mod/install.php:264
+msgid "Site settings"
+msgstr "Impostazioni sito"
-#: mod/dfrn_request.php:280
-#, php-format
-msgid "%s has received too many connection requests today."
-msgstr "%s ha ricevuto troppe richieste di connessione per oggi."
+#: mod/install.php:278
+msgid "System Language:"
+msgstr "Lingua di Sistema:"
-#: mod/dfrn_request.php:281
-msgid "Spam protection measures have been invoked."
-msgstr "Sono state attivate le misure di protezione contro lo spam."
+#: mod/install.php:278
+msgid ""
+"Set the default language for your Friendica installation interface and to "
+"send emails."
+msgstr "Imposta la lingua di default per l'interfaccia e l'invio delle email."
-#: mod/dfrn_request.php:282
-msgid "Friends are advised to please try again in 24 hours."
-msgstr "Gli amici sono pregati di riprovare tra 24 ore."
+#: mod/install.php:318
+msgid "Could not find a command line version of PHP in the web server PATH."
+msgstr "Non riesco a trovare la versione di PHP da riga di comando nel PATH del server web"
-#: mod/dfrn_request.php:344
-msgid "Invalid locator"
-msgstr "Indirizzo non valido"
+#: mod/install.php:319
+msgid ""
+"If you don't have a command line version of PHP installed on server, you "
+"will not be able to run the background processing. See <a "
+"href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-"
+"up-the-poller'>'Setup the poller'</a>"
+msgstr "Se non hai la versione a riga di comando di PHP installata sul tuo server, non sarai in grado di eseguire i processi in background. Vedi <a href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-poller'>'Setup the poller'</a>"
-#: mod/dfrn_request.php:353
-msgid "Invalid email address."
-msgstr "Indirizzo email non valido."
+#: mod/install.php:323
+msgid "PHP executable path"
+msgstr "Percorso eseguibile PHP"
-#: mod/dfrn_request.php:378
-msgid "This account has not been configured for email. Request failed."
-msgstr "Questo account non è stato configurato per l'email. Richiesta fallita."
+#: mod/install.php:323
+msgid ""
+"Enter full path to php executable. You can leave this blank to continue the "
+"installation."
+msgstr "Inserisci il percorso completo all'eseguibile di php. Puoi lasciare bianco questo campo per continuare l'installazione."
-#: mod/dfrn_request.php:481
-msgid "You have already introduced yourself here."
-msgstr "Ti sei già presentato qui."
+#: mod/install.php:328
+msgid "Command line PHP"
+msgstr "PHP da riga di comando"
-#: mod/dfrn_request.php:485
-#, php-format
-msgid "Apparently you are already friends with %s."
-msgstr "Pare che tu e %s siate già amici."
+#: mod/install.php:337
+msgid "PHP executable is not the php cli binary (could be cgi-fgci version)"
+msgstr "L'eseguibile PHP non è il binario php cli (potrebbe essere la versione cgi-fcgi)"
-#: mod/dfrn_request.php:506
-msgid "Invalid profile URL."
-msgstr "Indirizzo profilo non valido."
+#: mod/install.php:338
+msgid "Found PHP version: "
+msgstr "Versione PHP:"
-#: mod/dfrn_request.php:614
-msgid "Your introduction has been sent."
-msgstr "La tua presentazione è stata inviata."
+#: mod/install.php:340
+msgid "PHP cli binary"
+msgstr "Binario PHP cli"
-#: mod/dfrn_request.php:656
+#: mod/install.php:351
msgid ""
-"Remote subscription can't be done for your network. Please subscribe "
-"directly on your system."
-msgstr "La richiesta di connessione remota non può essere effettuata per la tua rete. Invia la richiesta direttamente sul nostro sistema."
+"The command line version of PHP on your system does not have "
+"\"register_argc_argv\" enabled."
+msgstr "La versione da riga di comando di PHP nel sistema non ha abilitato \"register_argc_argv\"."
-#: mod/dfrn_request.php:677
-msgid "Please login to confirm introduction."
-msgstr "Accedi per confermare la presentazione."
+#: mod/install.php:352
+msgid "This is required for message delivery to work."
+msgstr "E' obbligatorio per far funzionare la consegna dei messaggi."
-#: mod/dfrn_request.php:687
+#: mod/install.php:354
+msgid "PHP register_argc_argv"
+msgstr "PHP register_argc_argv"
+
+#: mod/install.php:377
msgid ""
-"Incorrect identity currently logged in. Please login to "
-"<strong>this</strong> profile."
-msgstr "Non hai fatto accesso con l'identità corretta. Accedi a <strong>questo</strong> profilo."
+"Error: the \"openssl_pkey_new\" function on this system is not able to "
+"generate encryption keys"
+msgstr "Errore: la funzione \"openssl_pkey_new\" in questo sistema non è in grado di generare le chiavi di criptazione"
-#: mod/dfrn_request.php:701 mod/dfrn_request.php:718
-msgid "Confirm"
-msgstr "Conferma"
+#: mod/install.php:378
+msgid ""
+"If running under Windows, please see "
+"\"http://www.php.net/manual/en/openssl.installation.php\"."
+msgstr "Se stai eseguendo friendika su windows, guarda \"http://www.php.net/manual/en/openssl.installation.php\"."
-#: mod/dfrn_request.php:713
-msgid "Hide this contact"
-msgstr "Nascondi questo contatto"
+#: mod/install.php:380
+msgid "Generate encryption keys"
+msgstr "Genera chiavi di criptazione"
-#: mod/dfrn_request.php:716
-#, php-format
-msgid "Welcome home %s."
-msgstr "Bentornato a casa %s."
+#: mod/install.php:387
+msgid "libCurl PHP module"
+msgstr "modulo PHP libCurl"
-#: mod/dfrn_request.php:717
-#, php-format
-msgid "Please confirm your introduction/connection request to %s."
-msgstr "Conferma la tua richiesta di connessione con %s."
+#: mod/install.php:388
+msgid "GD graphics PHP module"
+msgstr "modulo PHP GD graphics"
-#: mod/dfrn_request.php:848
-msgid ""
-"Please enter your 'Identity Address' from one of the following supported "
-"communications networks:"
-msgstr "Inserisci il tuo 'Indirizzo Identità' da uno dei seguenti network supportati:"
+#: mod/install.php:389
+msgid "OpenSSL PHP module"
+msgstr "modulo PHP OpenSSL"
-#: mod/dfrn_request.php:872
-#, php-format
-msgid ""
-"If you are not yet a member of the free social web, <a "
-"href=\"%s/siteinfo\">follow this link to find a public Friendica site and "
-"join us today</a>."
-msgstr "Se non sei un membro del web sociale libero, <a href=\"%s/siteinfo\">segui questo link per trovare un sito Friendica pubblico e unisciti a noi oggi</a>"
+#: mod/install.php:390
+msgid "PDO or MySQLi PHP module"
+msgstr "modulo PHP PDO o MySQLi"
-#: mod/dfrn_request.php:877
-msgid "Friend/Connection Request"
-msgstr "Richieste di amicizia/connessione"
+#: mod/install.php:391
+msgid "mb_string PHP module"
+msgstr "modulo PHP mb_string"
-#: mod/dfrn_request.php:878
-msgid ""
-"Examples: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, "
-"testuser@identi.ca"
-msgstr "Esempi: jojo@demo.friendica.com, http://demo.friendica.com/profile/jojo, testuser@identi.ca"
+#: mod/install.php:392
+msgid "XML PHP module"
+msgstr "Modulo PHP XML"
-#: mod/dfrn_request.php:879 mod/follow.php:112
-msgid "Please answer the following:"
-msgstr "Rispondi:"
+#: mod/install.php:393
+msgid "iconv module"
+msgstr "modulo iconv"
-#: mod/dfrn_request.php:880 mod/follow.php:113
-#, php-format
-msgid "Does %s know you?"
-msgstr "%s ti conosce?"
+#: mod/install.php:397 mod/install.php:399
+msgid "Apache mod_rewrite module"
+msgstr "Modulo mod_rewrite di Apache"
-#: mod/dfrn_request.php:884 mod/follow.php:114
-msgid "Add a personal note:"
-msgstr "Aggiungi una nota personale:"
+#: mod/install.php:397
+msgid ""
+"Error: Apache webserver mod-rewrite module is required but not installed."
+msgstr "Errore: E' il modulo mod-rewrite di Apache è richiesto, ma non risulta installato"
-#: mod/dfrn_request.php:887
-msgid "StatusNet/Federated Social Web"
-msgstr "StatusNet/Federated Social Web"
+#: mod/install.php:405
+msgid "Error: libCURL PHP module required but not installed."
+msgstr "Errore: il modulo libCURL di PHP è richiesto, ma non risulta installato."
-#: mod/dfrn_request.php:889
-#, php-format
+#: mod/install.php:409
msgid ""
-" - please do not use this form. Instead, enter %s into your Diaspora search"
-" bar."
-msgstr " - per favore non usare questa form. Invece, inserisci %s nella tua barra di ricerca su Diaspora."
+"Error: GD graphics PHP module with JPEG support required but not installed."
+msgstr "Errore: Il modulo GD graphics di PHP con supporto a JPEG è richiesto, ma non risulta installato."
-#: mod/dfrn_request.php:890 mod/follow.php:120
-msgid "Your Identity Address:"
-msgstr "L'indirizzo della tua identità:"
+#: mod/install.php:413
+msgid "Error: openssl PHP module required but not installed."
+msgstr "Errore: il modulo openssl di PHP è richiesto, ma non risulta installato."
-#: mod/dfrn_request.php:893 mod/follow.php:19
-msgid "Submit Request"
-msgstr "Invia richiesta"
+#: mod/install.php:417
+msgid "Error: PDO or MySQLi PHP module required but not installed."
+msgstr "Errore: uno dei due moduli PHP PDO o MySQLi è richiesto ma non installato."
-#: mod/dirfind.php:37
-#, php-format
-msgid "People Search - %s"
-msgstr "Cerca persone - %s"
+#: mod/install.php:421
+msgid "Error: The MySQL driver for PDO is not installed."
+msgstr "Errore: il driver MySQL per PDO non è installato."
-#: mod/dirfind.php:48
-#, php-format
-msgid "Forum Search - %s"
-msgstr "Ricerca Forum - %s"
+#: mod/install.php:425
+msgid "Error: mb_string PHP module required but not installed."
+msgstr "Errore: il modulo PHP mb_string è richiesto, ma non risulta installato."
-#: mod/events.php:93 mod/events.php:95
-msgid "Event can not end before it has started."
-msgstr "Un evento non può finire prima di iniziare."
+#: mod/install.php:429
+msgid "Error: iconv PHP module required but not installed."
+msgstr "Errore: il modulo PHP iconv è richiesto ma non installato."
-#: mod/events.php:102 mod/events.php:104
-msgid "Event title and start time are required."
-msgstr "Titolo e ora di inizio dell'evento sono richiesti."
+#: mod/install.php:439
+msgid "Error, XML PHP module required but not installed."
+msgstr "Errore, il modulo PHP XML è richiesto ma non installato."
-#: mod/events.php:376
-msgid "Create New Event"
-msgstr "Crea un nuovo evento"
+#: mod/install.php:451
+msgid ""
+"The web installer needs to be able to create a file called \".htconfig.php\""
+" in the top folder of your web server and it is unable to do so."
+msgstr "L'installazione web deve poter creare un file chiamato \".htconfig.php\" nella cartella principale del tuo web server ma non è in grado di farlo."
-#: mod/events.php:481
-msgid "Event details"
-msgstr "Dettagli dell'evento"
+#: mod/install.php:452
+msgid ""
+"This is most often a permission setting, as the web server may not be able "
+"to write files in your folder - even if you can."
+msgstr "Ciò è dovuto spesso a impostazioni di permessi, dato che il web server può non essere in grado di scrivere il file nella tua cartella, anche se tu puoi."
-#: mod/events.php:482
-msgid "Starting date and Title are required."
-msgstr "La data di inizio e il titolo sono richiesti."
+#: mod/install.php:453
+msgid ""
+"At the end of this procedure, we will give you a text to save in a file "
+"named .htconfig.php in your Friendica top folder."
+msgstr "Alla fine di questa procedura, di daremo un testo da salvare in un file chiamato .htconfig.php nella tua cartella principale di Friendica"
-#: mod/events.php:483 mod/events.php:484
-msgid "Event Starts:"
-msgstr "L'evento inizia:"
+#: mod/install.php:454
+msgid ""
+"You can alternatively skip this procedure and perform a manual installation."
+" Please see the file \"INSTALL.txt\" for instructions."
+msgstr "Puoi in alternativa saltare questa procedura ed eseguire l'installazione manualmente. Vedi il file \"INSTALL.txt\" per le istruzioni."
-#: mod/events.php:483 mod/events.php:495 mod/profiles.php:709
-msgid "Required"
-msgstr "Richiesto"
+#: mod/install.php:457
+msgid ".htconfig.php is writable"
+msgstr ".htconfig.php è scrivibile"
-#: mod/events.php:485 mod/events.php:501
-msgid "Finish date/time is not known or not relevant"
-msgstr "La data/ora di fine non è definita"
+#: mod/install.php:467
+msgid ""
+"Friendica uses the Smarty3 template engine to render its web views. Smarty3 "
+"compiles templates to PHP to speed up rendering."
+msgstr "Friendica usa il motore di template Smarty3 per renderizzare le sue pagine web. Smarty3 compila i template in PHP per velocizzare il rendering."
-#: mod/events.php:487 mod/events.php:488
-msgid "Event Finishes:"
-msgstr "L'evento finisce:"
+#: mod/install.php:468
+msgid ""
+"In order to store these compiled templates, the web server needs to have "
+"write access to the directory view/smarty3/ under the Friendica top level "
+"folder."
+msgstr "Per salvare questi template compilati, il server werb ha bisogno dell'accesso in scrittura alla cartella view/smarty3/ nella cartella principale dei Friendica."
-#: mod/events.php:489 mod/events.php:502
-msgid "Adjust for viewer timezone"
-msgstr "Visualizza con il fuso orario di chi legge"
+#: mod/install.php:469
+msgid ""
+"Please ensure that the user that your web server runs as (e.g. www-data) has"
+" write access to this folder."
+msgstr "Per favore, controlla che l'utente con cui il tuo server web gira (es www-data) ha accesso in scrittura a questa cartella."
-#: mod/events.php:491
-msgid "Description:"
-msgstr "Descrizione:"
+#: mod/install.php:470
+msgid ""
+"Note: as a security measure, you should give the web server write access to "
+"view/smarty3/ only--not the template files (.tpl) that it contains."
+msgstr "Nota: come misura di sicurezza, dovresti dare accesso in scrittura solo alla cartella view/smarty3, non ai template (.tpl) che contiene."
-#: mod/events.php:495 mod/events.php:497
-msgid "Title:"
-msgstr "Titolo:"
+#: mod/install.php:473
+msgid "view/smarty3 is writable"
+msgstr "view/smarty3 è scrivibile"
-#: mod/events.php:498 mod/events.php:499
-msgid "Share this event"
-msgstr "Condividi questo evento"
+#: mod/install.php:489
+msgid ""
+"Url rewrite in .htaccess is not working. Check your server configuration."
+msgstr "La riscrittura degli url in .htaccess non funziona. Controlla la configurazione del tuo server."
-#: mod/events.php:528
-msgid "Failed to remove event"
-msgstr "Rimozione evento fallita."
+#: mod/install.php:491
+msgid "Url rewrite is working"
+msgstr "La riscrittura degli url funziona"
-#: mod/events.php:530
-msgid "Event removed"
-msgstr "Evento rimosso"
+#: mod/install.php:510
+msgid "ImageMagick PHP extension is not installed"
+msgstr "L'estensione PHP ImageMagick non è installata"
-#: mod/follow.php:30
-msgid "You already added this contact."
-msgstr "Hai già aggiunto questo contatto."
+#: mod/install.php:512
+msgid "ImageMagick PHP extension is installed"
+msgstr "L'estensione PHP ImageMagick è installata"
-#: mod/follow.php:39
-msgid "Diaspora support isn't enabled. Contact can't be added."
-msgstr "Il supporto Diaspora non è abilitato. Il contatto non può essere aggiunto."
+#: mod/install.php:514
+msgid "ImageMagick supports GIF"
+msgstr "ImageMagick supporta i GIF"
-#: mod/follow.php:46
-msgid "OStatus support is disabled. Contact can't be added."
-msgstr "Il supporto OStatus non è abilitato. Il contatto non può essere aggiunto."
+#: mod/install.php:521
+msgid ""
+"The database configuration file \".htconfig.php\" could not be written. "
+"Please use the enclosed text to create a configuration file in your web "
+"server root."
+msgstr "Il file di configurazione del database \".htconfig.php\" non può essere scritto. Usa il testo qui di seguito per creare un file di configurazione nella cartella principale del tuo sito."
-#: mod/follow.php:53
-msgid "The network type couldn't be detected. Contact can't be added."
-msgstr "Non è possibile rilevare il tipo di rete. Il contatto non può essere aggiunto."
+#: mod/install.php:546
+msgid "<h1>What next</h1>"
+msgstr "<h1>Cosa fare ora</h1>"
-#: mod/follow.php:186
-msgid "Contact added"
-msgstr "Contatto aggiunto"
+#: mod/install.php:547
+msgid ""
+"IMPORTANT: You will need to [manually] setup a scheduled task for the "
+"poller."
+msgstr "IMPORTANTE: Devi impostare [manualmente] la pianificazione del poller."
-#: mod/friendica.php:68
-msgid "This is Friendica, version"
-msgstr "Questo è Friendica, versione"
+#: mod/search.php:28 mod/network.php:189
+msgid "Remove term"
+msgstr "Rimuovi termine"
-#: mod/friendica.php:69
-msgid "running at web location"
-msgstr "in esecuzione all'indirizzo web"
+#: mod/search.php:96
+msgid "Only logged in users are permitted to perform a search."
+msgstr "Solo agli utenti autenticati è permesso eseguire ricerche."
-#: mod/friendica.php:73
-msgid ""
-"Please visit <a href=\"http://friendica.com\">Friendica.com</a> to learn "
-"more about the Friendica project."
-msgstr "Visita <a href=\"http://friendica.com\">Friendica.com</a> per saperne di più sul progetto Friendica."
+#: mod/search.php:120
+msgid "Too Many Requests"
+msgstr "Troppe richieste"
-#: mod/friendica.php:77
-msgid "Bug reports and issues: please visit"
-msgstr "Segnalazioni di bug e problemi: visita"
+#: mod/search.php:121
+msgid "Only one search per minute is permitted for not logged in users."
+msgstr "Solo una ricerca al minuto è permessa agli utenti non autenticati."
-#: mod/friendica.php:77
-msgid "the bugtracker at github"
-msgstr "il bugtracker su github"
+#: mod/search.php:221
+#, php-format
+msgid "Items tagged with: %s"
+msgstr "Elementi taggati con: %s"
-#: mod/friendica.php:80
-msgid ""
-"Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - "
-"dot com"
-msgstr "Suggerimenti, lodi, donazioni, ecc - e-mail a \"Info\" at Friendica punto com"
+#: mod/search.php:223 mod/contacts.php:827
+#, php-format
+msgid "Results for: %s"
+msgstr "Risultati per: %s"
-#: mod/friendica.php:94
-msgid "Installed plugins/addons/apps:"
-msgstr "Plugin/componenti aggiuntivi/applicazioni installate"
+#: mod/unfollow.php:33
+msgid "Contact wasn't found or can't be unfollowed."
+msgstr ""
-#: mod/friendica.php:108
-msgid "No installed plugins/addons/apps"
-msgstr "Nessun plugin/componente aggiuntivo/applicazione installata"
+#: mod/unfollow.php:47
+msgid "Contact unfollowed"
+msgstr ""
-#: mod/friendica.php:113
-msgid "On this server the following remote servers are blocked."
-msgstr "In questo server i seguenti server remoti sono bloccati."
+#: mod/unfollow.php:73
+msgid "You aren't a friend of this contact."
+msgstr "Non sei un amico di questo contatto"
-#: mod/friendica.php:114 mod/admin.php:280 mod/admin.php:298
-msgid "Reason for the block"
-msgstr "Motivazione del blocco"
+#: mod/unfollow.php:79
+msgid "Unfollowing is currently not supported by your network."
+msgstr ""
-#: mod/group.php:29
-msgid "Group created."
-msgstr "Gruppo creato."
+#: mod/unfollow.php:100 mod/contacts.php:593
+msgid "Disconnect/Unfollow"
+msgstr "Disconnetti/Non Seguire"
-#: mod/group.php:35
-msgid "Could not create group."
-msgstr "Impossibile creare il gruppo."
-
-#: mod/group.php:49 mod/group.php:154
-msgid "Group not found."
-msgstr "Gruppo non trovato."
+#: mod/admin.php:100
+msgid "Theme settings updated."
+msgstr "Impostazioni del tema aggiornate."
-#: mod/group.php:63
-msgid "Group name changed."
-msgstr "Il nome del gruppo è cambiato."
+#: mod/admin.php:172 mod/admin.php:1175
+msgid "Site"
+msgstr "Sito"
-#: mod/group.php:93
-msgid "Save Group"
-msgstr "Salva gruppo"
+#: mod/admin.php:173 mod/admin.php:1103 mod/admin.php:1620 mod/admin.php:1636
+msgid "Users"
+msgstr "Utenti"
-#: mod/group.php:98
-msgid "Create a group of contacts/friends."
-msgstr "Crea un gruppo di amici/contatti."
+#: mod/admin.php:174 mod/admin.php:1738 mod/admin.php:1801 mod/settings.php:74
+msgid "Plugins"
+msgstr "Plugin"
-#: mod/group.php:123
-msgid "Group removed."
-msgstr "Gruppo rimosso."
+#: mod/admin.php:175 mod/admin.php:2014 mod/admin.php:2064
+msgid "Themes"
+msgstr "Temi"
-#: mod/group.php:125
-msgid "Unable to remove group."
-msgstr "Impossibile rimuovere il gruppo."
+#: mod/admin.php:176 mod/settings.php:52
+msgid "Additional features"
+msgstr "Funzionalità aggiuntive"
-#: mod/group.php:189
-msgid "Delete Group"
-msgstr "Elimina Gruppo"
+#: mod/admin.php:177
+msgid "DB updates"
+msgstr "Aggiornamenti Database"
-#: mod/group.php:195
-msgid "Group Editor"
-msgstr "Modifica gruppo"
+#: mod/admin.php:178 mod/admin.php:585
+msgid "Inspect Queue"
+msgstr "Ispeziona Coda di invio"
-#: mod/group.php:200
-msgid "Edit Group Name"
-msgstr "Modifica Nome Gruppo"
+#: mod/admin.php:179 mod/admin.php:299
+msgid "Server Blocklist"
+msgstr "Server Blocklist"
-#: mod/group.php:210
-msgid "Members"
-msgstr "Membri"
+#: mod/admin.php:180 mod/admin.php:551
+msgid "Federation Statistics"
+msgstr "Statistiche sulla Federazione"
-#: mod/group.php:226
-msgid "Remove Contact"
-msgstr "Rimuovi Contatto"
+#: mod/admin.php:181 mod/admin.php:376
+msgid "Delete Item"
+msgstr "Rimuovi elemento"
-#: mod/group.php:250
-msgid "Add Contact"
-msgstr "Aggiungi Contatto"
+#: mod/admin.php:195 mod/admin.php:206 mod/admin.php:2138
+msgid "Logs"
+msgstr "Log"
-#: mod/manage.php:151
-msgid "Manage Identities and/or Pages"
-msgstr "Gestisci identità e/o pagine"
+#: mod/admin.php:196 mod/admin.php:2206
+msgid "View Logs"
+msgstr "Vedi i log"
-#: mod/manage.php:152
-msgid ""
-"Toggle between different identities or community/group pages which share "
-"your account details or which you have been granted \"manage\" permissions"
-msgstr "Cambia tra differenti identità o pagine comunità/gruppi che condividono il tuo account o per cui hai i permessi di gestione"
+#: mod/admin.php:197
+msgid "probe address"
+msgstr "controlla indirizzo"
-#: mod/manage.php:153
-msgid "Select an identity to manage: "
-msgstr "Seleziona un'identità da gestire:"
+#: mod/admin.php:198
+msgid "check webfinger"
+msgstr "verifica webfinger"
-#: mod/message.php:64
-msgid "Unable to locate contact information."
-msgstr "Impossibile trovare le informazioni del contatto."
+#: mod/admin.php:205
+msgid "Plugin Features"
+msgstr "Impostazioni Plugins"
-#: mod/message.php:204
-msgid "Do you really want to delete this message?"
-msgstr "Vuoi veramente cancellare questo messaggio?"
+#: mod/admin.php:207
+msgid "diagnostics"
+msgstr "diagnostiche"
-#: mod/message.php:224
-msgid "Message deleted."
-msgstr "Messaggio eliminato."
+#: mod/admin.php:208
+msgid "User registrations waiting for confirmation"
+msgstr "Utenti registrati in attesa di conferma"
-#: mod/message.php:255
-msgid "Conversation removed."
-msgstr "Conversazione rimossa."
+#: mod/admin.php:290
+msgid "The blocked domain"
+msgstr "Il dominio bloccato"
-#: mod/message.php:364
-msgid "No messages."
-msgstr "Nessun messaggio."
+#: mod/admin.php:291 mod/admin.php:304
+msgid "The reason why you blocked this domain."
+msgstr "Le ragioni per cui blocchi questo dominio."
-#: mod/message.php:403
-msgid "Message not available."
-msgstr "Messaggio non disponibile."
+#: mod/admin.php:292
+msgid "Delete domain"
+msgstr "Elimina dominio"
-#: mod/message.php:477
-msgid "Delete message"
-msgstr "Elimina il messaggio"
+#: mod/admin.php:292
+msgid "Check to delete this entry from the blocklist"
+msgstr "Seleziona per eliminare questa voce dalla blocklist"
-#: mod/message.php:503 mod/message.php:591
-msgid "Delete conversation"
-msgstr "Elimina la conversazione"
+#: mod/admin.php:298 mod/admin.php:375 mod/admin.php:550 mod/admin.php:584
+#: mod/admin.php:681 mod/admin.php:1174 mod/admin.php:1619 mod/admin.php:1737
+#: mod/admin.php:1800 mod/admin.php:2013 mod/admin.php:2063 mod/admin.php:2137
+#: mod/admin.php:2205
+msgid "Administration"
+msgstr "Amministrazione"
-#: mod/message.php:505
+#: mod/admin.php:300
msgid ""
-"No secure communications available. You <strong>may</strong> be able to "
-"respond from the sender's profile page."
-msgstr "Nessuna comunicazione sicura disponibile, <strong>Potresti</strong> essere in grado di rispondere dalla pagina del profilo del mittente."
-
-#: mod/message.php:509
-msgid "Send Reply"
-msgstr "Invia la risposta"
-
-#: mod/message.php:561
-#, php-format
-msgid "Unknown sender - %s"
-msgstr "Mittente sconosciuto - %s"
-
-#: mod/message.php:563
-#, php-format
-msgid "You and %s"
-msgstr "Tu e %s"
-
-#: mod/message.php:565
-#, php-format
-msgid "%s and You"
-msgstr "%s e Tu"
+"This page can be used to define a black list of servers from the federated "
+"network that are not allowed to interact with your node. For all entered "
+"domains you should also give a reason why you have blocked the remote "
+"server."
+msgstr "Questa pagina puo' essere usata per definire una black list di server dal network federato a cui nono è permesso interagire col tuo nodo. Per ogni dominio inserito, dovresti anche riportare una ragione per cui hai bloccato il server remoto."
-#: mod/message.php:594
-msgid "D, d M Y - g:i A"
-msgstr "D d M Y - G:i"
+#: mod/admin.php:301
+msgid ""
+"The list of blocked servers will be made publically available on the "
+"/friendica page so that your users and people investigating communication "
+"problems can find the reason easily."
+msgstr "La lista di server bloccati sarà resa disponibile pubblicamente sulla pagina /friendica, così che i tuoi utenti e le persone che indagano su problemi di comunicazione possano trovarne la ragione facilmente."
-#: mod/message.php:597
-#, php-format
-msgid "%d message"
-msgid_plural "%d messages"
-msgstr[0] "%d messaggio"
-msgstr[1] "%d messaggi"
+#: mod/admin.php:302
+msgid "Add new entry to block list"
+msgstr "Aggiungi una nuova voce alla blocklist"
-#: mod/network.php:197 mod/search.php:25
-msgid "Remove term"
-msgstr "Rimuovi termine"
+#: mod/admin.php:303
+msgid "Server Domain"
+msgstr "Dominio del Server"
-#: mod/network.php:404
-#, php-format
+#: mod/admin.php:303
msgid ""
-"Warning: This group contains %s member from a network that doesn't allow non"
-" public messages."
-msgid_plural ""
-"Warning: This group contains %s members from a network that doesn't allow "
-"non public messages."
-msgstr[0] "Attenzione: Questo gruppo contiene %s membro da una rete che non permette la ricezione di messaggi non pubblici."
-msgstr[1] "Attenzione: Questo gruppo contiene %s membri da reti che non permettono la ricezione di messaggi non pubblici."
+"The domain of the new server to add to the block list. Do not include the "
+"protocol."
+msgstr "Il dominio del server da aggiungere alla blocklist. Non includere il protocollo."
-#: mod/network.php:407
-msgid "Messages in this group won't be send to these receivers."
-msgstr "I messaggi in questo gruppo non saranno inviati ai quei contatti."
+#: mod/admin.php:304
+msgid "Block reason"
+msgstr "Ragione blocco"
-#: mod/network.php:535
-msgid "Private messages to this person are at risk of public disclosure."
-msgstr "I messaggi privati a questa persona potrebbero risultare visibili anche pubblicamente."
+#: mod/admin.php:305
+msgid "Add Entry"
+msgstr "Aggiungi Voce"
-#: mod/network.php:540
-msgid "Invalid contact."
-msgstr "Contatto non valido."
+#: mod/admin.php:306
+msgid "Save changes to the blocklist"
+msgstr "Salva modifiche alla blocklist"
-#: mod/network.php:813
-msgid "Commented Order"
-msgstr "Ordina per commento"
+#: mod/admin.php:307
+msgid "Current Entries in the Blocklist"
+msgstr "Voci correnti nella blocklist"
-#: mod/network.php:816
-msgid "Sort by Comment Date"
-msgstr "Ordina per data commento"
+#: mod/admin.php:310
+msgid "Delete entry from blocklist"
+msgstr "Elimina voce dalla blocklist"
-#: mod/network.php:821
-msgid "Posted Order"
-msgstr "Ordina per invio"
+#: mod/admin.php:313
+msgid "Delete entry from blocklist?"
+msgstr "Eliminare la voce dalla blocklist?"
-#: mod/network.php:824
-msgid "Sort by Post Date"
-msgstr "Ordina per data messaggio"
+#: mod/admin.php:338
+msgid "Server added to blocklist."
+msgstr "Server aggiunto alla blocklist."
-#: mod/network.php:835
-msgid "Posts that mention or involve you"
-msgstr "Messaggi che ti citano o coinvolgono"
+#: mod/admin.php:354
+msgid "Site blocklist updated."
+msgstr "Blocklist del sito aggiornata."
-#: mod/network.php:843
-msgid "New"
-msgstr "Nuovo"
+#: mod/admin.php:377
+msgid "Delete this Item"
+msgstr "Rimuovi questo elemento"
-#: mod/network.php:846
-msgid "Activity Stream - by date"
-msgstr "Activity Stream - per data"
+#: mod/admin.php:378
+msgid ""
+"On this page you can delete an item from your node. If the item is a top "
+"level posting, the entire thread will be deleted."
+msgstr ""
-#: mod/network.php:854
-msgid "Shared Links"
-msgstr "Links condivisi"
+#: mod/admin.php:379
+msgid ""
+"You need to know the GUID of the item. You can find it e.g. by looking at "
+"the display URL. The last part of http://example.com/display/123456 is the "
+"GUID, here 123456."
+msgstr ""
-#: mod/network.php:857
-msgid "Interesting Links"
-msgstr "Link Interessanti"
+#: mod/admin.php:380
+msgid "GUID"
+msgstr ""
-#: mod/network.php:865
-msgid "Starred"
-msgstr "Preferiti"
+#: mod/admin.php:380
+msgid "The GUID of the item you want to delete."
+msgstr ""
-#: mod/network.php:868
-msgid "Favourite Posts"
-msgstr "Messaggi preferiti"
+#: mod/admin.php:417
+msgid "Item marked for deletion."
+msgstr ""
-#: mod/openid.php:24
-msgid "OpenID protocol error. No ID returned."
-msgstr "Errore protocollo OpenID. Nessun ID ricevuto."
+#: mod/admin.php:481
+msgid "unknown"
+msgstr "sconosciuto"
-#: mod/openid.php:60
+#: mod/admin.php:544
msgid ""
-"Account not found and OpenID registration is not permitted on this site."
-msgstr "L'account non è stato trovato, e la registrazione via OpenID non è permessa su questo sito."
+"This page offers you some numbers to the known part of the federated social "
+"network your Friendica node is part of. These numbers are not complete but "
+"only reflect the part of the network your node is aware of."
+msgstr "Questa pagina offre alcuni numeri riguardo la porzione del social network federato di cui il tuo nodo Friendica fa parte. Questi numeri non sono completi ma riflettono esclusivamente la porzione di rete di cui il tuo nodo e' a conoscenza."
-#: mod/photos.php:94 mod/photos.php:1900
-msgid "Recent Photos"
-msgstr "Foto recenti"
+#: mod/admin.php:545
+msgid ""
+"The <em>Auto Discovered Contact Directory</em> feature is not enabled, it "
+"will improve the data displayed here."
+msgstr "La funzione <em>Elenco Contatti Scoperto Automaticamente</em> non è abilitata, migliorerà i dati visualizzati qui."
-#: mod/photos.php:97 mod/photos.php:1328 mod/photos.php:1902
-msgid "Upload New Photos"
-msgstr "Carica nuove foto"
+#: mod/admin.php:557
+#, php-format
+msgid "Currently this node is aware of %d nodes from the following platforms:"
+msgstr "Attualmente questo nodo conosce %d nodi dalle seguenti piattaforme:"
-#: mod/photos.php:112 mod/settings.php:36
-msgid "everybody"
-msgstr "tutti"
+#: mod/admin.php:587
+msgid "ID"
+msgstr "ID"
-#: mod/photos.php:176
-msgid "Contact information unavailable"
-msgstr "I dati di questo contatto non sono disponibili"
+#: mod/admin.php:588
+msgid "Recipient Name"
+msgstr "Nome Destinatario"
-#: mod/photos.php:197
-msgid "Album not found."
-msgstr "Album non trovato."
+#: mod/admin.php:589
+msgid "Recipient Profile"
+msgstr "Profilo Destinatario"
-#: mod/photos.php:230 mod/photos.php:242 mod/photos.php:1272
-msgid "Delete Album"
-msgstr "Rimuovi album"
+#: mod/admin.php:591
+msgid "Created"
+msgstr "Creato"
-#: mod/photos.php:240
-msgid "Do you really want to delete this photo album and all its photos?"
-msgstr "Vuoi davvero cancellare questo album e tutte le sue foto?"
-
-#: mod/photos.php:323 mod/photos.php:334 mod/photos.php:1598
-msgid "Delete Photo"
-msgstr "Rimuovi foto"
+#: mod/admin.php:592
+msgid "Last Tried"
+msgstr "Ultimo Tentativo"
-#: mod/photos.php:332
-msgid "Do you really want to delete this photo?"
-msgstr "Vuoi veramente cancellare questa foto?"
+#: mod/admin.php:593
+msgid ""
+"This page lists the content of the queue for outgoing postings. These are "
+"postings the initial delivery failed for. They will be resend later and "
+"eventually deleted if the delivery fails permanently."
+msgstr "Questa pagina elenca il contenuto della coda di invio dei post. Questi sono post la cui consegna è fallita. Verranno inviati nuovamente più tardi ed eventualmente cancellati se la consegna continua a fallire."
-#: mod/photos.php:713
+#: mod/admin.php:617
#, php-format
-msgid "%1$s was tagged in %2$s by %3$s"
-msgstr "%1$s è stato taggato in %2$s da %3$s"
-
-#: mod/photos.php:713
-msgid "a photo"
-msgstr "una foto"
+msgid ""
+"Your DB still runs with MyISAM tables. You should change the engine type to "
+"InnoDB. As Friendica will use InnoDB only features in the future, you should"
+" change this! See <a href=\"%s\">here</a> for a guide that may be helpful "
+"converting the table engines. You may also use the command <tt>php "
+"include/dbstructure.php toinnodb</tt> of your Friendica installation for an "
+"automatic conversion.<br />"
+msgstr "Il tuo database contiene ancora tabelle MyISAM. Dovresti cambiare il motore a InnoDB. Siccome Friendica userà esclusivamente InnoDB nelle versioni a venire, dovresti cambiarle! Vedi <a href=\"%s\">qui</a> per una guida che puo' essere d'aiuto nel convertire il motore delle tabelle. Puoi anche usare il comando <tt>php include/dbstructure.php toinnodb</tt> nella tua installazione Friendica per eseguire la conversione automaticamente.<br />"
-#: mod/photos.php:821
-msgid "Image file is empty."
-msgstr "Il file dell'immagine è vuoto."
+#: mod/admin.php:624
+#, php-format
+msgid ""
+"There is a new version of Friendica available for download. Your current "
+"version is %1$s, upstream version is %2$s"
+msgstr ""
-#: mod/photos.php:988
-msgid "No photos selected"
-msgstr "Nessuna foto selezionata"
+#: mod/admin.php:635
+msgid ""
+"The database update failed. Please run \"php include/dbstructure.php "
+"update\" from the command line and have a look at the errors that might "
+"appear."
+msgstr ""
-#: mod/photos.php:1091 mod/videos.php:309
-msgid "Access to this item is restricted."
-msgstr "Questo oggetto non è visibile a tutti."
+#: mod/admin.php:641
+msgid "The worker was never executed. Please check your database structure!"
+msgstr ""
-#: mod/photos.php:1151
+#: mod/admin.php:644
#, php-format
-msgid "You have used %1$.2f Mbytes of %2$.2f Mbytes photo storage."
-msgstr "Hai usato %1$.2f MBytes su %2$.2f disponibili."
-
-#: mod/photos.php:1188
-msgid "Upload Photos"
-msgstr "Carica foto"
+msgid ""
+"The last worker execution was on %s UTC. This is older than one hour. Please"
+" check your crontab settings."
+msgstr ""
-#: mod/photos.php:1192 mod/photos.php:1267
-msgid "New album name: "
-msgstr "Nome nuovo album: "
+#: mod/admin.php:649 mod/admin.php:1569
+msgid "Normal Account"
+msgstr "Account normale"
-#: mod/photos.php:1193
-msgid "or existing album name: "
-msgstr "o nome di un album esistente: "
+#: mod/admin.php:650 mod/admin.php:1570
+msgid "Automatic Follower Account"
+msgstr ""
-#: mod/photos.php:1194
-msgid "Do not show a status post for this upload"
-msgstr "Non creare un post per questo upload"
+#: mod/admin.php:651 mod/admin.php:1571
+msgid "Public Forum Account"
+msgstr ""
-#: mod/photos.php:1205 mod/photos.php:1602 mod/settings.php:1307
-msgid "Show to Groups"
-msgstr "Mostra ai gruppi"
+#: mod/admin.php:652 mod/admin.php:1572
+msgid "Automatic Friend Account"
+msgstr "Account per amicizia automatizzato"
-#: mod/photos.php:1206 mod/photos.php:1603 mod/settings.php:1308
-msgid "Show to Contacts"
-msgstr "Mostra ai contatti"
+#: mod/admin.php:653
+msgid "Blog Account"
+msgstr "Account Blog"
-#: mod/photos.php:1207
-msgid "Private Photo"
-msgstr "Foto privata"
+#: mod/admin.php:654
+msgid "Private Forum Account"
+msgstr ""
-#: mod/photos.php:1208
-msgid "Public Photo"
-msgstr "Foto pubblica"
+#: mod/admin.php:676
+msgid "Message queues"
+msgstr "Code messaggi"
-#: mod/photos.php:1278
-msgid "Edit Album"
-msgstr "Modifica album"
+#: mod/admin.php:682
+msgid "Summary"
+msgstr "Sommario"
-#: mod/photos.php:1283
-msgid "Show Newest First"
-msgstr "Mostra nuove foto per prime"
+#: mod/admin.php:684
+msgid "Registered users"
+msgstr "Utenti registrati"
-#: mod/photos.php:1285
-msgid "Show Oldest First"
-msgstr "Mostra vecchie foto per prime"
+#: mod/admin.php:686
+msgid "Pending registrations"
+msgstr "Registrazioni in attesa"
-#: mod/photos.php:1314 mod/photos.php:1885
-msgid "View Photo"
-msgstr "Vedi foto"
+#: mod/admin.php:687
+msgid "Version"
+msgstr "Versione"
-#: mod/photos.php:1359
-msgid "Permission denied. Access to this item may be restricted."
-msgstr "Permesso negato. L'accesso a questo elemento può essere limitato."
+#: mod/admin.php:692
+msgid "Active plugins"
+msgstr "Plugin attivi"
-#: mod/photos.php:1361
-msgid "Photo not available"
-msgstr "Foto non disponibile"
+#: mod/admin.php:722
+msgid "Can not parse base url. Must have at least <scheme>://<domain>"
+msgstr "Impossibile analizzare l'url base. Deve avere almeno [schema]://[dominio]"
-#: mod/photos.php:1422
-msgid "View photo"
-msgstr "Vedi foto"
+#: mod/admin.php:1029
+msgid "Site settings updated."
+msgstr "Impostazioni del sito aggiornate."
-#: mod/photos.php:1422
-msgid "Edit photo"
-msgstr "Modifica foto"
+#: mod/admin.php:1057 mod/settings.php:948
+msgid "No special theme for mobile devices"
+msgstr "Nessun tema speciale per i dispositivi mobili"
-#: mod/photos.php:1423
-msgid "Use as profile photo"
-msgstr "Usa come foto del profilo"
+#: mod/admin.php:1086
+msgid "No community page"
+msgstr "Nessuna pagina Comunità"
-#: mod/photos.php:1448
-msgid "View Full Size"
-msgstr "Vedi dimensione intera"
+#: mod/admin.php:1087
+msgid "Public postings from users of this site"
+msgstr "Messaggi pubblici dagli utenti di questo sito"
-#: mod/photos.php:1538
-msgid "Tags: "
-msgstr "Tag: "
+#: mod/admin.php:1088
+msgid "Global community page"
+msgstr "Pagina Comunità globale"
-#: mod/photos.php:1541
-msgid "[Remove any tag]"
-msgstr "[Rimuovi tutti i tag]"
+#: mod/admin.php:1093 mod/contacts.php:552
+msgid "Never"
+msgstr "Mai"
-#: mod/photos.php:1584
-msgid "New album name"
-msgstr "Nuovo nome dell'album"
+#: mod/admin.php:1094
+msgid "At post arrival"
+msgstr "All'arrivo di un messaggio"
-#: mod/photos.php:1585
-msgid "Caption"
-msgstr "Titolo"
+#: mod/admin.php:1102 mod/contacts.php:579
+msgid "Disabled"
+msgstr "Disabilitato"
-#: mod/photos.php:1586
-msgid "Add a Tag"
-msgstr "Aggiungi tag"
+#: mod/admin.php:1104
+msgid "Users, Global Contacts"
+msgstr "Utenti, Contatti Globali"
-#: mod/photos.php:1586
-msgid ""
-"Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"
-msgstr "Esempio: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"
+#: mod/admin.php:1105
+msgid "Users, Global Contacts/fallback"
+msgstr "Utenti, Contatti Globali/fallback"
-#: mod/photos.php:1587
-msgid "Do not rotate"
-msgstr "Non ruotare"
+#: mod/admin.php:1109
+msgid "One month"
+msgstr "Un mese"
-#: mod/photos.php:1588
-msgid "Rotate CW (right)"
-msgstr "Ruota a destra"
+#: mod/admin.php:1110
+msgid "Three months"
+msgstr "Tre mesi"
-#: mod/photos.php:1589
-msgid "Rotate CCW (left)"
-msgstr "Ruota a sinistra"
+#: mod/admin.php:1111
+msgid "Half a year"
+msgstr "Sei mesi"
-#: mod/photos.php:1604
-msgid "Private photo"
-msgstr "Foto privata"
+#: mod/admin.php:1112
+msgid "One year"
+msgstr "Un anno"
-#: mod/photos.php:1605
-msgid "Public photo"
-msgstr "Foto pubblica"
+#: mod/admin.php:1117
+msgid "Multi user instance"
+msgstr "Istanza multi utente"
-#: mod/photos.php:1814
-msgid "Map"
-msgstr "Mappa"
+#: mod/admin.php:1140
+msgid "Closed"
+msgstr "Chiusa"
-#: mod/photos.php:1891 mod/videos.php:393
-msgid "View Album"
-msgstr "Sfoglia l'album"
+#: mod/admin.php:1141
+msgid "Requires approval"
+msgstr "Richiede l'approvazione"
-#: mod/probe.php:10 mod/webfinger.php:9
-msgid "Only logged in users are permitted to perform a probing."
-msgstr "Solo agli utenti loggati è permesso effettuare un probe."
+#: mod/admin.php:1142
+msgid "Open"
+msgstr "Aperta"
-#: mod/profile.php:175
-msgid "Tips for New Members"
-msgstr "Consigli per i Nuovi Utenti"
+#: mod/admin.php:1146
+msgid "No SSL policy, links will track page SSL state"
+msgstr "Nessuna gestione SSL, i link seguiranno lo stato SSL della pagina"
-#: mod/profiles.php:38
-msgid "Profile deleted."
-msgstr "Profilo eliminato."
+#: mod/admin.php:1147
+msgid "Force all links to use SSL"
+msgstr "Forza tutti i link ad usare SSL"
-#: mod/profiles.php:54 mod/profiles.php:90
-msgid "Profile-"
-msgstr "Profilo-"
+#: mod/admin.php:1148
+msgid "Self-signed certificate, use SSL for local links only (discouraged)"
+msgstr "Certificato auto-firmato, usa SSL solo per i link locali (sconsigliato)"
-#: mod/profiles.php:73 mod/profiles.php:118
-msgid "New profile created."
-msgstr "Il nuovo profilo è stato creato."
+#: mod/admin.php:1152
+msgid "Don't check"
+msgstr ""
-#: mod/profiles.php:96
-msgid "Profile unavailable to clone."
-msgstr "Impossibile duplicare il profilo."
+#: mod/admin.php:1153
+msgid "check the stable version"
+msgstr ""
-#: mod/profiles.php:192
-msgid "Profile Name is required."
-msgstr "Il nome profilo è obbligatorio ."
+#: mod/admin.php:1154
+msgid "check the development version"
+msgstr ""
-#: mod/profiles.php:332
-msgid "Marital Status"
-msgstr "Stato civile"
+#: mod/admin.php:1176 mod/admin.php:1802 mod/admin.php:2065 mod/admin.php:2139
+#: mod/admin.php:2292 mod/settings.php:691 mod/settings.php:802
+#: mod/settings.php:851 mod/settings.php:913 mod/settings.php:1010
+#: mod/settings.php:1258
+msgid "Save Settings"
+msgstr "Salva Impostazioni"
-#: mod/profiles.php:336
-msgid "Romantic Partner"
-msgstr "Partner romantico"
+#: mod/admin.php:1177
+msgid "Republish users to directory"
+msgstr ""
-#: mod/profiles.php:348
-msgid "Work/Employment"
-msgstr "Lavoro/Impiego"
+#: mod/admin.php:1178 mod/register.php:277
+msgid "Registration"
+msgstr "Registrazione"
-#: mod/profiles.php:351
-msgid "Religion"
-msgstr "Religione"
+#: mod/admin.php:1179
+msgid "File upload"
+msgstr "Caricamento file"
-#: mod/profiles.php:355
-msgid "Political Views"
-msgstr "Orientamento Politico"
+#: mod/admin.php:1180
+msgid "Policies"
+msgstr "Politiche"
-#: mod/profiles.php:359
-msgid "Gender"
-msgstr "Sesso"
+#: mod/admin.php:1182
+msgid "Auto Discovered Contact Directory"
+msgstr "Elenco Contatti Scoperto Automaticamente"
-#: mod/profiles.php:363
-msgid "Sexual Preference"
-msgstr "Preferenza sessuale"
+#: mod/admin.php:1183
+msgid "Performance"
+msgstr "Performance"
-#: mod/profiles.php:367
-msgid "XMPP"
-msgstr "XMPP"
+#: mod/admin.php:1184
+msgid "Worker"
+msgstr "Worker"
-#: mod/profiles.php:371
-msgid "Homepage"
-msgstr "Homepage"
+#: mod/admin.php:1185
+msgid ""
+"Relocate - WARNING: advanced function. Could make this server unreachable."
+msgstr "Trasloca - ATTENZIONE: funzione avanzata! Può rendere questo server irraggiungibile."
-#: mod/profiles.php:375 mod/profiles.php:695
-msgid "Interests"
-msgstr "Interessi"
+#: mod/admin.php:1188
+msgid "Site name"
+msgstr "Nome del sito"
-#: mod/profiles.php:379
-msgid "Address"
-msgstr "Indirizzo"
+#: mod/admin.php:1189
+msgid "Host name"
+msgstr "Nome host"
-#: mod/profiles.php:386 mod/profiles.php:691
-msgid "Location"
-msgstr "Posizione"
+#: mod/admin.php:1190
+msgid "Sender Email"
+msgstr "Mittente email"
-#: mod/profiles.php:471
-msgid "Profile updated."
-msgstr "Profilo aggiornato."
+#: mod/admin.php:1190
+msgid ""
+"The email address your server shall use to send notification emails from."
+msgstr "L'indirizzo email che il tuo server dovrà usare per inviare notifiche via email."
-#: mod/profiles.php:564
-msgid " and "
-msgstr "e "
+#: mod/admin.php:1191
+msgid "Banner/Logo"
+msgstr "Banner/Logo"
-#: mod/profiles.php:573
-msgid "public profile"
-msgstr "profilo pubblico"
+#: mod/admin.php:1192
+msgid "Shortcut icon"
+msgstr "Icona shortcut"
-#: mod/profiles.php:576
-#, php-format
-msgid "%1$s changed %2$s to “%3$s”"
-msgstr "%1$s ha cambiato %2$s in “%3$s”"
+#: mod/admin.php:1192
+msgid "Link to an icon that will be used for browsers."
+msgstr "Link verso un'icona che verrà usata dai browser."
-#: mod/profiles.php:577
-#, php-format
-msgid " - Visit %1$s's %2$s"
-msgstr "- Visita %2$s di %1$s"
+#: mod/admin.php:1193
+msgid "Touch icon"
+msgstr "Icona touch"
-#: mod/profiles.php:579
-#, php-format
-msgid "%1$s has an updated %2$s, changing %3$s."
-msgstr "%1$s ha un %2$s aggiornato. Ha cambiato %3$s"
+#: mod/admin.php:1193
+msgid "Link to an icon that will be used for tablets and mobiles."
+msgstr "Link verso un'icona che verrà usata dai tablet e i telefonini."
-#: mod/profiles.php:637
-msgid "Hide contacts and friends:"
-msgstr "Nascondi contatti:"
+#: mod/admin.php:1194
+msgid "Additional Info"
+msgstr "Informazioni aggiuntive"
-#: mod/profiles.php:642
-msgid "Hide your contact/friend list from viewers of this profile?"
-msgstr "Nascondi la tua lista di contatti/amici ai visitatori di questo profilo?"
+#: mod/admin.php:1194
+#, php-format
+msgid ""
+"For public servers: you can add additional information here that will be "
+"listed at %s/siteinfo."
+msgstr "Per server pubblici: puoi aggiungere informazioni extra che verrano mostrate su %s/siteinfo."
-#: mod/profiles.php:667
-msgid "Show more profile fields:"
-msgstr "Mostra più informazioni di profilo:"
+#: mod/admin.php:1195
+msgid "System language"
+msgstr "Lingua di sistema"
-#: mod/profiles.php:679
-msgid "Profile Actions"
-msgstr "Azioni Profilo"
+#: mod/admin.php:1196
+msgid "System theme"
+msgstr "Tema di sistema"
-#: mod/profiles.php:680
-msgid "Edit Profile Details"
-msgstr "Modifica i dettagli del profilo"
+#: mod/admin.php:1196
+msgid ""
+"Default system theme - may be over-ridden by user profiles - <a href='#' "
+"id='cnftheme'>change theme settings</a>"
+msgstr "Tema di sistema - può essere sovrascritto dalle impostazioni utente - <a href='#' id='cnftheme'>cambia le impostazioni del tema</a>"
-#: mod/profiles.php:682
-msgid "Change Profile Photo"
-msgstr "Cambia la foto del profilo"
+#: mod/admin.php:1197
+msgid "Mobile system theme"
+msgstr "Tema mobile di sistema"
-#: mod/profiles.php:683
-msgid "View this profile"
-msgstr "Visualizza questo profilo"
+#: mod/admin.php:1197
+msgid "Theme for mobile devices"
+msgstr "Tema per dispositivi mobili"
-#: mod/profiles.php:685
-msgid "Create a new profile using these settings"
-msgstr "Crea un nuovo profilo usando queste impostazioni"
+#: mod/admin.php:1198
+msgid "SSL link policy"
+msgstr "Gestione link SSL"
-#: mod/profiles.php:686
-msgid "Clone this profile"
-msgstr "Clona questo profilo"
+#: mod/admin.php:1198
+msgid "Determines whether generated links should be forced to use SSL"
+msgstr "Determina se i link generati devono essere forzati a usare SSL"
-#: mod/profiles.php:687
-msgid "Delete this profile"
-msgstr "Elimina questo profilo"
+#: mod/admin.php:1199
+msgid "Force SSL"
+msgstr "Forza SSL"
-#: mod/profiles.php:689
-msgid "Basic information"
-msgstr "Informazioni di base"
+#: mod/admin.php:1199
+msgid ""
+"Force all Non-SSL requests to SSL - Attention: on some systems it could lead"
+" to endless loops."
+msgstr "Forza tutte le richieste non SSL su SSL - Attenzione: su alcuni sistemi può portare a loop senza fine"
-#: mod/profiles.php:690
-msgid "Profile picture"
-msgstr "Immagine del profilo"
+#: mod/admin.php:1200
+msgid "Hide help entry from navigation menu"
+msgstr "Nascondi la voce 'Guida' dal menu di navigazione"
-#: mod/profiles.php:692
-msgid "Preferences"
-msgstr "Preferenze"
+#: mod/admin.php:1200
+msgid ""
+"Hides the menu entry for the Help pages from the navigation menu. You can "
+"still access it calling /help directly."
+msgstr "Nasconde la voce per le pagine della guida dal menu di navigazione. E' comunque possibile accedervi richiamando /help direttamente."
-#: mod/profiles.php:693
-msgid "Status information"
-msgstr "Informazioni stato"
+#: mod/admin.php:1201
+msgid "Single user instance"
+msgstr "Istanza a singolo utente"
-#: mod/profiles.php:694
-msgid "Additional information"
-msgstr "Informazioni aggiuntive"
+#: mod/admin.php:1201
+msgid "Make this instance multi-user or single-user for the named user"
+msgstr "Rendi questa istanza multi utente o a singolo utente per l'utente selezionato"
-#: mod/profiles.php:697
-msgid "Relation"
-msgstr "Relazione"
+#: mod/admin.php:1202
+msgid "Maximum image size"
+msgstr "Massima dimensione immagini"
-#: mod/profiles.php:701
-msgid "Your Gender:"
-msgstr "Il tuo sesso:"
+#: mod/admin.php:1202
+msgid ""
+"Maximum size in bytes of uploaded images. Default is 0, which means no "
+"limits."
+msgstr "Massima dimensione in byte delle immagini caricate. Il default è 0, cioè nessun limite."
-#: mod/profiles.php:702
-msgid "<span class=\"heart\">♥</span> Marital Status:"
-msgstr "<span class=\"heart\">♥</span> Stato sentimentale:"
+#: mod/admin.php:1203
+msgid "Maximum image length"
+msgstr "Massima lunghezza immagine"
-#: mod/profiles.php:704
-msgid "Example: fishing photography software"
-msgstr "Esempio: pesca fotografia programmazione"
+#: mod/admin.php:1203
+msgid ""
+"Maximum length in pixels of the longest side of uploaded images. Default is "
+"-1, which means no limits."
+msgstr "Massima lunghezza in pixel del lato più lungo delle immagini caricate. Predefinito a -1, ovvero nessun limite."
-#: mod/profiles.php:709
-msgid "Profile Name:"
-msgstr "Nome del profilo:"
+#: mod/admin.php:1204
+msgid "JPEG image quality"
+msgstr "Qualità immagini JPEG"
-#: mod/profiles.php:711
+#: mod/admin.php:1204
msgid ""
-"This is your <strong>public</strong> profile.<br />It <strong>may</strong> "
-"be visible to anybody using the internet."
-msgstr "Questo è il tuo profilo <strong>publico</strong>.<br /><strong>Potrebbe</strong> essere visto da chiunque attraverso internet."
+"Uploaded JPEGS will be saved at this quality setting [0-100]. Default is "
+"100, which is full quality."
+msgstr "Le immagini JPEG caricate verranno salvate con questa qualità [0-100]. Predefinito è 100, ovvero qualità piena."
-#: mod/profiles.php:712
-msgid "Your Full Name:"
-msgstr "Il tuo nome completo:"
+#: mod/admin.php:1206
+msgid "Register policy"
+msgstr "Politica di registrazione"
-#: mod/profiles.php:713
-msgid "Title/Description:"
-msgstr "Breve descrizione (es. titolo, posizione, altro):"
+#: mod/admin.php:1207
+msgid "Maximum Daily Registrations"
+msgstr "Massime registrazioni giornaliere"
-#: mod/profiles.php:716
-msgid "Street Address:"
-msgstr "Indirizzo (via/piazza):"
+#: mod/admin.php:1207
+msgid ""
+"If registration is permitted above, this sets the maximum number of new user"
+" registrations to accept per day. If register is set to closed, this "
+"setting has no effect."
+msgstr "Se la registrazione è permessa, qui si definisce il massimo numero di nuovi utenti registrati da accettare giornalmente. Se la registrazione è chiusa, questa impostazione non ha effetto."
-#: mod/profiles.php:717
-msgid "Locality/City:"
-msgstr "Località:"
+#: mod/admin.php:1208
+msgid "Register text"
+msgstr "Testo registrazione"
-#: mod/profiles.php:718
-msgid "Region/State:"
-msgstr "Regione/Stato:"
+#: mod/admin.php:1208
+msgid "Will be displayed prominently on the registration page."
+msgstr "Sarà mostrato ben visibile nella pagina di registrazione."
-#: mod/profiles.php:719
-msgid "Postal/Zip Code:"
-msgstr "CAP:"
+#: mod/admin.php:1209
+msgid "Accounts abandoned after x days"
+msgstr "Account abbandonati dopo x giorni"
-#: mod/profiles.php:720
-msgid "Country:"
-msgstr "Nazione:"
+#: mod/admin.php:1209
+msgid ""
+"Will not waste system resources polling external sites for abandonded "
+"accounts. Enter 0 for no time limit."
+msgstr "Non spreca risorse di sistema controllando siti esterni per gli account abbandonati. Immettere 0 per nessun limite di tempo."
-#: mod/profiles.php:724
-msgid "Who: (if applicable)"
-msgstr "Con chi: (se possibile)"
+#: mod/admin.php:1210
+msgid "Allowed friend domains"
+msgstr "Domini amici consentiti"
-#: mod/profiles.php:724
-msgid "Examples: cathy123, Cathy Williams, cathy@example.com"
-msgstr "Esempio: cathy123, Cathy Williams, cathy@example.com"
+#: mod/admin.php:1210
+msgid ""
+"Comma separated list of domains which are allowed to establish friendships "
+"with this site. Wildcards are accepted. Empty to allow any domains"
+msgstr "Elenco separato da virgola dei domini che possono stabilire amicizie con questo sito. Sono accettati caratteri jolly. Vuoto per accettare qualsiasi dominio."
-#: mod/profiles.php:725
-msgid "Since [date]:"
-msgstr "Dal [data]:"
+#: mod/admin.php:1211
+msgid "Allowed email domains"
+msgstr "Domini email consentiti"
-#: mod/profiles.php:727
-msgid "Tell us about yourself..."
-msgstr "Raccontaci di te..."
+#: mod/admin.php:1211
+msgid ""
+"Comma separated list of domains which are allowed in email addresses for "
+"registrations to this site. Wildcards are accepted. Empty to allow any "
+"domains"
+msgstr "Elenco separato da virgola dei domini permessi come indirizzi email in fase di registrazione a questo sito. Sono accettati caratteri jolly. Lascalo vuoto per accettare qualsiasi dominio."
-#: mod/profiles.php:728
-msgid "XMPP (Jabber) address:"
-msgstr "Indirizzo XMPP (Jabber):"
+#: mod/admin.php:1212
+msgid "Block public"
+msgstr "Blocca pagine pubbliche"
-#: mod/profiles.php:728
+#: mod/admin.php:1212
msgid ""
-"The XMPP address will be propagated to your contacts so that they can follow"
-" you."
-msgstr "L'indirizzo XMPP verrà propagato ai tuoi contatti così che possano seguirti."
+"Check to block public access to all otherwise public personal pages on this "
+"site unless you are currently logged in."
+msgstr "Seleziona per bloccare l'accesso pubblico a tutte le pagine personali di questo sito, a meno di essere loggato."
-#: mod/profiles.php:729
-msgid "Homepage URL:"
-msgstr "Homepage:"
+#: mod/admin.php:1213
+msgid "Force publish"
+msgstr "Forza pubblicazione"
-#: mod/profiles.php:732
-msgid "Religious Views:"
-msgstr "Orientamento religioso:"
+#: mod/admin.php:1213
+msgid ""
+"Check to force all profiles on this site to be listed in the site directory."
+msgstr "Seleziona per forzare tutti i profili di questo sito ad essere compresi nell'elenco di questo sito."
-#: mod/profiles.php:733
-msgid "Public Keywords:"
-msgstr "Parole chiave visibili a tutti:"
+#: mod/admin.php:1214
+msgid "Global directory URL"
+msgstr "URL della directory globale"
-#: mod/profiles.php:733
-msgid "(Used for suggesting potential friends, can be seen by others)"
-msgstr "(E' utilizzato per suggerire potenziali amici, può essere visto da altri)"
+#: mod/admin.php:1214
+msgid ""
+"URL to the global directory. If this is not set, the global directory is "
+"completely unavailable to the application."
+msgstr "URL dell'elenco globale. Se vuoto, l'elenco globale sarà completamente disabilitato."
-#: mod/profiles.php:734
-msgid "Private Keywords:"
-msgstr "Parole chiave private:"
+#: mod/admin.php:1215
+msgid "Allow threaded items"
+msgstr "Permetti commenti nidificati"
-#: mod/profiles.php:734
-msgid "(Used for searching profiles, never shown to others)"
-msgstr "(Usato per cercare tra i profili, non è mai visibile agli altri)"
+#: mod/admin.php:1215
+msgid "Allow infinite level threading for items on this site."
+msgstr "Permette un infinito livello di nidificazione dei commenti su questo sito."
-#: mod/profiles.php:737
-msgid "Musical interests"
-msgstr "Interessi musicali"
-
-#: mod/profiles.php:738
-msgid "Books, literature"
-msgstr "Libri, letteratura"
+#: mod/admin.php:1216
+msgid "Private posts by default for new users"
+msgstr "Post privati di default per i nuovi utenti"
-#: mod/profiles.php:739
-msgid "Television"
-msgstr "Televisione"
+#: mod/admin.php:1216
+msgid ""
+"Set default post permissions for all new members to the default privacy "
+"group rather than public."
+msgstr "Imposta i permessi predefiniti dei post per tutti i nuovi utenti come privati per il gruppo predefinito, invece che pubblici."
-#: mod/profiles.php:740
-msgid "Film/dance/culture/entertainment"
-msgstr "Film/danza/cultura/intrattenimento"
+#: mod/admin.php:1217
+msgid "Don't include post content in email notifications"
+msgstr "Non includere il contenuto dei post nelle notifiche via email"
-#: mod/profiles.php:741
-msgid "Hobbies/Interests"
-msgstr "Hobby/interessi"
+#: mod/admin.php:1217
+msgid ""
+"Don't include the content of a post/comment/private message/etc. in the "
+"email notifications that are sent out from this site, as a privacy measure."
+msgstr "Non include il contenuti del post/commento/messaggio privato/etc. nelle notifiche email che sono inviate da questo sito, per privacy"
-#: mod/profiles.php:742
-msgid "Love/romance"
-msgstr "Amore"
+#: mod/admin.php:1218
+msgid "Disallow public access to addons listed in the apps menu."
+msgstr "Disabilita l'accesso pubblico ai plugin raccolti nel menu apps."
-#: mod/profiles.php:743
-msgid "Work/employment"
-msgstr "Lavoro/impiego"
+#: mod/admin.php:1218
+msgid ""
+"Checking this box will restrict addons listed in the apps menu to members "
+"only."
+msgstr "Selezionando questo box si limiterà ai soli membri l'accesso ai componenti aggiuntivi nel menu applicazioni"
-#: mod/profiles.php:744
-msgid "School/education"
-msgstr "Scuola/educazione"
+#: mod/admin.php:1219
+msgid "Don't embed private images in posts"
+msgstr "Non inglobare immagini private nei post"
-#: mod/profiles.php:745
-msgid "Contact information and Social Networks"
-msgstr "Informazioni su contatti e social network"
+#: mod/admin.php:1219
+msgid ""
+"Don't replace locally-hosted private photos in posts with an embedded copy "
+"of the image. This means that contacts who receive posts containing private "
+"photos will have to authenticate and load each image, which may take a "
+"while."
+msgstr "Non sostituire le foto locali nei post con una copia incorporata dell'immagine. Questo significa che i contatti che riceveranno i post contenenti foto private dovranno autenticarsi e caricare ogni immagine, cosa che può richiedere un po' di tempo."
-#: mod/profiles.php:786
-msgid "Edit/Manage Profiles"
-msgstr "Modifica / Gestisci profili"
+#: mod/admin.php:1220
+msgid "Allow Users to set remote_self"
+msgstr "Permetti agli utenti di impostare 'io remoto'"
-#: mod/register.php:93
+#: mod/admin.php:1220
msgid ""
-"Registration successful. Please check your email for further instructions."
-msgstr "Registrazione completata. Controlla la tua mail per ulteriori informazioni."
+"With checking this, every user is allowed to mark every contact as a "
+"remote_self in the repair contact dialog. Setting this flag on a contact "
+"causes mirroring every posting of that contact in the users stream."
+msgstr "Selezionando questo, a tutti gli utenti sarà permesso di impostare qualsiasi contatto come 'io remoto' nella pagina di modifica del contatto. Impostare questa opzione fa si che tutti i messaggi di quel contatto vengano ripetuti nello stream dell'utente."
-#: mod/register.php:98
-#, php-format
-msgid ""
-"Failed to send email message. Here your accout details:<br> login: %s<br> "
-"password: %s<br><br>You can change your password after login."
-msgstr "Si è verificato un errore inviando l'email. I dettagli del tuo account:<br> login: %s<br> password: %s<br><br>Puoi cambiare la password dopo il login."
+#: mod/admin.php:1221
+msgid "Block multiple registrations"
+msgstr "Blocca registrazioni multiple"
-#: mod/register.php:105
-msgid "Registration successful."
-msgstr "Registrazione completata."
+#: mod/admin.php:1221
+msgid "Disallow users to register additional accounts for use as pages."
+msgstr "Non permette all'utente di registrare account extra da usare come pagine."
-#: mod/register.php:111
-msgid "Your registration can not be processed."
-msgstr "La tua registrazione non puo' essere elaborata."
+#: mod/admin.php:1222
+msgid "OpenID support"
+msgstr "Supporto OpenID"
-#: mod/register.php:160
-msgid "Your registration is pending approval by the site owner."
-msgstr "La tua richiesta è in attesa di approvazione da parte del proprietario del sito."
+#: mod/admin.php:1222
+msgid "OpenID support for registration and logins."
+msgstr "Supporta OpenID per la registrazione e il login"
-#: mod/register.php:226
-msgid ""
-"You may (optionally) fill in this form via OpenID by supplying your OpenID "
-"and clicking 'Register'."
-msgstr "Se vuoi, puoi riempire questo modulo tramite OpenID, inserendo il tuo OpenID e cliccando 'Registra'."
+#: mod/admin.php:1223
+msgid "Fullname check"
+msgstr "Controllo nome completo"
-#: mod/register.php:227
+#: mod/admin.php:1223
msgid ""
-"If you are not familiar with OpenID, please leave that field blank and fill "
-"in the rest of the items."
-msgstr "Se non hai familiarità con OpenID, lascia il campo vuoto e riempi il resto della maschera."
+"Force users to register with a space between firstname and lastname in Full "
+"name, as an antispam measure"
+msgstr "Forza gli utenti a registrarsi con uno spazio tra il nome e il cognome in \"Nome completo\", come misura anti spam"
-#: mod/register.php:228
-msgid "Your OpenID (optional): "
-msgstr "Il tuo OpenID (opzionale): "
+#: mod/admin.php:1224
+msgid "Community Page Style"
+msgstr "Stile pagina Comunità"
-#: mod/register.php:242
-msgid "Include your profile in member directory?"
-msgstr "Includi il tuo profilo nell'elenco pubblico?"
+#: mod/admin.php:1224
+msgid ""
+"Type of community page to show. 'Global community' shows every public "
+"posting from an open distributed network that arrived on this server."
+msgstr "Tipo di pagina Comunità da mostrare. 'Comunità Globale' mostra tutti i messaggi pubblici arrivati su questo server da network aperti distribuiti."
-#: mod/register.php:267
-msgid "Note for the admin"
-msgstr "Nota per l'amministratore"
+#: mod/admin.php:1225
+msgid "Posts per user on community page"
+msgstr "Messaggi per utente nella pagina Comunità"
-#: mod/register.php:267
-msgid "Leave a message for the admin, why you want to join this node"
-msgstr "Lascia un messaggio per l'amministratore, per esempio perché vuoi registrarti su questo nodo"
+#: mod/admin.php:1225
+msgid ""
+"The maximum number of posts per user on the community page. (Not valid for "
+"'Global Community')"
+msgstr "Il numero massimo di messaggi per utente mostrato nella pagina Comunità (non valido per 'Comunità globale')"
-#: mod/register.php:268
-msgid "Membership on this site is by invitation only."
-msgstr "La registrazione su questo sito è solo su invito."
+#: mod/admin.php:1226
+msgid "Enable OStatus support"
+msgstr "Abilita supporto OStatus"
-#: mod/register.php:269
-msgid "Your invitation ID: "
-msgstr "L'ID del tuo invito:"
+#: mod/admin.php:1226
+msgid ""
+"Provide built-in OStatus (StatusNet, GNU Social etc.) compatibility. All "
+"communications in OStatus are public, so privacy warnings will be "
+"occasionally displayed."
+msgstr "Fornisce la compatibilità integrata a OStatus (StatusNet, Gnu Social, etc.). Tutte le comunicazioni su OStatus sono pubbliche, quindi un avviso di privacy verrà mostrato occasionalmente."
-#: mod/register.php:272 mod/admin.php:1056
-msgid "Registration"
-msgstr "Registrazione"
+#: mod/admin.php:1227
+msgid "Only import OStatus threads from our contacts"
+msgstr "Importa conversazioni OStatus solo dai nostri contatti."
-#: mod/register.php:280
-msgid "Your Full Name (e.g. Joe Smith, real or real-looking): "
-msgstr "Il tuo nome completo (es. Mario Rossi, vero o che sembri vero): "
+#: mod/admin.php:1227
+msgid ""
+"Normally we import every content from our OStatus contacts. With this option"
+" we only store threads that are started by a contact that is known on our "
+"system."
+msgstr "Normalmente importiamo tutto il contenuto dai contatti OStatus. Con questa opzione salviamo solo le conversazioni iniziate da un contatto è conosciuto a questo nodo."
-#: mod/register.php:281
-msgid "Your Email Address: "
-msgstr "Il tuo indirizzo email: "
+#: mod/admin.php:1228
+msgid "OStatus support can only be enabled if threading is enabled."
+msgstr "Il supporto OStatus può essere abilitato solo se è abilitato il threading."
-#: mod/register.php:283 mod/settings.php:1278
-msgid "New Password:"
-msgstr "Nuova password:"
+#: mod/admin.php:1230
+msgid ""
+"Diaspora support can't be enabled because Friendica was installed into a sub"
+" directory."
+msgstr "Il supporto a Diaspora non può essere abilitato perché Friendica è stato installato in una sotto directory."
-#: mod/register.php:283
-msgid "Leave empty for an auto generated password."
-msgstr "Lascia vuoto per generare automaticamente una password."
+#: mod/admin.php:1231
+msgid "Enable Diaspora support"
+msgstr "Abilita il supporto a Diaspora"
-#: mod/register.php:284 mod/settings.php:1279
-msgid "Confirm:"
-msgstr "Conferma:"
+#: mod/admin.php:1231
+msgid "Provide built-in Diaspora network compatibility."
+msgstr "Fornisce compatibilità con il network Diaspora."
-#: mod/register.php:285
+#: mod/admin.php:1232
+msgid "Only allow Friendica contacts"
+msgstr "Permetti solo contatti Friendica"
+
+#: mod/admin.php:1232
msgid ""
-"Choose a profile nickname. This must begin with a text character. Your "
-"profile address on this site will then be "
-"'<strong>nickname@$sitename</strong>'."
-msgstr "Scegli un nome utente. Deve cominciare con una lettera. L'indirizzo del tuo profilo sarà '<strong>soprannome@$sitename</strong>'."
+"All contacts must use Friendica protocols. All other built-in communication "
+"protocols disabled."
+msgstr "Tutti i contatti devono usare il protocollo di Friendica. Tutti gli altri protocolli sono disabilitati."
-#: mod/register.php:286
-msgid "Choose a nickname: "
-msgstr "Scegli un nome utente: "
+#: mod/admin.php:1233
+msgid "Verify SSL"
+msgstr "Verifica SSL"
-#: mod/register.php:296
-msgid "Import your profile to this friendica instance"
-msgstr "Importa il tuo profilo in questo server friendica"
+#: mod/admin.php:1233
+msgid ""
+"If you wish, you can turn on strict certificate checking. This will mean you"
+" cannot connect (at all) to self-signed SSL sites."
+msgstr "Se vuoi, puoi abilitare il controllo rigoroso dei certificati.Questo significa che non potrai collegarti (del tutto) con siti con certificati SSL auto-firmati."
-#: mod/search.php:100
-msgid "Only logged in users are permitted to perform a search."
-msgstr "Solo agli utenti autenticati è permesso eseguire ricerche."
+#: mod/admin.php:1234
+msgid "Proxy user"
+msgstr "Utente Proxy"
-#: mod/search.php:124
-msgid "Too Many Requests"
-msgstr "Troppe richieste"
+#: mod/admin.php:1235
+msgid "Proxy URL"
+msgstr "URL Proxy"
-#: mod/search.php:125
-msgid "Only one search per minute is permitted for not logged in users."
-msgstr "Solo una ricerca al minuto è permessa agli utenti non autenticati."
+#: mod/admin.php:1236
+msgid "Network timeout"
+msgstr "Timeout rete"
-#: mod/search.php:225
-#, php-format
-msgid "Items tagged with: %s"
-msgstr "Elementi taggati con: %s"
+#: mod/admin.php:1236
+msgid "Value is in seconds. Set to 0 for unlimited (not recommended)."
+msgstr "Valore in secondi. Imposta a 0 per illimitato (non raccomandato)."
-#: mod/settings.php:43 mod/admin.php:1490
-msgid "Account"
-msgstr "Account"
+#: mod/admin.php:1237
+msgid "Maximum Load Average"
+msgstr "Massimo carico medio"
-#: mod/settings.php:52 mod/admin.php:169
-msgid "Additional features"
-msgstr "Funzionalità aggiuntive"
+#: mod/admin.php:1237
+msgid ""
+"Maximum system load before delivery and poll processes are deferred - "
+"default 50."
+msgstr "Massimo carico di sistema prima che i processi di invio e di poll siano ritardati. Predefinito a 50."
-#: mod/settings.php:60
-msgid "Display"
-msgstr "Visualizzazione"
+#: mod/admin.php:1238
+msgid "Maximum Load Average (Frontend)"
+msgstr "Media Massimo Carico (Frontend)"
-#: mod/settings.php:67 mod/settings.php:890
-msgid "Social Networks"
-msgstr "Social Networks"
+#: mod/admin.php:1238
+msgid "Maximum system load before the frontend quits service - default 50."
+msgstr "Massimo carico di sistema prima che il frontend fermi il servizio - default 50."
-#: mod/settings.php:74 mod/admin.php:167 mod/admin.php:1616 mod/admin.php:1679
-msgid "Plugins"
-msgstr "Plugin"
+#: mod/admin.php:1239
+msgid "Minimal Memory"
+msgstr "Memoria Minima"
-#: mod/settings.php:88
-msgid "Connected apps"
-msgstr "Applicazioni collegate"
+#: mod/admin.php:1239
+msgid ""
+"Minimal free memory in MB for the poller. Needs access to /proc/meminfo - "
+"default 0 (deactivated)."
+msgstr "Minima memoria libera in MB per il poller. Necessita di avere accesso a /proc/meminfo - default 0 (disabilitato)."
-#: mod/settings.php:95 mod/uexport.php:45
-msgid "Export personal data"
-msgstr "Esporta dati personali"
+#: mod/admin.php:1240
+msgid "Maximum table size for optimization"
+msgstr "Dimensione massima della tabella per l'ottimizzazione"
-#: mod/settings.php:102
-msgid "Remove account"
-msgstr "Rimuovi account"
+#: mod/admin.php:1240
+msgid ""
+"Maximum table size (in MB) for the automatic optimization - default 100 MB. "
+"Enter -1 to disable it."
+msgstr "La dimensione massima (in MB) per l'ottimizzazione automatica - default 100 MB. Inserisci -1 per disabilitarlo."
-#: mod/settings.php:157
-msgid "Missing some important data!"
-msgstr "Mancano alcuni dati importanti!"
+#: mod/admin.php:1241
+msgid "Minimum level of fragmentation"
+msgstr "Livello minimo di frammentazione"
-#: mod/settings.php:271
-msgid "Failed to connect with email account using the settings provided."
-msgstr "Impossibile collegarsi all'account email con i parametri forniti."
+#: mod/admin.php:1241
+msgid ""
+"Minimum fragmenation level to start the automatic optimization - default "
+"value is 30%."
+msgstr "Livello minimo di frammentazione per iniziare la procedura di ottimizzazione automatica - il valore di default è 30%."
-#: mod/settings.php:276
-msgid "Email settings updated."
-msgstr "Impostazioni e-mail aggiornate."
+#: mod/admin.php:1243
+msgid "Periodical check of global contacts"
+msgstr "Check periodico dei contatti globali"
-#: mod/settings.php:291
-msgid "Features updated"
-msgstr "Funzionalità aggiornate"
+#: mod/admin.php:1243
+msgid ""
+"If enabled, the global contacts are checked periodically for missing or "
+"outdated data and the vitality of the contacts and servers."
+msgstr "Se abilitato, i contatti globali sono controllati periodicamente per verificare dati mancanti o sorpassati e la vitalità dei contatti e dei server."
-#: mod/settings.php:361
-msgid "Relocate message has been send to your contacts"
-msgstr "Il messaggio di trasloco è stato inviato ai tuoi contatti"
+#: mod/admin.php:1244
+msgid "Days between requery"
+msgstr "Giorni tra le richieste"
-#: mod/settings.php:380
-msgid "Empty passwords are not allowed. Password unchanged."
-msgstr "Le password non possono essere vuote. Password non cambiata."
+#: mod/admin.php:1244
+msgid "Number of days after which a server is requeried for his contacts."
+msgstr "Numero di giorni dopo i quali al server vengono richiesti i suoi contatti."
-#: mod/settings.php:388
-msgid "Wrong password."
-msgstr "Password sbagliata."
+#: mod/admin.php:1245
+msgid "Discover contacts from other servers"
+msgstr "Trova contatti dagli altri server"
-#: mod/settings.php:399
-msgid "Password changed."
-msgstr "Password cambiata."
+#: mod/admin.php:1245
+msgid ""
+"Periodically query other servers for contacts. You can choose between "
+"'users': the users on the remote system, 'Global Contacts': active contacts "
+"that are known on the system. The fallback is meant for Redmatrix servers "
+"and older friendica servers, where global contacts weren't available. The "
+"fallback increases the server load, so the recommened setting is 'Users, "
+"Global Contacts'."
+msgstr "Richiede periodicamente contatti agli altri server. Puoi scegliere tra 'utenti', gli utenti sul sistema remoto, o 'contatti globali', i contatti attivi che sono conosciuti dal sistema. Il fallback è pensato per i server Redmatrix e i vecchi server Friendica, dove i contatti globali non sono disponibili. Il fallback incrementa il carico di sistema, per cui l'impostazione consigliata è \"Utenti, Contatti Globali\"."
-#: mod/settings.php:401
-msgid "Password update failed. Please try again."
-msgstr "Aggiornamento password fallito. Prova ancora."
+#: mod/admin.php:1246
+msgid "Timeframe for fetching global contacts"
+msgstr "Termine per il recupero contatti globali"
-#: mod/settings.php:481
-msgid " Please use a shorter name."
-msgstr " Usa un nome più corto."
+#: mod/admin.php:1246
+msgid ""
+"When the discovery is activated, this value defines the timeframe for the "
+"activity of the global contacts that are fetched from other servers."
+msgstr "Quando si attiva la scoperta, questo valore definisce il periodo di tempo per l'attività dei contatti globali che vengono prelevati da altri server."
-#: mod/settings.php:483
-msgid " Name too short."
-msgstr " Nome troppo corto."
+#: mod/admin.php:1247
+msgid "Search the local directory"
+msgstr "Cerca la directory locale"
-#: mod/settings.php:492
-msgid "Wrong Password"
-msgstr "Password Sbagliata"
+#: mod/admin.php:1247
+msgid ""
+"Search the local directory instead of the global directory. When searching "
+"locally, every search will be executed on the global directory in the "
+"background. This improves the search results when the search is repeated."
+msgstr "Cerca nella directory locale invece che nella directory globale. Durante la ricerca a livello locale, ogni ricerca verrà eseguita sulla directory globale in background. Ciò migliora i risultati della ricerca quando la ricerca viene ripetuta."
-#: mod/settings.php:497
-msgid " Not valid email."
-msgstr " Email non valida."
+#: mod/admin.php:1249
+msgid "Publish server information"
+msgstr "Pubblica informazioni server"
-#: mod/settings.php:503
-msgid " Cannot change to that email."
-msgstr "Non puoi usare quella email."
+#: mod/admin.php:1249
+msgid ""
+"If enabled, general server and usage data will be published. The data "
+"contains the name and version of the server, number of users with public "
+"profiles, number of posts and the activated protocols and connectors. See <a"
+" href='http://the-federation.info/'>the-federation.info</a> for details."
+msgstr "Se abilitata, saranno pubblicati i dati generali del server e i dati di utilizzo. I dati contengono il nome e la versione del server, il numero di utenti con profili pubblici, numero dei posti e dei protocolli e connettori attivati. Per informazioni, vedere <a href='http://the-federation.info/'> the-federation.info </a>."
-#: mod/settings.php:559
-msgid "Private forum has no privacy permissions. Using default privacy group."
-msgstr "Il forum privato non ha permessi di privacy. Uso il gruppo di privacy predefinito."
+#: mod/admin.php:1251
+msgid "Check upstream version"
+msgstr ""
-#: mod/settings.php:563
-msgid "Private forum has no privacy permissions and no default privacy group."
-msgstr "Il gruppo privato non ha permessi di privacy e nessun gruppo di privacy predefinito."
+#: mod/admin.php:1251
+msgid ""
+"Enables checking for new Friendica versions at github. If there is a new "
+"version, you will be informed in the admin panel overview."
+msgstr ""
-#: mod/settings.php:603
-msgid "Settings updated."
-msgstr "Impostazioni aggiornate."
+#: mod/admin.php:1252
+msgid "Suppress Tags"
+msgstr "Sopprimi Tags"
-#: mod/settings.php:680 mod/settings.php:706 mod/settings.php:742
-msgid "Add application"
-msgstr "Aggiungi applicazione"
+#: mod/admin.php:1252
+msgid "Suppress showing a list of hashtags at the end of the posting."
+msgstr "Non mostra la lista di hashtag in coda al messaggio"
-#: mod/settings.php:681 mod/settings.php:792 mod/settings.php:841
-#: mod/settings.php:908 mod/settings.php:1005 mod/settings.php:1271
-#: mod/admin.php:1055 mod/admin.php:1680 mod/admin.php:1943 mod/admin.php:2017
-#: mod/admin.php:2170
-msgid "Save Settings"
-msgstr "Salva Impostazioni"
+#: mod/admin.php:1253
+msgid "Path to item cache"
+msgstr "Percorso cache elementi"
-#: mod/settings.php:684 mod/settings.php:710
-msgid "Consumer Key"
-msgstr "Consumer Key"
+#: mod/admin.php:1253
+msgid "The item caches buffers generated bbcode and external images."
+msgstr "La cache degli elementi memorizza il bbcode generato e le immagini esterne."
-#: mod/settings.php:685 mod/settings.php:711
-msgid "Consumer Secret"
-msgstr "Consumer Secret"
+#: mod/admin.php:1254
+msgid "Cache duration in seconds"
+msgstr "Durata della cache in secondi"
-#: mod/settings.php:686 mod/settings.php:712
-msgid "Redirect"
-msgstr "Redirect"
+#: mod/admin.php:1254
+msgid ""
+"How long should the cache files be hold? Default value is 86400 seconds (One"
+" day). To disable the item cache, set the value to -1."
+msgstr "Quanto a lungo devono essere mantenuti i file di cache? Il valore predefinito è 86400 secondi (un giorno). Per disabilitare la cache, imposta il valore a -1."
-#: mod/settings.php:687 mod/settings.php:713
-msgid "Icon url"
-msgstr "Url icona"
+#: mod/admin.php:1255
+msgid "Maximum numbers of comments per post"
+msgstr "Numero massimo di commenti per post"
-#: mod/settings.php:698
-msgid "You can't edit this application."
-msgstr "Non puoi modificare questa applicazione."
+#: mod/admin.php:1255
+msgid "How much comments should be shown for each post? Default value is 100."
+msgstr "Quanti commenti devono essere mostrati per ogni post? Default : 100."
-#: mod/settings.php:741
-msgid "Connected Apps"
-msgstr "Applicazioni Collegate"
+#: mod/admin.php:1256
+msgid "Temp path"
+msgstr "Percorso file temporanei"
-#: mod/settings.php:745
-msgid "Client key starts with"
-msgstr "Chiave del client inizia con"
+#: mod/admin.php:1256
+msgid ""
+"If you have a restricted system where the webserver can't access the system "
+"temp path, enter another path here."
+msgstr "Se si dispone di un sistema ristretto in cui il server web non può accedere al percorso temporaneo di sistema, inserire un altro percorso qui."
-#: mod/settings.php:746
-msgid "No name"
-msgstr "Nessun nome"
+#: mod/admin.php:1257
+msgid "Base path to installation"
+msgstr "Percorso base all'installazione"
-#: mod/settings.php:747
-msgid "Remove authorization"
-msgstr "Rimuovi l'autorizzazione"
+#: mod/admin.php:1257
+msgid ""
+"If the system cannot detect the correct path to your installation, enter the"
+" correct path here. This setting should only be set if you are using a "
+"restricted system and symbolic links to your webroot."
+msgstr "Se il sistema non è in grado di rilevare il percorso corretto per l'installazione, immettere il percorso corretto qui. Questa impostazione deve essere inserita solo se si utilizza un sistema limitato e/o collegamenti simbolici al tuo webroot."
-#: mod/settings.php:759
-msgid "No Plugin settings configured"
-msgstr "Nessun plugin ha impostazioni modificabili"
+#: mod/admin.php:1258
+msgid "Disable picture proxy"
+msgstr "Disabilita il proxy immagini"
-#: mod/settings.php:768
-msgid "Plugin Settings"
-msgstr "Impostazioni plugin"
+#: mod/admin.php:1258
+msgid ""
+"The picture proxy increases performance and privacy. It shouldn't be used on"
+" systems with very low bandwith."
+msgstr "Il proxy immagini aumenta le performance e la privacy. Non dovrebbe essere usato su server con poca banda disponibile."
-#: mod/settings.php:782 mod/admin.php:2159 mod/admin.php:2160
-msgid "Off"
-msgstr "Spento"
+#: mod/admin.php:1259
+msgid "Only search in tags"
+msgstr "Cerca solo nei tag"
-#: mod/settings.php:782 mod/admin.php:2159 mod/admin.php:2160
-msgid "On"
-msgstr "Acceso"
+#: mod/admin.php:1259
+msgid "On large systems the text search can slow down the system extremely."
+msgstr "Su server con molti dati, la ricerca nel testo può estremamente rallentare il sistema."
-#: mod/settings.php:790
-msgid "Additional Features"
-msgstr "Funzionalità aggiuntive"
+#: mod/admin.php:1261
+msgid "New base url"
+msgstr "Nuovo url base"
-#: mod/settings.php:800 mod/settings.php:804
-msgid "General Social Media Settings"
-msgstr "Impostazioni Media Sociali"
+#: mod/admin.php:1261
+msgid ""
+"Change base url for this server. Sends relocate message to all Friendica and"
+" Diaspora* contacts of all users."
+msgstr ""
-#: mod/settings.php:810
-msgid "Disable intelligent shortening"
-msgstr "Disabilita accorciamento intelligente"
+#: mod/admin.php:1263
+msgid "RINO Encryption"
+msgstr "Crittografia RINO"
-#: mod/settings.php:812
-msgid ""
-"Normally the system tries to find the best link to add to shortened posts. "
-"If this option is enabled then every shortened post will always point to the"
-" original friendica post."
-msgstr "Normalmente il sistema tenta di trovare il migliore link da aggiungere a un post accorciato. Se questa opzione è abilitata, ogni post accorciato conterrà sempre un link al post originale su Friendica."
+#: mod/admin.php:1263
+msgid "Encryption layer between nodes."
+msgstr "Crittografia delle comunicazioni tra nodi."
-#: mod/settings.php:818
-msgid "Automatically follow any GNU Social (OStatus) followers/mentioners"
-msgstr "Segui automaticamente chiunque da GNU Social (OStatus) ti segua o ti menzioni"
+#: mod/admin.php:1265
+msgid "Maximum number of parallel workers"
+msgstr "Massimo numero di lavori in parallelo"
-#: mod/settings.php:820
+#: mod/admin.php:1265
msgid ""
-"If you receive a message from an unknown OStatus user, this option decides "
-"what to do. If it is checked, a new contact will be created for every "
-"unknown user."
-msgstr "Se ricevi un messaggio da un utente OStatus sconosciuto, questa opzione decide cosa fare. Se selezionato, un nuovo contatto verrà creato per ogni utente sconosciuto."
+"On shared hosters set this to 2. On larger systems, values of 10 are great. "
+"Default value is 4."
+msgstr "Su host condivisi imposta a 2. Su sistemi più grandi, valori fino a 10 vanno bene. Il valore di default è 4."
-#: mod/settings.php:826
-msgid "Default group for OStatus contacts"
-msgstr "Gruppo di default per i contatti OStatus"
+#: mod/admin.php:1266
+msgid "Don't use 'proc_open' with the worker"
+msgstr "Non usare 'proc_open' con il worker"
-#: mod/settings.php:834
-msgid "Your legacy GNU Social account"
-msgstr "Il tuo vecchio account GNU Social"
+#: mod/admin.php:1266
+msgid ""
+"Enable this if your system doesn't allow the use of 'proc_open'. This can "
+"happen on shared hosters. If this is enabled you should increase the "
+"frequency of poller calls in your crontab."
+msgstr "Abilita se il tuo sistema non consente l'utilizzo di 'proc_open'. Può succedere con gli hosting condivisi. Se abiliti questa opzione, dovresti aumentare la frequenza delle chiamate al poller nel tuo crontab."
-#: mod/settings.php:836
+#: mod/admin.php:1267
+msgid "Enable fastlane"
+msgstr "Abilita fastlane"
+
+#: mod/admin.php:1267
msgid ""
-"If you enter your old GNU Social/Statusnet account name here (in the format "
-"user@domain.tld), your contacts will be added automatically. The field will "
-"be emptied when done."
-msgstr "Se inserisci il nome del tuo vecchio account GNU Social/Statusnet qui (nel formato utente@dominio.tld), i tuoi contatti verranno automaticamente aggiunti. Il campo verrà svuotato una volta terminato."
+"When enabed, the fastlane mechanism starts an additional worker if processes"
+" with higher priority are blocked by processes of lower priority."
+msgstr "Quando abilitato, il meccanismo di fastlane avvia processi aggiuntivi se processi con priorità più alta sono bloccati da processi con priorità più bassa."
-#: mod/settings.php:839
-msgid "Repair OStatus subscriptions"
-msgstr "Ripara le iscrizioni OStatus"
+#: mod/admin.php:1268
+msgid "Enable frontend worker"
+msgstr "Abilita worker da frontend"
-#: mod/settings.php:848 mod/settings.php:849
+#: mod/admin.php:1268
#, php-format
-msgid "Built-in support for %s connectivity is %s"
-msgstr "Il supporto integrato per la connettività con %s è %s"
+msgid ""
+"When enabled the Worker process is triggered when backend access is "
+"performed (e.g. messages being delivered). On smaller sites you might want "
+"to call %s/worker on a regular basis via an external cron job. You should "
+"only enable this option if you cannot utilize cron/scheduled jobs on your "
+"server."
+msgstr ""
-#: mod/settings.php:848 mod/settings.php:849
-msgid "enabled"
-msgstr "abilitato"
+#: mod/admin.php:1298
+msgid "Update has been marked successful"
+msgstr "L'aggiornamento è stato segnato come di successo"
-#: mod/settings.php:848 mod/settings.php:849
-msgid "disabled"
-msgstr "disabilitato"
+#: mod/admin.php:1306
+#, php-format
+msgid "Database structure update %s was successfully applied."
+msgstr "Aggiornamento struttura database %s applicata con successo."
-#: mod/settings.php:849
-msgid "GNU Social (OStatus)"
-msgstr "GNU Social (OStatus)"
+#: mod/admin.php:1309
+#, php-format
+msgid "Executing of database structure update %s failed with error: %s"
+msgstr "Aggiornamento struttura database %s fallita con errore: %s"
-#: mod/settings.php:883
-msgid "Email access is disabled on this site."
-msgstr "L'accesso email è disabilitato su questo sito."
+#: mod/admin.php:1323
+#, php-format
+msgid "Executing %s failed with error: %s"
+msgstr "Esecuzione di %s fallita con errore: %s"
-#: mod/settings.php:895
-msgid "Email/Mailbox Setup"
-msgstr "Impostazioni email"
+#: mod/admin.php:1326
+#, php-format
+msgid "Update %s was successfully applied."
+msgstr "L'aggiornamento %s è stato applicato con successo"
-#: mod/settings.php:896
-msgid ""
-"If you wish to communicate with email contacts using this service "
-"(optional), please specify how to connect to your mailbox."
-msgstr "Se vuoi comunicare con i contatti email usando questo servizio, specifica come collegarti alla tua casella di posta. (opzionale)"
+#: mod/admin.php:1329
+#, php-format
+msgid "Update %s did not return a status. Unknown if it succeeded."
+msgstr "L'aggiornamento %s non ha riportato uno stato. Non so se è andato a buon fine."
-#: mod/settings.php:897
-msgid "Last successful email check:"
-msgstr "Ultimo controllo email eseguito con successo:"
+#: mod/admin.php:1332
+#, php-format
+msgid "There was no additional update function %s that needed to be called."
+msgstr "Non ci sono altre funzioni di aggiornamento %s da richiamare."
-#: mod/settings.php:899
-msgid "IMAP server name:"
-msgstr "Nome server IMAP:"
+#: mod/admin.php:1352
+msgid "No failed updates."
+msgstr "Nessun aggiornamento fallito."
-#: mod/settings.php:900
-msgid "IMAP port:"
-msgstr "Porta IMAP:"
+#: mod/admin.php:1353
+msgid "Check database structure"
+msgstr "Controlla struttura database"
-#: mod/settings.php:901
-msgid "Security:"
-msgstr "Sicurezza:"
+#: mod/admin.php:1358
+msgid "Failed Updates"
+msgstr "Aggiornamenti falliti"
-#: mod/settings.php:901 mod/settings.php:906
-msgid "None"
-msgstr "Nessuna"
+#: mod/admin.php:1359
+msgid ""
+"This does not include updates prior to 1139, which did not return a status."
+msgstr "Questo non include gli aggiornamenti prima del 1139, che non ritornano lo stato."
-#: mod/settings.php:902
-msgid "Email login name:"
-msgstr "Nome utente email:"
+#: mod/admin.php:1360
+msgid "Mark success (if update was manually applied)"
+msgstr "Segna completato (se l'update è stato applicato manualmente)"
-#: mod/settings.php:903
-msgid "Email password:"
-msgstr "Password email:"
+#: mod/admin.php:1361
+msgid "Attempt to execute this update step automatically"
+msgstr "Cerco di eseguire questo aggiornamento in automatico"
-#: mod/settings.php:904
-msgid "Reply-to address:"
-msgstr "Indirizzo di risposta:"
+#: mod/admin.php:1395
+#, php-format
+msgid ""
+"\n"
+"\t\t\tDear %1$s,\n"
+"\t\t\t\tthe administrator of %2$s has set up an account for you."
+msgstr "\nGentile %1$s,\n l'amministratore di %2$s ha impostato un account per te."
-#: mod/settings.php:905
-msgid "Send public posts to all email contacts:"
-msgstr "Invia i messaggi pubblici ai contatti email:"
+#: mod/admin.php:1398
+#, php-format
+msgid ""
+"\n"
+"\t\t\tThe login details are as follows:\n"
+"\n"
+"\t\t\tSite Location:\t%1$s\n"
+"\t\t\tLogin Name:\t\t%2$s\n"
+"\t\t\tPassword:\t\t%3$s\n"
+"\n"
+"\t\t\tYou may change your password from your account \"Settings\" page after logging\n"
+"\t\t\tin.\n"
+"\n"
+"\t\t\tPlease take a few moments to review the other account settings on that page.\n"
+"\n"
+"\t\t\tYou may also wish to add some basic information to your default profile\n"
+"\t\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
+"\n"
+"\t\t\tWe recommend setting your full name, adding a profile photo,\n"
+"\t\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n"
+"\t\t\tperhaps what country you live in; if you do not wish to be more specific\n"
+"\t\t\tthan that.\n"
+"\n"
+"\t\t\tWe fully respect your right to privacy, and none of these items are necessary.\n"
+"\t\t\tIf you are new and do not know anybody here, they may help\n"
+"\t\t\tyou to make some new and interesting friends.\n"
+"\n"
+"\t\t\tThank you and welcome to %4$s."
+msgstr "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %1$s\n Nome utente: %2$s\n Password: %3$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %4$s"
-#: mod/settings.php:906
-msgid "Action after import:"
-msgstr "Azione post importazione:"
+#: mod/admin.php:1442
+#, php-format
+msgid "%s user blocked/unblocked"
+msgid_plural "%s users blocked/unblocked"
+msgstr[0] "%s utente bloccato/sbloccato"
+msgstr[1] "%s utenti bloccati/sbloccati"
-#: mod/settings.php:906
-msgid "Move to folder"
-msgstr "Sposta nella cartella"
+#: mod/admin.php:1449
+#, php-format
+msgid "%s user deleted"
+msgid_plural "%s users deleted"
+msgstr[0] "%s utente cancellato"
+msgstr[1] "%s utenti cancellati"
-#: mod/settings.php:907
-msgid "Move to folder:"
-msgstr "Sposta nella cartella:"
+#: mod/admin.php:1496
+#, php-format
+msgid "User '%s' deleted"
+msgstr "Utente '%s' cancellato"
-#: mod/settings.php:943 mod/admin.php:942
-msgid "No special theme for mobile devices"
-msgstr "Nessun tema speciale per i dispositivi mobili"
+#: mod/admin.php:1504
+#, php-format
+msgid "User '%s' unblocked"
+msgstr "Utente '%s' sbloccato"
-#: mod/settings.php:1003
-msgid "Display Settings"
-msgstr "Impostazioni Grafiche"
+#: mod/admin.php:1504
+#, php-format
+msgid "User '%s' blocked"
+msgstr "Utente '%s' bloccato"
-#: mod/settings.php:1009 mod/settings.php:1032
-msgid "Display Theme:"
-msgstr "Tema:"
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Register date"
+msgstr "Data registrazione"
-#: mod/settings.php:1010
-msgid "Mobile Theme:"
-msgstr "Tema mobile:"
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Last login"
+msgstr "Ultimo accesso"
-#: mod/settings.php:1011
-msgid "Suppress warning of insecure networks"
-msgstr "Sopprimi avvisi reti insicure"
+#: mod/admin.php:1612 mod/admin.php:1638
+msgid "Last item"
+msgstr "Ultimo elemento"
-#: mod/settings.php:1011
-msgid ""
-"Should the system suppress the warning that the current group contains "
-"members of networks that can't receive non public postings."
-msgstr "Il sistema sopprimerà l'avviso che il gruppo selezionato contiene membri di reti che non possono ricevere post non pubblici."
+#: mod/admin.php:1612 mod/settings.php:43
+msgid "Account"
+msgstr "Account"
-#: mod/settings.php:1012
-msgid "Update browser every xx seconds"
-msgstr "Aggiorna il browser ogni x secondi"
+#: mod/admin.php:1621
+msgid "Add User"
+msgstr "Aggiungi utente"
-#: mod/settings.php:1012
-msgid "Minimum of 10 seconds. Enter -1 to disable it."
-msgstr "Minimo 10 secondi. Inserisci -1 per disabilitarlo"
+#: mod/admin.php:1622
+msgid "select all"
+msgstr "seleziona tutti"
-#: mod/settings.php:1013
-msgid "Number of items to display per page:"
-msgstr "Numero di elementi da mostrare per pagina:"
+#: mod/admin.php:1623
+msgid "User registrations waiting for confirm"
+msgstr "Richieste di registrazione in attesa di conferma"
-#: mod/settings.php:1013 mod/settings.php:1014
-msgid "Maximum of 100 items"
-msgstr "Massimo 100 voci"
+#: mod/admin.php:1624
+msgid "User waiting for permanent deletion"
+msgstr "Utente in attesa di cancellazione definitiva"
-#: mod/settings.php:1014
-msgid "Number of items to display per page when viewed from mobile device:"
-msgstr "Numero di voci da visualizzare per pagina quando si utilizza un dispositivo mobile:"
+#: mod/admin.php:1625
+msgid "Request date"
+msgstr "Data richiesta"
-#: mod/settings.php:1015
-msgid "Don't show emoticons"
-msgstr "Non mostrare le emoticons"
+#: mod/admin.php:1626
+msgid "No registrations."
+msgstr "Nessuna registrazione."
-#: mod/settings.php:1016
-msgid "Calendar"
-msgstr "Calendario"
+#: mod/admin.php:1627
+msgid "Note from the user"
+msgstr "Nota dall'utente"
-#: mod/settings.php:1017
-msgid "Beginning of week:"
-msgstr "Inizio della settimana:"
+#: mod/admin.php:1629
+msgid "Deny"
+msgstr "Nega"
-#: mod/settings.php:1018
-msgid "Don't show notices"
-msgstr "Non mostrare gli avvisi"
+#: mod/admin.php:1631 mod/contacts.php:635 mod/contacts.php:835
+#: mod/contacts.php:1013
+msgid "Block"
+msgstr "Blocca"
-#: mod/settings.php:1019
-msgid "Infinite scroll"
-msgstr "Scroll infinito"
+#: mod/admin.php:1632 mod/contacts.php:635 mod/contacts.php:835
+#: mod/contacts.php:1013
+msgid "Unblock"
+msgstr "Sblocca"
-#: mod/settings.php:1020
-msgid "Automatic updates only at the top of the network page"
-msgstr "Aggiornamenti automatici solo in cima alla pagina \"rete\""
+#: mod/admin.php:1633
+msgid "Site admin"
+msgstr "Amministrazione sito"
-#: mod/settings.php:1021
-msgid "Bandwith Saver Mode"
-msgstr "Modalità Salva Banda"
+#: mod/admin.php:1634
+msgid "Account expired"
+msgstr "Account scaduto"
-#: mod/settings.php:1021
-msgid ""
-"When enabled, embedded content is not displayed on automatic updates, they "
-"only show on page reload."
-msgstr "Quando abilitato, il contenuto embeddato non è mostrato quando la pagina si aggiorna automaticamente, ma solo quando la pagina viene ricaricata."
+#: mod/admin.php:1637
+msgid "New User"
+msgstr "Nuovo Utente"
-#: mod/settings.php:1023
-msgid "General Theme Settings"
-msgstr "Opzioni Generali Tema"
+#: mod/admin.php:1638
+msgid "Deleted since"
+msgstr "Rimosso da"
-#: mod/settings.php:1024
-msgid "Custom Theme Settings"
-msgstr "Opzioni Personalizzate Tema"
+#: mod/admin.php:1643
+msgid ""
+"Selected users will be deleted!\\n\\nEverything these users had posted on "
+"this site will be permanently deleted!\\n\\nAre you sure?"
+msgstr "Gli utenti selezionati saranno cancellati!\\n\\nTutto quello che gli utenti hanno inviato su questo sito sarà permanentemente canellato!\\n\\nSei sicuro?"
-#: mod/settings.php:1025
-msgid "Content Settings"
-msgstr "Opzioni Contenuto"
+#: mod/admin.php:1644
+msgid ""
+"The user {0} will be deleted!\\n\\nEverything this user has posted on this "
+"site will be permanently deleted!\\n\\nAre you sure?"
+msgstr "L'utente {0} sarà cancellato!\\n\\nTutto quello che ha inviato su questo sito sarà permanentemente cancellato!\\n\\nSei sicuro?"
-#: mod/settings.php:1026 view/theme/duepuntozero/config.php:63
-#: view/theme/frio/config.php:66 view/theme/quattro/config.php:69
-#: view/theme/vier/config.php:114
-msgid "Theme settings"
-msgstr "Impostazioni tema"
+#: mod/admin.php:1654
+msgid "Name of the new user."
+msgstr "Nome del nuovo utente."
-#: mod/settings.php:1110
-msgid "Account Types"
-msgstr "Tipi di Account"
+#: mod/admin.php:1655
+msgid "Nickname"
+msgstr "Nome utente"
-#: mod/settings.php:1111
-msgid "Personal Page Subtypes"
-msgstr "Sottotipi di Pagine Personali"
+#: mod/admin.php:1655
+msgid "Nickname of the new user."
+msgstr "Nome utente del nuovo utente."
-#: mod/settings.php:1112
-msgid "Community Forum Subtypes"
-msgstr "Sottotipi di Community Forum"
+#: mod/admin.php:1656
+msgid "Email address of the new user."
+msgstr "Indirizzo Email del nuovo utente."
-#: mod/settings.php:1119
-msgid "Personal Page"
-msgstr "Pagina Personale"
+#: mod/admin.php:1699
+#, php-format
+msgid "Plugin %s disabled."
+msgstr "Plugin %s disabilitato."
-#: mod/settings.php:1120
-msgid "This account is a regular personal profile"
-msgstr "Questo account è un profilo personale regolare"
+#: mod/admin.php:1703
+#, php-format
+msgid "Plugin %s enabled."
+msgstr "Plugin %s abilitato."
-#: mod/settings.php:1123
-msgid "Organisation Page"
-msgstr "Pagina Organizzazione"
+#: mod/admin.php:1714 mod/admin.php:1966
+msgid "Disable"
+msgstr "Disabilita"
-#: mod/settings.php:1124
-msgid "This account is a profile for an organisation"
-msgstr "Questo account è il profilo per un'organizzazione"
+#: mod/admin.php:1716 mod/admin.php:1968
+msgid "Enable"
+msgstr "Abilita"
-#: mod/settings.php:1127
-msgid "News Page"
-msgstr "Pagina Notizie"
+#: mod/admin.php:1739 mod/admin.php:2015
+msgid "Toggle"
+msgstr "Inverti"
+
+#: mod/admin.php:1747 mod/admin.php:2024
+msgid "Author: "
+msgstr "Autore: "
-#: mod/settings.php:1128
-msgid "This account is a news account/reflector"
-msgstr "Questo account è un account di notizie"
+#: mod/admin.php:1748 mod/admin.php:2025
+msgid "Maintainer: "
+msgstr "Manutentore: "
-#: mod/settings.php:1131
-msgid "Community Forum"
-msgstr "Community Forum"
+#: mod/admin.php:1803
+msgid "Reload active plugins"
+msgstr "Ricarica i plugin attivi"
-#: mod/settings.php:1132
+#: mod/admin.php:1808
+#, php-format
msgid ""
-"This account is a community forum where people can discuss with each other"
-msgstr "Questo account è un forum comunitario dove le persone possono discutere tra loro"
+"There are currently no plugins available on your node. You can find the "
+"official plugin repository at %1$s and might find other interesting plugins "
+"in the open plugin registry at %2$s"
+msgstr "Non sono disponibili componenti aggiuntivi sul tuo nodo. Puoi trovare il repository ufficiale dei plugin su %1$s e potresti trovare altri plugin interessanti nell'open plugin repository su %2$s"
-#: mod/settings.php:1135
-msgid "Normal Account Page"
-msgstr "Pagina Account Normale"
+#: mod/admin.php:1927
+msgid "No themes found."
+msgstr "Nessun tema trovato."
-#: mod/settings.php:1136
-msgid "This account is a normal personal profile"
-msgstr "Questo account è un normale profilo personale"
+#: mod/admin.php:2006
+msgid "Screenshot"
+msgstr "Anteprima"
-#: mod/settings.php:1139
-msgid "Soapbox Page"
-msgstr "Pagina Sandbox"
-
-#: mod/settings.php:1140
-msgid "Automatically approve all connection/friend requests as read-only fans"
-msgstr "Chi richiede la connessione/amicizia sarà accettato automaticamente come fan che potrà solamente leggere la bacheca"
+#: mod/admin.php:2066
+msgid "Reload active themes"
+msgstr "Ricarica i temi attivi"
-#: mod/settings.php:1143
-msgid "Public Forum"
-msgstr "Forum Pubblico"
+#: mod/admin.php:2071
+#, php-format
+msgid "No themes found on the system. They should be paced in %1$s"
+msgstr "Non sono stati trovati temi sul tuo sistema. Dovrebbero essere in %1$s"
-#: mod/settings.php:1144
-msgid "Automatically approve all contact requests"
-msgstr "Approva automaticamente tutte le richieste di contatto"
+#: mod/admin.php:2072
+msgid "[Experimental]"
+msgstr "[Sperimentale]"
-#: mod/settings.php:1147
-msgid "Automatic Friend Page"
-msgstr "Pagina con amicizia automatica"
+#: mod/admin.php:2073
+msgid "[Unsupported]"
+msgstr "[Non supportato]"
-#: mod/settings.php:1148
-msgid "Automatically approve all connection/friend requests as friends"
-msgstr "Chi richiede la connessione/amicizia sarà accettato automaticamente come amico"
+#: mod/admin.php:2097
+msgid "Log settings updated."
+msgstr "Impostazioni Log aggiornate."
-#: mod/settings.php:1151
-msgid "Private Forum [Experimental]"
-msgstr "Forum privato [sperimentale]"
+#: mod/admin.php:2129
+msgid "PHP log currently enabled."
+msgstr "Log PHP abilitato."
-#: mod/settings.php:1152
-msgid "Private forum - approved members only"
-msgstr "Forum privato - solo membri approvati"
+#: mod/admin.php:2131
+msgid "PHP log currently disabled."
+msgstr "Log PHP disabilitato"
-#: mod/settings.php:1163
-msgid "OpenID:"
-msgstr "OpenID:"
+#: mod/admin.php:2140
+msgid "Clear"
+msgstr "Pulisci"
-#: mod/settings.php:1163
-msgid "(Optional) Allow this OpenID to login to this account."
-msgstr "(Opzionale) Consente di loggarti in questo account con questo OpenID"
+#: mod/admin.php:2145
+msgid "Enable Debugging"
+msgstr "Abilita Debugging"
-#: mod/settings.php:1171
-msgid "Publish your default profile in your local site directory?"
-msgstr "Pubblica il tuo profilo predefinito nell'elenco locale del sito"
+#: mod/admin.php:2146
+msgid "Log file"
+msgstr "File di Log"
-#: mod/settings.php:1171
-msgid "Your profile may be visible in public."
-msgstr "Il tuo profilo potrebbe essere visibile pubblicamente."
+#: mod/admin.php:2146
+msgid ""
+"Must be writable by web server. Relative to your Friendica top-level "
+"directory."
+msgstr "Il server web deve avere i permessi di scrittura. Relativo alla tua directory Friendica."
-#: mod/settings.php:1177
-msgid "Publish your default profile in the global social directory?"
-msgstr "Pubblica il tuo profilo predefinito nell'elenco sociale globale"
+#: mod/admin.php:2147
+msgid "Log level"
+msgstr "Livello di Log"
-#: mod/settings.php:1184
-msgid "Hide your contact/friend list from viewers of your default profile?"
-msgstr "Nascondi la lista dei tuoi contatti/amici dai visitatori del tuo profilo predefinito"
+#: mod/admin.php:2150
+msgid "PHP logging"
+msgstr "Log PHP"
-#: mod/settings.php:1188
+#: mod/admin.php:2151
msgid ""
-"If enabled, posting public messages to Diaspora and other networks isn't "
-"possible."
-msgstr "Se abilitato, l'invio di messaggi pubblici verso Diaspora e altri network non sarà possibile"
-
-#: mod/settings.php:1193
-msgid "Allow friends to post to your profile page?"
-msgstr "Permetti agli amici di scrivere sulla tua pagina profilo?"
+"To enable logging of PHP errors and warnings you can add the following to "
+"the .htconfig.php file of your installation. The filename set in the "
+"'error_log' line is relative to the friendica top-level directory and must "
+"be writeable by the web server. The option '1' for 'log_errors' and "
+"'display_errors' is to enable these options, set to '0' to disable them."
+msgstr "Per abilitare il log degli errori e degli avvisi di PHP puoi aggiungere le seguenti righe al file .htconfig.php nella tua installazione. La posizione del file impostato in 'error_log' è relativa alla directory principale della tua installazione Friendica e il server web deve avere i permessi di scrittura sul file. Il valore '1' per 'log_errors' e 'display_errors' abilita le opzioni, imposta '0' per disabilitarle."
-#: mod/settings.php:1198
-msgid "Allow friends to tag your posts?"
-msgstr "Permetti agli amici di aggiungere tag ai tuoi messaggi?"
+#: mod/admin.php:2281 mod/admin.php:2282 mod/settings.php:792
+msgid "Off"
+msgstr "Spento"
-#: mod/settings.php:1203
-msgid "Allow us to suggest you as a potential friend to new members?"
-msgstr "Ci permetti di suggerirti come potenziale amico ai nuovi membri?"
+#: mod/admin.php:2281 mod/admin.php:2282 mod/settings.php:792
+msgid "On"
+msgstr "Acceso"
-#: mod/settings.php:1208
-msgid "Permit unknown people to send you private mail?"
-msgstr "Permetti a utenti sconosciuti di inviarti messaggi privati?"
+#: mod/admin.php:2282
+#, php-format
+msgid "Lock feature %s"
+msgstr "Blocca funzionalità %s"
-#: mod/settings.php:1216
-msgid "Profile is <strong>not published</strong>."
-msgstr "Il profilo <strong>non è pubblicato</strong>."
+#: mod/admin.php:2290
+msgid "Manage Additional Features"
+msgstr "Gestisci Funzionalità Aggiuntive"
-#: mod/settings.php:1224
+#: mod/contacts.php:139
#, php-format
-msgid "Your Identity Address is <strong>'%s'</strong> or '%s'."
-msgstr "L'indirizzo della tua identità è <strong>'%s'</strong> or '%s'."
+msgid "%d contact edited."
+msgid_plural "%d contacts edited."
+msgstr[0] "%d contatto modificato."
+msgstr[1] "%d contatti modificati"
-#: mod/settings.php:1231
-msgid "Automatically expire posts after this many days:"
-msgstr "Fai scadere i post automaticamente dopo x giorni:"
+#: mod/contacts.php:174 mod/contacts.php:392
+msgid "Could not access contact record."
+msgstr "Non è possibile accedere al contatto."
-#: mod/settings.php:1231
-msgid "If empty, posts will not expire. Expired posts will be deleted"
-msgstr "Se lasciato vuoto, i messaggi non verranno cancellati."
+#: mod/contacts.php:188
+msgid "Could not locate selected profile."
+msgstr "Non riesco a trovare il profilo selezionato."
-#: mod/settings.php:1232
-msgid "Advanced expiration settings"
-msgstr "Impostazioni avanzate di scadenza"
+#: mod/contacts.php:221
+msgid "Contact updated."
+msgstr "Contatto aggiornato."
-#: mod/settings.php:1233
-msgid "Advanced Expiration"
-msgstr "Scadenza avanzata"
+#: mod/contacts.php:413
+msgid "Contact has been blocked"
+msgstr "Il contatto è stato bloccato"
-#: mod/settings.php:1234
-msgid "Expire posts:"
-msgstr "Fai scadere i post:"
+#: mod/contacts.php:413
+msgid "Contact has been unblocked"
+msgstr "Il contatto è stato sbloccato"
-#: mod/settings.php:1235
-msgid "Expire personal notes:"
-msgstr "Fai scadere le Note personali:"
+#: mod/contacts.php:424
+msgid "Contact has been ignored"
+msgstr "Il contatto è ignorato"
-#: mod/settings.php:1236
-msgid "Expire starred posts:"
-msgstr "Fai scadere i post Speciali:"
+#: mod/contacts.php:424
+msgid "Contact has been unignored"
+msgstr "Il contatto non è più ignorato"
-#: mod/settings.php:1237
-msgid "Expire photos:"
-msgstr "Fai scadere le foto:"
+#: mod/contacts.php:436
+msgid "Contact has been archived"
+msgstr "Il contatto è stato archiviato"
-#: mod/settings.php:1238
-msgid "Only expire posts by others:"
-msgstr "Fai scadere solo i post degli altri:"
+#: mod/contacts.php:436
+msgid "Contact has been unarchived"
+msgstr "Il contatto è stato dearchiviato"
-#: mod/settings.php:1269
-msgid "Account Settings"
-msgstr "Impostazioni account"
+#: mod/contacts.php:461
+msgid "Drop contact"
+msgstr "Cancella contatto"
-#: mod/settings.php:1277
-msgid "Password Settings"
-msgstr "Impostazioni password"
+#: mod/contacts.php:464 mod/contacts.php:831
+msgid "Do you really want to delete this contact?"
+msgstr "Vuoi veramente cancellare questo contatto?"
-#: mod/settings.php:1279
-msgid "Leave password fields blank unless changing"
-msgstr "Lascia questi campi in bianco per non effettuare variazioni alla password"
+#: mod/contacts.php:483
+msgid "Contact has been removed."
+msgstr "Il contatto è stato rimosso."
-#: mod/settings.php:1280
-msgid "Current Password:"
-msgstr "Password Attuale:"
+#: mod/contacts.php:520
+#, php-format
+msgid "You are mutual friends with %s"
+msgstr "Sei amico reciproco con %s"
-#: mod/settings.php:1280 mod/settings.php:1281
-msgid "Your current password to confirm the changes"
-msgstr "La tua password attuale per confermare le modifiche"
+#: mod/contacts.php:524
+#, php-format
+msgid "You are sharing with %s"
+msgstr "Stai condividendo con %s"
-#: mod/settings.php:1281
-msgid "Password:"
-msgstr "Password:"
+#: mod/contacts.php:529
+#, php-format
+msgid "%s is sharing with you"
+msgstr "%s sta condividendo con te"
-#: mod/settings.php:1285
-msgid "Basic Settings"
-msgstr "Impostazioni base"
+#: mod/contacts.php:549
+msgid "Private communications are not available for this contact."
+msgstr "Le comunicazioni private non sono disponibili per questo contatto."
-#: mod/settings.php:1287
-msgid "Email Address:"
-msgstr "Indirizzo Email:"
+#: mod/contacts.php:556
+msgid "(Update was successful)"
+msgstr "(L'aggiornamento è stato completato)"
-#: mod/settings.php:1288
-msgid "Your Timezone:"
-msgstr "Il tuo fuso orario:"
+#: mod/contacts.php:556
+msgid "(Update was not successful)"
+msgstr "(L'aggiornamento non è stato completato)"
-#: mod/settings.php:1289
-msgid "Your Language:"
-msgstr "La tua lingua:"
+#: mod/contacts.php:558 mod/contacts.php:994
+msgid "Suggest friends"
+msgstr "Suggerisci amici"
-#: mod/settings.php:1289
-msgid ""
-"Set the language we use to show you friendica interface and to send you "
-"emails"
-msgstr "Imposta la lingua che sarà usata per mostrarti l'interfaccia di Friendica e per inviarti le email"
+#: mod/contacts.php:562
+#, php-format
+msgid "Network type: %s"
+msgstr "Tipo di rete: %s"
-#: mod/settings.php:1290
-msgid "Default Post Location:"
-msgstr "Località predefinita:"
+#: mod/contacts.php:575
+msgid "Communications lost with this contact!"
+msgstr "Comunicazione con questo contatto persa!"
-#: mod/settings.php:1291
-msgid "Use Browser Location:"
-msgstr "Usa la località rilevata dal browser:"
+#: mod/contacts.php:578
+msgid "Fetch further information for feeds"
+msgstr "Recupera maggiori informazioni per i feed"
-#: mod/settings.php:1294
-msgid "Security and Privacy Settings"
-msgstr "Impostazioni di sicurezza e privacy"
+#: mod/contacts.php:579
+msgid "Fetch information"
+msgstr "Recupera informazioni"
-#: mod/settings.php:1296
-msgid "Maximum Friend Requests/Day:"
-msgstr "Numero massimo di richieste di amicizia al giorno:"
+#: mod/contacts.php:579
+msgid "Fetch information and keywords"
+msgstr "Recupera informazioni e parole chiave"
-#: mod/settings.php:1296 mod/settings.php:1326
-msgid "(to prevent spam abuse)"
-msgstr "(per prevenire lo spam)"
+#: mod/contacts.php:603
+msgid "Contact"
+msgstr "Contatto"
-#: mod/settings.php:1297
-msgid "Default Post Permissions"
-msgstr "Permessi predefiniti per i messaggi"
+#: mod/contacts.php:606
+msgid "Profile Visibility"
+msgstr "Visibilità del profilo"
-#: mod/settings.php:1298
-msgid "(click to open/close)"
-msgstr "(clicca per aprire/chiudere)"
+#: mod/contacts.php:607
+#, php-format
+msgid ""
+"Please choose the profile you would like to display to %s when viewing your "
+"profile securely."
+msgstr "Seleziona il profilo che vuoi mostrare a %s quando visita il tuo profilo in modo sicuro."
-#: mod/settings.php:1309
-msgid "Default Private Post"
-msgstr "Default Post Privato"
+#: mod/contacts.php:608
+msgid "Contact Information / Notes"
+msgstr "Informazioni / Note sul contatto"
-#: mod/settings.php:1310
-msgid "Default Public Post"
-msgstr "Default Post Pubblico"
+#: mod/contacts.php:609
+msgid "Their personal note"
+msgstr ""
-#: mod/settings.php:1314
-msgid "Default Permissions for New Posts"
-msgstr "Permessi predefiniti per i nuovi post"
+#: mod/contacts.php:611
+msgid "Edit contact notes"
+msgstr "Modifica note contatto"
-#: mod/settings.php:1326
-msgid "Maximum private messages per day from unknown people:"
-msgstr "Numero massimo di messaggi privati da utenti sconosciuti per giorno:"
+#: mod/contacts.php:617
+msgid "Block/Unblock contact"
+msgstr "Blocca/Sblocca contatto"
-#: mod/settings.php:1329
-msgid "Notification Settings"
-msgstr "Impostazioni notifiche"
+#: mod/contacts.php:618
+msgid "Ignore contact"
+msgstr "Ignora il contatto"
-#: mod/settings.php:1330
-msgid "By default post a status message when:"
-msgstr "Invia un messaggio di stato quando:"
+#: mod/contacts.php:619
+msgid "Repair URL settings"
+msgstr "Impostazioni riparazione URL"
-#: mod/settings.php:1331
-msgid "accepting a friend request"
-msgstr "accetti una richiesta di amicizia"
+#: mod/contacts.php:620
+msgid "View conversations"
+msgstr "Vedi conversazioni"
-#: mod/settings.php:1332
-msgid "joining a forum/community"
-msgstr "ti unisci a un forum/comunità"
+#: mod/contacts.php:626
+msgid "Last update:"
+msgstr "Ultimo aggiornamento:"
-#: mod/settings.php:1333
-msgid "making an <em>interesting</em> profile change"
-msgstr "fai un <em>interessante</em> modifica al profilo"
+#: mod/contacts.php:628
+msgid "Update public posts"
+msgstr "Aggiorna messaggi pubblici"
-#: mod/settings.php:1334
-msgid "Send a notification email when:"
-msgstr "Invia una mail di notifica quando:"
+#: mod/contacts.php:630 mod/contacts.php:1004
+msgid "Update now"
+msgstr "Aggiorna adesso"
-#: mod/settings.php:1335
-msgid "You receive an introduction"
-msgstr "Ricevi una presentazione"
+#: mod/contacts.php:636 mod/contacts.php:836 mod/contacts.php:1021
+msgid "Unignore"
+msgstr "Non ignorare"
-#: mod/settings.php:1336
-msgid "Your introductions are confirmed"
-msgstr "Le tue presentazioni sono confermate"
+#: mod/contacts.php:640
+msgid "Currently blocked"
+msgstr "Bloccato"
-#: mod/settings.php:1337
-msgid "Someone writes on your profile wall"
-msgstr "Qualcuno scrive sulla bacheca del tuo profilo"
+#: mod/contacts.php:641
+msgid "Currently ignored"
+msgstr "Ignorato"
-#: mod/settings.php:1338
-msgid "Someone writes a followup comment"
-msgstr "Qualcuno scrive un commento a un tuo messaggio"
+#: mod/contacts.php:642
+msgid "Currently archived"
+msgstr "Al momento archiviato"
-#: mod/settings.php:1339
-msgid "You receive a private message"
-msgstr "Ricevi un messaggio privato"
+#: mod/contacts.php:643
+msgid ""
+"Replies/likes to your public posts <strong>may</strong> still be visible"
+msgstr "Risposte ai tuoi post pubblici <strong>possono</strong> essere comunque visibili"
-#: mod/settings.php:1340
-msgid "You receive a friend suggestion"
-msgstr "Hai ricevuto un suggerimento di amicizia"
+#: mod/contacts.php:644
+msgid "Notification for new posts"
+msgstr "Notifica per i nuovi messaggi"
-#: mod/settings.php:1341
-msgid "You are tagged in a post"
-msgstr "Sei stato taggato in un post"
+#: mod/contacts.php:644
+msgid "Send a notification of every new post of this contact"
+msgstr "Invia una notifica per ogni nuovo messaggio di questo contatto"
-#: mod/settings.php:1342
-msgid "You are poked/prodded/etc. in a post"
-msgstr "Sei 'toccato'/'spronato'/ecc. in un post"
+#: mod/contacts.php:647
+msgid "Blacklisted keywords"
+msgstr "Parole chiave in blacklist"
-#: mod/settings.php:1344
-msgid "Activate desktop notifications"
-msgstr "Attiva notifiche desktop"
+#: mod/contacts.php:647
+msgid ""
+"Comma separated list of keywords that should not be converted to hashtags, "
+"when \"Fetch information and keywords\" is selected"
+msgstr "Lista separata da virgola di parole chiave che non dovranno essere convertite in hashtag, quando \"Recupera informazioni e parole chiave\" è selezionato"
-#: mod/settings.php:1344
-msgid "Show desktop popup on new notifications"
-msgstr "Mostra un popup di notifica sul desktop all'arrivo di nuove notifiche"
+#: mod/contacts.php:665
+msgid "Actions"
+msgstr "Azioni"
-#: mod/settings.php:1346
-msgid "Text-only notification emails"
-msgstr "Email di notifica in solo testo"
+#: mod/contacts.php:668
+msgid "Contact Settings"
+msgstr "Impostazioni Contatto"
-#: mod/settings.php:1348
-msgid "Send text only notification emails, without the html part"
-msgstr "Invia le email di notifica in solo testo, senza la parte in html"
+#: mod/contacts.php:714
+msgid "Suggestions"
+msgstr "Suggerimenti"
-#: mod/settings.php:1350
-msgid "Advanced Account/Page Type Settings"
-msgstr "Impostazioni avanzate Account/Tipo di pagina"
+#: mod/contacts.php:717
+msgid "Suggest potential friends"
+msgstr "Suggerisci potenziali amici"
-#: mod/settings.php:1351
-msgid "Change the behaviour of this account for special situations"
-msgstr "Modifica il comportamento di questo account in situazioni speciali"
+#: mod/contacts.php:725
+msgid "Show all contacts"
+msgstr "Mostra tutti i contatti"
-#: mod/settings.php:1354
-msgid "Relocate"
-msgstr "Trasloca"
+#: mod/contacts.php:730
+msgid "Unblocked"
+msgstr "Sbloccato"
-#: mod/settings.php:1355
-msgid ""
-"If you have moved this profile from another server, and some of your "
-"contacts don't receive your updates, try pushing this button."
-msgstr "Se hai spostato questo profilo da un'altro server, e alcuni dei tuoi contatti non ricevono i tuoi aggiornamenti, prova a premere questo bottone."
+#: mod/contacts.php:733
+msgid "Only show unblocked contacts"
+msgstr "Mostra solo contatti non bloccati"
-#: mod/settings.php:1356
-msgid "Resend relocate message to contacts"
-msgstr "Invia nuovamente il messaggio di trasloco ai contatti"
+#: mod/contacts.php:739
+msgid "Blocked"
+msgstr "Bloccato"
-#: mod/uexport.php:37
-msgid "Export account"
-msgstr "Esporta account"
+#: mod/contacts.php:742
+msgid "Only show blocked contacts"
+msgstr "Mostra solo contatti bloccati"
-#: mod/uexport.php:37
-msgid ""
-"Export your account info and contacts. Use this to make a backup of your "
-"account and/or to move it to another server."
-msgstr "Esporta le informazioni del tuo account e dei contatti. Usa questa funzione per fare un backup del tuo account o per spostarlo in un altro server."
+#: mod/contacts.php:748
+msgid "Ignored"
+msgstr "Ignorato"
-#: mod/uexport.php:38
-msgid "Export all"
-msgstr "Esporta tutto"
+#: mod/contacts.php:751
+msgid "Only show ignored contacts"
+msgstr "Mostra solo contatti ignorati"
-#: mod/uexport.php:38
-msgid ""
-"Export your accout info, contacts and all your items as json. Could be a "
-"very big file, and could take a lot of time. Use this to make a full backup "
-"of your account (photos are not exported)"
-msgstr "Esporta le informazioni del tuo account, i tuoi contatti e tutti i tuoi elementi in json. Può diventare un file veramente molto grosso e metterci un sacco di tempo. Usa questa funzione per fare un backup completo del tuo account (le foto non sono esportate)"
+#: mod/contacts.php:757
+msgid "Archived"
+msgstr "Archiviato"
-#: mod/videos.php:124
-msgid "Do you really want to delete this video?"
-msgstr "Vuoi veramente cancellare questo video?"
+#: mod/contacts.php:760
+msgid "Only show archived contacts"
+msgstr "Mostra solo contatti archiviati"
-#: mod/videos.php:129
-msgid "Delete Video"
-msgstr "Rimuovi video"
+#: mod/contacts.php:766
+msgid "Hidden"
+msgstr "Nascosto"
-#: mod/videos.php:208
-msgid "No videos selected"
-msgstr "Nessun video selezionato"
+#: mod/contacts.php:769
+msgid "Only show hidden contacts"
+msgstr "Mostra solo contatti nascosti"
-#: mod/videos.php:402
-msgid "Recent Videos"
-msgstr "Video Recenti"
+#: mod/contacts.php:826
+msgid "Search your contacts"
+msgstr "Cerca nei tuoi contatti"
-#: mod/videos.php:404
-msgid "Upload New Videos"
-msgstr "Carica Nuovo Video"
+#: mod/contacts.php:834 mod/settings.php:160 mod/settings.php:717
+msgid "Update"
+msgstr "Aggiorna"
-#: mod/install.php:106
-msgid "Friendica Communications Server - Setup"
-msgstr "Friendica Comunicazione Server - Impostazioni"
+#: mod/contacts.php:837 mod/contacts.php:1029
+msgid "Archive"
+msgstr "Archivia"
-#: mod/install.php:112
-msgid "Could not connect to database."
-msgstr " Impossibile collegarsi con il database."
+#: mod/contacts.php:837 mod/contacts.php:1029
+msgid "Unarchive"
+msgstr "Dearchivia"
-#: mod/install.php:116
-msgid "Could not create table."
-msgstr "Impossibile creare le tabelle."
+#: mod/contacts.php:840
+msgid "Batch Actions"
+msgstr "Azioni Batch"
-#: mod/install.php:122
-msgid "Your Friendica site database has been installed."
-msgstr "Il tuo Friendica è stato installato."
+#: mod/contacts.php:886
+msgid "View all contacts"
+msgstr "Vedi tutti i contatti"
-#: mod/install.php:127
-msgid ""
-"You may need to import the file \"database.sql\" manually using phpmyadmin "
-"or mysql."
-msgstr "Potresti dover importare il file \"database.sql\" manualmente con phpmyadmin o mysql"
+#: mod/contacts.php:896
+msgid "View all common friends"
+msgstr "Vedi tutti gli amici in comune"
-#: mod/install.php:128 mod/install.php:200 mod/install.php:547
-msgid "Please see the file \"INSTALL.txt\"."
-msgstr "Leggi il file \"INSTALL.txt\"."
+#: mod/contacts.php:903
+msgid "Advanced Contact Settings"
+msgstr "Impostazioni avanzate Contatto"
-#: mod/install.php:140
-msgid "Database already in use."
-msgstr "Database già in uso."
+#: mod/contacts.php:937
+msgid "Mutual Friendship"
+msgstr "Amicizia reciproca"
-#: mod/install.php:197
-msgid "System check"
-msgstr "Controllo sistema"
+#: mod/contacts.php:941
+msgid "is a fan of yours"
+msgstr "è un tuo fan"
-#: mod/install.php:202
-msgid "Check again"
-msgstr "Controlla ancora"
+#: mod/contacts.php:945
+msgid "you are a fan of"
+msgstr "sei un fan di"
-#: mod/install.php:221
-msgid "Database connection"
-msgstr "Connessione al database"
+#: mod/contacts.php:1015
+msgid "Toggle Blocked status"
+msgstr "Inverti stato \"Blocca\""
-#: mod/install.php:222
-msgid ""
-"In order to install Friendica we need to know how to connect to your "
-"database."
-msgstr "Per installare Friendica dobbiamo sapere come collegarci al tuo database."
+#: mod/contacts.php:1023
+msgid "Toggle Ignored status"
+msgstr "Inverti stato \"Ignora\""
-#: mod/install.php:223
-msgid ""
-"Please contact your hosting provider or site administrator if you have "
-"questions about these settings."
-msgstr "Contatta il tuo fornitore di hosting o l'amministratore del sito se hai domande su queste impostazioni."
+#: mod/contacts.php:1031
+msgid "Toggle Archive status"
+msgstr "Inverti stato \"Archiviato\""
-#: mod/install.php:224
+#: mod/contacts.php:1039
+msgid "Delete contact"
+msgstr "Rimuovi contatto"
+
+#: mod/dfrn_confirm.php:74 mod/profiles.php:25 mod/profiles.php:135
+#: mod/profiles.php:182 mod/profiles.php:618
+msgid "Profile not found."
+msgstr "Profilo non trovato."
+
+#: mod/dfrn_confirm.php:131
msgid ""
-"The database you specify below should already exist. If it does not, please "
-"create it before continuing."
-msgstr "Il database dovrà già esistere. Se non esiste, crealo prima di continuare."
+"This may occasionally happen if contact was requested by both persons and it"
+" has already been approved."
+msgstr "Questo può accadere occasionalmente se la richiesta di contatto era stata inviata da entrambe le persone e già approvata."
-#: mod/install.php:228
-msgid "Database Server Name"
-msgstr "Nome del database server"
+#: mod/dfrn_confirm.php:248
+msgid "Response from remote site was not understood."
+msgstr "Errore di comunicazione con l'altro sito."
-#: mod/install.php:229
-msgid "Database Login Name"
-msgstr "Nome utente database"
+#: mod/dfrn_confirm.php:257 mod/dfrn_confirm.php:262
+msgid "Unexpected response from remote site: "
+msgstr "La risposta dell'altro sito non può essere gestita: "
-#: mod/install.php:230
-msgid "Database Login Password"
-msgstr "Password utente database"
+#: mod/dfrn_confirm.php:271
+msgid "Confirmation completed successfully."
+msgstr "Conferma completata con successo."
-#: mod/install.php:230
-msgid "For security reasons the password must not be empty"
-msgstr "Per motivi di sicurezza la password non puo' essere vuota."
+#: mod/dfrn_confirm.php:273 mod/dfrn_confirm.php:287 mod/dfrn_confirm.php:294
+msgid "Remote site reported: "
+msgstr "Il sito remoto riporta: "
-#: mod/install.php:231
-msgid "Database Name"
-msgstr "Nome database"
+#: mod/dfrn_confirm.php:285
+msgid "Temporary failure. Please wait and try again."
+msgstr "Problema temporaneo. Attendi e riprova."
-#: mod/install.php:232 mod/install.php:273
-msgid "Site administrator email address"
-msgstr "Indirizzo email dell'amministratore del sito"
+#: mod/dfrn_confirm.php:292
+msgid "Introduction failed or was revoked."
+msgstr "La presentazione ha generato un errore o è stata revocata."
-#: mod/install.php:232 mod/install.php:273
-msgid ""
-"Your account email address must match this in order to use the web admin "
-"panel."
-msgstr "Il tuo indirizzo email deve corrispondere a questo per poter usare il pannello di amministrazione web."
+#: mod/dfrn_confirm.php:421
+msgid "Unable to set contact photo."
+msgstr "Impossibile impostare la foto del contatto."
-#: mod/install.php:236 mod/install.php:276
-msgid "Please select a default timezone for your website"
-msgstr "Seleziona il fuso orario predefinito per il tuo sito web"
+#: mod/dfrn_confirm.php:562
+#, php-format
+msgid "No user record found for '%s' "
+msgstr "Nessun utente trovato '%s'"
-#: mod/install.php:263
-msgid "Site settings"
-msgstr "Impostazioni sito"
+#: mod/dfrn_confirm.php:572
+msgid "Our site encryption key is apparently messed up."
+msgstr "La nostra chiave di criptazione del sito sembra essere corrotta."
-#: mod/install.php:277
-msgid "System Language:"
-msgstr "Lingua di Sistema:"
+#: mod/dfrn_confirm.php:583
+msgid "Empty site URL was provided or URL could not be decrypted by us."
+msgstr "E' stato fornito un indirizzo vuoto o non possiamo decrittare l'indirizzo."
-#: mod/install.php:277
-msgid ""
-"Set the default language for your Friendica installation interface and to "
-"send emails."
-msgstr "Imposta la lingua di default per l'interfaccia e l'invio delle email."
+#: mod/dfrn_confirm.php:605
+msgid "Contact record was not found for you on our site."
+msgstr "Il contatto non è stato trovato sul nostro sito."
-#: mod/install.php:317
-msgid "Could not find a command line version of PHP in the web server PATH."
-msgstr "Non riesco a trovare la versione di PHP da riga di comando nel PATH del server web"
+#: mod/dfrn_confirm.php:619
+#, php-format
+msgid "Site public key not available in contact record for URL %s."
+msgstr "La chiave pubblica del sito non è disponibile per l'URL %s"
-#: mod/install.php:318
+#: mod/dfrn_confirm.php:639
msgid ""
-"If you don't have a command line version of PHP installed on server, you "
-"will not be able to run the background processing. See <a "
-"href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-"
-"up-the-poller'>'Setup the poller'</a>"
-msgstr "Se non hai la versione a riga di comando di PHP installata sul tuo server, non sarai in grado di eseguire i processi in background. Vedi <a href='https://github.com/friendica/friendica/blob/master/doc/Install.md#set-up-the-poller'>'Setup the poller'</a>"
-
-#: mod/install.php:322
-msgid "PHP executable path"
-msgstr "Percorso eseguibile PHP"
-
-#: mod/install.php:322
-msgid ""
-"Enter full path to php executable. You can leave this blank to continue the "
-"installation."
-msgstr "Inserisci il percorso completo all'eseguibile di php. Puoi lasciare bianco questo campo per continuare l'installazione."
-
-#: mod/install.php:327
-msgid "Command line PHP"
-msgstr "PHP da riga di comando"
-
-#: mod/install.php:336
-msgid "PHP executable is not the php cli binary (could be cgi-fgci version)"
-msgstr "L'eseguibile PHP non è il binario php cli (potrebbe essere la versione cgi-fcgi)"
-
-#: mod/install.php:337
-msgid "Found PHP version: "
-msgstr "Versione PHP:"
-
-#: mod/install.php:339
-msgid "PHP cli binary"
-msgstr "Binario PHP cli"
-
-#: mod/install.php:350
-msgid ""
-"The command line version of PHP on your system does not have "
-"\"register_argc_argv\" enabled."
-msgstr "La versione da riga di comando di PHP nel sistema non ha abilitato \"register_argc_argv\"."
-
-#: mod/install.php:351
-msgid "This is required for message delivery to work."
-msgstr "E' obbligatorio per far funzionare la consegna dei messaggi."
-
-#: mod/install.php:353
-msgid "PHP register_argc_argv"
-msgstr "PHP register_argc_argv"
-
-#: mod/install.php:376
-msgid ""
-"Error: the \"openssl_pkey_new\" function on this system is not able to "
-"generate encryption keys"
-msgstr "Errore: la funzione \"openssl_pkey_new\" in questo sistema non è in grado di generare le chiavi di criptazione"
-
-#: mod/install.php:377
-msgid ""
-"If running under Windows, please see "
-"\"http://www.php.net/manual/en/openssl.installation.php\"."
-msgstr "Se stai eseguendo friendika su windows, guarda \"http://www.php.net/manual/en/openssl.installation.php\"."
-
-#: mod/install.php:379
-msgid "Generate encryption keys"
-msgstr "Genera chiavi di criptazione"
-
-#: mod/install.php:386
-msgid "libCurl PHP module"
-msgstr "modulo PHP libCurl"
-
-#: mod/install.php:387
-msgid "GD graphics PHP module"
-msgstr "modulo PHP GD graphics"
-
-#: mod/install.php:388
-msgid "OpenSSL PHP module"
-msgstr "modulo PHP OpenSSL"
-
-#: mod/install.php:389
-msgid "PDO or MySQLi PHP module"
-msgstr "modulo PHP PDO o MySQLi"
-
-#: mod/install.php:390
-msgid "mb_string PHP module"
-msgstr "modulo PHP mb_string"
-
-#: mod/install.php:391
-msgid "XML PHP module"
-msgstr "Modulo PHP XML"
-
-#: mod/install.php:392
-msgid "iconv module"
-msgstr "modulo iconv"
-
-#: mod/install.php:396 mod/install.php:398
-msgid "Apache mod_rewrite module"
-msgstr "Modulo mod_rewrite di Apache"
-
-#: mod/install.php:396
-msgid ""
-"Error: Apache webserver mod-rewrite module is required but not installed."
-msgstr "Errore: E' il modulo mod-rewrite di Apache è richiesto, ma non risulta installato"
-
-#: mod/install.php:404
-msgid "Error: libCURL PHP module required but not installed."
-msgstr "Errore: il modulo libCURL di PHP è richiesto, ma non risulta installato."
-
-#: mod/install.php:408
-msgid ""
-"Error: GD graphics PHP module with JPEG support required but not installed."
-msgstr "Errore: Il modulo GD graphics di PHP con supporto a JPEG è richiesto, ma non risulta installato."
+"The ID provided by your system is a duplicate on our system. It should work "
+"if you try again."
+msgstr "L'ID fornito dal tuo sistema è duplicato sul nostro sistema. Se riprovi dovrebbe funzionare."
-#: mod/install.php:412
-msgid "Error: openssl PHP module required but not installed."
-msgstr "Errore: il modulo openssl di PHP è richiesto, ma non risulta installato."
+#: mod/dfrn_confirm.php:650
+msgid "Unable to set your contact credentials on our system."
+msgstr "Impossibile impostare le credenziali del tuo contatto sul nostro sistema."
-#: mod/install.php:416
-msgid "Error: PDO or MySQLi PHP module required but not installed."
-msgstr "Errore: uno dei due moduli PHP PDO o MySQLi è richiesto ma non installato."
+#: mod/dfrn_confirm.php:712
+msgid "Unable to update your contact profile details on our system"
+msgstr "Impossibile aggiornare i dettagli del tuo contatto sul nostro sistema"
-#: mod/install.php:420
-msgid "Error: The MySQL driver for PDO is not installed."
-msgstr "Errore: il driver MySQL per PDO non è installato."
+#: mod/dfrn_confirm.php:784
+#, php-format
+msgid "%1$s has joined %2$s"
+msgstr "%1$s si è unito a %2$s"
-#: mod/install.php:424
-msgid "Error: mb_string PHP module required but not installed."
-msgstr "Errore: il modulo PHP mb_string è richiesto, ma non risulta installato."
+#: mod/dirfind.php:41
+#, php-format
+msgid "People Search - %s"
+msgstr "Cerca persone - %s"
-#: mod/install.php:428
-msgid "Error: iconv PHP module required but not installed."
-msgstr "Errore: il modulo PHP iconv è richiesto ma non installato."
+#: mod/dirfind.php:52
+#, php-format
+msgid "Forum Search - %s"
+msgstr "Ricerca Forum - %s"
-#: mod/install.php:438
-msgid "Error, XML PHP module required but not installed."
-msgstr "Errore, il modulo PHP XML è richiesto ma non installato."
+#: mod/display.php:482
+msgid "Item has been removed."
+msgstr "L'oggetto è stato rimosso."
-#: mod/install.php:450
-msgid ""
-"The web installer needs to be able to create a file called \".htconfig.php\""
-" in the top folder of your web server and it is unable to do so."
-msgstr "L'installazione web deve poter creare un file chiamato \".htconfig.php\" nella cartella principale del tuo web server ma non è in grado di farlo."
+#: mod/events.php:98 mod/events.php:100
+msgid "Event can not end before it has started."
+msgstr "Un evento non può finire prima di iniziare."
-#: mod/install.php:451
-msgid ""
-"This is most often a permission setting, as the web server may not be able "
-"to write files in your folder - even if you can."
-msgstr "Ciò è dovuto spesso a impostazioni di permessi, dato che il web server può non essere in grado di scrivere il file nella tua cartella, anche se tu puoi."
+#: mod/events.php:107 mod/events.php:109
+msgid "Event title and start time are required."
+msgstr "Titolo e ora di inizio dell'evento sono richiesti."
-#: mod/install.php:452
-msgid ""
-"At the end of this procedure, we will give you a text to save in a file "
-"named .htconfig.php in your Friendica top folder."
-msgstr "Alla fine di questa procedura, di daremo un testo da salvare in un file chiamato .htconfig.php nella tua cartella principale di Friendica"
+#: mod/events.php:385
+msgid "Create New Event"
+msgstr "Crea un nuovo evento"
-#: mod/install.php:453
-msgid ""
-"You can alternatively skip this procedure and perform a manual installation."
-" Please see the file \"INSTALL.txt\" for instructions."
-msgstr "Puoi in alternativa saltare questa procedura ed eseguire l'installazione manualmente. Vedi il file \"INSTALL.txt\" per le istruzioni."
+#: mod/events.php:505
+msgid "Event details"
+msgstr "Dettagli dell'evento"
-#: mod/install.php:456
-msgid ".htconfig.php is writable"
-msgstr ".htconfig.php è scrivibile"
+#: mod/events.php:506
+msgid "Starting date and Title are required."
+msgstr "La data di inizio e il titolo sono richiesti."
-#: mod/install.php:466
-msgid ""
-"Friendica uses the Smarty3 template engine to render its web views. Smarty3 "
-"compiles templates to PHP to speed up rendering."
-msgstr "Friendica usa il motore di template Smarty3 per renderizzare le sue pagine web. Smarty3 compila i template in PHP per velocizzare il rendering."
+#: mod/events.php:507 mod/events.php:508
+msgid "Event Starts:"
+msgstr "L'evento inizia:"
-#: mod/install.php:467
-msgid ""
-"In order to store these compiled templates, the web server needs to have "
-"write access to the directory view/smarty3/ under the Friendica top level "
-"folder."
-msgstr "Per salvare questi template compilati, il server werb ha bisogno dell'accesso in scrittura alla cartella view/smarty3/ nella cartella principale dei Friendica."
+#: mod/events.php:507 mod/events.php:519 mod/profiles.php:708
+msgid "Required"
+msgstr "Richiesto"
-#: mod/install.php:468
-msgid ""
-"Please ensure that the user that your web server runs as (e.g. www-data) has"
-" write access to this folder."
-msgstr "Per favore, controlla che l'utente con cui il tuo server web gira (es www-data) ha accesso in scrittura a questa cartella."
+#: mod/events.php:509 mod/events.php:525
+msgid "Finish date/time is not known or not relevant"
+msgstr "La data/ora di fine non è definita"
-#: mod/install.php:469
-msgid ""
-"Note: as a security measure, you should give the web server write access to "
-"view/smarty3/ only--not the template files (.tpl) that it contains."
-msgstr "Nota: come misura di sicurezza, dovresti dare accesso in scrittura solo alla cartella view/smarty3, non ai template (.tpl) che contiene."
+#: mod/events.php:511 mod/events.php:512
+msgid "Event Finishes:"
+msgstr "L'evento finisce:"
-#: mod/install.php:472
-msgid "view/smarty3 is writable"
-msgstr "view/smarty3 è scrivibile"
+#: mod/events.php:513 mod/events.php:526
+msgid "Adjust for viewer timezone"
+msgstr "Visualizza con il fuso orario di chi legge"
-#: mod/install.php:488
-msgid ""
-"Url rewrite in .htaccess is not working. Check your server configuration."
-msgstr "La riscrittura degli url in .htaccess non funziona. Controlla la configurazione del tuo server."
+#: mod/events.php:515
+msgid "Description:"
+msgstr "Descrizione:"
-#: mod/install.php:490
-msgid "Url rewrite is working"
-msgstr "La riscrittura degli url funziona"
+#: mod/events.php:519 mod/events.php:521
+msgid "Title:"
+msgstr "Titolo:"
-#: mod/install.php:509
-msgid "ImageMagick PHP extension is not installed"
-msgstr "L'estensione PHP ImageMagick non è installata"
+#: mod/events.php:522 mod/events.php:523
+msgid "Share this event"
+msgstr "Condividi questo evento"
-#: mod/install.php:511
-msgid "ImageMagick PHP extension is installed"
-msgstr "L'estensione PHP ImageMagick è installata"
+#: mod/events.php:552
+msgid "Failed to remove event"
+msgstr "Rimozione evento fallita."
-#: mod/install.php:513
-msgid "ImageMagick supports GIF"
-msgstr "ImageMagick supporta i GIF"
+#: mod/events.php:554
+msgid "Event removed"
+msgstr "Evento rimosso"
-#: mod/install.php:520
-msgid ""
-"The database configuration file \".htconfig.php\" could not be written. "
-"Please use the enclosed text to create a configuration file in your web "
-"server root."
-msgstr "Il file di configurazione del database \".htconfig.php\" non può essere scritto. Usa il testo qui di seguito per creare un file di configurazione nella cartella principale del tuo sito."
+#: mod/fsuggest.php:66
+msgid "Friend suggestion sent."
+msgstr "Suggerimento di amicizia inviato."
-#: mod/install.php:545
-msgid "<h1>What next</h1>"
-msgstr "<h1>Cosa fare ora</h1>"
+#: mod/fsuggest.php:100
+msgid "Suggest Friends"
+msgstr "Suggerisci amici"
-#: mod/install.php:546
-msgid ""
-"IMPORTANT: You will need to [manually] setup a scheduled task for the "
-"poller."
-msgstr "IMPORTANTE: Devi impostare [manualmente] la pianificazione del poller."
+#: mod/fsuggest.php:102
+#, php-format
+msgid "Suggest a friend for %s"
+msgstr "Suggerisci un amico a %s"
-#: mod/item.php:116
+#: mod/item.php:120
msgid "Unable to locate original post."
msgstr "Impossibile trovare il messaggio originale."
-#: mod/item.php:344
+#: mod/item.php:347
msgid "Empty post discarded."
msgstr "Messaggio vuoto scartato."
-#: mod/item.php:904
+#: mod/item.php:931
msgid "System error. Post not saved."
msgstr "Errore di sistema. Messaggio non salvato."
-#: mod/item.php:995
+#: mod/item.php:1022
#, php-format
msgid ""
"This message was sent to you by %s, a member of the Friendica social "
"network."
msgstr "Questo messaggio ti è stato inviato da %s, un membro del social network Friendica."
-#: mod/item.php:997
+#: mod/item.php:1024
#, php-format
msgid "You may visit them online at %s"
msgstr "Puoi visitarli online su %s"
-#: mod/item.php:998
+#: mod/item.php:1025
msgid ""
"Please contact the sender by replying to this post if you do not wish to "
"receive these messages."
msgstr "Contatta il mittente rispondendo a questo post se non vuoi ricevere questi messaggi."
-#: mod/item.php:1002
+#: mod/item.php:1029
#, php-format
msgid "%s posted an update."
msgstr "%s ha inviato un aggiornamento."
-#: mod/notifications.php:35
-msgid "Invalid request identifier."
-msgstr "L'identificativo della richiesta non è valido."
+#: mod/mood.php:137
+msgid "Mood"
+msgstr "Umore"
-#: mod/notifications.php:44 mod/notifications.php:180
-#: mod/notifications.php:227
-msgid "Discard"
-msgstr "Scarta"
+#: mod/mood.php:138
+msgid "Set your current mood and tell your friends"
+msgstr "Condividi il tuo umore con i tuoi amici"
-#: mod/notifications.php:105
-msgid "Network Notifications"
-msgstr "Notifiche dalla rete"
+#: mod/network.php:563
+#, php-format
+msgid ""
+"Warning: This group contains %s member from a network that doesn't allow non"
+" public messages."
+msgid_plural ""
+"Warning: This group contains %s members from a network that doesn't allow "
+"non public messages."
+msgstr[0] "Attenzione: Questo gruppo contiene %s membro da una rete che non permette la ricezione di messaggi non pubblici."
+msgstr[1] "Attenzione: Questo gruppo contiene %s membri da reti che non permettono la ricezione di messaggi non pubblici."
-#: mod/notifications.php:117
-msgid "Personal Notifications"
-msgstr "Notifiche personali"
+#: mod/network.php:566
+msgid "Messages in this group won't be send to these receivers."
+msgstr "I messaggi in questo gruppo non saranno inviati ai quei contatti."
-#: mod/notifications.php:123
-msgid "Home Notifications"
-msgstr "Notifiche bacheca"
+#: mod/network.php:634
+msgid "No such group"
+msgstr "Nessun gruppo"
-#: mod/notifications.php:152
-msgid "Show Ignored Requests"
-msgstr "Mostra richieste ignorate"
+#: mod/network.php:659
+#, php-format
+msgid "Group: %s"
+msgstr "Gruppo: %s"
-#: mod/notifications.php:152
-msgid "Hide Ignored Requests"
-msgstr "Nascondi richieste ignorate"
+#: mod/network.php:686
+msgid "Private messages to this person are at risk of public disclosure."
+msgstr "I messaggi privati a questa persona potrebbero risultare visibili anche pubblicamente."
-#: mod/notifications.php:164 mod/notifications.php:234
-msgid "Notification type: "
-msgstr "Tipo di notifica: "
+#: mod/network.php:690
+msgid "Invalid contact."
+msgstr "Contatto non valido."
-#: mod/notifications.php:167
-#, php-format
-msgid "suggested by %s"
-msgstr "suggerito da %s"
+#: mod/network.php:895
+msgid "Commented Order"
+msgstr "Ordina per commento"
-#: mod/notifications.php:173 mod/notifications.php:252
-msgid "Post a new friend activity"
-msgstr "Invia una attività \"è ora amico con\""
+#: mod/network.php:898
+msgid "Sort by Comment Date"
+msgstr "Ordina per data commento"
-#: mod/notifications.php:173 mod/notifications.php:252
-msgid "if applicable"
-msgstr "se applicabile"
+#: mod/network.php:903
+msgid "Posted Order"
+msgstr "Ordina per invio"
-#: mod/notifications.php:176 mod/notifications.php:261 mod/admin.php:1506
-msgid "Approve"
-msgstr "Approva"
+#: mod/network.php:906
+msgid "Sort by Post Date"
+msgstr "Ordina per data messaggio"
-#: mod/notifications.php:195
-msgid "Claims to be known to you: "
-msgstr "Dice di conoscerti: "
+#: mod/network.php:917
+msgid "Posts that mention or involve you"
+msgstr "Messaggi che ti citano o coinvolgono"
-#: mod/notifications.php:196
-msgid "yes"
-msgstr "si"
+#: mod/network.php:925
+msgid "New"
+msgstr "Nuovo"
-#: mod/notifications.php:196
-msgid "no"
-msgstr "no"
+#: mod/network.php:928
+msgid "Activity Stream - by date"
+msgstr "Activity Stream - per data"
-#: mod/notifications.php:197 mod/notifications.php:202
-msgid "Shall your connection be bidirectional or not?"
-msgstr "La connessione dovrà essere bidirezionale o no?"
+#: mod/network.php:936
+msgid "Shared Links"
+msgstr "Links condivisi"
-#: mod/notifications.php:198 mod/notifications.php:203
-#, php-format
-msgid ""
-"Accepting %s as a friend allows %s to subscribe to your posts, and you will "
-"also receive updates from them in your news feed."
-msgstr "Accettando %s come amico permette a %s di seguire i tuoi post, e a te di riceverne gli aggiornamenti."
+#: mod/network.php:939
+msgid "Interesting Links"
+msgstr "Link Interessanti"
-#: mod/notifications.php:199
-#, php-format
-msgid ""
-"Accepting %s as a subscriber allows them to subscribe to your posts, but you"
-" will not receive updates from them in your news feed."
-msgstr "Accentrando %s come abbonato gli permette di abbonarsi ai tuoi messaggi, ma tu non riceverai aggiornamenti da lui."
+#: mod/network.php:947
+msgid "Starred"
+msgstr "Preferiti"
-#: mod/notifications.php:204
-#, php-format
-msgid ""
-"Accepting %s as a sharer allows them to subscribe to your posts, but you "
-"will not receive updates from them in your news feed."
-msgstr "Accentando %s come condivisore, gli permetti di abbonarsi ai tuoi messaggi, ma tu non riceverai nessun aggiornamento da loro."
+#: mod/network.php:950
+msgid "Favourite Posts"
+msgstr "Messaggi preferiti"
-#: mod/notifications.php:215
-msgid "Friend"
-msgstr "Amico"
+#: mod/ostatus_subscribe.php:17
+msgid "Subscribing to OStatus contacts"
+msgstr "Iscrizione a contatti OStatus"
-#: mod/notifications.php:216
-msgid "Sharer"
-msgstr "Condivisore"
+#: mod/ostatus_subscribe.php:28
+msgid "No contact provided."
+msgstr "Nessun contatto disponibile."
-#: mod/notifications.php:216
-msgid "Subscriber"
-msgstr "Abbonato"
+#: mod/ostatus_subscribe.php:34
+msgid "Couldn't fetch information for contact."
+msgstr "Non è stato possibile recuperare le informazioni del contatto."
-#: mod/notifications.php:272
-msgid "No introductions."
-msgstr "Nessuna presentazione."
+#: mod/ostatus_subscribe.php:43
+msgid "Couldn't fetch friends for contact."
+msgstr "Non è stato possibile recuperare gli amici del contatto."
-#: mod/notifications.php:313
-msgid "Show unread"
-msgstr "Mostra non letti"
+#: mod/ostatus_subscribe.php:71
+msgid "success"
+msgstr "successo"
-#: mod/notifications.php:313
-msgid "Show all"
-msgstr "Mostra tutti"
+#: mod/ostatus_subscribe.php:73
+msgid "failed"
+msgstr "fallito"
-#: mod/notifications.php:319
-#, php-format
-msgid "No more %s notifications."
-msgstr "Nessun'altra notifica %s."
+#: mod/ostatus_subscribe.php:76 object/Item.php:262
+msgid "ignored"
+msgstr "ignorato"
-#: mod/ping.php:270
-msgid "{0} wants to be your friend"
-msgstr "{0} vuole essere tuo amico"
+#: mod/photos.php:98 mod/photos.php:1877
+msgid "Recent Photos"
+msgstr "Foto recenti"
-#: mod/ping.php:285
-msgid "{0} sent you a message"
-msgstr "{0} ti ha inviato un messaggio"
+#: mod/photos.php:101 mod/photos.php:1305 mod/photos.php:1879
+msgid "Upload New Photos"
+msgstr "Carica nuove foto"
-#: mod/ping.php:300
-msgid "{0} requested registration"
-msgstr "{0} chiede la registrazione"
+#: mod/photos.php:116 mod/settings.php:36
+msgid "everybody"
+msgstr "tutti"
-#: mod/admin.php:96
-msgid "Theme settings updated."
-msgstr "Impostazioni del tema aggiornate."
+#: mod/photos.php:180
+msgid "Contact information unavailable"
+msgstr "I dati di questo contatto non sono disponibili"
-#: mod/admin.php:165 mod/admin.php:1054
-msgid "Site"
-msgstr "Sito"
+#: mod/photos.php:201
+msgid "Album not found."
+msgstr "Album non trovato."
-#: mod/admin.php:166 mod/admin.php:988 mod/admin.php:1498 mod/admin.php:1514
-msgid "Users"
-msgstr "Utenti"
+#: mod/photos.php:234 mod/photos.php:246 mod/photos.php:1249
+msgid "Delete Album"
+msgstr "Rimuovi album"
-#: mod/admin.php:168 mod/admin.php:1892 mod/admin.php:1942
-msgid "Themes"
-msgstr "Temi"
+#: mod/photos.php:244
+msgid "Do you really want to delete this photo album and all its photos?"
+msgstr "Vuoi davvero cancellare questo album e tutte le sue foto?"
-#: mod/admin.php:170
-msgid "DB updates"
-msgstr "Aggiornamenti Database"
+#: mod/photos.php:327 mod/photos.php:338 mod/photos.php:1575
+msgid "Delete Photo"
+msgstr "Rimuovi foto"
-#: mod/admin.php:171 mod/admin.php:512
-msgid "Inspect Queue"
-msgstr "Ispeziona Coda di invio"
+#: mod/photos.php:336
+msgid "Do you really want to delete this photo?"
+msgstr "Vuoi veramente cancellare questa foto?"
-#: mod/admin.php:172 mod/admin.php:288
-msgid "Server Blocklist"
-msgstr "Server Blocklist"
+#: mod/photos.php:717
+#, php-format
+msgid "%1$s was tagged in %2$s by %3$s"
+msgstr "%1$s è stato taggato in %2$s da %3$s"
-#: mod/admin.php:173 mod/admin.php:478
-msgid "Federation Statistics"
-msgstr "Statistiche sulla Federazione"
+#: mod/photos.php:717
+msgid "a photo"
+msgstr "una foto"
-#: mod/admin.php:187 mod/admin.php:198 mod/admin.php:2016
-msgid "Logs"
-msgstr "Log"
+#: mod/photos.php:817 mod/profile_photo.php:157 mod/wall_upload.php:182
+#, php-format
+msgid "Image exceeds size limit of %s"
+msgstr "La dimensione dell'immagine supera il limite di %s"
-#: mod/admin.php:188 mod/admin.php:2084
-msgid "View Logs"
-msgstr "Vedi i log"
+#: mod/photos.php:825
+msgid "Image file is empty."
+msgstr "Il file dell'immagine è vuoto."
-#: mod/admin.php:189
-msgid "probe address"
-msgstr "controlla indirizzo"
+#: mod/photos.php:840 mod/profile_photo.php:166 mod/wall_upload.php:196
+msgid "Unable to process image."
+msgstr "Impossibile caricare l'immagine."
-#: mod/admin.php:190
-msgid "check webfinger"
-msgstr "verifica webfinger"
+#: mod/photos.php:869 mod/profile_photo.php:316 mod/wall_upload.php:235
+msgid "Image upload failed."
+msgstr "Caricamento immagine fallito."
-#: mod/admin.php:197
-msgid "Plugin Features"
-msgstr "Impostazioni Plugins"
+#: mod/photos.php:974
+msgid "No photos selected"
+msgstr "Nessuna foto selezionata"
-#: mod/admin.php:199
-msgid "diagnostics"
-msgstr "diagnostiche"
+#: mod/photos.php:1077 mod/videos.php:313
+msgid "Access to this item is restricted."
+msgstr "Questo oggetto non è visibile a tutti."
-#: mod/admin.php:200
-msgid "User registrations waiting for confirmation"
-msgstr "Utenti registrati in attesa di conferma"
+#: mod/photos.php:1165
+msgid "Upload Photos"
+msgstr "Carica foto"
-#: mod/admin.php:279
-msgid "The blocked domain"
-msgstr "Il dominio bloccato"
+#: mod/photos.php:1169 mod/photos.php:1244
+msgid "New album name: "
+msgstr "Nome nuovo album: "
-#: mod/admin.php:280 mod/admin.php:293
-msgid "The reason why you blocked this domain."
-msgstr "Le ragioni per cui blocchi questo dominio."
+#: mod/photos.php:1170
+msgid "or existing album name: "
+msgstr "o nome di un album esistente: "
-#: mod/admin.php:281
-msgid "Delete domain"
-msgstr "Elimina dominio"
+#: mod/photos.php:1171
+msgid "Do not show a status post for this upload"
+msgstr "Non creare un post per questo upload"
-#: mod/admin.php:281
-msgid "Check to delete this entry from the blocklist"
-msgstr "Seleziona per eliminare questa voce dalla blocklist"
+#: mod/photos.php:1182 mod/photos.php:1579 mod/settings.php:1294
+msgid "Show to Groups"
+msgstr "Mostra ai gruppi"
-#: mod/admin.php:287 mod/admin.php:477 mod/admin.php:511 mod/admin.php:586
-#: mod/admin.php:1053 mod/admin.php:1497 mod/admin.php:1615 mod/admin.php:1678
-#: mod/admin.php:1891 mod/admin.php:1941 mod/admin.php:2015 mod/admin.php:2083
-msgid "Administration"
-msgstr "Amministrazione"
+#: mod/photos.php:1183 mod/photos.php:1580 mod/settings.php:1295
+msgid "Show to Contacts"
+msgstr "Mostra ai contatti"
-#: mod/admin.php:289
-msgid ""
-"This page can be used to define a black list of servers from the federated "
-"network that are not allowed to interact with your node. For all entered "
-"domains you should also give a reason why you have blocked the remote "
-"server."
-msgstr "Questa pagina puo' essere usata per definire una black list di server dal network federato a cui nono è permesso interagire col tuo nodo. Per ogni dominio inserito, dovresti anche riportare una ragione per cui hai bloccato il server remoto."
+#: mod/photos.php:1184
+msgid "Private Photo"
+msgstr "Foto privata"
-#: mod/admin.php:290
-msgid ""
-"The list of blocked servers will be made publically available on the "
-"/friendica page so that your users and people investigating communication "
-"problems can find the reason easily."
-msgstr "La lista di server bloccati sarà resa disponibile pubblicamente sulla pagina /friendica, così che i tuoi utenti e le persone che indagano su problemi di comunicazione possano trovarne la ragione facilmente."
+#: mod/photos.php:1185
+msgid "Public Photo"
+msgstr "Foto pubblica"
-#: mod/admin.php:291
-msgid "Add new entry to block list"
-msgstr "Aggiungi una nuova voce alla blocklist"
+#: mod/photos.php:1255
+msgid "Edit Album"
+msgstr "Modifica album"
-#: mod/admin.php:292
-msgid "Server Domain"
-msgstr "Dominio del Server"
+#: mod/photos.php:1260
+msgid "Show Newest First"
+msgstr "Mostra nuove foto per prime"
-#: mod/admin.php:292
-msgid ""
-"The domain of the new server to add to the block list. Do not include the "
-"protocol."
-msgstr "Il dominio del server da aggiungere alla blocklist. Non includere il protocollo."
+#: mod/photos.php:1262
+msgid "Show Oldest First"
+msgstr "Mostra vecchie foto per prime"
-#: mod/admin.php:293
-msgid "Block reason"
-msgstr "Ragione blocco"
+#: mod/photos.php:1291 mod/photos.php:1862
+msgid "View Photo"
+msgstr "Vedi foto"
-#: mod/admin.php:294
-msgid "Add Entry"
-msgstr "Aggiungi Voce"
+#: mod/photos.php:1336
+msgid "Permission denied. Access to this item may be restricted."
+msgstr "Permesso negato. L'accesso a questo elemento può essere limitato."
-#: mod/admin.php:295
-msgid "Save changes to the blocklist"
-msgstr "Salva modifiche alla blocklist"
+#: mod/photos.php:1338
+msgid "Photo not available"
+msgstr "Foto non disponibile"
-#: mod/admin.php:296
-msgid "Current Entries in the Blocklist"
-msgstr "Voci correnti nella blocklist"
+#: mod/photos.php:1399
+msgid "View photo"
+msgstr "Vedi foto"
-#: mod/admin.php:299
-msgid "Delete entry from blocklist"
-msgstr "Elimina voce dalla blocklist"
+#: mod/photos.php:1399
+msgid "Edit photo"
+msgstr "Modifica foto"
-#: mod/admin.php:302
-msgid "Delete entry from blocklist?"
-msgstr "Eliminare la voce dalla blocklist?"
+#: mod/photos.php:1400
+msgid "Use as profile photo"
+msgstr "Usa come foto del profilo"
-#: mod/admin.php:327
-msgid "Server added to blocklist."
-msgstr "Server aggiunto alla blocklist."
+#: mod/photos.php:1406 object/Item.php:127
+msgid "Private Message"
+msgstr "Messaggio privato"
-#: mod/admin.php:343
-msgid "Site blocklist updated."
-msgstr "Blocklist del sito aggiornata."
+#: mod/photos.php:1425
+msgid "View Full Size"
+msgstr "Vedi dimensione intera"
-#: mod/admin.php:408
-msgid "unknown"
-msgstr "sconosciuto"
+#: mod/photos.php:1515
+msgid "Tags: "
+msgstr "Tag: "
-#: mod/admin.php:471
-msgid ""
-"This page offers you some numbers to the known part of the federated social "
-"network your Friendica node is part of. These numbers are not complete but "
-"only reflect the part of the network your node is aware of."
-msgstr "Questa pagina offre alcuni numeri riguardo la porzione del social network federato di cui il tuo nodo Friendica fa parte. Questi numeri non sono completi ma riflettono esclusivamente la porzione di rete di cui il tuo nodo e' a conoscenza."
-
-#: mod/admin.php:472
-msgid ""
-"The <em>Auto Discovered Contact Directory</em> feature is not enabled, it "
-"will improve the data displayed here."
-msgstr "La funzione <em>Elenco Contatti Scoperto Automaticamente</em> non è abilitata, migliorerà i dati visualizzati qui."
+#: mod/photos.php:1518
+msgid "[Remove any tag]"
+msgstr "[Rimuovi tutti i tag]"
-#: mod/admin.php:484
-#, php-format
-msgid "Currently this node is aware of %d nodes from the following platforms:"
-msgstr "Attualmente questo nodo conosce %d nodi dalle seguenti piattaforme:"
+#: mod/photos.php:1561
+msgid "New album name"
+msgstr "Nuovo nome dell'album"
-#: mod/admin.php:514
-msgid "ID"
-msgstr "ID"
+#: mod/photos.php:1562
+msgid "Caption"
+msgstr "Titolo"
-#: mod/admin.php:515
-msgid "Recipient Name"
-msgstr "Nome Destinatario"
+#: mod/photos.php:1563
+msgid "Add a Tag"
+msgstr "Aggiungi tag"
-#: mod/admin.php:516
-msgid "Recipient Profile"
-msgstr "Profilo Destinatario"
+#: mod/photos.php:1563
+msgid ""
+"Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"
+msgstr "Esempio: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"
-#: mod/admin.php:518
-msgid "Created"
-msgstr "Creato"
+#: mod/photos.php:1564
+msgid "Do not rotate"
+msgstr "Non ruotare"
-#: mod/admin.php:519
-msgid "Last Tried"
-msgstr "Ultimo Tentativo"
+#: mod/photos.php:1565
+msgid "Rotate CW (right)"
+msgstr "Ruota a destra"
-#: mod/admin.php:520
-msgid ""
-"This page lists the content of the queue for outgoing postings. These are "
-"postings the initial delivery failed for. They will be resend later and "
-"eventually deleted if the delivery fails permanently."
-msgstr "Questa pagina elenca il contenuto della coda di invio dei post. Questi sono post la cui consegna è fallita. Verranno inviati nuovamente più tardi ed eventualmente cancellati se la consegna continua a fallire."
+#: mod/photos.php:1566
+msgid "Rotate CCW (left)"
+msgstr "Ruota a sinistra"
-#: mod/admin.php:545
-#, php-format
-msgid ""
-"Your DB still runs with MyISAM tables. You should change the engine type to "
-"InnoDB. As Friendica will use InnoDB only features in the future, you should"
-" change this! See <a href=\"%s\">here</a> for a guide that may be helpful "
-"converting the table engines. You may also use the command <tt>php "
-"include/dbstructure.php toinnodb</tt> of your Friendica installation for an "
-"automatic conversion.<br />"
-msgstr "Il tuo database contiene ancora tabelle MyISAM. Dovresti cambiare il motore a InnoDB. Siccome Friendica userà esclusivamente InnoDB nelle versioni a venire, dovresti cambiarle! Vedi <a href=\"%s\">qui</a> per una guida che puo' essere d'aiuto nel convertire il motore delle tabelle. Puoi anche usare il comando <tt>php include/dbstructure.php toinnodb</tt> nella tua installazione Friendica per eseguire la conversione automaticamente.<br />"
+#: mod/photos.php:1581
+msgid "Private photo"
+msgstr "Foto privata"
-#: mod/admin.php:550
-msgid ""
-"You are using a MySQL version which does not support all features that "
-"Friendica uses. You should consider switching to MariaDB."
-msgstr "Stai usando una versione di MySQL che non supporta tutte le funzionalità che Friendica usa. Dovresti considerare di utilizzare MariaDB."
+#: mod/photos.php:1582
+msgid "Public photo"
+msgstr "Foto pubblica"
-#: mod/admin.php:554 mod/admin.php:1447
-msgid "Normal Account"
-msgstr "Account normale"
+#: mod/photos.php:1602 object/Item.php:280
+msgid "I like this (toggle)"
+msgstr "Mi piace (clic per cambiare)"
-#: mod/admin.php:555 mod/admin.php:1448
-msgid "Soapbox Account"
-msgstr "Account per comunicati e annunci"
+#: mod/photos.php:1603 object/Item.php:281
+msgid "I don't like this (toggle)"
+msgstr "Non mi piace (clic per cambiare)"
-#: mod/admin.php:556 mod/admin.php:1449
-msgid "Community/Celebrity Account"
-msgstr "Account per celebrità o per comunità"
+#: mod/photos.php:1620 mod/photos.php:1662 mod/photos.php:1742
+#: object/Item.php:699
+msgid "This is you"
+msgstr "Questo sei tu"
-#: mod/admin.php:557 mod/admin.php:1450
-msgid "Automatic Friend Account"
-msgstr "Account per amicizia automatizzato"
+#: mod/photos.php:1622 mod/photos.php:1664 mod/photos.php:1744
+#: object/Item.php:386 object/Item.php:701
+msgid "Comment"
+msgstr "Commento"
-#: mod/admin.php:558
-msgid "Blog Account"
-msgstr "Account Blog"
+#: mod/photos.php:1791
+msgid "Map"
+msgstr "Mappa"
-#: mod/admin.php:559
-msgid "Private Forum"
-msgstr "Forum Privato"
+#: mod/photos.php:1868 mod/videos.php:397
+msgid "View Album"
+msgstr "Sfoglia l'album"
-#: mod/admin.php:581
-msgid "Message queues"
-msgstr "Code messaggi"
+#: mod/ping.php:276
+msgid "{0} wants to be your friend"
+msgstr "{0} vuole essere tuo amico"
-#: mod/admin.php:587
-msgid "Summary"
-msgstr "Sommario"
+#: mod/ping.php:291
+msgid "{0} sent you a message"
+msgstr "{0} ti ha inviato un messaggio"
-#: mod/admin.php:589
-msgid "Registered users"
-msgstr "Utenti registrati"
+#: mod/ping.php:306
+msgid "{0} requested registration"
+msgstr "{0} chiede la registrazione"
-#: mod/admin.php:591
-msgid "Pending registrations"
-msgstr "Registrazioni in attesa"
+#: mod/poke.php:199
+msgid "Poke/Prod"
+msgstr "Tocca/Pungola"
-#: mod/admin.php:592
-msgid "Version"
-msgstr "Versione"
+#: mod/poke.php:200
+msgid "poke, prod or do other things to somebody"
+msgstr "tocca, pungola o fai altre cose a qualcuno"
-#: mod/admin.php:597
-msgid "Active plugins"
-msgstr "Plugin attivi"
+#: mod/poke.php:201
+msgid "Recipient"
+msgstr "Destinatario"
-#: mod/admin.php:622
-msgid "Can not parse base url. Must have at least <scheme>://<domain>"
-msgstr "Impossibile analizzare l'url base. Deve avere almeno [schema]://[dominio]"
+#: mod/poke.php:202
+msgid "Choose what you wish to do to recipient"
+msgstr "Scegli cosa vuoi fare al destinatario"
-#: mod/admin.php:914
-msgid "Site settings updated."
-msgstr "Impostazioni del sito aggiornate."
+#: mod/poke.php:205
+msgid "Make this post private"
+msgstr "Rendi questo post privato"
-#: mod/admin.php:971
-msgid "No community page"
-msgstr "Nessuna pagina Comunità"
+#: mod/profile_photo.php:46
+msgid "Image uploaded but image cropping failed."
+msgstr "L'immagine è stata caricata, ma il non è stato possibile ritagliarla."
-#: mod/admin.php:972
-msgid "Public postings from users of this site"
-msgstr "Messaggi pubblici dagli utenti di questo sito"
+#: mod/profile_photo.php:79 mod/profile_photo.php:87 mod/profile_photo.php:95
+#: mod/profile_photo.php:324
+#, php-format
+msgid "Image size reduction [%s] failed."
+msgstr "Il ridimensionamento dell'immagine [%s] è fallito."
-#: mod/admin.php:973
-msgid "Global community page"
-msgstr "Pagina Comunità globale"
+#: mod/profile_photo.php:129
+msgid ""
+"Shift-reload the page or clear browser cache if the new photo does not "
+"display immediately."
+msgstr "Ricarica la pagina con shift+F5 o cancella la cache del browser se la nuova foto non viene mostrata immediatamente."
-#: mod/admin.php:979
-msgid "At post arrival"
-msgstr "All'arrivo di un messaggio"
+#: mod/profile_photo.php:138
+msgid "Unable to process image"
+msgstr "Impossibile elaborare l'immagine"
-#: mod/admin.php:989
-msgid "Users, Global Contacts"
-msgstr "Utenti, Contatti Globali"
+#: mod/profile_photo.php:255
+msgid "Upload File:"
+msgstr "Carica un file:"
-#: mod/admin.php:990
-msgid "Users, Global Contacts/fallback"
-msgstr "Utenti, Contatti Globali/fallback"
+#: mod/profile_photo.php:256
+msgid "Select a profile:"
+msgstr "Seleziona un profilo:"
-#: mod/admin.php:994
-msgid "One month"
-msgstr "Un mese"
+#: mod/profile_photo.php:258
+msgid "Upload"
+msgstr "Carica"
-#: mod/admin.php:995
-msgid "Three months"
-msgstr "Tre mesi"
+#: mod/profile_photo.php:261
+msgid "or"
+msgstr "o"
-#: mod/admin.php:996
-msgid "Half a year"
-msgstr "Sei mesi"
+#: mod/profile_photo.php:261
+msgid "skip this step"
+msgstr "salta questo passaggio"
-#: mod/admin.php:997
-msgid "One year"
-msgstr "Un anno"
+#: mod/profile_photo.php:261
+msgid "select a photo from your photo albums"
+msgstr "seleziona una foto dai tuoi album"
-#: mod/admin.php:1002
-msgid "Multi user instance"
-msgstr "Istanza multi utente"
+#: mod/profile_photo.php:275
+msgid "Crop Image"
+msgstr "Ritaglia immagine"
-#: mod/admin.php:1025
-msgid "Closed"
-msgstr "Chiusa"
+#: mod/profile_photo.php:276
+msgid "Please adjust the image cropping for optimum viewing."
+msgstr "Ritaglia l'immagine per una visualizzazione migliore."
-#: mod/admin.php:1026
-msgid "Requires approval"
-msgstr "Richiede l'approvazione"
+#: mod/profile_photo.php:278
+msgid "Done Editing"
+msgstr "Finito"
-#: mod/admin.php:1027
-msgid "Open"
-msgstr "Aperta"
+#: mod/profile_photo.php:314
+msgid "Image uploaded successfully."
+msgstr "Immagine caricata con successo."
-#: mod/admin.php:1031
-msgid "No SSL policy, links will track page SSL state"
-msgstr "Nessuna gestione SSL, i link seguiranno lo stato SSL della pagina"
+#: mod/profiles.php:44
+msgid "Profile deleted."
+msgstr "Profilo eliminato."
-#: mod/admin.php:1032
-msgid "Force all links to use SSL"
-msgstr "Forza tutti i link ad usare SSL"
+#: mod/profiles.php:60 mod/profiles.php:96
+msgid "Profile-"
+msgstr "Profilo-"
-#: mod/admin.php:1033
-msgid "Self-signed certificate, use SSL for local links only (discouraged)"
-msgstr "Certificato auto-firmato, usa SSL solo per i link locali (sconsigliato)"
+#: mod/profiles.php:79 mod/profiles.php:118
+msgid "New profile created."
+msgstr "Il nuovo profilo è stato creato."
-#: mod/admin.php:1057
-msgid "File upload"
-msgstr "Caricamento file"
+#: mod/profiles.php:102
+msgid "Profile unavailable to clone."
+msgstr "Impossibile duplicare il profilo."
-#: mod/admin.php:1058
-msgid "Policies"
-msgstr "Politiche"
+#: mod/profiles.php:192
+msgid "Profile Name is required."
+msgstr "Il nome profilo è obbligatorio ."
-#: mod/admin.php:1060
-msgid "Auto Discovered Contact Directory"
-msgstr "Elenco Contatti Scoperto Automaticamente"
+#: mod/profiles.php:332
+msgid "Marital Status"
+msgstr "Stato civile"
-#: mod/admin.php:1061
-msgid "Performance"
-msgstr "Performance"
+#: mod/profiles.php:336
+msgid "Romantic Partner"
+msgstr "Partner romantico"
-#: mod/admin.php:1062
-msgid "Worker"
-msgstr "Worker"
+#: mod/profiles.php:348
+msgid "Work/Employment"
+msgstr "Lavoro/Impiego"
-#: mod/admin.php:1063
-msgid ""
-"Relocate - WARNING: advanced function. Could make this server unreachable."
-msgstr "Trasloca - ATTENZIONE: funzione avanzata! Può rendere questo server irraggiungibile."
+#: mod/profiles.php:351
+msgid "Religion"
+msgstr "Religione"
-#: mod/admin.php:1066
-msgid "Site name"
-msgstr "Nome del sito"
+#: mod/profiles.php:355
+msgid "Political Views"
+msgstr "Orientamento Politico"
-#: mod/admin.php:1067
-msgid "Host name"
-msgstr "Nome host"
+#: mod/profiles.php:359
+msgid "Gender"
+msgstr "Sesso"
-#: mod/admin.php:1068
-msgid "Sender Email"
-msgstr "Mittente email"
+#: mod/profiles.php:363
+msgid "Sexual Preference"
+msgstr "Preferenza sessuale"
-#: mod/admin.php:1068
-msgid ""
-"The email address your server shall use to send notification emails from."
-msgstr "L'indirizzo email che il tuo server dovrà usare per inviare notifiche via email."
+#: mod/profiles.php:367
+msgid "XMPP"
+msgstr "XMPP"
-#: mod/admin.php:1069
-msgid "Banner/Logo"
-msgstr "Banner/Logo"
+#: mod/profiles.php:371
+msgid "Homepage"
+msgstr "Homepage"
-#: mod/admin.php:1070
-msgid "Shortcut icon"
-msgstr "Icona shortcut"
+#: mod/profiles.php:375 mod/profiles.php:694
+msgid "Interests"
+msgstr "Interessi"
-#: mod/admin.php:1070
-msgid "Link to an icon that will be used for browsers."
-msgstr "Link verso un'icona che verrà usata dai browser."
+#: mod/profiles.php:379
+msgid "Address"
+msgstr "Indirizzo"
-#: mod/admin.php:1071
-msgid "Touch icon"
-msgstr "Icona touch"
+#: mod/profiles.php:386 mod/profiles.php:690
+msgid "Location"
+msgstr "Posizione"
-#: mod/admin.php:1071
-msgid "Link to an icon that will be used for tablets and mobiles."
-msgstr "Link verso un'icona che verrà usata dai tablet e i telefonini."
+#: mod/profiles.php:471
+msgid "Profile updated."
+msgstr "Profilo aggiornato."
-#: mod/admin.php:1072
-msgid "Additional Info"
-msgstr "Informazioni aggiuntive"
+#: mod/profiles.php:563
+msgid " and "
+msgstr "e "
+
+#: mod/profiles.php:572
+msgid "public profile"
+msgstr "profilo pubblico"
-#: mod/admin.php:1072
+#: mod/profiles.php:575
#, php-format
-msgid ""
-"For public servers: you can add additional information here that will be "
-"listed at %s/siteinfo."
-msgstr "Per server pubblici: puoi aggiungere informazioni extra che verrano mostrate su %s/siteinfo."
+msgid "%1$s changed %2$s to “%3$s”"
+msgstr "%1$s ha cambiato %2$s in “%3$s”"
-#: mod/admin.php:1073
-msgid "System language"
-msgstr "Lingua di sistema"
+#: mod/profiles.php:576
+#, php-format
+msgid " - Visit %1$s's %2$s"
+msgstr "- Visita %2$s di %1$s"
-#: mod/admin.php:1074
-msgid "System theme"
-msgstr "Tema di sistema"
+#: mod/profiles.php:578
+#, php-format
+msgid "%1$s has an updated %2$s, changing %3$s."
+msgstr "%1$s ha un %2$s aggiornato. Ha cambiato %3$s"
-#: mod/admin.php:1074
-msgid ""
-"Default system theme - may be over-ridden by user profiles - <a href='#' "
-"id='cnftheme'>change theme settings</a>"
-msgstr "Tema di sistema - può essere sovrascritto dalle impostazioni utente - <a href='#' id='cnftheme'>cambia le impostazioni del tema</a>"
+#: mod/profiles.php:636
+msgid "Hide contacts and friends:"
+msgstr "Nascondi contatti:"
-#: mod/admin.php:1075
-msgid "Mobile system theme"
-msgstr "Tema mobile di sistema"
+#: mod/profiles.php:641
+msgid "Hide your contact/friend list from viewers of this profile?"
+msgstr "Nascondi la tua lista di contatti/amici ai visitatori di questo profilo?"
-#: mod/admin.php:1075
-msgid "Theme for mobile devices"
-msgstr "Tema per dispositivi mobili"
+#: mod/profiles.php:666
+msgid "Show more profile fields:"
+msgstr "Mostra più informazioni di profilo:"
-#: mod/admin.php:1076
-msgid "SSL link policy"
-msgstr "Gestione link SSL"
+#: mod/profiles.php:678
+msgid "Profile Actions"
+msgstr "Azioni Profilo"
-#: mod/admin.php:1076
-msgid "Determines whether generated links should be forced to use SSL"
-msgstr "Determina se i link generati devono essere forzati a usare SSL"
+#: mod/profiles.php:679
+msgid "Edit Profile Details"
+msgstr "Modifica i dettagli del profilo"
-#: mod/admin.php:1077
-msgid "Force SSL"
-msgstr "Forza SSL"
+#: mod/profiles.php:681
+msgid "Change Profile Photo"
+msgstr "Cambia la foto del profilo"
-#: mod/admin.php:1077
-msgid ""
-"Force all Non-SSL requests to SSL - Attention: on some systems it could lead"
-" to endless loops."
-msgstr "Forza tutte le richieste non SSL su SSL - Attenzione: su alcuni sistemi può portare a loop senza fine"
+#: mod/profiles.php:682
+msgid "View this profile"
+msgstr "Visualizza questo profilo"
-#: mod/admin.php:1078
-msgid "Hide help entry from navigation menu"
-msgstr "Nascondi la voce 'Guida' dal menu di navigazione"
+#: mod/profiles.php:684
+msgid "Create a new profile using these settings"
+msgstr "Crea un nuovo profilo usando queste impostazioni"
-#: mod/admin.php:1078
-msgid ""
-"Hides the menu entry for the Help pages from the navigation menu. You can "
-"still access it calling /help directly."
-msgstr "Nasconde la voce per le pagine della guida dal menu di navigazione. E' comunque possibile accedervi richiamando /help direttamente."
+#: mod/profiles.php:685
+msgid "Clone this profile"
+msgstr "Clona questo profilo"
-#: mod/admin.php:1079
-msgid "Single user instance"
-msgstr "Istanza a singolo utente"
+#: mod/profiles.php:686
+msgid "Delete this profile"
+msgstr "Elimina questo profilo"
-#: mod/admin.php:1079
-msgid "Make this instance multi-user or single-user for the named user"
-msgstr "Rendi questa istanza multi utente o a singolo utente per l'utente selezionato"
+#: mod/profiles.php:688
+msgid "Basic information"
+msgstr "Informazioni di base"
-#: mod/admin.php:1080
-msgid "Maximum image size"
-msgstr "Massima dimensione immagini"
+#: mod/profiles.php:689
+msgid "Profile picture"
+msgstr "Immagine del profilo"
-#: mod/admin.php:1080
-msgid ""
-"Maximum size in bytes of uploaded images. Default is 0, which means no "
-"limits."
-msgstr "Massima dimensione in byte delle immagini caricate. Il default è 0, cioè nessun limite."
+#: mod/profiles.php:691
+msgid "Preferences"
+msgstr "Preferenze"
-#: mod/admin.php:1081
-msgid "Maximum image length"
-msgstr "Massima lunghezza immagine"
+#: mod/profiles.php:692
+msgid "Status information"
+msgstr "Informazioni stato"
-#: mod/admin.php:1081
-msgid ""
-"Maximum length in pixels of the longest side of uploaded images. Default is "
-"-1, which means no limits."
-msgstr "Massima lunghezza in pixel del lato più lungo delle immagini caricate. Predefinito a -1, ovvero nessun limite."
+#: mod/profiles.php:693
+msgid "Additional information"
+msgstr "Informazioni aggiuntive"
-#: mod/admin.php:1082
-msgid "JPEG image quality"
-msgstr "Qualità immagini JPEG"
+#: mod/profiles.php:696
+msgid "Relation"
+msgstr "Relazione"
-#: mod/admin.php:1082
-msgid ""
-"Uploaded JPEGS will be saved at this quality setting [0-100]. Default is "
-"100, which is full quality."
-msgstr "Le immagini JPEG caricate verranno salvate con questa qualità [0-100]. Predefinito è 100, ovvero qualità piena."
+#: mod/profiles.php:700
+msgid "Your Gender:"
+msgstr "Il tuo sesso:"
-#: mod/admin.php:1084
-msgid "Register policy"
-msgstr "Politica di registrazione"
+#: mod/profiles.php:701
+msgid "<span class=\"heart\">♥</span> Marital Status:"
+msgstr "<span class=\"heart\">♥</span> Stato sentimentale:"
-#: mod/admin.php:1085
-msgid "Maximum Daily Registrations"
-msgstr "Massime registrazioni giornaliere"
+#: mod/profiles.php:703
+msgid "Example: fishing photography software"
+msgstr "Esempio: pesca fotografia programmazione"
-#: mod/admin.php:1085
-msgid ""
-"If registration is permitted above, this sets the maximum number of new user"
-" registrations to accept per day. If register is set to closed, this "
-"setting has no effect."
-msgstr "Se la registrazione è permessa, qui si definisce il massimo numero di nuovi utenti registrati da accettare giornalmente. Se la registrazione è chiusa, questa impostazione non ha effetto."
+#: mod/profiles.php:708
+msgid "Profile Name:"
+msgstr "Nome del profilo:"
-#: mod/admin.php:1086
-msgid "Register text"
-msgstr "Testo registrazione"
+#: mod/profiles.php:710
+msgid ""
+"This is your <strong>public</strong> profile.<br />It <strong>may</strong> "
+"be visible to anybody using the internet."
+msgstr "Questo è il tuo profilo <strong>publico</strong>.<br /><strong>Potrebbe</strong> essere visto da chiunque attraverso internet."
-#: mod/admin.php:1086
-msgid "Will be displayed prominently on the registration page."
-msgstr "Sarà mostrato ben visibile nella pagina di registrazione."
+#: mod/profiles.php:711
+msgid "Your Full Name:"
+msgstr "Il tuo nome completo:"
-#: mod/admin.php:1087
-msgid "Accounts abandoned after x days"
-msgstr "Account abbandonati dopo x giorni"
+#: mod/profiles.php:712
+msgid "Title/Description:"
+msgstr "Breve descrizione (es. titolo, posizione, altro):"
-#: mod/admin.php:1087
-msgid ""
-"Will not waste system resources polling external sites for abandonded "
-"accounts. Enter 0 for no time limit."
-msgstr "Non spreca risorse di sistema controllando siti esterni per gli account abbandonati. Immettere 0 per nessun limite di tempo."
+#: mod/profiles.php:715
+msgid "Street Address:"
+msgstr "Indirizzo (via/piazza):"
-#: mod/admin.php:1088
-msgid "Allowed friend domains"
-msgstr "Domini amici consentiti"
+#: mod/profiles.php:716
+msgid "Locality/City:"
+msgstr "Località:"
-#: mod/admin.php:1088
-msgid ""
-"Comma separated list of domains which are allowed to establish friendships "
-"with this site. Wildcards are accepted. Empty to allow any domains"
-msgstr "Elenco separato da virgola dei domini che possono stabilire amicizie con questo sito. Sono accettati caratteri jolly. Vuoto per accettare qualsiasi dominio."
+#: mod/profiles.php:717
+msgid "Region/State:"
+msgstr "Regione/Stato:"
-#: mod/admin.php:1089
-msgid "Allowed email domains"
-msgstr "Domini email consentiti"
+#: mod/profiles.php:718
+msgid "Postal/Zip Code:"
+msgstr "CAP:"
-#: mod/admin.php:1089
-msgid ""
-"Comma separated list of domains which are allowed in email addresses for "
-"registrations to this site. Wildcards are accepted. Empty to allow any "
-"domains"
-msgstr "Elenco separato da virgola dei domini permessi come indirizzi email in fase di registrazione a questo sito. Sono accettati caratteri jolly. Lascalo vuoto per accettare qualsiasi dominio."
+#: mod/profiles.php:719
+msgid "Country:"
+msgstr "Nazione:"
-#: mod/admin.php:1090
-msgid "Block public"
-msgstr "Blocca pagine pubbliche"
+#: mod/profiles.php:723
+msgid "Who: (if applicable)"
+msgstr "Con chi: (se possibile)"
-#: mod/admin.php:1090
-msgid ""
-"Check to block public access to all otherwise public personal pages on this "
-"site unless you are currently logged in."
-msgstr "Seleziona per bloccare l'accesso pubblico a tutte le pagine personali di questo sito, a meno di essere loggato."
+#: mod/profiles.php:723
+msgid "Examples: cathy123, Cathy Williams, cathy@example.com"
+msgstr "Esempio: cathy123, Cathy Williams, cathy@example.com"
-#: mod/admin.php:1091
-msgid "Force publish"
-msgstr "Forza pubblicazione"
+#: mod/profiles.php:724
+msgid "Since [date]:"
+msgstr "Dal [data]:"
-#: mod/admin.php:1091
-msgid ""
-"Check to force all profiles on this site to be listed in the site directory."
-msgstr "Seleziona per forzare tutti i profili di questo sito ad essere compresi nell'elenco di questo sito."
+#: mod/profiles.php:726
+msgid "Tell us about yourself..."
+msgstr "Raccontaci di te..."
-#: mod/admin.php:1092
-msgid "Global directory URL"
-msgstr "URL della directory globale"
+#: mod/profiles.php:727
+msgid "XMPP (Jabber) address:"
+msgstr "Indirizzo XMPP (Jabber):"
-#: mod/admin.php:1092
+#: mod/profiles.php:727
msgid ""
-"URL to the global directory. If this is not set, the global directory is "
-"completely unavailable to the application."
-msgstr "URL dell'elenco globale. Se vuoto, l'elenco globale sarà completamente disabilitato."
-
-#: mod/admin.php:1093
-msgid "Allow threaded items"
-msgstr "Permetti commenti nidificati"
+"The XMPP address will be propagated to your contacts so that they can follow"
+" you."
+msgstr "L'indirizzo XMPP verrà propagato ai tuoi contatti così che possano seguirti."
-#: mod/admin.php:1093
-msgid "Allow infinite level threading for items on this site."
-msgstr "Permette un infinito livello di nidificazione dei commenti su questo sito."
+#: mod/profiles.php:728
+msgid "Homepage URL:"
+msgstr "Homepage:"
-#: mod/admin.php:1094
-msgid "Private posts by default for new users"
-msgstr "Post privati di default per i nuovi utenti"
+#: mod/profiles.php:731
+msgid "Religious Views:"
+msgstr "Orientamento religioso:"
-#: mod/admin.php:1094
-msgid ""
-"Set default post permissions for all new members to the default privacy "
-"group rather than public."
-msgstr "Imposta i permessi predefiniti dei post per tutti i nuovi utenti come privati per il gruppo predefinito, invece che pubblici."
+#: mod/profiles.php:732
+msgid "Public Keywords:"
+msgstr "Parole chiave visibili a tutti:"
-#: mod/admin.php:1095
-msgid "Don't include post content in email notifications"
-msgstr "Non includere il contenuto dei post nelle notifiche via email"
+#: mod/profiles.php:732
+msgid "(Used for suggesting potential friends, can be seen by others)"
+msgstr "(E' utilizzato per suggerire potenziali amici, può essere visto da altri)"
-#: mod/admin.php:1095
-msgid ""
-"Don't include the content of a post/comment/private message/etc. in the "
-"email notifications that are sent out from this site, as a privacy measure."
-msgstr "Non include il contenuti del post/commento/messaggio privato/etc. nelle notifiche email che sono inviate da questo sito, per privacy"
+#: mod/profiles.php:733
+msgid "Private Keywords:"
+msgstr "Parole chiave private:"
-#: mod/admin.php:1096
-msgid "Disallow public access to addons listed in the apps menu."
-msgstr "Disabilita l'accesso pubblico ai plugin raccolti nel menu apps."
+#: mod/profiles.php:733
+msgid "(Used for searching profiles, never shown to others)"
+msgstr "(Usato per cercare tra i profili, non è mai visibile agli altri)"
-#: mod/admin.php:1096
-msgid ""
-"Checking this box will restrict addons listed in the apps menu to members "
-"only."
-msgstr "Selezionando questo box si limiterà ai soli membri l'accesso ai componenti aggiuntivi nel menu applicazioni"
+#: mod/profiles.php:736
+msgid "Musical interests"
+msgstr "Interessi musicali"
-#: mod/admin.php:1097
-msgid "Don't embed private images in posts"
-msgstr "Non inglobare immagini private nei post"
+#: mod/profiles.php:737
+msgid "Books, literature"
+msgstr "Libri, letteratura"
-#: mod/admin.php:1097
-msgid ""
-"Don't replace locally-hosted private photos in posts with an embedded copy "
-"of the image. This means that contacts who receive posts containing private "
-"photos will have to authenticate and load each image, which may take a "
-"while."
-msgstr "Non sostituire le foto locali nei post con una copia incorporata dell'immagine. Questo significa che i contatti che riceveranno i post contenenti foto private dovranno autenticarsi e caricare ogni immagine, cosa che può richiedere un po' di tempo."
+#: mod/profiles.php:738
+msgid "Television"
+msgstr "Televisione"
-#: mod/admin.php:1098
-msgid "Allow Users to set remote_self"
-msgstr "Permetti agli utenti di impostare 'io remoto'"
+#: mod/profiles.php:739
+msgid "Film/dance/culture/entertainment"
+msgstr "Film/danza/cultura/intrattenimento"
-#: mod/admin.php:1098
-msgid ""
-"With checking this, every user is allowed to mark every contact as a "
-"remote_self in the repair contact dialog. Setting this flag on a contact "
-"causes mirroring every posting of that contact in the users stream."
-msgstr "Selezionando questo, a tutti gli utenti sarà permesso di impostare qualsiasi contatto come 'io remoto' nella pagina di modifica del contatto. Impostare questa opzione fa si che tutti i messaggi di quel contatto vengano ripetuti nello stream dell'utente."
+#: mod/profiles.php:740
+msgid "Hobbies/Interests"
+msgstr "Hobby/interessi"
-#: mod/admin.php:1099
-msgid "Block multiple registrations"
-msgstr "Blocca registrazioni multiple"
+#: mod/profiles.php:741
+msgid "Love/romance"
+msgstr "Amore"
-#: mod/admin.php:1099
-msgid "Disallow users to register additional accounts for use as pages."
-msgstr "Non permette all'utente di registrare account extra da usare come pagine."
+#: mod/profiles.php:742
+msgid "Work/employment"
+msgstr "Lavoro/impiego"
-#: mod/admin.php:1100
-msgid "OpenID support"
-msgstr "Supporto OpenID"
+#: mod/profiles.php:743
+msgid "School/education"
+msgstr "Scuola/educazione"
-#: mod/admin.php:1100
-msgid "OpenID support for registration and logins."
-msgstr "Supporta OpenID per la registrazione e il login"
+#: mod/profiles.php:744
+msgid "Contact information and Social Networks"
+msgstr "Informazioni su contatti e social network"
-#: mod/admin.php:1101
-msgid "Fullname check"
-msgstr "Controllo nome completo"
+#: mod/profiles.php:785
+msgid "Edit/Manage Profiles"
+msgstr "Modifica / Gestisci profili"
-#: mod/admin.php:1101
+#: mod/register.php:98
msgid ""
-"Force users to register with a space between firstname and lastname in Full "
-"name, as an antispam measure"
-msgstr "Forza gli utenti a registrarsi con uno spazio tra il nome e il cognome in \"Nome completo\", come misura anti spam"
-
-#: mod/admin.php:1102
-msgid "Community Page Style"
-msgstr "Stile pagina Comunità"
+"Registration successful. Please check your email for further instructions."
+msgstr "Registrazione completata. Controlla la tua mail per ulteriori informazioni."
-#: mod/admin.php:1102
+#: mod/register.php:103
+#, php-format
msgid ""
-"Type of community page to show. 'Global community' shows every public "
-"posting from an open distributed network that arrived on this server."
-msgstr "Tipo di pagina Comunità da mostrare. 'Comunità Globale' mostra tutti i messaggi pubblici arrivati su questo server da network aperti distribuiti."
+"Failed to send email message. Here your accout details:<br> login: %s<br> "
+"password: %s<br><br>You can change your password after login."
+msgstr "Si è verificato un errore inviando l'email. I dettagli del tuo account:<br> login: %s<br> password: %s<br><br>Puoi cambiare la password dopo il login."
-#: mod/admin.php:1103
-msgid "Posts per user on community page"
-msgstr "Messaggi per utente nella pagina Comunità"
+#: mod/register.php:110
+msgid "Registration successful."
+msgstr "Registrazione completata."
-#: mod/admin.php:1103
-msgid ""
-"The maximum number of posts per user on the community page. (Not valid for "
-"'Global Community')"
-msgstr "Il numero massimo di messaggi per utente mostrato nella pagina Comunità (non valido per 'Comunità globale')"
+#: mod/register.php:116
+msgid "Your registration can not be processed."
+msgstr "La tua registrazione non puo' essere elaborata."
-#: mod/admin.php:1104
-msgid "Enable OStatus support"
-msgstr "Abilita supporto OStatus"
+#: mod/register.php:165
+msgid "Your registration is pending approval by the site owner."
+msgstr "La tua richiesta è in attesa di approvazione da parte del proprietario del sito."
-#: mod/admin.php:1104
+#: mod/register.php:231
msgid ""
-"Provide built-in OStatus (StatusNet, GNU Social etc.) compatibility. All "
-"communications in OStatus are public, so privacy warnings will be "
-"occasionally displayed."
-msgstr "Fornisce la compatibilità integrata a OStatus (StatusNet, Gnu Social, etc.). Tutte le comunicazioni su OStatus sono pubbliche, quindi un avviso di privacy verrà mostrato occasionalmente."
-
-#: mod/admin.php:1105
-msgid "OStatus conversation completion interval"
-msgstr "Intervallo completamento conversazioni OStatus"
+"You may (optionally) fill in this form via OpenID by supplying your OpenID "
+"and clicking 'Register'."
+msgstr "Se vuoi, puoi riempire questo modulo tramite OpenID, inserendo il tuo OpenID e cliccando 'Registra'."
-#: mod/admin.php:1105
+#: mod/register.php:232
msgid ""
-"How often shall the poller check for new entries in OStatus conversations? "
-"This can be a very ressource task."
-msgstr "quanto spesso il poller deve controllare se esistono nuovi commenti in una conversazione OStatus? Questo è un lavoro che può richiedere molte risorse."
+"If you are not familiar with OpenID, please leave that field blank and fill "
+"in the rest of the items."
+msgstr "Se non hai familiarità con OpenID, lascia il campo vuoto e riempi il resto della maschera."
-#: mod/admin.php:1106
-msgid "Only import OStatus threads from our contacts"
-msgstr "Importa conversazioni OStatus solo dai nostri contatti."
+#: mod/register.php:233
+msgid "Your OpenID (optional): "
+msgstr "Il tuo OpenID (opzionale): "
-#: mod/admin.php:1106
-msgid ""
-"Normally we import every content from our OStatus contacts. With this option"
-" we only store threads that are started by a contact that is known on our "
-"system."
-msgstr "Normalmente importiamo tutto il contenuto dai contatti OStatus. Con questa opzione salviamo solo le conversazioni iniziate da un contatto è conosciuto a questo nodo."
+#: mod/register.php:247
+msgid "Include your profile in member directory?"
+msgstr "Includi il tuo profilo nell'elenco pubblico?"
-#: mod/admin.php:1107
-msgid "OStatus support can only be enabled if threading is enabled."
-msgstr "Il supporto OStatus può essere abilitato solo se è abilitato il threading."
+#: mod/register.php:272
+msgid "Note for the admin"
+msgstr "Nota per l'amministratore"
-#: mod/admin.php:1109
-msgid ""
-"Diaspora support can't be enabled because Friendica was installed into a sub"
-" directory."
-msgstr "Il supporto a Diaspora non può essere abilitato perché Friendica è stato installato in una sotto directory."
+#: mod/register.php:272
+msgid "Leave a message for the admin, why you want to join this node"
+msgstr "Lascia un messaggio per l'amministratore, per esempio perché vuoi registrarti su questo nodo"
-#: mod/admin.php:1110
-msgid "Enable Diaspora support"
-msgstr "Abilita il supporto a Diaspora"
+#: mod/register.php:273
+msgid "Membership on this site is by invitation only."
+msgstr "La registrazione su questo sito è solo su invito."
-#: mod/admin.php:1110
-msgid "Provide built-in Diaspora network compatibility."
-msgstr "Fornisce compatibilità con il network Diaspora."
+#: mod/register.php:274
+msgid "Your invitation ID: "
+msgstr "L'ID del tuo invito:"
-#: mod/admin.php:1111
-msgid "Only allow Friendica contacts"
-msgstr "Permetti solo contatti Friendica"
+#: mod/register.php:285
+msgid "Your Full Name (e.g. Joe Smith, real or real-looking): "
+msgstr "Il tuo nome completo (es. Mario Rossi, vero o che sembri vero): "
-#: mod/admin.php:1111
-msgid ""
-"All contacts must use Friendica protocols. All other built-in communication "
-"protocols disabled."
-msgstr "Tutti i contatti devono usare il protocollo di Friendica. Tutti gli altri protocolli sono disabilitati."
+#: mod/register.php:286
+msgid "Your Email Address: "
+msgstr "Il tuo indirizzo email: "
-#: mod/admin.php:1112
-msgid "Verify SSL"
-msgstr "Verifica SSL"
+#: mod/register.php:288 mod/settings.php:1265
+msgid "New Password:"
+msgstr "Nuova password:"
-#: mod/admin.php:1112
-msgid ""
-"If you wish, you can turn on strict certificate checking. This will mean you"
-" cannot connect (at all) to self-signed SSL sites."
-msgstr "Se vuoi, puoi abilitare il controllo rigoroso dei certificati.Questo significa che non potrai collegarti (del tutto) con siti con certificati SSL auto-firmati."
+#: mod/register.php:288
+msgid "Leave empty for an auto generated password."
+msgstr "Lascia vuoto per generare automaticamente una password."
-#: mod/admin.php:1113
-msgid "Proxy user"
-msgstr "Utente Proxy"
+#: mod/register.php:289 mod/settings.php:1266
+msgid "Confirm:"
+msgstr "Conferma:"
-#: mod/admin.php:1114
-msgid "Proxy URL"
-msgstr "URL Proxy"
+#: mod/register.php:290
+msgid ""
+"Choose a profile nickname. This must begin with a text character. Your "
+"profile address on this site will then be "
+"'<strong>nickname@$sitename</strong>'."
+msgstr "Scegli un nome utente. Deve cominciare con una lettera. L'indirizzo del tuo profilo sarà '<strong>soprannome@$sitename</strong>'."
-#: mod/admin.php:1115
-msgid "Network timeout"
-msgstr "Timeout rete"
+#: mod/register.php:291
+msgid "Choose a nickname: "
+msgstr "Scegli un nome utente: "
-#: mod/admin.php:1115
-msgid "Value is in seconds. Set to 0 for unlimited (not recommended)."
-msgstr "Valore in secondi. Imposta a 0 per illimitato (non raccomandato)."
+#: mod/register.php:301
+msgid "Import your profile to this friendica instance"
+msgstr "Importa il tuo profilo in questo server friendica"
-#: mod/admin.php:1116
-msgid "Maximum Load Average"
-msgstr "Massimo carico medio"
+#: mod/regmod.php:62
+msgid "Account approved."
+msgstr "Account approvato."
-#: mod/admin.php:1116
-msgid ""
-"Maximum system load before delivery and poll processes are deferred - "
-"default 50."
-msgstr "Massimo carico di sistema prima che i processi di invio e di poll siano ritardati. Predefinito a 50."
+#: mod/regmod.php:90
+#, php-format
+msgid "Registration revoked for %s"
+msgstr "Registrazione revocata per %s"
-#: mod/admin.php:1117
-msgid "Maximum Load Average (Frontend)"
-msgstr "Media Massimo Carico (Frontend)"
+#: mod/regmod.php:102
+msgid "Please login."
+msgstr "Accedi."
-#: mod/admin.php:1117
-msgid "Maximum system load before the frontend quits service - default 50."
-msgstr "Massimo carico di sistema prima che il frontend fermi il servizio - default 50."
+#: mod/settings.php:60
+msgid "Display"
+msgstr "Visualizzazione"
-#: mod/admin.php:1118
-msgid "Minimal Memory"
-msgstr "Memoria Minima"
+#: mod/settings.php:67 mod/settings.php:895
+msgid "Social Networks"
+msgstr "Social Networks"
-#: mod/admin.php:1118
-msgid ""
-"Minimal free memory in MB for the poller. Needs access to /proc/meminfo - "
-"default 0 (deactivated)."
-msgstr "Minima memoria libera in MB per il poller. Necessita di avere accesso a /proc/meminfo - default 0 (disabilitato)."
+#: mod/settings.php:88
+msgid "Connected apps"
+msgstr "Applicazioni collegate"
-#: mod/admin.php:1119
-msgid "Maximum table size for optimization"
-msgstr "Dimensione massima della tabella per l'ottimizzazione"
+#: mod/settings.php:102
+msgid "Remove account"
+msgstr "Rimuovi account"
-#: mod/admin.php:1119
-msgid ""
-"Maximum table size (in MB) for the automatic optimization - default 100 MB. "
-"Enter -1 to disable it."
-msgstr "La dimensione massima (in MB) per l'ottimizzazione automatica - default 100 MB. Inserisci -1 per disabilitarlo."
+#: mod/settings.php:157
+msgid "Missing some important data!"
+msgstr "Mancano alcuni dati importanti!"
-#: mod/admin.php:1120
-msgid "Minimum level of fragmentation"
-msgstr "Livello minimo di frammentazione"
+#: mod/settings.php:267
+msgid "Failed to connect with email account using the settings provided."
+msgstr "Impossibile collegarsi all'account email con i parametri forniti."
-#: mod/admin.php:1120
-msgid ""
-"Minimum fragmenation level to start the automatic optimization - default "
-"value is 30%."
-msgstr "Livello minimo di frammentazione per iniziare la procedura di ottimizzazione automatica - il valore di default è 30%."
+#: mod/settings.php:272
+msgid "Email settings updated."
+msgstr "Impostazioni e-mail aggiornate."
-#: mod/admin.php:1122
-msgid "Periodical check of global contacts"
-msgstr "Check periodico dei contatti globali"
+#: mod/settings.php:288
+msgid "Features updated"
+msgstr "Funzionalità aggiornate"
-#: mod/admin.php:1122
-msgid ""
-"If enabled, the global contacts are checked periodically for missing or "
-"outdated data and the vitality of the contacts and servers."
-msgstr "Se abilitato, i contatti globali sono controllati periodicamente per verificare dati mancanti o sorpassati e la vitalità dei contatti e dei server."
+#: mod/settings.php:359
+msgid "Relocate message has been send to your contacts"
+msgstr "Il messaggio di trasloco è stato inviato ai tuoi contatti"
-#: mod/admin.php:1123
-msgid "Days between requery"
-msgstr "Giorni tra le richieste"
+#: mod/settings.php:378
+msgid "Empty passwords are not allowed. Password unchanged."
+msgstr "Le password non possono essere vuote. Password non cambiata."
-#: mod/admin.php:1123
-msgid "Number of days after which a server is requeried for his contacts."
-msgstr "Numero di giorni dopo i quali al server vengono richiesti i suoi contatti."
+#: mod/settings.php:386
+msgid "Wrong password."
+msgstr "Password sbagliata."
-#: mod/admin.php:1124
-msgid "Discover contacts from other servers"
-msgstr "Trova contatti dagli altri server"
+#: mod/settings.php:397
+msgid "Password changed."
+msgstr "Password cambiata."
-#: mod/admin.php:1124
-msgid ""
-"Periodically query other servers for contacts. You can choose between "
-"'users': the users on the remote system, 'Global Contacts': active contacts "
-"that are known on the system. The fallback is meant for Redmatrix servers "
-"and older friendica servers, where global contacts weren't available. The "
-"fallback increases the server load, so the recommened setting is 'Users, "
-"Global Contacts'."
-msgstr "Richiede periodicamente contatti agli altri server. Puoi scegliere tra 'utenti', gli utenti sul sistema remoto, o 'contatti globali', i contatti attivi che sono conosciuti dal sistema. Il fallback è pensato per i server Redmatrix e i vecchi server Friendica, dove i contatti globali non sono disponibili. Il fallback incrementa il carico di sistema, per cui l'impostazione consigliata è \"Utenti, Contatti Globali\"."
-
-#: mod/admin.php:1125
-msgid "Timeframe for fetching global contacts"
-msgstr "Termine per il recupero contatti globali"
-
-#: mod/admin.php:1125
-msgid ""
-"When the discovery is activated, this value defines the timeframe for the "
-"activity of the global contacts that are fetched from other servers."
-msgstr "Quando si attiva la scoperta, questo valore definisce il periodo di tempo per l'attività dei contatti globali che vengono prelevati da altri server."
-
-#: mod/admin.php:1126
-msgid "Search the local directory"
-msgstr "Cerca la directory locale"
+#: mod/settings.php:399
+msgid "Password update failed. Please try again."
+msgstr "Aggiornamento password fallito. Prova ancora."
-#: mod/admin.php:1126
-msgid ""
-"Search the local directory instead of the global directory. When searching "
-"locally, every search will be executed on the global directory in the "
-"background. This improves the search results when the search is repeated."
-msgstr "Cerca nella directory locale invece che nella directory globale. Durante la ricerca a livello locale, ogni ricerca verrà eseguita sulla directory globale in background. Ciò migliora i risultati della ricerca quando la ricerca viene ripetuta."
+#: mod/settings.php:489
+msgid " Please use a shorter name."
+msgstr " Usa un nome più corto."
-#: mod/admin.php:1128
-msgid "Publish server information"
-msgstr "Pubblica informazioni server"
+#: mod/settings.php:492
+msgid " Name too short."
+msgstr " Nome troppo corto."
-#: mod/admin.php:1128
-msgid ""
-"If enabled, general server and usage data will be published. The data "
-"contains the name and version of the server, number of users with public "
-"profiles, number of posts and the activated protocols and connectors. See <a"
-" href='http://the-federation.info/'>the-federation.info</a> for details."
-msgstr "Se abilitata, saranno pubblicati i dati generali del server e i dati di utilizzo. I dati contengono il nome e la versione del server, il numero di utenti con profili pubblici, numero dei posti e dei protocolli e connettori attivati. Per informazioni, vedere <a href='http://the-federation.info/'> the-federation.info </a>."
+#: mod/settings.php:502
+msgid "Wrong Password"
+msgstr "Password Sbagliata"
-#: mod/admin.php:1130
-msgid "Suppress Tags"
-msgstr "Sopprimi Tags"
+#: mod/settings.php:507
+msgid " Not valid email."
+msgstr " Email non valida."
-#: mod/admin.php:1130
-msgid "Suppress showing a list of hashtags at the end of the posting."
-msgstr "Non mostra la lista di hashtag in coda al messaggio"
+#: mod/settings.php:514
+msgid " Cannot change to that email."
+msgstr "Non puoi usare quella email."
-#: mod/admin.php:1131
-msgid "Path to item cache"
-msgstr "Percorso cache elementi"
+#: mod/settings.php:570
+msgid "Private forum has no privacy permissions. Using default privacy group."
+msgstr "Il forum privato non ha permessi di privacy. Uso il gruppo di privacy predefinito."
-#: mod/admin.php:1131
-msgid "The item caches buffers generated bbcode and external images."
-msgstr "La cache degli elementi memorizza il bbcode generato e le immagini esterne."
+#: mod/settings.php:573
+msgid "Private forum has no privacy permissions and no default privacy group."
+msgstr "Il gruppo privato non ha permessi di privacy e nessun gruppo di privacy predefinito."
-#: mod/admin.php:1132
-msgid "Cache duration in seconds"
-msgstr "Durata della cache in secondi"
+#: mod/settings.php:613
+msgid "Settings updated."
+msgstr "Impostazioni aggiornate."
-#: mod/admin.php:1132
-msgid ""
-"How long should the cache files be hold? Default value is 86400 seconds (One"
-" day). To disable the item cache, set the value to -1."
-msgstr "Quanto a lungo devono essere mantenuti i file di cache? Il valore predefinito è 86400 secondi (un giorno). Per disabilitare la cache, imposta il valore a -1."
+#: mod/settings.php:690 mod/settings.php:716 mod/settings.php:752
+msgid "Add application"
+msgstr "Aggiungi applicazione"
-#: mod/admin.php:1133
-msgid "Maximum numbers of comments per post"
-msgstr "Numero massimo di commenti per post"
+#: mod/settings.php:694 mod/settings.php:720
+msgid "Consumer Key"
+msgstr "Consumer Key"
-#: mod/admin.php:1133
-msgid "How much comments should be shown for each post? Default value is 100."
-msgstr "Quanti commenti devono essere mostrati per ogni post? Default : 100."
+#: mod/settings.php:695 mod/settings.php:721
+msgid "Consumer Secret"
+msgstr "Consumer Secret"
-#: mod/admin.php:1134
-msgid "Temp path"
-msgstr "Percorso file temporanei"
+#: mod/settings.php:696 mod/settings.php:722
+msgid "Redirect"
+msgstr "Redirect"
-#: mod/admin.php:1134
-msgid ""
-"If you have a restricted system where the webserver can't access the system "
-"temp path, enter another path here."
-msgstr "Se si dispone di un sistema ristretto in cui il server web non può accedere al percorso temporaneo di sistema, inserire un altro percorso qui."
+#: mod/settings.php:697 mod/settings.php:723
+msgid "Icon url"
+msgstr "Url icona"
-#: mod/admin.php:1135
-msgid "Base path to installation"
-msgstr "Percorso base all'installazione"
+#: mod/settings.php:708
+msgid "You can't edit this application."
+msgstr "Non puoi modificare questa applicazione."
-#: mod/admin.php:1135
-msgid ""
-"If the system cannot detect the correct path to your installation, enter the"
-" correct path here. This setting should only be set if you are using a "
-"restricted system and symbolic links to your webroot."
-msgstr "Se il sistema non è in grado di rilevare il percorso corretto per l'installazione, immettere il percorso corretto qui. Questa impostazione deve essere inserita solo se si utilizza un sistema limitato e/o collegamenti simbolici al tuo webroot."
+#: mod/settings.php:751
+msgid "Connected Apps"
+msgstr "Applicazioni Collegate"
-#: mod/admin.php:1136
-msgid "Disable picture proxy"
-msgstr "Disabilita il proxy immagini"
+#: mod/settings.php:753 object/Item.php:132 object/Item.php:134
+msgid "Edit"
+msgstr "Modifica"
-#: mod/admin.php:1136
-msgid ""
-"The picture proxy increases performance and privacy. It shouldn't be used on"
-" systems with very low bandwith."
-msgstr "Il proxy immagini aumenta le performance e la privacy. Non dovrebbe essere usato su server con poca banda disponibile."
+#: mod/settings.php:755
+msgid "Client key starts with"
+msgstr "Chiave del client inizia con"
-#: mod/admin.php:1137
-msgid "Only search in tags"
-msgstr "Cerca solo nei tag"
+#: mod/settings.php:756
+msgid "No name"
+msgstr "Nessun nome"
-#: mod/admin.php:1137
-msgid "On large systems the text search can slow down the system extremely."
-msgstr "Su server con molti dati, la ricerca nel testo può estremamente rallentare il sistema."
+#: mod/settings.php:757
+msgid "Remove authorization"
+msgstr "Rimuovi l'autorizzazione"
-#: mod/admin.php:1139
-msgid "New base url"
-msgstr "Nuovo url base"
+#: mod/settings.php:769
+msgid "No Plugin settings configured"
+msgstr "Nessun plugin ha impostazioni modificabili"
-#: mod/admin.php:1139
-msgid ""
-"Change base url for this server. Sends relocate message to all DFRN contacts"
-" of all users."
-msgstr "Cambia l'url base di questo server. Invia il messaggio di trasloco a tutti i contatti DFRN di tutti gli utenti."
+#: mod/settings.php:778
+msgid "Plugin Settings"
+msgstr "Impostazioni plugin"
-#: mod/admin.php:1141
-msgid "RINO Encryption"
-msgstr "Crittografia RINO"
+#: mod/settings.php:800
+msgid "Additional Features"
+msgstr "Funzionalità aggiuntive"
-#: mod/admin.php:1141
-msgid "Encryption layer between nodes."
-msgstr "Crittografia delle comunicazioni tra nodi."
+#: mod/settings.php:810 mod/settings.php:814
+msgid "General Social Media Settings"
+msgstr "Impostazioni Media Sociali"
-#: mod/admin.php:1143
-msgid "Maximum number of parallel workers"
-msgstr "Massimo numero di lavori in parallelo"
+#: mod/settings.php:820
+msgid "Disable intelligent shortening"
+msgstr "Disabilita accorciamento intelligente"
-#: mod/admin.php:1143
+#: mod/settings.php:822
msgid ""
-"On shared hosters set this to 2. On larger systems, values of 10 are great. "
-"Default value is 4."
-msgstr "Su host condivisi imposta a 2. Su sistemi più grandi, valori fino a 10 vanno bene. Il valore di default è 4."
+"Normally the system tries to find the best link to add to shortened posts. "
+"If this option is enabled then every shortened post will always point to the"
+" original friendica post."
+msgstr "Normalmente il sistema tenta di trovare il migliore link da aggiungere a un post accorciato. Se questa opzione è abilitata, ogni post accorciato conterrà sempre un link al post originale su Friendica."
-#: mod/admin.php:1144
-msgid "Don't use 'proc_open' with the worker"
-msgstr "Non usare 'proc_open' con il worker"
+#: mod/settings.php:828
+msgid "Automatically follow any GNU Social (OStatus) followers/mentioners"
+msgstr "Segui automaticamente chiunque da GNU Social (OStatus) ti segua o ti menzioni"
-#: mod/admin.php:1144
+#: mod/settings.php:830
msgid ""
-"Enable this if your system doesn't allow the use of 'proc_open'. This can "
-"happen on shared hosters. If this is enabled you should increase the "
-"frequency of poller calls in your crontab."
-msgstr "Abilita se il tuo sistema non consente l'utilizzo di 'proc_open'. Può succedere con gli hosting condivisi. Se abiliti questa opzione, dovresti aumentare la frequenza delle chiamate al poller nel tuo crontab."
-
-#: mod/admin.php:1145
-msgid "Enable fastlane"
-msgstr "Abilita fastlane"
+"If you receive a message from an unknown OStatus user, this option decides "
+"what to do. If it is checked, a new contact will be created for every "
+"unknown user."
+msgstr "Se ricevi un messaggio da un utente OStatus sconosciuto, questa opzione decide cosa fare. Se selezionato, un nuovo contatto verrà creato per ogni utente sconosciuto."
-#: mod/admin.php:1145
-msgid ""
-"When enabed, the fastlane mechanism starts an additional worker if processes"
-" with higher priority are blocked by processes of lower priority."
-msgstr "Quando abilitato, il meccanismo di fastlane avvia processi aggiuntivi se processi con priorità più alta sono bloccati da processi con priorità più bassa."
+#: mod/settings.php:836
+msgid "Default group for OStatus contacts"
+msgstr "Gruppo di default per i contatti OStatus"
-#: mod/admin.php:1146
-msgid "Enable frontend worker"
-msgstr "Abilita worker da frontend"
+#: mod/settings.php:844
+msgid "Your legacy GNU Social account"
+msgstr "Il tuo vecchio account GNU Social"
-#: mod/admin.php:1146
+#: mod/settings.php:846
msgid ""
-"When enabled the Worker process is triggered when backend access is "
-"performed (e.g. messages being delivered). On smaller sites you might want "
-"to call yourdomain.tld/worker on a regular basis via an external cron job. "
-"You should only enable this option if you cannot utilize cron/scheduled jobs"
-" on your server. The worker background process needs to be activated for "
-"this."
-msgstr "Quando abilitato, il processo è avviato quando viene eseguito un accesso al backend (per esempio, quando un messaggio viene consegnato). Su siti più piccoli potresti voler chiamare yourdomain.tld/worker regolarmente attraverso un cron esterno. Dovresti abilitare questa opzione solo se non puoi utilizzare cron sul tuo server. L'elaborazione in background con worker deve essere abilitata perchè questa opzione sia effettiva."
+"If you enter your old GNU Social/Statusnet account name here (in the format "
+"user@domain.tld), your contacts will be added automatically. The field will "
+"be emptied when done."
+msgstr "Se inserisci il nome del tuo vecchio account GNU Social/Statusnet qui (nel formato utente@dominio.tld), i tuoi contatti verranno automaticamente aggiunti. Il campo verrà svuotato una volta terminato."
-#: mod/admin.php:1176
-msgid "Update has been marked successful"
-msgstr "L'aggiornamento è stato segnato come di successo"
+#: mod/settings.php:849
+msgid "Repair OStatus subscriptions"
+msgstr "Ripara le iscrizioni OStatus"
-#: mod/admin.php:1184
+#: mod/settings.php:858 mod/settings.php:859
#, php-format
-msgid "Database structure update %s was successfully applied."
-msgstr "Aggiornamento struttura database %s applicata con successo."
+msgid "Built-in support for %s connectivity is %s"
+msgstr "Il supporto integrato per la connettività con %s è %s"
-#: mod/admin.php:1187
-#, php-format
-msgid "Executing of database structure update %s failed with error: %s"
-msgstr "Aggiornamento struttura database %s fallita con errore: %s"
+#: mod/settings.php:858 mod/settings.php:859
+msgid "enabled"
+msgstr "abilitato"
-#: mod/admin.php:1201
-#, php-format
-msgid "Executing %s failed with error: %s"
-msgstr "Esecuzione di %s fallita con errore: %s"
+#: mod/settings.php:858 mod/settings.php:859
+msgid "disabled"
+msgstr "disabilitato"
-#: mod/admin.php:1204
-#, php-format
-msgid "Update %s was successfully applied."
-msgstr "L'aggiornamento %s è stato applicato con successo"
+#: mod/settings.php:859
+msgid "GNU Social (OStatus)"
+msgstr "GNU Social (OStatus)"
-#: mod/admin.php:1207
-#, php-format
-msgid "Update %s did not return a status. Unknown if it succeeded."
-msgstr "L'aggiornamento %s non ha riportato uno stato. Non so se è andato a buon fine."
+#: mod/settings.php:890
+msgid "Email access is disabled on this site."
+msgstr "L'accesso email è disabilitato su questo sito."
-#: mod/admin.php:1210
-#, php-format
-msgid "There was no additional update function %s that needed to be called."
-msgstr "Non ci sono altre funzioni di aggiornamento %s da richiamare."
+#: mod/settings.php:900
+msgid "Email/Mailbox Setup"
+msgstr "Impostazioni email"
-#: mod/admin.php:1230
-msgid "No failed updates."
-msgstr "Nessun aggiornamento fallito."
+#: mod/settings.php:901
+msgid ""
+"If you wish to communicate with email contacts using this service "
+"(optional), please specify how to connect to your mailbox."
+msgstr "Se vuoi comunicare con i contatti email usando questo servizio, specifica come collegarti alla tua casella di posta. (opzionale)"
-#: mod/admin.php:1231
-msgid "Check database structure"
-msgstr "Controlla struttura database"
+#: mod/settings.php:902
+msgid "Last successful email check:"
+msgstr "Ultimo controllo email eseguito con successo:"
-#: mod/admin.php:1236
-msgid "Failed Updates"
-msgstr "Aggiornamenti falliti"
+#: mod/settings.php:904
+msgid "IMAP server name:"
+msgstr "Nome server IMAP:"
-#: mod/admin.php:1237
-msgid ""
-"This does not include updates prior to 1139, which did not return a status."
-msgstr "Questo non include gli aggiornamenti prima del 1139, che non ritornano lo stato."
+#: mod/settings.php:905
+msgid "IMAP port:"
+msgstr "Porta IMAP:"
-#: mod/admin.php:1238
-msgid "Mark success (if update was manually applied)"
-msgstr "Segna completato (se l'update è stato applicato manualmente)"
+#: mod/settings.php:906
+msgid "Security:"
+msgstr "Sicurezza:"
-#: mod/admin.php:1239
-msgid "Attempt to execute this update step automatically"
-msgstr "Cerco di eseguire questo aggiornamento in automatico"
+#: mod/settings.php:906 mod/settings.php:911
+msgid "None"
+msgstr "Nessuna"
-#: mod/admin.php:1273
-#, php-format
+#: mod/settings.php:907
+msgid "Email login name:"
+msgstr "Nome utente email:"
+
+#: mod/settings.php:908
+msgid "Email password:"
+msgstr "Password email:"
+
+#: mod/settings.php:909
+msgid "Reply-to address:"
+msgstr "Indirizzo di risposta:"
+
+#: mod/settings.php:910
+msgid "Send public posts to all email contacts:"
+msgstr "Invia i messaggi pubblici ai contatti email:"
+
+#: mod/settings.php:911
+msgid "Action after import:"
+msgstr "Azione post importazione:"
+
+#: mod/settings.php:911
+msgid "Move to folder"
+msgstr "Sposta nella cartella"
+
+#: mod/settings.php:912
+msgid "Move to folder:"
+msgstr "Sposta nella cartella:"
+
+#: mod/settings.php:1008
+msgid "Display Settings"
+msgstr "Impostazioni Grafiche"
+
+#: mod/settings.php:1014 mod/settings.php:1037
+msgid "Display Theme:"
+msgstr "Tema:"
+
+#: mod/settings.php:1015
+msgid "Mobile Theme:"
+msgstr "Tema mobile:"
+
+#: mod/settings.php:1016
+msgid "Suppress warning of insecure networks"
+msgstr "Sopprimi avvisi reti insicure"
+
+#: mod/settings.php:1016
msgid ""
-"\n"
-"\t\t\tDear %1$s,\n"
-"\t\t\t\tthe administrator of %2$s has set up an account for you."
-msgstr "\nGentile %1$s,\n l'amministratore di %2$s ha impostato un account per te."
+"Should the system suppress the warning that the current group contains "
+"members of networks that can't receive non public postings."
+msgstr "Il sistema sopprimerà l'avviso che il gruppo selezionato contiene membri di reti che non possono ricevere post non pubblici."
-#: mod/admin.php:1276
-#, php-format
+#: mod/settings.php:1017
+msgid "Update browser every xx seconds"
+msgstr "Aggiorna il browser ogni x secondi"
+
+#: mod/settings.php:1017
+msgid "Minimum of 10 seconds. Enter -1 to disable it."
+msgstr "Minimo 10 secondi. Inserisci -1 per disabilitarlo"
+
+#: mod/settings.php:1018
+msgid "Number of items to display per page:"
+msgstr "Numero di elementi da mostrare per pagina:"
+
+#: mod/settings.php:1018 mod/settings.php:1019
+msgid "Maximum of 100 items"
+msgstr "Massimo 100 voci"
+
+#: mod/settings.php:1019
+msgid "Number of items to display per page when viewed from mobile device:"
+msgstr "Numero di voci da visualizzare per pagina quando si utilizza un dispositivo mobile:"
+
+#: mod/settings.php:1020
+msgid "Don't show emoticons"
+msgstr "Non mostrare le emoticons"
+
+#: mod/settings.php:1021
+msgid "Calendar"
+msgstr "Calendario"
+
+#: mod/settings.php:1022
+msgid "Beginning of week:"
+msgstr "Inizio della settimana:"
+
+#: mod/settings.php:1023
+msgid "Don't show notices"
+msgstr "Non mostrare gli avvisi"
+
+#: mod/settings.php:1024
+msgid "Infinite scroll"
+msgstr "Scroll infinito"
+
+#: mod/settings.php:1025
+msgid "Automatic updates only at the top of the network page"
+msgstr "Aggiornamenti automatici solo in cima alla pagina \"rete\""
+
+#: mod/settings.php:1025
msgid ""
-"\n"
-"\t\t\tThe login details are as follows:\n"
-"\n"
-"\t\t\tSite Location:\t%1$s\n"
-"\t\t\tLogin Name:\t\t%2$s\n"
-"\t\t\tPassword:\t\t%3$s\n"
-"\n"
-"\t\t\tYou may change your password from your account \"Settings\" page after logging\n"
-"\t\t\tin.\n"
-"\n"
-"\t\t\tPlease take a few moments to review the other account settings on that page.\n"
-"\n"
-"\t\t\tYou may also wish to add some basic information to your default profile\n"
-"\t\t\t(on the \"Profiles\" page) so that other people can easily find you.\n"
-"\n"
-"\t\t\tWe recommend setting your full name, adding a profile photo,\n"
-"\t\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n"
-"\t\t\tperhaps what country you live in; if you do not wish to be more specific\n"
-"\t\t\tthan that.\n"
-"\n"
-"\t\t\tWe fully respect your right to privacy, and none of these items are necessary.\n"
-"\t\t\tIf you are new and do not know anybody here, they may help\n"
-"\t\t\tyou to make some new and interesting friends.\n"
-"\n"
-"\t\t\tThank you and welcome to %4$s."
-msgstr "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %1$s\n Nome utente: %2$s\n Password: %3$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %4$s"
+"When disabled, the network page is updated all the time, which could be "
+"confusing while reading."
+msgstr ""
-#: mod/admin.php:1320
-#, php-format
-msgid "%s user blocked/unblocked"
-msgid_plural "%s users blocked/unblocked"
-msgstr[0] "%s utente bloccato/sbloccato"
-msgstr[1] "%s utenti bloccati/sbloccati"
+#: mod/settings.php:1026
+msgid "Bandwith Saver Mode"
+msgstr "Modalità Salva Banda"
-#: mod/admin.php:1327
-#, php-format
-msgid "%s user deleted"
-msgid_plural "%s users deleted"
-msgstr[0] "%s utente cancellato"
-msgstr[1] "%s utenti cancellati"
+#: mod/settings.php:1026
+msgid ""
+"When enabled, embedded content is not displayed on automatic updates, they "
+"only show on page reload."
+msgstr "Quando abilitato, il contenuto embeddato non è mostrato quando la pagina si aggiorna automaticamente, ma solo quando la pagina viene ricaricata."
-#: mod/admin.php:1374
-#, php-format
-msgid "User '%s' deleted"
-msgstr "Utente '%s' cancellato"
+#: mod/settings.php:1028
+msgid "General Theme Settings"
+msgstr "Opzioni Generali Tema"
-#: mod/admin.php:1382
-#, php-format
-msgid "User '%s' unblocked"
-msgstr "Utente '%s' sbloccato"
+#: mod/settings.php:1029
+msgid "Custom Theme Settings"
+msgstr "Opzioni Personalizzate Tema"
+
+#: mod/settings.php:1030
+msgid "Content Settings"
+msgstr "Opzioni Contenuto"
+
+#: mod/settings.php:1031 view/theme/duepuntozero/config.php:67
+#: view/theme/frio/config.php:110 view/theme/quattro/config.php:73
+#: view/theme/vier/config.php:116
+msgid "Theme settings"
+msgstr "Impostazioni tema"
+
+#: mod/settings.php:1097
+msgid "Account Types"
+msgstr "Tipi di Account"
+
+#: mod/settings.php:1098
+msgid "Personal Page Subtypes"
+msgstr "Sottotipi di Pagine Personali"
+
+#: mod/settings.php:1099
+msgid "Community Forum Subtypes"
+msgstr "Sottotipi di Community Forum"
+
+#: mod/settings.php:1106
+msgid "Personal Page"
+msgstr "Pagina Personale"
+
+#: mod/settings.php:1107
+msgid "Account for a personal profile."
+msgstr ""
+
+#: mod/settings.php:1110
+msgid "Organisation Page"
+msgstr "Pagina Organizzazione"
+
+#: mod/settings.php:1111
+msgid ""
+"Account for an organisation that automatically approves contact requests as "
+"\"Followers\"."
+msgstr ""
+
+#: mod/settings.php:1114
+msgid "News Page"
+msgstr "Pagina Notizie"
+
+#: mod/settings.php:1115
+msgid ""
+"Account for a news reflector that automatically approves contact requests as"
+" \"Followers\"."
+msgstr ""
+
+#: mod/settings.php:1118
+msgid "Community Forum"
+msgstr "Community Forum"
+
+#: mod/settings.php:1119
+msgid "Account for community discussions."
+msgstr ""
+
+#: mod/settings.php:1122
+msgid "Normal Account Page"
+msgstr "Pagina Account Normale"
+
+#: mod/settings.php:1123
+msgid ""
+"Account for a regular personal profile that requires manual approval of "
+"\"Friends\" and \"Followers\"."
+msgstr ""
+
+#: mod/settings.php:1126
+msgid "Soapbox Page"
+msgstr "Pagina Sandbox"
+
+#: mod/settings.php:1127
+msgid ""
+"Account for a public profile that automatically approves contact requests as"
+" \"Followers\"."
+msgstr ""
+
+#: mod/settings.php:1130
+msgid "Public Forum"
+msgstr "Forum Pubblico"
+
+#: mod/settings.php:1131
+msgid "Automatically approves all contact requests."
+msgstr ""
+
+#: mod/settings.php:1134
+msgid "Automatic Friend Page"
+msgstr "Pagina con amicizia automatica"
+
+#: mod/settings.php:1135
+msgid ""
+"Account for a popular profile that automatically approves contact requests "
+"as \"Friends\"."
+msgstr ""
+
+#: mod/settings.php:1138
+msgid "Private Forum [Experimental]"
+msgstr "Forum privato [sperimentale]"
+
+#: mod/settings.php:1139
+msgid "Requires manual approval of contact requests."
+msgstr ""
+
+#: mod/settings.php:1150
+msgid "OpenID:"
+msgstr "OpenID:"
+
+#: mod/settings.php:1150
+msgid "(Optional) Allow this OpenID to login to this account."
+msgstr "(Opzionale) Consente di loggarti in questo account con questo OpenID"
+
+#: mod/settings.php:1158
+msgid "Publish your default profile in your local site directory?"
+msgstr "Pubblica il tuo profilo predefinito nell'elenco locale del sito"
+
+#: mod/settings.php:1158
+msgid "Your profile may be visible in public."
+msgstr "Il tuo profilo potrebbe essere visibile pubblicamente."
+
+#: mod/settings.php:1164
+msgid "Publish your default profile in the global social directory?"
+msgstr "Pubblica il tuo profilo predefinito nell'elenco sociale globale"
+
+#: mod/settings.php:1171
+msgid "Hide your contact/friend list from viewers of your default profile?"
+msgstr "Nascondi la lista dei tuoi contatti/amici dai visitatori del tuo profilo predefinito"
+
+#: mod/settings.php:1175
+msgid ""
+"If enabled, posting public messages to Diaspora and other networks isn't "
+"possible."
+msgstr "Se abilitato, l'invio di messaggi pubblici verso Diaspora e altri network non sarà possibile"
+
+#: mod/settings.php:1180
+msgid "Allow friends to post to your profile page?"
+msgstr "Permetti agli amici di scrivere sulla tua pagina profilo?"
-#: mod/admin.php:1382
+#: mod/settings.php:1185
+msgid "Allow friends to tag your posts?"
+msgstr "Permetti agli amici di aggiungere tag ai tuoi messaggi?"
+
+#: mod/settings.php:1190
+msgid "Allow us to suggest you as a potential friend to new members?"
+msgstr "Ci permetti di suggerirti come potenziale amico ai nuovi membri?"
+
+#: mod/settings.php:1195
+msgid "Permit unknown people to send you private mail?"
+msgstr "Permetti a utenti sconosciuti di inviarti messaggi privati?"
+
+#: mod/settings.php:1203
+msgid "Profile is <strong>not published</strong>."
+msgstr "Il profilo <strong>non è pubblicato</strong>."
+
+#: mod/settings.php:1211
#, php-format
-msgid "User '%s' blocked"
-msgstr "Utente '%s' bloccato"
+msgid "Your Identity Address is <strong>'%s'</strong> or '%s'."
+msgstr "L'indirizzo della tua identità è <strong>'%s'</strong> or '%s'."
-#: mod/admin.php:1490 mod/admin.php:1516
-msgid "Register date"
-msgstr "Data registrazione"
+#: mod/settings.php:1218
+msgid "Automatically expire posts after this many days:"
+msgstr "Fai scadere i post automaticamente dopo x giorni:"
-#: mod/admin.php:1490 mod/admin.php:1516
-msgid "Last login"
-msgstr "Ultimo accesso"
+#: mod/settings.php:1218
+msgid "If empty, posts will not expire. Expired posts will be deleted"
+msgstr "Se lasciato vuoto, i messaggi non verranno cancellati."
-#: mod/admin.php:1490 mod/admin.php:1516
-msgid "Last item"
-msgstr "Ultimo elemento"
+#: mod/settings.php:1219
+msgid "Advanced expiration settings"
+msgstr "Impostazioni avanzate di scadenza"
-#: mod/admin.php:1499
-msgid "Add User"
-msgstr "Aggiungi utente"
+#: mod/settings.php:1220
+msgid "Advanced Expiration"
+msgstr "Scadenza avanzata"
-#: mod/admin.php:1500
-msgid "select all"
-msgstr "seleziona tutti"
+#: mod/settings.php:1221
+msgid "Expire posts:"
+msgstr "Fai scadere i post:"
-#: mod/admin.php:1501
-msgid "User registrations waiting for confirm"
-msgstr "Richieste di registrazione in attesa di conferma"
+#: mod/settings.php:1222
+msgid "Expire personal notes:"
+msgstr "Fai scadere le Note personali:"
-#: mod/admin.php:1502
-msgid "User waiting for permanent deletion"
-msgstr "Utente in attesa di cancellazione definitiva"
+#: mod/settings.php:1223
+msgid "Expire starred posts:"
+msgstr "Fai scadere i post Speciali:"
-#: mod/admin.php:1503
-msgid "Request date"
-msgstr "Data richiesta"
+#: mod/settings.php:1224
+msgid "Expire photos:"
+msgstr "Fai scadere le foto:"
-#: mod/admin.php:1504
-msgid "No registrations."
-msgstr "Nessuna registrazione."
+#: mod/settings.php:1225
+msgid "Only expire posts by others:"
+msgstr "Fai scadere solo i post degli altri:"
-#: mod/admin.php:1505
-msgid "Note from the user"
-msgstr "Nota dall'utente"
+#: mod/settings.php:1256
+msgid "Account Settings"
+msgstr "Impostazioni account"
-#: mod/admin.php:1507
-msgid "Deny"
-msgstr "Nega"
+#: mod/settings.php:1264
+msgid "Password Settings"
+msgstr "Impostazioni password"
-#: mod/admin.php:1511
-msgid "Site admin"
-msgstr "Amministrazione sito"
+#: mod/settings.php:1266
+msgid "Leave password fields blank unless changing"
+msgstr "Lascia questi campi in bianco per non effettuare variazioni alla password"
-#: mod/admin.php:1512
-msgid "Account expired"
-msgstr "Account scaduto"
+#: mod/settings.php:1267
+msgid "Current Password:"
+msgstr "Password Attuale:"
-#: mod/admin.php:1515
-msgid "New User"
-msgstr "Nuovo Utente"
+#: mod/settings.php:1267 mod/settings.php:1268
+msgid "Your current password to confirm the changes"
+msgstr "La tua password attuale per confermare le modifiche"
-#: mod/admin.php:1516
-msgid "Deleted since"
-msgstr "Rimosso da"
+#: mod/settings.php:1268
+msgid "Password:"
+msgstr "Password:"
+
+#: mod/settings.php:1272
+msgid "Basic Settings"
+msgstr "Impostazioni base"
+
+#: mod/settings.php:1274
+msgid "Email Address:"
+msgstr "Indirizzo Email:"
-#: mod/admin.php:1521
+#: mod/settings.php:1275
+msgid "Your Timezone:"
+msgstr "Il tuo fuso orario:"
+
+#: mod/settings.php:1276
+msgid "Your Language:"
+msgstr "La tua lingua:"
+
+#: mod/settings.php:1276
msgid ""
-"Selected users will be deleted!\\n\\nEverything these users had posted on "
-"this site will be permanently deleted!\\n\\nAre you sure?"
-msgstr "Gli utenti selezionati saranno cancellati!\\n\\nTutto quello che gli utenti hanno inviato su questo sito sarà permanentemente canellato!\\n\\nSei sicuro?"
+"Set the language we use to show you friendica interface and to send you "
+"emails"
+msgstr "Imposta la lingua che sarà usata per mostrarti l'interfaccia di Friendica e per inviarti le email"
+
+#: mod/settings.php:1277
+msgid "Default Post Location:"
+msgstr "Località predefinita:"
+
+#: mod/settings.php:1278
+msgid "Use Browser Location:"
+msgstr "Usa la località rilevata dal browser:"
+
+#: mod/settings.php:1281
+msgid "Security and Privacy Settings"
+msgstr "Impostazioni di sicurezza e privacy"
+
+#: mod/settings.php:1283
+msgid "Maximum Friend Requests/Day:"
+msgstr "Numero massimo di richieste di amicizia al giorno:"
+
+#: mod/settings.php:1283 mod/settings.php:1313
+msgid "(to prevent spam abuse)"
+msgstr "(per prevenire lo spam)"
+
+#: mod/settings.php:1284
+msgid "Default Post Permissions"
+msgstr "Permessi predefiniti per i messaggi"
+
+#: mod/settings.php:1285
+msgid "(click to open/close)"
+msgstr "(clicca per aprire/chiudere)"
+
+#: mod/settings.php:1296
+msgid "Default Private Post"
+msgstr "Default Post Privato"
+
+#: mod/settings.php:1297
+msgid "Default Public Post"
+msgstr "Default Post Pubblico"
+
+#: mod/settings.php:1301
+msgid "Default Permissions for New Posts"
+msgstr "Permessi predefiniti per i nuovi post"
+
+#: mod/settings.php:1313
+msgid "Maximum private messages per day from unknown people:"
+msgstr "Numero massimo di messaggi privati da utenti sconosciuti per giorno:"
+
+#: mod/settings.php:1316
+msgid "Notification Settings"
+msgstr "Impostazioni notifiche"
+
+#: mod/settings.php:1317
+msgid "By default post a status message when:"
+msgstr "Invia un messaggio di stato quando:"
+
+#: mod/settings.php:1318
+msgid "accepting a friend request"
+msgstr "accetti una richiesta di amicizia"
+
+#: mod/settings.php:1319
+msgid "joining a forum/community"
+msgstr "ti unisci a un forum/comunità"
+
+#: mod/settings.php:1320
+msgid "making an <em>interesting</em> profile change"
+msgstr "fai un <em>interessante</em> modifica al profilo"
+
+#: mod/settings.php:1321
+msgid "Send a notification email when:"
+msgstr "Invia una mail di notifica quando:"
+
+#: mod/settings.php:1322
+msgid "You receive an introduction"
+msgstr "Ricevi una presentazione"
+
+#: mod/settings.php:1323
+msgid "Your introductions are confirmed"
+msgstr "Le tue presentazioni sono confermate"
+
+#: mod/settings.php:1324
+msgid "Someone writes on your profile wall"
+msgstr "Qualcuno scrive sulla bacheca del tuo profilo"
+
+#: mod/settings.php:1325
+msgid "Someone writes a followup comment"
+msgstr "Qualcuno scrive un commento a un tuo messaggio"
+
+#: mod/settings.php:1326
+msgid "You receive a private message"
+msgstr "Ricevi un messaggio privato"
+
+#: mod/settings.php:1327
+msgid "You receive a friend suggestion"
+msgstr "Hai ricevuto un suggerimento di amicizia"
+
+#: mod/settings.php:1328
+msgid "You are tagged in a post"
+msgstr "Sei stato taggato in un post"
+
+#: mod/settings.php:1329
+msgid "You are poked/prodded/etc. in a post"
+msgstr "Sei 'toccato'/'spronato'/ecc. in un post"
+
+#: mod/settings.php:1331
+msgid "Activate desktop notifications"
+msgstr "Attiva notifiche desktop"
+
+#: mod/settings.php:1331
+msgid "Show desktop popup on new notifications"
+msgstr "Mostra un popup di notifica sul desktop all'arrivo di nuove notifiche"
+
+#: mod/settings.php:1333
+msgid "Text-only notification emails"
+msgstr "Email di notifica in solo testo"
+
+#: mod/settings.php:1335
+msgid "Send text only notification emails, without the html part"
+msgstr "Invia le email di notifica in solo testo, senza la parte in html"
+
+#: mod/settings.php:1337
+msgid "Show detailled notifications"
+msgstr ""
+
+#: mod/settings.php:1339
+msgid ""
+"Per default the notificiation are condensed to a single notification per "
+"item. When enabled, every notification is displayed."
+msgstr ""
+
+#: mod/settings.php:1341
+msgid "Advanced Account/Page Type Settings"
+msgstr "Impostazioni avanzate Account/Tipo di pagina"
+
+#: mod/settings.php:1342
+msgid "Change the behaviour of this account for special situations"
+msgstr "Modifica il comportamento di questo account in situazioni speciali"
+
+#: mod/settings.php:1345
+msgid "Relocate"
+msgstr "Trasloca"
+
+#: mod/settings.php:1346
+msgid ""
+"If you have moved this profile from another server, and some of your "
+"contacts don't receive your updates, try pushing this button."
+msgstr "Se hai spostato questo profilo da un'altro server, e alcuni dei tuoi contatti non ricevono i tuoi aggiornamenti, prova a premere questo bottone."
+
+#: mod/settings.php:1347
+msgid "Resend relocate message to contacts"
+msgstr "Invia nuovamente il messaggio di trasloco ai contatti"
+
+#: mod/videos.php:128
+msgid "Do you really want to delete this video?"
+msgstr "Vuoi veramente cancellare questo video?"
+
+#: mod/videos.php:133
+msgid "Delete Video"
+msgstr "Rimuovi video"
+
+#: mod/videos.php:212
+msgid "No videos selected"
+msgstr "Nessun video selezionato"
+
+#: mod/videos.php:406
+msgid "Recent Videos"
+msgstr "Video Recenti"
+
+#: mod/videos.php:408
+msgid "Upload New Videos"
+msgstr "Carica Nuovo Video"
+
+#: mod/wall_attach.php:19 mod/wall_attach.php:27 mod/wall_attach.php:78
+#: mod/wall_upload.php:37 mod/wall_upload.php:53 mod/wall_upload.php:111
+#: mod/wall_upload.php:151 mod/wall_upload.php:154
+msgid "Invalid request."
+msgstr "Richiesta non valida."
+
+#: mod/wall_attach.php:96
+msgid "Sorry, maybe your upload is bigger than the PHP configuration allows"
+msgstr "Mi spiace, forse il file che stai caricando è più grosso di quanto la configurazione di PHP permetta"
-#: mod/admin.php:1522
-msgid ""
-"The user {0} will be deleted!\\n\\nEverything this user has posted on this "
-"site will be permanently deleted!\\n\\nAre you sure?"
-msgstr "L'utente {0} sarà cancellato!\\n\\nTutto quello che ha inviato su questo sito sarà permanentemente cancellato!\\n\\nSei sicuro?"
+#: mod/wall_attach.php:96
+msgid "Or - did you try to upload an empty file?"
+msgstr "O.. non avrai provato a caricare un file vuoto?"
-#: mod/admin.php:1532
-msgid "Name of the new user."
-msgstr "Nome del nuovo utente."
+#: mod/wall_attach.php:107
+#, php-format
+msgid "File exceeds size limit of %s"
+msgstr "Il file supera la dimensione massima di %s"
-#: mod/admin.php:1533
-msgid "Nickname"
-msgstr "Nome utente"
+#: mod/wall_attach.php:131 mod/wall_attach.php:147
+msgid "File upload failed."
+msgstr "Caricamento del file non riuscito."
-#: mod/admin.php:1533
-msgid "Nickname of the new user."
-msgstr "Nome utente del nuovo utente."
+#: object/Item.php:106
+msgid "This entry was edited"
+msgstr "Questa voce è stata modificata"
-#: mod/admin.php:1534
-msgid "Email address of the new user."
-msgstr "Indirizzo Email del nuovo utente."
+#: object/Item.php:151
+msgid "save to folder"
+msgstr "salva nella cartella"
-#: mod/admin.php:1577
-#, php-format
-msgid "Plugin %s disabled."
-msgstr "Plugin %s disabilitato."
+#: object/Item.php:221
+msgid "I will attend"
+msgstr "Parteciperò"
-#: mod/admin.php:1581
-#, php-format
-msgid "Plugin %s enabled."
-msgstr "Plugin %s abilitato."
+#: object/Item.php:221
+msgid "I will not attend"
+msgstr "Non parteciperò"
-#: mod/admin.php:1592 mod/admin.php:1844
-msgid "Disable"
-msgstr "Disabilita"
+#: object/Item.php:221
+msgid "I might attend"
+msgstr "Forse parteciperò"
-#: mod/admin.php:1594 mod/admin.php:1846
-msgid "Enable"
-msgstr "Abilita"
+#: object/Item.php:247
+msgid "add star"
+msgstr "aggiungi a speciali"
-#: mod/admin.php:1617 mod/admin.php:1893
-msgid "Toggle"
-msgstr "Inverti"
+#: object/Item.php:248
+msgid "remove star"
+msgstr "rimuovi da speciali"
-#: mod/admin.php:1625 mod/admin.php:1902
-msgid "Author: "
-msgstr "Autore: "
+#: object/Item.php:249
+msgid "toggle star status"
+msgstr "Inverti stato preferito"
-#: mod/admin.php:1626 mod/admin.php:1903
-msgid "Maintainer: "
-msgstr "Manutentore: "
+#: object/Item.php:252
+msgid "starred"
+msgstr "preferito"
-#: mod/admin.php:1681
-msgid "Reload active plugins"
-msgstr "Ricarica i plugin attivi"
+#: object/Item.php:257
+msgid "ignore thread"
+msgstr "ignora la discussione"
-#: mod/admin.php:1686
-#, php-format
-msgid ""
-"There are currently no plugins available on your node. You can find the "
-"official plugin repository at %1$s and might find other interesting plugins "
-"in the open plugin registry at %2$s"
-msgstr "Non sono disponibili componenti aggiuntivi sul tuo nodo. Puoi trovare il repository ufficiale dei plugin su %1$s e potresti trovare altri plugin interessanti nell'open plugin repository su %2$s"
+#: object/Item.php:258
+msgid "unignore thread"
+msgstr "non ignorare la discussione"
-#: mod/admin.php:1805
-msgid "No themes found."
-msgstr "Nessun tema trovato."
+#: object/Item.php:259
+msgid "toggle ignore status"
+msgstr "inverti stato \"Ignora\""
-#: mod/admin.php:1884
-msgid "Screenshot"
-msgstr "Anteprima"
+#: object/Item.php:269
+msgid "add tag"
+msgstr "aggiungi tag"
-#: mod/admin.php:1944
-msgid "Reload active themes"
-msgstr "Ricarica i temi attivi"
+#: object/Item.php:280
+msgid "like"
+msgstr "mi piace"
-#: mod/admin.php:1949
-#, php-format
-msgid "No themes found on the system. They should be paced in %1$s"
-msgstr "Non sono stati trovati temi sul tuo sistema. Dovrebbero essere in %1$s"
+#: object/Item.php:281
+msgid "dislike"
+msgstr "non mi piace"
-#: mod/admin.php:1950
-msgid "[Experimental]"
-msgstr "[Sperimentale]"
+#: object/Item.php:284
+msgid "Share this"
+msgstr "Condividi questo"
-#: mod/admin.php:1951
-msgid "[Unsupported]"
-msgstr "[Non supportato]"
+#: object/Item.php:284
+msgid "share"
+msgstr "condividi"
-#: mod/admin.php:1975
-msgid "Log settings updated."
-msgstr "Impostazioni Log aggiornate."
+#: object/Item.php:352
+msgid "to"
+msgstr "a"
-#: mod/admin.php:2007
-msgid "PHP log currently enabled."
-msgstr "Log PHP abilitato."
+#: object/Item.php:353
+msgid "via"
+msgstr "via"
-#: mod/admin.php:2009
-msgid "PHP log currently disabled."
-msgstr "Log PHP disabilitato"
+#: object/Item.php:354
+msgid "Wall-to-Wall"
+msgstr "Da bacheca a bacheca"
-#: mod/admin.php:2018
-msgid "Clear"
-msgstr "Pulisci"
+#: object/Item.php:355
+msgid "via Wall-To-Wall:"
+msgstr "da bacheca a bacheca"
-#: mod/admin.php:2023
-msgid "Enable Debugging"
-msgstr "Abilita Debugging"
+#: object/Item.php:414
+#, php-format
+msgid "%d comment"
+msgid_plural "%d comments"
+msgstr[0] "%d commento"
+msgstr[1] "%d commenti"
-#: mod/admin.php:2024
-msgid "Log file"
-msgstr "File di Log"
+#: object/Item.php:703
+msgid "Bold"
+msgstr "Grassetto"
-#: mod/admin.php:2024
-msgid ""
-"Must be writable by web server. Relative to your Friendica top-level "
-"directory."
-msgstr "Il server web deve avere i permessi di scrittura. Relativo alla tua directory Friendica."
+#: object/Item.php:704
+msgid "Italic"
+msgstr "Corsivo"
-#: mod/admin.php:2025
-msgid "Log level"
-msgstr "Livello di Log"
+#: object/Item.php:705
+msgid "Underline"
+msgstr "Sottolineato"
-#: mod/admin.php:2028
-msgid "PHP logging"
-msgstr "Log PHP"
+#: object/Item.php:706
+msgid "Quote"
+msgstr "Citazione"
-#: mod/admin.php:2029
-msgid ""
-"To enable logging of PHP errors and warnings you can add the following to "
-"the .htconfig.php file of your installation. The filename set in the "
-"'error_log' line is relative to the friendica top-level directory and must "
-"be writeable by the web server. The option '1' for 'log_errors' and "
-"'display_errors' is to enable these options, set to '0' to disable them."
-msgstr "Per abilitare il log degli errori e degli avvisi di PHP puoi aggiungere le seguenti righe al file .htconfig.php nella tua installazione. La posizione del file impostato in 'error_log' è relativa alla directory principale della tua installazione Friendica e il server web deve avere i permessi di scrittura sul file. Il valore '1' per 'log_errors' e 'display_errors' abilita le opzioni, imposta '0' per disabilitarle."
+#: object/Item.php:707
+msgid "Code"
+msgstr "Codice"
-#: mod/admin.php:2160
-#, php-format
-msgid "Lock feature %s"
-msgstr "Blocca funzionalità %s"
+#: object/Item.php:708
+msgid "Image"
+msgstr "Immagine"
-#: mod/admin.php:2168
-msgid "Manage Additional Features"
-msgstr "Gestisci Funzionalità Aggiuntive"
+#: object/Item.php:709
+msgid "Link"
+msgstr "Link"
-#: object/Item.php:359
-msgid "via"
-msgstr "via"
+#: object/Item.php:710
+msgid "Video"
+msgstr "Video"
-#: view/theme/duepuntozero/config.php:44
+#: view/theme/duepuntozero/config.php:48
msgid "greenzero"
msgstr "greenzero"
-#: view/theme/duepuntozero/config.php:45
+#: view/theme/duepuntozero/config.php:49
msgid "purplezero"
msgstr "purplezero"
-#: view/theme/duepuntozero/config.php:46
+#: view/theme/duepuntozero/config.php:50
msgid "easterbunny"
msgstr "easterbunny"
-#: view/theme/duepuntozero/config.php:47
+#: view/theme/duepuntozero/config.php:51
msgid "darkzero"
msgstr "darkzero"
-#: view/theme/duepuntozero/config.php:48
+#: view/theme/duepuntozero/config.php:52
msgid "comix"
msgstr "comix"
-#: view/theme/duepuntozero/config.php:49
+#: view/theme/duepuntozero/config.php:53
msgid "slackr"
msgstr "slackr"
-#: view/theme/duepuntozero/config.php:64
+#: view/theme/duepuntozero/config.php:68
msgid "Variations"
msgstr "Varianti"
-#: view/theme/frio/config.php:47
-msgid "Default"
-msgstr "Default"
-
-#: view/theme/frio/config.php:59
-msgid "Note: "
-msgstr "Nota:"
-
-#: view/theme/frio/config.php:59
-msgid "Check image permissions if all users are allowed to visit the image"
-msgstr "Controlla i permessi dell'immagine se tutti gli utenti sono autorizzati a vederla"
-
-#: view/theme/frio/config.php:67
-msgid "Select scheme"
-msgstr "Seleziona schema"
-
-#: view/theme/frio/config.php:68
-msgid "Navigation bar background color"
-msgstr "Colore di sfondo barra di navigazione"
-
-#: view/theme/frio/config.php:69
-msgid "Navigation bar icon color "
-msgstr "Colore icona barra di navigazione"
-
-#: view/theme/frio/config.php:70
-msgid "Link color"
-msgstr "Colore link"
-
-#: view/theme/frio/config.php:71
-msgid "Set the background color"
-msgstr "Imposta il colore di sfondo"
-
-#: view/theme/frio/config.php:72
-msgid "Content background transparency"
-msgstr "Trasparenza sfondo contenuto"
-
-#: view/theme/frio/config.php:73
-msgid "Set the background image"
-msgstr "Imposta l'immagine di sfondo"
-
#: view/theme/frio/php/Image.php:23
msgid "Repeat the image"
msgstr "Ripeti l'immagine"
msgid "Resize to best fit and retain aspect ratio."
msgstr "Scala l'immagine alla miglior dimensione per riempire mantenendo le proporzioni."
-#: view/theme/frio/theme.php:226
+#: view/theme/frio/config.php:92
+msgid "Default"
+msgstr "Default"
+
+#: view/theme/frio/config.php:104
+msgid "Note"
+msgstr ""
+
+#: view/theme/frio/config.php:104
+msgid "Check image permissions if all users are allowed to visit the image"
+msgstr "Controlla i permessi dell'immagine se tutti gli utenti sono autorizzati a vederla"
+
+#: view/theme/frio/config.php:111
+msgid "Select scheme"
+msgstr "Seleziona schema"
+
+#: view/theme/frio/config.php:112
+msgid "Navigation bar background color"
+msgstr "Colore di sfondo barra di navigazione"
+
+#: view/theme/frio/config.php:113
+msgid "Navigation bar icon color "
+msgstr "Colore icona barra di navigazione"
+
+#: view/theme/frio/config.php:114
+msgid "Link color"
+msgstr "Colore link"
+
+#: view/theme/frio/config.php:115
+msgid "Set the background color"
+msgstr "Imposta il colore di sfondo"
+
+#: view/theme/frio/config.php:116
+msgid "Content background transparency"
+msgstr "Trasparenza sfondo contenuto"
+
+#: view/theme/frio/config.php:117
+msgid "Set the background image"
+msgstr "Imposta l'immagine di sfondo"
+
+#: view/theme/frio/theme.php:231
msgid "Guest"
msgstr "Ospite"
-#: view/theme/frio/theme.php:232
+#: view/theme/frio/theme.php:237
msgid "Visitor"
msgstr "Visitatore"
-#: view/theme/quattro/config.php:70
+#: view/theme/quattro/config.php:74
msgid "Alignment"
msgstr "Allineamento"
-#: view/theme/quattro/config.php:70
+#: view/theme/quattro/config.php:74
msgid "Left"
msgstr "Sinistra"
-#: view/theme/quattro/config.php:70
+#: view/theme/quattro/config.php:74
msgid "Center"
msgstr "Centrato"
-#: view/theme/quattro/config.php:71
+#: view/theme/quattro/config.php:75
msgid "Color scheme"
msgstr "Schema colori"
-#: view/theme/quattro/config.php:72
+#: view/theme/quattro/config.php:76
msgid "Posts font size"
msgstr "Dimensione caratteri post"
-#: view/theme/quattro/config.php:73
+#: view/theme/quattro/config.php:77
msgid "Textareas font size"
msgstr "Dimensione caratteri nelle aree di testo"
-#: view/theme/vier/config.php:69
-msgid "Comma separated list of helper forums"
-msgstr "Lista separata da virgola di forum di aiuto"
-
-#: view/theme/vier/config.php:115
-msgid "Set style"
-msgstr "Imposta stile"
-
-#: view/theme/vier/config.php:116
-msgid "Community Pages"
-msgstr "Pagine Comunitarie"
-
-#: view/theme/vier/config.php:117 view/theme/vier/theme.php:149
+#: view/theme/vier/theme.php:144 view/theme/vier/config.php:119
msgid "Community Profiles"
msgstr "Profili Comunità"
-#: view/theme/vier/config.php:118
-msgid "Help or @NewHere ?"
-msgstr "Serve aiuto? Sei nuovo?"
-
-#: view/theme/vier/config.php:119 view/theme/vier/theme.php:390
-msgid "Connect Services"
-msgstr "Servizi connessi"
+#: view/theme/vier/theme.php:174 view/theme/vier/config.php:123
+msgid "Last users"
+msgstr "Ultimi utenti"
-#: view/theme/vier/config.php:120 view/theme/vier/theme.php:197
+#: view/theme/vier/theme.php:192 view/theme/vier/config.php:122
msgid "Find Friends"
msgstr "Trova Amici"
-#: view/theme/vier/config.php:121 view/theme/vier/theme.php:179
-msgid "Last users"
-msgstr "Ultimi utenti"
-
-#: view/theme/vier/theme.php:198
+#: view/theme/vier/theme.php:193
msgid "Local Directory"
msgstr "Elenco Locale"
-#: view/theme/vier/theme.php:290
+#: view/theme/vier/theme.php:285
msgid "Quick Start"
msgstr "Quick Start"
-#: index.php:433
-msgid "toggle mobile"
-msgstr "commuta tema mobile"
+#: view/theme/vier/theme.php:385 view/theme/vier/config.php:121
+msgid "Connect Services"
+msgstr "Servizi connessi"
-#: boot.php:999
+#: view/theme/vier/config.php:71
+msgid "Comma separated list of helper forums"
+msgstr "Lista separata da virgola di forum di aiuto"
+
+#: view/theme/vier/config.php:117
+msgid "Set style"
+msgstr "Imposta stile"
+
+#: view/theme/vier/config.php:118
+msgid "Community Pages"
+msgstr "Pagine Comunitarie"
+
+#: view/theme/vier/config.php:120
+msgid "Help or @NewHere ?"
+msgstr "Serve aiuto? Sei nuovo?"
+
+#: src/App.php:522
msgid "Delete this item?"
msgstr "Cancellare questo elemento?"
-#: boot.php:1001
+#: src/App.php:524
msgid "show fewer"
msgstr "mostra di meno"
-#: boot.php:1729
+#: boot.php:738
#, php-format
msgid "Update %s failed. See error logs."
msgstr "aggiornamento %s fallito. Guarda i log di errore."
-#: boot.php:1843
+#: boot.php:850
msgid "Create a New Account"
msgstr "Crea un nuovo account"
-#: boot.php:1871
+#: boot.php:878
msgid "Password: "
msgstr "Password: "
-#: boot.php:1872
+#: boot.php:879
msgid "Remember me"
msgstr "Ricordati di me"
-#: boot.php:1875
+#: boot.php:882
msgid "Or login using OpenID: "
msgstr "O entra con OpenID:"
-#: boot.php:1881
+#: boot.php:888
msgid "Forgot your password?"
msgstr "Hai dimenticato la password?"
-#: boot.php:1884
+#: boot.php:891
msgid "Website Terms of Service"
msgstr "Condizioni di servizio del sito web "
-#: boot.php:1885
+#: boot.php:892
msgid "terms of service"
msgstr "condizioni del servizio"
-#: boot.php:1887
+#: boot.php:894
msgid "Website Privacy Policy"
msgstr "Politiche di privacy del sito"
-#: boot.php:1888
+#: boot.php:895
msgid "privacy policy"
msgstr "politiche di privacy"
+
+#: index.php:438
+msgid "toggle mobile"
+msgstr "commuta tema mobile"
return ($n != 1);;
}}
;
+$a->strings["General Features"] = "Funzionalità generali";
+$a->strings["Multiple Profiles"] = "Profili multipli";
+$a->strings["Ability to create multiple profiles"] = "Possibilità di creare profili multipli";
+$a->strings["Photo Location"] = "Località Foto";
+$a->strings["Photo metadata is normally stripped. This extracts the location (if present) prior to stripping metadata and links it to a map."] = "I metadati delle foto vengono rimossi. Questa opzione estrae la località (se presenta) prima di rimuovere i metadati e la collega a una mappa.";
+$a->strings["Export Public Calendar"] = "Esporta calendario pubblico";
+$a->strings["Ability for visitors to download the public calendar"] = "Permesso ai visitatori di scaricare il calendario pubblico";
+$a->strings["Post Composition Features"] = "Funzionalità di composizione dei post";
+$a->strings["Post Preview"] = "Anteprima dei post";
+$a->strings["Allow previewing posts and comments before publishing them"] = "Permetti di avere un'anteprima di messaggi e commenti prima di pubblicarli";
+$a->strings["Auto-mention Forums"] = "Auto-cita i Forum";
+$a->strings["Add/remove mention when a forum page is selected/deselected in ACL window."] = "Aggiunge/rimuove una menzione quando una pagina forum è selezionata/deselezionata nella finestra dei permessi.";
+$a->strings["Network Sidebar Widgets"] = "Widget della barra laterale nella pagina Rete";
+$a->strings["Search by Date"] = "Cerca per data";
+$a->strings["Ability to select posts by date ranges"] = "Permette di filtrare i post per data";
+$a->strings["List Forums"] = "Elenco forum";
+$a->strings["Enable widget to display the forums your are connected with"] = "Abilita il widget che mostra i forum ai quali sei connesso";
+$a->strings["Group Filter"] = "Filtra gruppi";
+$a->strings["Enable widget to display Network posts only from selected group"] = "Abilita il widget per filtrare i post solo per il gruppo selezionato";
+$a->strings["Network Filter"] = "Filtro reti";
+$a->strings["Enable widget to display Network posts only from selected network"] = "Abilita il widget per mostrare i post solo per la rete selezionata";
+$a->strings["Saved Searches"] = "Ricerche salvate";
+$a->strings["Save search terms for re-use"] = "Salva i termini cercati per riutilizzarli";
+$a->strings["Network Tabs"] = "Schede pagina Rete";
+$a->strings["Network Personal Tab"] = "Scheda Personali";
+$a->strings["Enable tab to display only Network posts that you've interacted on"] = "Abilita la scheda per mostrare solo i post a cui hai partecipato";
+$a->strings["Network New Tab"] = "Scheda Nuovi";
+$a->strings["Enable tab to display only new Network posts (from the last 12 hours)"] = "Abilita la scheda per mostrare solo i post nuovi (nelle ultime 12 ore)";
+$a->strings["Network Shared Links Tab"] = "Scheda Link Condivisi";
+$a->strings["Enable tab to display only Network posts with links in them"] = "Abilita la scheda per mostrare solo i post che contengono link";
+$a->strings["Post/Comment Tools"] = "Strumenti per messaggi/commenti";
+$a->strings["Multiple Deletion"] = "Eliminazione multipla";
+$a->strings["Select and delete multiple posts/comments at once"] = "Seleziona ed elimina vari messaggi e commenti in una volta sola";
+$a->strings["Edit Sent Posts"] = "Modifica i post inviati";
+$a->strings["Edit and correct posts and comments after sending"] = "Modifica e correggi messaggi e commenti dopo averli inviati";
+$a->strings["Tagging"] = "Aggiunta tag";
+$a->strings["Ability to tag existing posts"] = "Permette di aggiungere tag ai post già esistenti";
+$a->strings["Post Categories"] = "Categorie post";
+$a->strings["Add categories to your posts"] = "Aggiungi categorie ai tuoi post";
+$a->strings["Saved Folders"] = "Cartelle Salvate";
+$a->strings["Ability to file posts under folders"] = "Permette di archiviare i post in cartelle";
+$a->strings["Dislike Posts"] = "Non mi piace";
+$a->strings["Ability to dislike posts/comments"] = "Permetti di inviare \"non mi piace\" ai messaggi";
+$a->strings["Star Posts"] = "Post preferiti";
+$a->strings["Ability to mark special posts with a star indicator"] = "Permette di segnare i post preferiti con una stella";
+$a->strings["Mute Post Notifications"] = "Silenzia le notifiche di nuovi post";
+$a->strings["Ability to mute notifications for a thread"] = "Permette di silenziare le notifiche di nuovi post in una discussione";
+$a->strings["Advanced Profile Settings"] = "Impostazioni Avanzate Profilo";
+$a->strings["Show visitors public community forums at the Advanced Profile Page"] = "Mostra ai visitatori i forum nella pagina Profilo Avanzato";
+$a->strings["Miscellaneous"] = "Varie";
+$a->strings["Birthday:"] = "Compleanno:";
+$a->strings["Age: "] = "Età : ";
+$a->strings["YYYY-MM-DD or MM-DD"] = "AAAA-MM-GG o MM-GG";
+$a->strings["never"] = "mai";
+$a->strings["less than a second ago"] = "meno di un secondo fa";
+$a->strings["year"] = "anno";
+$a->strings["years"] = "anni";
+$a->strings["month"] = "mese";
+$a->strings["months"] = "mesi";
+$a->strings["week"] = "settimana";
+$a->strings["weeks"] = "settimane";
+$a->strings["day"] = "giorno";
+$a->strings["days"] = "giorni";
+$a->strings["hour"] = "ora";
+$a->strings["hours"] = "ore";
+$a->strings["minute"] = "minuto";
+$a->strings["minutes"] = "minuti";
+$a->strings["second"] = "secondo";
+$a->strings["seconds"] = "secondi";
+$a->strings["%1\$d %2\$s ago"] = "%1\$d %2\$s fa";
+$a->strings["%s's birthday"] = "Compleanno di %s";
+$a->strings["Happy Birthday %s"] = "Buon compleanno %s";
+$a->strings["Male"] = "Maschio";
+$a->strings["Female"] = "Femmina";
+$a->strings["Currently Male"] = "Al momento maschio";
+$a->strings["Currently Female"] = "Al momento femmina";
+$a->strings["Mostly Male"] = "Prevalentemente maschio";
+$a->strings["Mostly Female"] = "Prevalentemente femmina";
+$a->strings["Transgender"] = "Transgender";
+$a->strings["Intersex"] = "Intersex";
+$a->strings["Transsexual"] = "Transessuale";
+$a->strings["Hermaphrodite"] = "Ermafrodito";
+$a->strings["Neuter"] = "Neutro";
+$a->strings["Non-specific"] = "Non specificato";
+$a->strings["Other"] = "Altro";
+$a->strings["Undecided"] = array(
+ 0 => "Indeciso",
+ 1 => "Indecisi",
+);
+$a->strings["Males"] = "Maschi";
+$a->strings["Females"] = "Femmine";
+$a->strings["Gay"] = "Gay";
+$a->strings["Lesbian"] = "Lesbica";
+$a->strings["No Preference"] = "Nessuna preferenza";
+$a->strings["Bisexual"] = "Bisessuale";
+$a->strings["Autosexual"] = "Autosessuale";
+$a->strings["Abstinent"] = "Astinente";
+$a->strings["Virgin"] = "Vergine";
+$a->strings["Deviant"] = "Deviato";
+$a->strings["Fetish"] = "Fetish";
+$a->strings["Oodles"] = "Un sacco";
+$a->strings["Nonsexual"] = "Asessuato";
+$a->strings["Single"] = "Single";
+$a->strings["Lonely"] = "Solitario";
+$a->strings["Available"] = "Disponibile";
+$a->strings["Unavailable"] = "Non disponibile";
+$a->strings["Has crush"] = "è cotto/a";
+$a->strings["Infatuated"] = "infatuato/a";
+$a->strings["Dating"] = "Disponibile a un incontro";
+$a->strings["Unfaithful"] = "Infedele";
+$a->strings["Sex Addict"] = "Sesso-dipendente";
+$a->strings["Friends"] = "Amici";
+$a->strings["Friends/Benefits"] = "Amici con benefici";
+$a->strings["Casual"] = "Casual";
+$a->strings["Engaged"] = "Impegnato";
+$a->strings["Married"] = "Sposato";
+$a->strings["Imaginarily married"] = "immaginariamente sposato/a";
+$a->strings["Partners"] = "Partners";
+$a->strings["Cohabiting"] = "Coinquilino";
+$a->strings["Common law"] = "diritto comune";
+$a->strings["Happy"] = "Felice";
+$a->strings["Not looking"] = "Non guarda";
+$a->strings["Swinger"] = "Scambista";
+$a->strings["Betrayed"] = "Tradito";
+$a->strings["Separated"] = "Separato";
+$a->strings["Unstable"] = "Instabile";
+$a->strings["Divorced"] = "Divorziato";
+$a->strings["Imaginarily divorced"] = "immaginariamente divorziato/a";
+$a->strings["Widowed"] = "Vedovo";
+$a->strings["Uncertain"] = "Incerto";
+$a->strings["It's complicated"] = "E' complicato";
+$a->strings["Don't care"] = "Non interessa";
+$a->strings["Ask me"] = "Chiedimelo";
+$a->strings["A deleted group with this name was revived. Existing item permissions <strong>may</strong> apply to this group and any future members. If this is not what you intended, please create another group with a different name."] = "Un gruppo eliminato con questo nome è stato ricreato. I permessi esistenti su un elemento <strong>possono</strong> essere applicati a questo gruppo e tutti i membri futuri. Se questo non è ciò che si intende, si prega di creare un altro gruppo con un nome diverso.";
+$a->strings["Default privacy group for new contacts"] = "Gruppo predefinito per i nuovi contatti";
+$a->strings["Everybody"] = "Tutti";
+$a->strings["edit"] = "modifica";
+$a->strings["Groups"] = "Gruppi";
+$a->strings["Edit groups"] = "Modifica gruppi";
+$a->strings["Edit group"] = "Modifica gruppo";
+$a->strings["Create a new group"] = "Crea un nuovo gruppo";
+$a->strings["Group Name: "] = "Nome del gruppo:";
+$a->strings["Contacts not in any group"] = "Contatti in nessun gruppo.";
+$a->strings["add"] = "aggiungi";
$a->strings["Forums"] = "Forum";
$a->strings["External link to forum"] = "Link esterno al forum";
$a->strings["show more"] = "mostra di più";
$a->strings["Friend Suggestion"] = "Amico suggerito";
$a->strings["Friend/Connect Request"] = "Richiesta amicizia/connessione";
$a->strings["New Follower"] = "Qualcuno inizia a seguirti";
-$a->strings["Wall Photos"] = "Foto della bacheca";
-$a->strings["(no subject)"] = "(nessun oggetto)";
+$a->strings["Logged out."] = "Uscita effettuata.";
+$a->strings["Login failed."] = "Accesso fallito.";
+$a->strings["We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID."] = "Abbiamo incontrato un problema mentre contattavamo il server OpenID che ci hai fornito. Controlla di averlo scritto giusto.";
+$a->strings["The error message was:"] = "Il messaggio riportato era:";
+$a->strings["l F d, Y \\@ g:i A"] = "l d F Y \\@ G:i";
+$a->strings["Starts:"] = "Inizia:";
+$a->strings["Finishes:"] = "Finisce:";
+$a->strings["Location:"] = "Posizione:";
+$a->strings["Add New Contact"] = "Aggiungi nuovo contatto";
+$a->strings["Enter address or web location"] = "Inserisci posizione o indirizzo web";
+$a->strings["Example: bob@example.com, http://example.com/barbara"] = "Esempio: bob@example.com, http://example.com/barbara";
+$a->strings["Connect"] = "Connetti";
+$a->strings["%d invitation available"] = array(
+ 0 => "%d invito disponibile",
+ 1 => "%d inviti disponibili",
+);
+$a->strings["Find People"] = "Trova persone";
+$a->strings["Enter name or interest"] = "Inserisci un nome o un interesse";
+$a->strings["Connect/Follow"] = "Connetti/segui";
+$a->strings["Examples: Robert Morgenstein, Fishing"] = "Esempi: Mario Rossi, Pesca";
+$a->strings["Find"] = "Trova";
+$a->strings["Friend Suggestions"] = "Contatti suggeriti";
+$a->strings["Similar Interests"] = "Interessi simili";
+$a->strings["Random Profile"] = "Profilo causale";
+$a->strings["Invite Friends"] = "Invita amici";
+$a->strings["View Global Directory"] = "Vedi Directory Globale";
+$a->strings["Networks"] = "Reti";
+$a->strings["All Networks"] = "Tutte le Reti";
+$a->strings["Everything"] = "Tutto";
+$a->strings["Categories"] = "Categorie";
+$a->strings["%d contact in common"] = array(
+ 0 => "%d contatto in comune",
+ 1 => "%d contatti in comune",
+);
+$a->strings["Friendica Notification"] = "Notifica Friendica";
+$a->strings["Thank You,"] = "Grazie,";
+$a->strings["%s Administrator"] = "Amministratore %s";
+$a->strings["%1\$s, %2\$s Administrator"] = "%1\$s, amministratore di %2\$s";
$a->strings["noreply"] = "nessuna risposta";
-$a->strings["%1\$s likes %2\$s's %3\$s"] = "A %1\$s piace %3\$s di %2\$s";
-$a->strings["%1\$s doesn't like %2\$s's %3\$s"] = "A %1\$s non piace %3\$s di %2\$s";
-$a->strings["%1\$s is attending %2\$s's %3\$s"] = "%1\$s parteciperà a %3\$s di %2\$s";
-$a->strings["%1\$s is not attending %2\$s's %3\$s"] = "%1\$s non parteciperà a %3\$s di %2\$s";
-$a->strings["%1\$s may attend %2\$s's %3\$s"] = "%1\$s forse parteciperà a %3\$s di %2\$s";
-$a->strings["photo"] = "foto";
-$a->strings["status"] = "stato";
-$a->strings["event"] = "l'evento";
-$a->strings["[no subject]"] = "[nessun oggetto]";
+$a->strings["%s <!item_type!>"] = "%s <!item_type!>";
+$a->strings["[Friendica:Notify] New mail received at %s"] = "[Friendica:Notifica] Nuovo messaggio privato ricevuto su %s";
+$a->strings["%1\$s sent you a new private message at %2\$s."] = "%1\$s ti ha inviato un nuovo messaggio privato su %2\$s.";
+$a->strings["%1\$s sent you %2\$s."] = "%1\$s ti ha inviato %2\$s";
+$a->strings["a private message"] = "un messaggio privato";
+$a->strings["Please visit %s to view and/or reply to your private messages."] = "Visita %s per vedere e/o rispondere ai tuoi messaggi privati.";
+$a->strings["%1\$s commented on [url=%2\$s]a %3\$s[/url]"] = "%1\$s ha commentato [url=%2\$s]%3\$s[/url]";
+$a->strings["%1\$s commented on [url=%2\$s]%3\$s's %4\$s[/url]"] = "%1\$s ha commentato [url=%2\$s]%4\$s di %3\$s[/url]";
+$a->strings["%1\$s commented on [url=%2\$s]your %3\$s[/url]"] = "%1\$s ha commentato un [url=%2\$s]tuo %3\$s[/url]";
+$a->strings["[Friendica:Notify] Comment to conversation #%1\$d by %2\$s"] = "[Friendica:Notifica] Commento di %2\$s alla conversazione #%1\$d";
+$a->strings["%s commented on an item/conversation you have been following."] = "%s ha commentato un elemento che stavi seguendo.";
+$a->strings["Please visit %s to view and/or reply to the conversation."] = "Visita %s per vedere e/o commentare la conversazione";
+$a->strings["[Friendica:Notify] %s posted to your profile wall"] = "[Friendica:Notifica] %s ha scritto sulla tua bacheca";
+$a->strings["%1\$s posted to your profile wall at %2\$s"] = "%1\$s ha scritto sulla tua bacheca su %2\$s";
+$a->strings["%1\$s posted to [url=%2\$s]your wall[/url]"] = "%1\$s ha inviato un messaggio sulla [url=%2\$s]tua bacheca[/url]";
+$a->strings["[Friendica:Notify] %s tagged you"] = "[Friendica:Notifica] %s ti ha taggato";
+$a->strings["%1\$s tagged you at %2\$s"] = "%1\$s ti ha taggato su %2\$s";
+$a->strings["%1\$s [url=%2\$s]tagged you[/url]."] = "%1\$s [url=%2\$s]ti ha taggato[/url].";
+$a->strings["[Friendica:Notify] %s shared a new post"] = "[Friendica:Notifica] %s ha condiviso un nuovo messaggio";
+$a->strings["%1\$s shared a new post at %2\$s"] = "%1\$s ha condiviso un nuovo messaggio su %2\$s";
+$a->strings["%1\$s [url=%2\$s]shared a post[/url]."] = "%1\$s [url=%2\$s]ha condiviso un messaggio[/url].";
+$a->strings["[Friendica:Notify] %1\$s poked you"] = "[Friendica:Notifica] %1\$s ti ha stuzzicato";
+$a->strings["%1\$s poked you at %2\$s"] = "%1\$s ti ha stuzzicato su %2\$s";
+$a->strings["%1\$s [url=%2\$s]poked you[/url]."] = "%1\$s [url=%2\$s]ti ha stuzzicato[/url].";
+$a->strings["[Friendica:Notify] %s tagged your post"] = "[Friendica:Notifica] %s ha taggato un tuo messaggio";
+$a->strings["%1\$s tagged your post at %2\$s"] = "%1\$s ha taggato il tuo post su %2\$s";
+$a->strings["%1\$s tagged [url=%2\$s]your post[/url]"] = "%1\$s ha taggato [url=%2\$s]il tuo post[/url]";
+$a->strings["[Friendica:Notify] Introduction received"] = "[Friendica:Notifica] Hai ricevuto una presentazione";
+$a->strings["You've received an introduction from '%1\$s' at %2\$s"] = "Hai ricevuto un'introduzione da '%1\$s' su %2\$s";
+$a->strings["You've received [url=%1\$s]an introduction[/url] from %2\$s."] = "Hai ricevuto [url=%1\$s]un'introduzione[/url] da %2\$s.";
+$a->strings["You may visit their profile at %s"] = "Puoi visitare il suo profilo presso %s";
+$a->strings["Please visit %s to approve or reject the introduction."] = "Visita %s per approvare o rifiutare la presentazione.";
+$a->strings["[Friendica:Notify] A new person is sharing with you"] = "[Friendica:Notifica] Una nuova persona sta condividendo con te";
+$a->strings["%1\$s is sharing with you at %2\$s"] = "%1\$s sta condividendo con te su %2\$s";
+$a->strings["[Friendica:Notify] You have a new follower"] = "[Friendica:Notifica] Una nuova persona ti segue";
+$a->strings["You have a new follower at %2\$s : %1\$s"] = "Un nuovo utente ha iniziato a seguirti su %2\$s : %1\$s";
+$a->strings["[Friendica:Notify] Friend suggestion received"] = "[Friendica:Notifica] Hai ricevuto un suggerimento di amicizia";
+$a->strings["You've received a friend suggestion from '%1\$s' at %2\$s"] = "Hai ricevuto un suggerimento di amicizia da '%1\$s' su %2\$s";
+$a->strings["You've received [url=%1\$s]a friend suggestion[/url] for %2\$s from %3\$s."] = "Hai ricevuto [url=%1\$s]un suggerimento di amicizia[/url] per %2\$s su %3\$s";
+$a->strings["Name:"] = "Nome:";
+$a->strings["Photo:"] = "Foto:";
+$a->strings["Please visit %s to approve or reject the suggestion."] = "Visita %s per approvare o rifiutare il suggerimento.";
+$a->strings["[Friendica:Notify] Connection accepted"] = "[Friendica:Notifica] Connessione accettata";
+$a->strings["'%1\$s' has accepted your connection request at %2\$s"] = "'%1\$s' ha accettato la tua richiesta di connessione su %2\$s";
+$a->strings["%2\$s has accepted your [url=%1\$s]connection request[/url]."] = "%2\$s ha accettato la tua [url=%1\$s]richiesta di connessione[/url]";
+$a->strings["You are now mutual friends and may exchange status updates, photos, and email without restriction."] = "Ora siete amici reciproci e potete scambiarvi aggiornamenti di stato, foto e messaggi privati senza restrizioni.";
+$a->strings["Please visit %s if you wish to make any changes to this relationship."] = "Visita %s se vuoi modificare questa relazione.";
+$a->strings["'%1\$s' has chosen to accept you a \"fan\", which restricts some forms of communication - such as private messaging and some profile interactions. If this is a celebrity or community page, these settings were applied automatically."] = "'%1\$s' ha scelto di accettarti come \"fan\", il che limita alcune forme di comunicazione, come i messaggi privati, e alcune possibilità di interazione col profilo. Se è una pagina di una comunità o di una celebrità, queste impostazioni sono state applicate automaticamente.";
+$a->strings["'%1\$s' may choose to extend this into a two-way or more permissive relationship in the future."] = "'%1\$s' può scegliere di estendere questa relazione in una relazione più permissiva in futuro.";
+$a->strings["Please visit %s if you wish to make any changes to this relationship."] = "Visita %s se desideri modificare questo collegamento.";
+$a->strings["[Friendica System:Notify] registration request"] = "[Friendica System:Notifica] richiesta di registrazione";
+$a->strings["You've received a registration request from '%1\$s' at %2\$s"] = "Hai ricevuto una richiesta di registrazione da '%1\$s' su %2\$s";
+$a->strings["You've received a [url=%1\$s]registration request[/url] from %2\$s."] = "Hai ricevuto una [url=%1\$s]richiesta di registrazione[/url] da %2\$s.";
+$a->strings["Full Name:\t%1\$s\\nSite Location:\t%2\$s\\nLogin Name:\t%3\$s (%4\$s)"] = "Nome completo: %1\$s\nIndirizzo del sito: %2\$s\nNome utente: %3\$s (%4\$s)";
+$a->strings["Please visit %s to approve or reject the request."] = "Visita %s per approvare o rifiutare la richiesta.";
+$a->strings["Embedded content"] = "Contenuto incorporato";
+$a->strings["Embedding disabled"] = "Embed disabilitato";
+$a->strings["Welcome "] = "Ciao";
+$a->strings["Please upload a profile photo."] = "Carica una foto per il profilo.";
+$a->strings["Welcome back "] = "Ciao ";
+$a->strings["The form security token was not correct. This probably happened because the form has been opened for too long (>3 hours) before submitting it."] = "Il token di sicurezza della form non era corretto. Probabilmente la form è rimasta aperta troppo a lungo (più di tre ore) prima di inviarla.";
+$a->strings["Contact Photos"] = "Foto dei contatti";
$a->strings["Nothing new here"] = "Niente di nuovo qui";
$a->strings["Clear notifications"] = "Pulisci le notifiche";
$a->strings["@name, !forum, #tags, content"] = "@nome, !forum, #tag, contenuto";
$a->strings["Site setup and configuration"] = "Configurazione del sito";
$a->strings["Navigation"] = "Navigazione";
$a->strings["Site map"] = "Mappa del sito";
-$a->strings["Click here to upgrade."] = "Clicca qui per aggiornare.";
-$a->strings["This action exceeds the limits set by your subscription plan."] = "Questa azione eccede i limiti del tuo piano di sottoscrizione.";
-$a->strings["This action is not available under your subscription plan."] = "Questa azione non è disponibile nel tuo piano di sottoscrizione.";
-$a->strings["Male"] = "Maschio";
-$a->strings["Female"] = "Femmina";
-$a->strings["Currently Male"] = "Al momento maschio";
-$a->strings["Currently Female"] = "Al momento femmina";
-$a->strings["Mostly Male"] = "Prevalentemente maschio";
-$a->strings["Mostly Female"] = "Prevalentemente femmina";
-$a->strings["Transgender"] = "Transgender";
-$a->strings["Intersex"] = "Intersex";
-$a->strings["Transsexual"] = "Transessuale";
-$a->strings["Hermaphrodite"] = "Ermafrodito";
-$a->strings["Neuter"] = "Neutro";
-$a->strings["Non-specific"] = "Non specificato";
-$a->strings["Other"] = "Altro";
-$a->strings["Undecided"] = array(
- 0 => "Indeciso",
- 1 => "Indecisi",
-);
-$a->strings["Males"] = "Maschi";
-$a->strings["Females"] = "Femmine";
-$a->strings["Gay"] = "Gay";
-$a->strings["Lesbian"] = "Lesbica";
-$a->strings["No Preference"] = "Nessuna preferenza";
-$a->strings["Bisexual"] = "Bisessuale";
-$a->strings["Autosexual"] = "Autosessuale";
-$a->strings["Abstinent"] = "Astinente";
-$a->strings["Virgin"] = "Vergine";
-$a->strings["Deviant"] = "Deviato";
-$a->strings["Fetish"] = "Fetish";
-$a->strings["Oodles"] = "Un sacco";
-$a->strings["Nonsexual"] = "Asessuato";
-$a->strings["Single"] = "Single";
-$a->strings["Lonely"] = "Solitario";
-$a->strings["Available"] = "Disponibile";
-$a->strings["Unavailable"] = "Non disponibile";
-$a->strings["Has crush"] = "è cotto/a";
-$a->strings["Infatuated"] = "infatuato/a";
-$a->strings["Dating"] = "Disponibile a un incontro";
-$a->strings["Unfaithful"] = "Infedele";
-$a->strings["Sex Addict"] = "Sesso-dipendente";
-$a->strings["Friends"] = "Amici";
-$a->strings["Friends/Benefits"] = "Amici con benefici";
-$a->strings["Casual"] = "Casual";
-$a->strings["Engaged"] = "Impegnato";
-$a->strings["Married"] = "Sposato";
-$a->strings["Imaginarily married"] = "immaginariamente sposato/a";
-$a->strings["Partners"] = "Partners";
-$a->strings["Cohabiting"] = "Coinquilino";
-$a->strings["Common law"] = "diritto comune";
-$a->strings["Happy"] = "Felice";
-$a->strings["Not looking"] = "Non guarda";
-$a->strings["Swinger"] = "Scambista";
-$a->strings["Betrayed"] = "Tradito";
-$a->strings["Separated"] = "Separato";
-$a->strings["Unstable"] = "Instabile";
-$a->strings["Divorced"] = "Divorziato";
-$a->strings["Imaginarily divorced"] = "immaginariamente divorziato/a";
-$a->strings["Widowed"] = "Vedovo";
-$a->strings["Uncertain"] = "Incerto";
-$a->strings["It's complicated"] = "E' complicato";
-$a->strings["Don't care"] = "Non interessa";
-$a->strings["Ask me"] = "Chiedimelo";
-$a->strings["Welcome "] = "Ciao";
-$a->strings["Please upload a profile photo."] = "Carica una foto per il profilo.";
-$a->strings["Welcome back "] = "Ciao ";
-$a->strings["The form security token was not correct. This probably happened because the form has been opened for too long (>3 hours) before submitting it."] = "Il token di sicurezza della form non era corretto. Probabilmente la form è rimasta aperta troppo a lungo (più di tre ore) prima di inviarla.";
-$a->strings["Error decoding account file"] = "Errore decodificando il file account";
-$a->strings["Error! No version data in file! This is not a Friendica account file?"] = "Errore! Nessuna informazione di versione nel file! Potrebbe non essere un file account di Friendica?";
-$a->strings["Error! Cannot check nickname"] = "Errore! Non posso controllare il nickname";
-$a->strings["User '%s' already exists on this server!"] = "L'utente '%s' esiste già su questo server!";
-$a->strings["User creation error"] = "Errore creando l'utente";
-$a->strings["User profile creation error"] = "Errore creando il profilo dell'utente";
-$a->strings["%d contact not imported"] = array(
- 0 => "%d contatto non importato",
- 1 => "%d contatti non importati",
-);
-$a->strings["Done. You can now login with your username and password"] = "Fatto. Ora puoi entrare con il tuo nome utente e la tua password";
$a->strings["View Profile"] = "Visualizza profilo";
-$a->strings["Connect/Follow"] = "Connetti/segui";
$a->strings["View Status"] = "Visualizza stato";
$a->strings["View Photos"] = "Visualizza foto";
$a->strings["Network Posts"] = "Post della Rete";
$a->strings["Organisation"] = "Organizzazione";
$a->strings["News"] = "Notizie";
$a->strings["Forum"] = "Forum";
+$a->strings["Wall Photos"] = "Foto della bacheca";
$a->strings["Post to Email"] = "Invia a email";
$a->strings["Connectors disabled, since \"%s\" is enabled."] = "Connettore disabilitato, dato che \"%s\" è abilitato.";
$a->strings["Hide your profile details from unknown viewers?"] = "Nascondi i dettagli del tuo profilo ai visitatori sconosciuti?";
$a->strings["Daily posting limit of %d posts reached. The post was rejected."] = "Limite giornaliero di %d messaggi raggiunto. Il messaggio è stato rifiutato";
$a->strings["Weekly posting limit of %d posts reached. The post was rejected."] = "Limite settimanale di %d messaggi raggiunto. Il messaggio è stato rifiutato";
$a->strings["Monthly posting limit of %d posts reached. The post was rejected."] = "Limite mensile di %d messaggi raggiunto. Il messaggio è stato rifiutato";
-$a->strings["Logged out."] = "Uscita effettuata.";
-$a->strings["Login failed."] = "Accesso fallito.";
-$a->strings["We encountered a problem while logging in with the OpenID you provided. Please check the correct spelling of the ID."] = "Abbiamo incontrato un problema mentre contattavamo il server OpenID che ci hai fornito. Controlla di averlo scritto giusto.";
-$a->strings["The error message was:"] = "Il messaggio riportato era:";
-$a->strings["l F d, Y \\@ g:i A"] = "l d F Y \\@ G:i";
-$a->strings["Starts:"] = "Inizia:";
-$a->strings["Finishes:"] = "Finisce:";
-$a->strings["Location:"] = "Posizione:";
+$a->strings["Profile Photos"] = "Foto del profilo";
$a->strings["Image/photo"] = "Immagine/foto";
$a->strings["<a href=\"%1\$s\" target=\"_blank\">%2\$s</a> %3\$s"] = "<a href=\"%1\$s\" target=\"_blank\">%2\$s</a> %3\$s";
$a->strings["$1 wrote:"] = "$1 ha scritto:";
$a->strings["GNU Social Connector"] = "Connettore GNU Social";
$a->strings["pnut"] = "pnut";
$a->strings["App.net"] = "App.net";
-$a->strings["Add New Contact"] = "Aggiungi nuovo contatto";
-$a->strings["Enter address or web location"] = "Inserisci posizione o indirizzo web";
-$a->strings["Example: bob@example.com, http://example.com/barbara"] = "Esempio: bob@example.com, http://example.com/barbara";
-$a->strings["Connect"] = "Connetti";
-$a->strings["%d invitation available"] = array(
- 0 => "%d invito disponibile",
- 1 => "%d inviti disponibili",
-);
-$a->strings["Find People"] = "Trova persone";
-$a->strings["Enter name or interest"] = "Inserisci un nome o un interesse";
-$a->strings["Examples: Robert Morgenstein, Fishing"] = "Esempi: Mario Rossi, Pesca";
-$a->strings["Find"] = "Trova";
-$a->strings["Friend Suggestions"] = "Contatti suggeriti";
-$a->strings["Similar Interests"] = "Interessi simili";
-$a->strings["Random Profile"] = "Profilo causale";
-$a->strings["Invite Friends"] = "Invita amici";
-$a->strings["Networks"] = "Reti";
-$a->strings["All Networks"] = "Tutte le Reti";
-$a->strings["Saved Folders"] = "Cartelle Salvate";
-$a->strings["Everything"] = "Tutto";
-$a->strings["Categories"] = "Categorie";
-$a->strings["%d contact in common"] = array(
- 0 => "%d contatto in comune",
- 1 => "%d contatti in comune",
-);
+$a->strings["event"] = "l'evento";
+$a->strings["status"] = "stato";
+$a->strings["photo"] = "foto";
+$a->strings["%1\$s likes %2\$s's %3\$s"] = "A %1\$s piace %3\$s di %2\$s";
+$a->strings["%1\$s doesn't like %2\$s's %3\$s"] = "A %1\$s non piace %3\$s di %2\$s";
$a->strings["%1\$s attends %2\$s's %3\$s"] = "%1\$s partecipa a %3\$s di %2\$s";
$a->strings["%1\$s doesn't attend %2\$s's %3\$s"] = "%1\$s non partecipa a %3\$s di %2\$s";
$a->strings["%1\$s attends maybe %2\$s's %3\$s"] = "%1\$s forse partecipa a %3\$s di %2\$s";
0 => "Non partecipa",
1 => "Non partecipano",
);
-$a->strings["Miscellaneous"] = "Varie";
-$a->strings["Birthday:"] = "Compleanno:";
-$a->strings["Age: "] = "Età : ";
-$a->strings["YYYY-MM-DD or MM-DD"] = "AAAA-MM-GG o MM-GG";
-$a->strings["never"] = "mai";
-$a->strings["less than a second ago"] = "meno di un secondo fa";
-$a->strings["year"] = "anno";
-$a->strings["years"] = "anni";
-$a->strings["month"] = "mese";
-$a->strings["months"] = "mesi";
-$a->strings["week"] = "settimana";
-$a->strings["weeks"] = "settimane";
-$a->strings["day"] = "giorno";
-$a->strings["days"] = "giorni";
-$a->strings["hour"] = "ora";
-$a->strings["hours"] = "ore";
-$a->strings["minute"] = "minuto";
-$a->strings["minutes"] = "minuti";
-$a->strings["second"] = "secondo";
-$a->strings["seconds"] = "secondi";
-$a->strings["%1\$d %2\$s ago"] = "%1\$d %2\$s fa";
-$a->strings["%s's birthday"] = "Compleanno di %s";
-$a->strings["Happy Birthday %s"] = "Buon compleanno %s";
$a->strings["Cannot locate DNS info for database server '%s'"] = "Non trovo le informazioni DNS per il database server '%s'";
-$a->strings["Friendica Notification"] = "Notifica Friendica";
-$a->strings["Thank You,"] = "Grazie,";
-$a->strings["%s Administrator"] = "Amministratore %s";
-$a->strings["%1\$s, %2\$s Administrator"] = "%1\$s, amministratore di %2\$s";
-$a->strings["%s <!item_type!>"] = "%s <!item_type!>";
-$a->strings["[Friendica:Notify] New mail received at %s"] = "[Friendica:Notifica] Nuovo messaggio privato ricevuto su %s";
-$a->strings["%1\$s sent you a new private message at %2\$s."] = "%1\$s ti ha inviato un nuovo messaggio privato su %2\$s.";
-$a->strings["%1\$s sent you %2\$s."] = "%1\$s ti ha inviato %2\$s";
-$a->strings["a private message"] = "un messaggio privato";
-$a->strings["Please visit %s to view and/or reply to your private messages."] = "Visita %s per vedere e/o rispondere ai tuoi messaggi privati.";
-$a->strings["%1\$s commented on [url=%2\$s]a %3\$s[/url]"] = "%1\$s ha commentato [url=%2\$s]%3\$s[/url]";
-$a->strings["%1\$s commented on [url=%2\$s]%3\$s's %4\$s[/url]"] = "%1\$s ha commentato [url=%2\$s]%4\$s di %3\$s[/url]";
-$a->strings["%1\$s commented on [url=%2\$s]your %3\$s[/url]"] = "%1\$s ha commentato un [url=%2\$s]tuo %3\$s[/url]";
-$a->strings["[Friendica:Notify] Comment to conversation #%1\$d by %2\$s"] = "[Friendica:Notifica] Commento di %2\$s alla conversazione #%1\$d";
-$a->strings["%s commented on an item/conversation you have been following."] = "%s ha commentato un elemento che stavi seguendo.";
-$a->strings["Please visit %s to view and/or reply to the conversation."] = "Visita %s per vedere e/o commentare la conversazione";
-$a->strings["[Friendica:Notify] %s posted to your profile wall"] = "[Friendica:Notifica] %s ha scritto sulla tua bacheca";
-$a->strings["%1\$s posted to your profile wall at %2\$s"] = "%1\$s ha scritto sulla tua bacheca su %2\$s";
-$a->strings["%1\$s posted to [url=%2\$s]your wall[/url]"] = "%1\$s ha inviato un messaggio sulla [url=%2\$s]tua bacheca[/url]";
-$a->strings["[Friendica:Notify] %s tagged you"] = "[Friendica:Notifica] %s ti ha taggato";
-$a->strings["%1\$s tagged you at %2\$s"] = "%1\$s ti ha taggato su %2\$s";
-$a->strings["%1\$s [url=%2\$s]tagged you[/url]."] = "%1\$s [url=%2\$s]ti ha taggato[/url].";
-$a->strings["[Friendica:Notify] %s shared a new post"] = "[Friendica:Notifica] %s ha condiviso un nuovo messaggio";
-$a->strings["%1\$s shared a new post at %2\$s"] = "%1\$s ha condiviso un nuovo messaggio su %2\$s";
-$a->strings["%1\$s [url=%2\$s]shared a post[/url]."] = "%1\$s [url=%2\$s]ha condiviso un messaggio[/url].";
-$a->strings["[Friendica:Notify] %1\$s poked you"] = "[Friendica:Notifica] %1\$s ti ha stuzzicato";
-$a->strings["%1\$s poked you at %2\$s"] = "%1\$s ti ha stuzzicato su %2\$s";
-$a->strings["%1\$s [url=%2\$s]poked you[/url]."] = "%1\$s [url=%2\$s]ti ha stuzzicato[/url].";
-$a->strings["[Friendica:Notify] %s tagged your post"] = "[Friendica:Notifica] %s ha taggato un tuo messaggio";
-$a->strings["%1\$s tagged your post at %2\$s"] = "%1\$s ha taggato il tuo post su %2\$s";
-$a->strings["%1\$s tagged [url=%2\$s]your post[/url]"] = "%1\$s ha taggato [url=%2\$s]il tuo post[/url]";
-$a->strings["[Friendica:Notify] Introduction received"] = "[Friendica:Notifica] Hai ricevuto una presentazione";
-$a->strings["You've received an introduction from '%1\$s' at %2\$s"] = "Hai ricevuto un'introduzione da '%1\$s' su %2\$s";
-$a->strings["You've received [url=%1\$s]an introduction[/url] from %2\$s."] = "Hai ricevuto [url=%1\$s]un'introduzione[/url] da %2\$s.";
-$a->strings["You may visit their profile at %s"] = "Puoi visitare il suo profilo presso %s";
-$a->strings["Please visit %s to approve or reject the introduction."] = "Visita %s per approvare o rifiutare la presentazione.";
-$a->strings["[Friendica:Notify] A new person is sharing with you"] = "[Friendica:Notifica] Una nuova persona sta condividendo con te";
-$a->strings["%1\$s is sharing with you at %2\$s"] = "%1\$s sta condividendo con te su %2\$s";
-$a->strings["[Friendica:Notify] You have a new follower"] = "[Friendica:Notifica] Una nuova persona ti segue";
-$a->strings["You have a new follower at %2\$s : %1\$s"] = "Un nuovo utente ha iniziato a seguirti su %2\$s : %1\$s";
-$a->strings["[Friendica:Notify] Friend suggestion received"] = "[Friendica:Notifica] Hai ricevuto un suggerimento di amicizia";
-$a->strings["You've received a friend suggestion from '%1\$s' at %2\$s"] = "Hai ricevuto un suggerimento di amicizia da '%1\$s' su %2\$s";
-$a->strings["You've received [url=%1\$s]a friend suggestion[/url] for %2\$s from %3\$s."] = "Hai ricevuto [url=%1\$s]un suggerimento di amicizia[/url] per %2\$s su %3\$s";
-$a->strings["Name:"] = "Nome:";
-$a->strings["Photo:"] = "Foto:";
-$a->strings["Please visit %s to approve or reject the suggestion."] = "Visita %s per approvare o rifiutare il suggerimento.";
-$a->strings["[Friendica:Notify] Connection accepted"] = "[Friendica:Notifica] Connessione accettata";
-$a->strings["'%1\$s' has accepted your connection request at %2\$s"] = "'%1\$s' ha accettato la tua richiesta di connessione su %2\$s";
-$a->strings["%2\$s has accepted your [url=%1\$s]connection request[/url]."] = "%2\$s ha accettato la tua [url=%1\$s]richiesta di connessione[/url]";
-$a->strings["You are now mutual friends and may exchange status updates, photos, and email without restriction."] = "Ora siete amici reciproci e potete scambiarvi aggiornamenti di stato, foto e messaggi privati senza restrizioni.";
-$a->strings["Please visit %s if you wish to make any changes to this relationship."] = "Visita %s se vuoi modificare questa relazione.";
-$a->strings["'%1\$s' has chosen to accept you a \"fan\", which restricts some forms of communication - such as private messaging and some profile interactions. If this is a celebrity or community page, these settings were applied automatically."] = "'%1\$s' ha scelto di accettarti come \"fan\", il che limita alcune forme di comunicazione, come i messaggi privati, e alcune possibilità di interazione col profilo. Se è una pagina di una comunità o di una celebrità, queste impostazioni sono state applicate automaticamente.";
-$a->strings["'%1\$s' may choose to extend this into a two-way or more permissive relationship in the future."] = "'%1\$s' può scegliere di estendere questa relazione in una relazione più permissiva in futuro.";
-$a->strings["Please visit %s if you wish to make any changes to this relationship."] = "Visita %s se desideri modificare questo collegamento.";
-$a->strings["[Friendica System:Notify] registration request"] = "[Friendica System:Notifica] richiesta di registrazione";
-$a->strings["You've received a registration request from '%1\$s' at %2\$s"] = "Hai ricevuto una richiesta di registrazione da '%1\$s' su %2\$s";
-$a->strings["You've received a [url=%1\$s]registration request[/url] from %2\$s."] = "Hai ricevuto una [url=%1\$s]richiesta di registrazione[/url] da %2\$s.";
-$a->strings["Full Name:\t%1\$s\\nSite Location:\t%2\$s\\nLogin Name:\t%3\$s (%4\$s)"] = "Nome completo: %1\$s\nIndirizzo del sito: %2\$s\nNome utente: %3\$s (%4\$s)";
-$a->strings["Please visit %s to approve or reject the request."] = "Visita %s per approvare o rifiutare la richiesta.";
+$a->strings["There are no tables on MyISAM."] = "Non ci sono tabelle MyISAM";
+$a->strings["\n\t\t\tThe friendica developers released update %s recently,\n\t\t\tbut when I tried to install it, something went terribly wrong.\n\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n\t\t\tfriendica developer if you can not help me on your own. My database might be invalid."] = "\nGli sviluppatori di Friendica hanno rilasciato l'aggiornamento %s\nrecentemente, ma quando ho provato a installarlo, qualcosa è \nandato terribilmente storto.\nBisogna sistemare le cose e non posso farlo da solo.\nContatta uno sviluppatore se non puoi aiutarmi da solo. Il mio database potrebbe essere invalido.";
+$a->strings["The error message is\n[pre]%s[/pre]"] = "Il messaggio di errore è\n[pre]%s[/pre]";
+$a->strings["\nError %d occurred during database update:\n%s\n"] = "\nErrore %d durante l'aggiornamento del database:\n%s\n";
+$a->strings["Errors encountered performing database changes: "] = "Errori riscontrati eseguendo le modifiche al database:";
+$a->strings[": Database update"] = ": Aggiornamento database";
+$a->strings["%s: updating %s table."] = "%s: aggiornando la tabella %s.";
+$a->strings["(no subject)"] = "(nessun oggetto)";
+$a->strings["%s\\'s birthday"] = "compleanno di %s";
+$a->strings["Sharing notification from Diaspora network"] = "Notifica di condivisione dal network Diaspora*";
+$a->strings["Attachments:"] = "Allegati:";
$a->strings["all-day"] = "tutto il giorno";
$a->strings["Sun"] = "Dom";
$a->strings["Mon"] = "Lun";
$a->strings["No events to display"] = "Nessun evento da mostrare";
$a->strings["l, F j"] = "l j F";
$a->strings["Edit event"] = "Modifica l'evento";
+$a->strings["Duplicate event"] = "Duplica evento";
$a->strings["Delete event"] = "Elimina evento";
$a->strings["link to source"] = "Collegamento all'originale";
$a->strings["Export"] = "Esporta";
$a->strings["Export calendar as ical"] = "Esporta il calendario in formato ical";
$a->strings["Export calendar as csv"] = "Esporta il calendario in formato csv";
-$a->strings["General Features"] = "Funzionalità generali";
-$a->strings["Multiple Profiles"] = "Profili multipli";
-$a->strings["Ability to create multiple profiles"] = "Possibilità di creare profili multipli";
-$a->strings["Photo Location"] = "Località Foto";
-$a->strings["Photo metadata is normally stripped. This extracts the location (if present) prior to stripping metadata and links it to a map."] = "I metadati delle foto vengono rimossi. Questa opzione estrae la località (se presenta) prima di rimuovere i metadati e la collega a una mappa.";
-$a->strings["Export Public Calendar"] = "Esporta calendario pubblico";
-$a->strings["Ability for visitors to download the public calendar"] = "Permesso ai visitatori di scaricare il calendario pubblico";
-$a->strings["Post Composition Features"] = "Funzionalità di composizione dei post";
-$a->strings["Post Preview"] = "Anteprima dei post";
-$a->strings["Allow previewing posts and comments before publishing them"] = "Permetti di avere un'anteprima di messaggi e commenti prima di pubblicarli";
-$a->strings["Auto-mention Forums"] = "Auto-cita i Forum";
-$a->strings["Add/remove mention when a forum page is selected/deselected in ACL window."] = "Aggiunge/rimuove una menzione quando una pagina forum è selezionata/deselezionata nella finestra dei permessi.";
-$a->strings["Network Sidebar Widgets"] = "Widget della barra laterale nella pagina Rete";
-$a->strings["Search by Date"] = "Cerca per data";
-$a->strings["Ability to select posts by date ranges"] = "Permette di filtrare i post per data";
-$a->strings["List Forums"] = "Elenco forum";
-$a->strings["Enable widget to display the forums your are connected with"] = "Abilita il widget che mostra i forum ai quali sei connesso";
-$a->strings["Group Filter"] = "Filtra gruppi";
-$a->strings["Enable widget to display Network posts only from selected group"] = "Abilita il widget per filtrare i post solo per il gruppo selezionato";
-$a->strings["Network Filter"] = "Filtro reti";
-$a->strings["Enable widget to display Network posts only from selected network"] = "Abilita il widget per mostrare i post solo per la rete selezionata";
-$a->strings["Saved Searches"] = "Ricerche salvate";
-$a->strings["Save search terms for re-use"] = "Salva i termini cercati per riutilizzarli";
-$a->strings["Network Tabs"] = "Schede pagina Rete";
-$a->strings["Network Personal Tab"] = "Scheda Personali";
-$a->strings["Enable tab to display only Network posts that you've interacted on"] = "Abilita la scheda per mostrare solo i post a cui hai partecipato";
-$a->strings["Network New Tab"] = "Scheda Nuovi";
-$a->strings["Enable tab to display only new Network posts (from the last 12 hours)"] = "Abilita la scheda per mostrare solo i post nuovi (nelle ultime 12 ore)";
-$a->strings["Network Shared Links Tab"] = "Scheda Link Condivisi";
-$a->strings["Enable tab to display only Network posts with links in them"] = "Abilita la scheda per mostrare solo i post che contengono link";
-$a->strings["Post/Comment Tools"] = "Strumenti per messaggi/commenti";
-$a->strings["Multiple Deletion"] = "Eliminazione multipla";
-$a->strings["Select and delete multiple posts/comments at once"] = "Seleziona ed elimina vari messaggi e commenti in una volta sola";
-$a->strings["Edit Sent Posts"] = "Modifica i post inviati";
-$a->strings["Edit and correct posts and comments after sending"] = "Modifica e correggi messaggi e commenti dopo averli inviati";
-$a->strings["Tagging"] = "Aggiunta tag";
-$a->strings["Ability to tag existing posts"] = "Permette di aggiungere tag ai post già esistenti";
-$a->strings["Post Categories"] = "Categorie post";
-$a->strings["Add categories to your posts"] = "Aggiungi categorie ai tuoi post";
-$a->strings["Ability to file posts under folders"] = "Permette di archiviare i post in cartelle";
-$a->strings["Dislike Posts"] = "Non mi piace";
-$a->strings["Ability to dislike posts/comments"] = "Permetti di inviare \"non mi piace\" ai messaggi";
-$a->strings["Star Posts"] = "Post preferiti";
-$a->strings["Ability to mark special posts with a star indicator"] = "Permette di segnare i post preferiti con una stella";
-$a->strings["Mute Post Notifications"] = "Silenzia le notifiche di nuovi post";
-$a->strings["Ability to mute notifications for a thread"] = "Permette di silenziare le notifiche di nuovi post in una discussione";
-$a->strings["Advanced Profile Settings"] = "Impostazioni Avanzate Profilo";
-$a->strings["Show visitors public community forums at the Advanced Profile Page"] = "Mostra ai visitatori i forum nella pagina Profilo Avanzato";
+$a->strings["D g:i A"] = "";
+$a->strings["g:i A"] = "";
+$a->strings["Show map"] = "Mostra mappa";
+$a->strings["Hide map"] = "Nascondi mappa";
$a->strings["Disallowed profile URL."] = "Indirizzo profilo non permesso.";
$a->strings["Blocked domain"] = "Dominio bloccato";
$a->strings["Connect URL missing."] = "URL di connessione mancante.";
$a->strings["The profile address specified belongs to a network which has been disabled on this site."] = "L'indirizzo del profilo specificato appartiene a un network che è stato disabilitato su questo sito.";
$a->strings["Limited profile. This person will be unable to receive direct/personal notifications from you."] = "Profilo limitato. Questa persona non sarà in grado di ricevere notifiche personali da te.";
$a->strings["Unable to retrieve contact information."] = "Impossibile recuperare informazioni sul contatto.";
-$a->strings["A deleted group with this name was revived. Existing item permissions <strong>may</strong> apply to this group and any future members. If this is not what you intended, please create another group with a different name."] = "Un gruppo eliminato con questo nome è stato ricreato. I permessi esistenti su un elemento <strong>possono</strong> essere applicati a questo gruppo e tutti i membri futuri. Se questo non è ciò che si intende, si prega di creare un altro gruppo con un nome diverso.";
-$a->strings["Default privacy group for new contacts"] = "Gruppo predefinito per i nuovi contatti";
-$a->strings["Everybody"] = "Tutti";
-$a->strings["edit"] = "modifica";
-$a->strings["Groups"] = "Gruppi";
-$a->strings["Edit groups"] = "Modifica gruppi";
-$a->strings["Edit group"] = "Modifica gruppo";
-$a->strings["Create a new group"] = "Crea un nuovo gruppo";
-$a->strings["Group Name: "] = "Nome del gruppo:";
-$a->strings["Contacts not in any group"] = "Contatti in nessun gruppo.";
-$a->strings["add"] = "aggiungi";
$a->strings["Requested account is not available."] = "L'account richiesto non è disponibile.";
$a->strings["Requested profile is not available."] = "Profilo richiesto non disponibile.";
$a->strings["Edit profile"] = "Modifica il profilo";
$a->strings["Photo Albums"] = "Album foto";
$a->strings["Personal Notes"] = "Note personali";
$a->strings["Only You Can See This"] = "Solo tu puoi vedere questo";
-$a->strings["view full size"] = "vedi a schermo intero";
-$a->strings["Embedded content"] = "Contenuto incorporato";
-$a->strings["Embedding disabled"] = "Embed disabilitato";
-$a->strings["Contact Photos"] = "Foto dei contatti";
-$a->strings["Passwords do not match. Password unchanged."] = "Le password non corrispondono. Password non cambiata.";
-$a->strings["An invitation is required."] = "E' richiesto un invito.";
-$a->strings["Invitation could not be verified."] = "L'invito non puo' essere verificato.";
-$a->strings["Invalid OpenID url"] = "Url OpenID non valido";
-$a->strings["Please enter the required information."] = "Inserisci le informazioni richieste.";
-$a->strings["Please use a shorter name."] = "Usa un nome più corto.";
-$a->strings["Name too short."] = "Il nome è troppo corto.";
-$a->strings["That doesn't appear to be your full (First Last) name."] = "Questo non sembra essere il tuo nome completo (Nome Cognome).";
-$a->strings["Your email domain is not among those allowed on this site."] = "Il dominio della tua email non è tra quelli autorizzati su questo sito.";
-$a->strings["Not a valid email address."] = "L'indirizzo email non è valido.";
-$a->strings["Cannot use that email."] = "Non puoi usare quell'email.";
-$a->strings["Your \"nickname\" can only contain \"a-z\", \"0-9\" and \"_\"."] = "Il tuo nome utente può contenere solo \"a-z\", \"0-9\", e \"_\".";
-$a->strings["Nickname is already registered. Please choose another."] = "Nome utente già registrato. Scegline un altro.";
-$a->strings["Nickname was once registered here and may not be re-used. Please choose another."] = "Questo nome utente stato già registrato. Per favore, sceglierne uno nuovo.";
-$a->strings["SERIOUS ERROR: Generation of security keys failed."] = "ERRORE GRAVE: La generazione delle chiavi di sicurezza è fallita.";
-$a->strings["An error occurred during registration. Please try again."] = "C'è stato un errore durante la registrazione. Prova ancora.";
-$a->strings["default"] = "default";
-$a->strings["An error occurred creating your default profile. Please try again."] = "C'è stato un errore nella creazione del tuo profilo. Prova ancora.";
-$a->strings["Profile Photos"] = "Foto del profilo";
-$a->strings["\n\t\tDear %1\$s,\n\t\t\tThank you for registering at %2\$s. Your account is pending for approval by the administrator.\n\t"] = "\nCaro %1\$s,\n Grazie per la tua registrazione su %2\$s. Il tuo account è in attesa di approvazione da parte di un amministratore.\n ";
-$a->strings["Registration at %s"] = "Registrazione su %s";
-$a->strings["\n\t\tDear %1\$s,\n\t\t\tThank you for registering at %2\$s. Your account has been created.\n\t"] = "\nGentile %1\$s,\nGrazie per esserti registrato su %2\$s. Il tuo account è stato creato.";
-$a->strings["\n\t\tThe login details are as follows:\n\t\t\tSite Location:\t%3\$s\n\t\t\tLogin Name:\t%1\$s\n\t\t\tPassword:\t%5\$s\n\n\t\tYou may change your password from your account \"Settings\" page after logging\n\t\tin.\n\n\t\tPlease take a few moments to review the other account settings on that page.\n\n\t\tYou may also wish to add some basic information to your default profile\n\t\t(on the \"Profiles\" page) so that other people can easily find you.\n\n\t\tWe recommend setting your full name, adding a profile photo,\n\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n\t\tperhaps what country you live in; if you do not wish to be more specific\n\t\tthan that.\n\n\t\tWe fully respect your right to privacy, and none of these items are necessary.\n\t\tIf you are new and do not know anybody here, they may help\n\t\tyou to make some new and interesting friends.\n\n\n\t\tThank you and welcome to %2\$s."] = "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %3\$s\n Nome utente: %1\$s\n Password: %5\$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %2\$s";
-$a->strings["Registration details for %s"] = "Dettagli della registrazione di %s";
-$a->strings["There are no tables on MyISAM."] = "Non ci sono tabelle MyISAM";
-$a->strings["\n\t\t\tThe friendica developers released update %s recently,\n\t\t\tbut when I tried to install it, something went terribly wrong.\n\t\t\tThis needs to be fixed soon and I can't do it alone. Please contact a\n\t\t\tfriendica developer if you can not help me on your own. My database might be invalid."] = "\nGli sviluppatori di Friendica hanno rilasciato l'aggiornamento %s\nrecentemente, ma quando ho provato a installarlo, qualcosa è \nandato terribilmente storto.\nBisogna sistemare le cose e non posso farlo da solo.\nContatta uno sviluppatore se non puoi aiutarmi da solo. Il mio database potrebbe essere invalido.";
-$a->strings["The error message is\n[pre]%s[/pre]"] = "Il messaggio di errore è\n[pre]%s[/pre]";
-$a->strings["\nError %d occurred during database update:\n%s\n"] = "\nErrore %d durante l'aggiornamento del database:\n%s\n";
-$a->strings["Errors encountered performing database changes: "] = "Errori riscontrati eseguendo le modifiche al database:";
-$a->strings[": Database update"] = ": Aggiornamento database";
-$a->strings["%s: updating %s table."] = "%s: aggiornando la tabella %s.";
-$a->strings["%s\\'s birthday"] = "compleanno di %s";
-$a->strings["Sharing notification from Diaspora network"] = "Notifica di condivisione dal network Diaspora*";
-$a->strings["Attachments:"] = "Allegati:";
$a->strings["[Name Withheld]"] = "[Nome Nascosto]";
$a->strings["Item not found."] = "Elemento non trovato.";
$a->strings["Do you really want to delete this item?"] = "Vuoi veramente cancellare questo elemento?";
$a->strings["Yes"] = "Si";
$a->strings["Permission denied."] = "Permesso negato.";
$a->strings["Archives"] = "Archivi";
+$a->strings["%1\$s is attending %2\$s's %3\$s"] = "%1\$s parteciperà a %3\$s di %2\$s";
+$a->strings["%1\$s is not attending %2\$s's %3\$s"] = "%1\$s non parteciperà a %3\$s di %2\$s";
+$a->strings["%1\$s may attend %2\$s's %3\$s"] = "%1\$s forse parteciperà a %3\$s di %2\$s";
+$a->strings["[no subject]"] = "[nessun oggetto]";
+$a->strings["view full size"] = "vedi a schermo intero";
$a->strings["%s is now following %s."] = "%s sta seguendo %s";
$a->strings["following"] = "segue";
$a->strings["%s stopped following %s."] = "%s ha smesso di seguire %s";
$a->strings["motivated"] = "motivato";
$a->strings["relaxed"] = "rilassato";
$a->strings["surprised"] = "sorpreso";
+$a->strings["Sund"] = "Dom";
+$a->strings["Sep"] = "Set";
$a->strings["View Video"] = "Guarda Video";
$a->strings["bytes"] = "bytes";
$a->strings["Click to open/close"] = "Clicca per aprire/chiudere";
$a->strings["view on separate page"] = "vedi in una pagina separata";
$a->strings["activity"] = "attività";
$a->strings["comment"] = array(
- 0 => "",
- 1 => "commento",
+ 0 => "commento ",
+ 1 => "commenti",
);
$a->strings["post"] = "messaggio";
$a->strings["Item filed"] = "Messaggio salvato";
-$a->strings["No friends to display."] = "Nessun amico da visualizzare.";
+$a->strings["Error decoding account file"] = "Errore decodificando il file account";
+$a->strings["Error! No version data in file! This is not a Friendica account file?"] = "Errore! Nessuna informazione di versione nel file! Potrebbe non essere un file account di Friendica?";
+$a->strings["Error! Cannot check nickname"] = "Errore! Non posso controllare il nickname";
+$a->strings["User '%s' already exists on this server!"] = "L'utente '%s' esiste già su questo server!";
+$a->strings["User creation error"] = "Errore creando l'utente";
+$a->strings["User profile creation error"] = "Errore creando il profilo dell'utente";
+$a->strings["%d contact not imported"] = array(
+ 0 => "%d contatto non importato",
+ 1 => "%d contatti non importati",
+);
+$a->strings["Done. You can now login with your username and password"] = "Fatto. Ora puoi entrare con il tuo nome utente e la tua password";
+$a->strings["Passwords do not match. Password unchanged."] = "Le password non corrispondono. Password non cambiata.";
+$a->strings["An invitation is required."] = "E' richiesto un invito.";
+$a->strings["Invitation could not be verified."] = "L'invito non puo' essere verificato.";
+$a->strings["Invalid OpenID url"] = "Url OpenID non valido";
+$a->strings["Please enter the required information."] = "Inserisci le informazioni richieste.";
+$a->strings["Please use a shorter name."] = "Usa un nome più corto.";
+$a->strings["Name too short."] = "Il nome è troppo corto.";
+$a->strings["That doesn't appear to be your full (First Last) name."] = "Questo non sembra essere il tuo nome completo (Nome Cognome).";
+$a->strings["Your email domain is not among those allowed on this site."] = "Il dominio della tua email non è tra quelli autorizzati su questo sito.";
+$a->strings["Not a valid email address."] = "L'indirizzo email non è valido.";
+$a->strings["Cannot use that email."] = "Non puoi usare quell'email.";
+$a->strings["Your \"nickname\" can only contain \"a-z\", \"0-9\" and \"_\"."] = "Il tuo nome utente può contenere solo \"a-z\", \"0-9\", e \"_\".";
+$a->strings["Nickname is already registered. Please choose another."] = "Nome utente già registrato. Scegline un altro.";
+$a->strings["Nickname was once registered here and may not be re-used. Please choose another."] = "Questo nome utente stato già registrato. Per favore, sceglierne uno nuovo.";
+$a->strings["SERIOUS ERROR: Generation of security keys failed."] = "ERRORE GRAVE: La generazione delle chiavi di sicurezza è fallita.";
+$a->strings["An error occurred during registration. Please try again."] = "C'è stato un errore durante la registrazione. Prova ancora.";
+$a->strings["default"] = "default";
+$a->strings["An error occurred creating your default profile. Please try again."] = "C'è stato un errore nella creazione del tuo profilo. Prova ancora.";
+$a->strings["\n\t\tDear %1\$s,\n\t\t\tThank you for registering at %2\$s. Your account is pending for approval by the administrator.\n\t"] = "\nCaro %1\$s,\n Grazie per la tua registrazione su %2\$s. Il tuo account è in attesa di approvazione da parte di un amministratore.\n ";
+$a->strings["Registration at %s"] = "Registrazione su %s";
+$a->strings["\n\t\tDear %1\$s,\n\t\t\tThank you for registering at %2\$s. Your account has been created.\n\t"] = "\nGentile %1\$s,\nGrazie per esserti registrato su %2\$s. Il tuo account è stato creato.";
+$a->strings["\n\t\tThe login details are as follows:\n\t\t\tSite Location:\t%3\$s\n\t\t\tLogin Name:\t%1\$s\n\t\t\tPassword:\t%5\$s\n\n\t\tYou may change your password from your account \"Settings\" page after logging\n\t\tin.\n\n\t\tPlease take a few moments to review the other account settings on that page.\n\n\t\tYou may also wish to add some basic information to your default profile\n\t\t(on the \"Profiles\" page) so that other people can easily find you.\n\n\t\tWe recommend setting your full name, adding a profile photo,\n\t\tadding some profile \"keywords\" (very useful in making new friends) - and\n\t\tperhaps what country you live in; if you do not wish to be more specific\n\t\tthan that.\n\n\t\tWe fully respect your right to privacy, and none of these items are necessary.\n\t\tIf you are new and do not know anybody here, they may help\n\t\tyou to make some new and interesting friends.\n\n\n\t\tThank you and welcome to %2\$s."] = "\nI dettagli del tuo utente sono:\n Indirizzo del sito: %3\$s\n Nome utente: %1\$s\n Password: %5\$s\n\nPuoi cambiare la tua password dalla pagina delle impostazioni del tuo account dopo esserti autenticato.\n\nPer favore, prenditi qualche momento per esaminare tutte le impostazioni presenti.\n\nPotresti voler aggiungere qualche informazione di base al tuo profilo predefinito (nella pagina \"Profili\"), così che le altre persone possano trovarti più facilmente.\n\nTi raccomandiamo di inserire il tuo nome completo, aggiungere una foto, aggiungere qualche parola chiave del profilo (molto utili per trovare nuovi contatti), e magari in quale nazione vivi, se non vuoi essere più specifico di così.\n\nNoi rispettiamo appieno la tua privacy, e nessuna di queste informazioni è necessaria o obbligatoria.\nSe sei nuovo e non conosci nessuno qui, possono aiutarti a trovare qualche nuovo e interessante contatto.\n\nGrazie e benvenuto su %2\$s";
+$a->strings["Registration details for %s"] = "Dettagli della registrazione di %s";
$a->strings["Authorize application connection"] = "Autorizza la connessione dell'applicazione";
$a->strings["Return to your app and insert this Securty Code:"] = "Torna alla tua applicazione e inserisci questo codice di sicurezza:";
$a->strings["Please login to continue."] = "Effettua il login per continuare.";
$a->strings["No installed applications."] = "Nessuna applicazione installata.";
$a->strings["Item not available."] = "Oggetto non disponibile.";
$a->strings["Item was not found."] = "Oggetto non trovato.";
-$a->strings["The post was created"] = "Il messaggio è stato creato";
+$a->strings["Source (bbcode) text:"] = "Testo sorgente (bbcode):";
+$a->strings["Source (Diaspora) text to convert to BBcode:"] = "Testo sorgente (da Diaspora) da convertire in BBcode:";
+$a->strings["Source input: "] = "Sorgente:";
+$a->strings["bb2html (raw HTML): "] = "bb2html (HTML grezzo):";
+$a->strings["bb2html: "] = "bb2html:";
+$a->strings["bb2html2bb: "] = "bb2html2bb: ";
+$a->strings["bb2md: "] = "bb2md: ";
+$a->strings["bb2md2html: "] = "bb2md2html: ";
+$a->strings["bb2dia2bb: "] = "bb2dia2bb: ";
+$a->strings["bb2md2html2bb: "] = "bb2md2html2bb: ";
+$a->strings["Source input (Diaspora format): "] = "Sorgente (formato Diaspora):";
+$a->strings["diaspora2bb: "] = "diaspora2bb: ";
$a->strings["No contacts in common."] = "Nessun contatto in comune.";
$a->strings["Common Friends"] = "Amici in comune";
-$a->strings["%d contact edited."] = array(
- 0 => "%d contatto modificato.",
- 1 => "%d contatti modificati",
-);
-$a->strings["Could not access contact record."] = "Non è possibile accedere al contatto.";
-$a->strings["Could not locate selected profile."] = "Non riesco a trovare il profilo selezionato.";
-$a->strings["Contact updated."] = "Contatto aggiornato.";
-$a->strings["Failed to update contact record."] = "Errore nell'aggiornamento del contatto.";
-$a->strings["Contact has been blocked"] = "Il contatto è stato bloccato";
-$a->strings["Contact has been unblocked"] = "Il contatto è stato sbloccato";
-$a->strings["Contact has been ignored"] = "Il contatto è ignorato";
-$a->strings["Contact has been unignored"] = "Il contatto non è più ignorato";
-$a->strings["Contact has been archived"] = "Il contatto è stato archiviato";
-$a->strings["Contact has been unarchived"] = "Il contatto è stato dearchiviato";
-$a->strings["Drop contact"] = "Cancella contatto";
-$a->strings["Do you really want to delete this contact?"] = "Vuoi veramente cancellare questo contatto?";
-$a->strings["Contact has been removed."] = "Il contatto è stato rimosso.";
-$a->strings["You are mutual friends with %s"] = "Sei amico reciproco con %s";
-$a->strings["You are sharing with %s"] = "Stai condividendo con %s";
-$a->strings["%s is sharing with you"] = "%s sta condividendo con te";
-$a->strings["Private communications are not available for this contact."] = "Le comunicazioni private non sono disponibili per questo contatto.";
-$a->strings["Never"] = "Mai";
-$a->strings["(Update was successful)"] = "(L'aggiornamento è stato completato)";
-$a->strings["(Update was not successful)"] = "(L'aggiornamento non è stato completato)";
-$a->strings["Suggest friends"] = "Suggerisci amici";
-$a->strings["Network type: %s"] = "Tipo di rete: %s";
-$a->strings["Communications lost with this contact!"] = "Comunicazione con questo contatto persa!";
-$a->strings["Fetch further information for feeds"] = "Recupera maggiori informazioni per i feed";
-$a->strings["Disabled"] = "Disabilitato";
-$a->strings["Fetch information"] = "Recupera informazioni";
-$a->strings["Fetch information and keywords"] = "Recupera informazioni e parole chiave";
-$a->strings["Contact"] = "Contatto";
-$a->strings["Submit"] = "Invia";
-$a->strings["Profile Visibility"] = "Visibilità del profilo";
-$a->strings["Please choose the profile you would like to display to %s when viewing your profile securely."] = "Seleziona il profilo che vuoi mostrare a %s quando visita il tuo profilo in modo sicuro.";
-$a->strings["Contact Information / Notes"] = "Informazioni / Note sul contatto";
-$a->strings["Edit contact notes"] = "Modifica note contatto";
-$a->strings["Visit %s's profile [%s]"] = "Visita il profilo di %s [%s]";
-$a->strings["Block/Unblock contact"] = "Blocca/Sblocca contatto";
-$a->strings["Ignore contact"] = "Ignora il contatto";
-$a->strings["Repair URL settings"] = "Impostazioni riparazione URL";
-$a->strings["View conversations"] = "Vedi conversazioni";
-$a->strings["Last update:"] = "Ultimo aggiornamento:";
-$a->strings["Update public posts"] = "Aggiorna messaggi pubblici";
-$a->strings["Update now"] = "Aggiorna adesso";
-$a->strings["Unblock"] = "Sblocca";
-$a->strings["Block"] = "Blocca";
-$a->strings["Unignore"] = "Non ignorare";
-$a->strings["Ignore"] = "Ignora";
-$a->strings["Currently blocked"] = "Bloccato";
-$a->strings["Currently ignored"] = "Ignorato";
-$a->strings["Currently archived"] = "Al momento archiviato";
-$a->strings["Hide this contact from others"] = "Nascondi questo contatto agli altri";
-$a->strings["Replies/likes to your public posts <strong>may</strong> still be visible"] = "Risposte ai tuoi post pubblici <strong>possono</strong> essere comunque visibili";
-$a->strings["Notification for new posts"] = "Notifica per i nuovi messaggi";
-$a->strings["Send a notification of every new post of this contact"] = "Invia una notifica per ogni nuovo messaggio di questo contatto";
-$a->strings["Blacklisted keywords"] = "Parole chiave in blacklist";
-$a->strings["Comma separated list of keywords that should not be converted to hashtags, when \"Fetch information and keywords\" is selected"] = "Lista separata da virgola di parole chiave che non dovranno essere convertite in hashtag, quando \"Recupera informazioni e parole chiave\" è selezionato";
-$a->strings["Profile URL"] = "URL Profilo";
-$a->strings["Actions"] = "Azioni";
-$a->strings["Contact Settings"] = "Impostazioni Contatto";
-$a->strings["Suggestions"] = "Suggerimenti";
-$a->strings["Suggest potential friends"] = "Suggerisci potenziali amici";
-$a->strings["All Contacts"] = "Tutti i contatti";
-$a->strings["Show all contacts"] = "Mostra tutti i contatti";
-$a->strings["Unblocked"] = "Sbloccato";
-$a->strings["Only show unblocked contacts"] = "Mostra solo contatti non bloccati";
-$a->strings["Blocked"] = "Bloccato";
-$a->strings["Only show blocked contacts"] = "Mostra solo contatti bloccati";
-$a->strings["Ignored"] = "Ignorato";
-$a->strings["Only show ignored contacts"] = "Mostra solo contatti ignorati";
-$a->strings["Archived"] = "Archiviato";
-$a->strings["Only show archived contacts"] = "Mostra solo contatti archiviati";
-$a->strings["Hidden"] = "Nascosto";
-$a->strings["Only show hidden contacts"] = "Mostra solo contatti nascosti";
-$a->strings["Search your contacts"] = "Cerca nei tuoi contatti";
-$a->strings["Results for: %s"] = "Risultati per: %s";
-$a->strings["Update"] = "Aggiorna";
-$a->strings["Archive"] = "Archivia";
-$a->strings["Unarchive"] = "Dearchivia";
-$a->strings["Batch Actions"] = "Azioni Batch";
-$a->strings["View all contacts"] = "Vedi tutti i contatti";
-$a->strings["View all common friends"] = "Vedi tutti gli amici in comune";
-$a->strings["Advanced Contact Settings"] = "Impostazioni avanzate Contatto";
-$a->strings["Mutual Friendship"] = "Amicizia reciproca";
-$a->strings["is a fan of yours"] = "è un tuo fan";
-$a->strings["you are a fan of"] = "sei un fan di";
-$a->strings["Edit contact"] = "Modifica contatto";
-$a->strings["Toggle Blocked status"] = "Inverti stato \"Blocca\"";
-$a->strings["Toggle Ignored status"] = "Inverti stato \"Ignora\"";
-$a->strings["Toggle Archive status"] = "Inverti stato \"Archiviato\"";
-$a->strings["Delete contact"] = "Rimuovi contatto";
-$a->strings["No such group"] = "Nessun gruppo";
-$a->strings["Group is empty"] = "Il gruppo è vuoto";
-$a->strings["Group: %s"] = "Gruppo: %s";
-$a->strings["This entry was edited"] = "Questa voce è stata modificata";
-$a->strings["%d comment"] = array(
- 0 => "%d commento",
- 1 => "%d commenti",
-);
-$a->strings["Private Message"] = "Messaggio privato";
-$a->strings["I like this (toggle)"] = "Mi piace (clic per cambiare)";
-$a->strings["like"] = "mi piace";
-$a->strings["I don't like this (toggle)"] = "Non mi piace (clic per cambiare)";
-$a->strings["dislike"] = "non mi piace";
-$a->strings["Share this"] = "Condividi questo";
-$a->strings["share"] = "condividi";
-$a->strings["This is you"] = "Questo sei tu";
-$a->strings["Comment"] = "Commento";
-$a->strings["Bold"] = "Grassetto";
-$a->strings["Italic"] = "Corsivo";
-$a->strings["Underline"] = "Sottolineato";
-$a->strings["Quote"] = "Citazione";
-$a->strings["Code"] = "Codice";
-$a->strings["Image"] = "Immagine";
-$a->strings["Link"] = "Link";
-$a->strings["Video"] = "Video";
-$a->strings["Edit"] = "Modifica";
-$a->strings["add star"] = "aggiungi a speciali";
-$a->strings["remove star"] = "rimuovi da speciali";
-$a->strings["toggle star status"] = "Inverti stato preferito";
-$a->strings["starred"] = "preferito";
-$a->strings["add tag"] = "aggiungi tag";
-$a->strings["ignore thread"] = "ignora la discussione";
-$a->strings["unignore thread"] = "non ignorare la discussione";
-$a->strings["toggle ignore status"] = "inverti stato \"Ignora\"";
-$a->strings["ignored"] = "ignorato";
-$a->strings["save to folder"] = "salva nella cartella";
-$a->strings["I will attend"] = "Parteciperò";
-$a->strings["I will not attend"] = "Non parteciperò";
-$a->strings["I might attend"] = "Forse parteciperò";
-$a->strings["to"] = "a";
-$a->strings["Wall-to-Wall"] = "Da bacheca a bacheca";
-$a->strings["via Wall-To-Wall:"] = "da bacheca a bacheca";
$a->strings["Credits"] = "Crediti";
$a->strings["Friendica is a community project, that would not be possible without the help of many people. Here is a list of those who have contributed to the code or the translation of Friendica. Thank you all!"] = "Friendica è un progetto comunitario, che non sarebbe stato possibile realizzare senza l'aiuto di molte persone.\nQuesta è una lista di chi ha contribuito al codice o alle traduzioni di Friendica. Grazie a tutti!";
$a->strings["Contact settings applied."] = "Contatto modificato.";
$a->strings["Mirror as my own posting"] = "Duplica come miei messaggi";
$a->strings["Return to contact editor"] = "Ritorna alla modifica contatto";
$a->strings["Refetch contact data"] = "Ricarica dati contatto";
+$a->strings["Submit"] = "Invia";
$a->strings["Remote Self"] = "Io remoto";
$a->strings["Mirror postings from this contact"] = "Ripeti i messaggi di questo contatto";
$a->strings["Mark this contact as remote_self, this will cause friendica to repost new entries from this contact."] = "Imposta questo contatto come 'io remoto', questo farà si che friendica re invii i nuovi messaggi da questo contatto.";
$a->strings["Notification Endpoint URL"] = "URL Notifiche";
$a->strings["Poll/Feed URL"] = "URL Feed";
$a->strings["New photo from this URL"] = "Nuova foto da questo URL";
-$a->strings["No potential page delegates located."] = "Nessun potenziale delegato per la pagina è stato trovato.";
-$a->strings["Delegates are able to manage all aspects of this account/page except for basic account settings. Please do not delegate your personal account to anybody that you do not trust completely."] = "I Delegati sono in grado di gestire tutti gli aspetti di questa pagina, tranne per le impostazioni di base dell'account. Non delegare il tuo account personale a nessuno di cui non ti fidi ciecamente.";
-$a->strings["Existing Page Managers"] = "Gestori Pagina Esistenti";
-$a->strings["Existing Page Delegates"] = "Delegati Pagina Esistenti";
-$a->strings["Potential Delegates"] = "Delegati Potenziali";
-$a->strings["Remove"] = "Rimuovi";
-$a->strings["Add"] = "Aggiungi";
-$a->strings["No entries."] = "Nessuna voce.";
-$a->strings["%1\$s welcomes %2\$s"] = "%s dà il benvenuto a %s";
-$a->strings["Public access denied."] = "Accesso negato.";
-$a->strings["Global Directory"] = "Elenco globale";
-$a->strings["Find on this site"] = "Cerca nel sito";
-$a->strings["Results for:"] = "Risultati per:";
-$a->strings["Site Directory"] = "Elenco del sito";
-$a->strings["No entries (some entries may be hidden)."] = "Nessuna voce (qualche voce potrebbe essere nascosta).";
-$a->strings["Access to this profile has been restricted."] = "L'accesso a questo profilo è stato limitato.";
-$a->strings["Item has been removed."] = "L'oggetto è stato rimosso.";
-$a->strings["Item not found"] = "Oggetto non trovato";
-$a->strings["Edit post"] = "Modifica messaggio";
-$a->strings["Files"] = "File";
-$a->strings["Not Found"] = "Non trovato";
$a->strings["- select -"] = "- seleziona -";
-$a->strings["Friend suggestion sent."] = "Suggerimento di amicizia inviato.";
-$a->strings["Suggest Friends"] = "Suggerisci amici";
-$a->strings["Suggest a friend for %s"] = "Suggerisci un amico a %s";
-$a->strings["No profile"] = "Nessun profilo";
-$a->strings["Help:"] = "Guida:";
-$a->strings["Page not found."] = "Pagina non trovata.";
-$a->strings["Welcome to %s"] = "Benvenuto su %s";
-$a->strings["Total invitation limit exceeded."] = "Limite totale degli inviti superato.";
-$a->strings["%s : Not a valid email address."] = "%s: non è un indirizzo email valido.";
-$a->strings["Please join us on Friendica"] = "Unisciti a noi su Friendica";
-$a->strings["Invitation limit exceeded. Please contact your site administrator."] = "Limite degli inviti superato. Contatta l'amministratore del tuo sito.";
-$a->strings["%s : Message delivery failed."] = "%s: la consegna del messaggio fallita.";
-$a->strings["%d message sent."] = array(
- 0 => "%d messaggio inviato.",
- 1 => "%d messaggi inviati.",
-);
-$a->strings["You have no more invitations available"] = "Non hai altri inviti disponibili";
-$a->strings["Visit %s for a list of public sites that you can join. Friendica members on other sites can all connect with each other, as well as with members of many other social networks."] = "Visita %s per una lista di siti pubblici a cui puoi iscriverti. I membri Friendica su altri siti possono collegarsi uno con l'altro, come con membri di molti altri social network.";
-$a->strings["To accept this invitation, please visit and register at %s or any other public Friendica website."] = "Per accettare questo invito, visita e registrati su %s o su un'altro sito web Friendica aperto al pubblico.";
-$a->strings["Friendica sites all inter-connect to create a huge privacy-enhanced social web that is owned and controlled by its members. They can also connect with many traditional social networks. See %s for a list of alternate Friendica sites you can join."] = "I siti Friendica son tutti collegati tra loro per creare una grossa rete sociale rispettosa della privacy, posseduta e controllata dai suoi membri. I siti Friendica possono anche collegarsi a molti altri social network tradizionali. Vai su %s per una lista di siti Friendica alternativi a cui puoi iscriverti.";
-$a->strings["Our apologies. This system is not currently configured to connect with other public sites or invite members."] = "Ci scusiamo, questo sistema non è configurato per collegarsi con altri siti pubblici o per invitare membri.";
-$a->strings["Send invitations"] = "Invia inviti";
-$a->strings["Enter email addresses, one per line:"] = "Inserisci gli indirizzi email, uno per riga:";
-$a->strings["Your message:"] = "Il tuo messaggio:";
-$a->strings["You are cordially invited to join me and other close friends on Friendica - and help us to create a better social web."] = "Sei cordialmente invitato/a ad unirti a me e ad altri amici su Friendica, e ad aiutarci a creare una rete sociale migliore.";
-$a->strings["You will need to supply this invitation code: \$invite_code"] = "Sarà necessario fornire questo codice invito: \$invite_code";
-$a->strings["Once you have registered, please connect with me via my profile page at:"] = "Una volta registrato, connettiti con me dal mio profilo:";
-$a->strings["For more information about the Friendica project and why we feel it is important, please visit http://friendica.com"] = "Per maggiori informazioni sul progetto Friendica e perché pensiamo sia importante, visita http://friendica.com";
-$a->strings["Time Conversion"] = "Conversione Ora";
-$a->strings["Friendica provides this service for sharing events with other networks and friends in unknown timezones."] = "Friendica fornisce questo servizio per la condivisione di eventi con altre reti e amici in fusi orari sconosciuti.";
-$a->strings["UTC time: %s"] = "Ora UTC: %s";
-$a->strings["Current timezone: %s"] = "Fuso orario corrente: %s";
-$a->strings["Converted localtime: %s"] = "Ora locale convertita: %s";
-$a->strings["Please select your timezone:"] = "Selezionare il tuo fuso orario:";
$a->strings["Remote privacy information not available."] = "Informazioni remote sulla privacy non disponibili.";
$a->strings["Visible to:"] = "Visibile a:";
-$a->strings["No valid account found."] = "Nessun account valido trovato.";
-$a->strings["Password reset request issued. Check your email."] = "La richiesta per reimpostare la password è stata inviata. Controlla la tua email.";
-$a->strings["\n\t\tDear %1\$s,\n\t\t\tA request was recently received at \"%2\$s\" to reset your account\n\t\tpassword. In order to confirm this request, please select the verification link\n\t\tbelow or paste it into your web browser address bar.\n\n\t\tIf you did NOT request this change, please DO NOT follow the link\n\t\tprovided and ignore and/or delete this email.\n\n\t\tYour password will not be changed unless we can verify that you\n\t\tissued this request."] = "\nGentile %1\$s,\n abbiamo ricevuto su \"%2\$s\" una richiesta di resettare la password del tuo account. Per confermare questa richiesta, selezionate il link di conferma qui sotto o incollatelo nella barra indirizzo del vostro browser.\n\nSe NON hai richiesto questa modifica, NON selezionare il link e ignora o cancella questa email.\n\nLa tua password non verrà modificata a meno che non possiamo verificare che tu abbia effettivamente richiesto la modifica.";
-$a->strings["\n\t\tFollow this link to verify your identity:\n\n\t\t%1\$s\n\n\t\tYou will then receive a follow-up message containing the new password.\n\t\tYou may change that password from your account settings page after logging in.\n\n\t\tThe login details are as follows:\n\n\t\tSite Location:\t%2\$s\n\t\tLogin Name:\t%3\$s"] = "\nSegui questo link per verificare la tua identità:\n\n%1\$s\n\nRiceverai in un successivo messaggio la nuova password.\nPotrai cambiarla dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato.\n\nI dettagli del tuo account sono:\n Indirizzo del sito: %2\$s\n Nome utente: %3\$s";
-$a->strings["Password reset requested at %s"] = "Richiesta reimpostazione password su %s";
-$a->strings["Request could not be verified. (You may have previously submitted it.) Password reset failed."] = "La richiesta non può essere verificata. (Puoi averla già richiesta precedentemente). Reimpostazione password fallita.";
-$a->strings["Password Reset"] = "Reimpostazione password";
-$a->strings["Your password has been reset as requested."] = "La tua password è stata reimpostata come richiesto.";
-$a->strings["Your new password is"] = "La tua nuova password è";
-$a->strings["Save or copy your new password - and then"] = "Salva o copia la tua nuova password, quindi";
-$a->strings["click here to login"] = "clicca qui per entrare";
-$a->strings["Your password may be changed from the <em>Settings</em> page after successful login."] = "Puoi cambiare la tua password dalla pagina <em>Impostazioni</em> dopo aver effettuato l'accesso.";
-$a->strings["\n\t\t\t\tDear %1\$s,\n\t\t\t\t\tYour password has been changed as requested. Please retain this\n\t\t\t\tinformation for your records (or change your password immediately to\n\t\t\t\tsomething that you will remember).\n\t\t\t"] = "\nGentile %1\$s,\n La tua password è stata modificata come richiesto.\nSalva questa password, o sostituiscila immediatamente con qualcosa che puoi ricordare.";
-$a->strings["\n\t\t\t\tYour login details are as follows:\n\n\t\t\t\tSite Location:\t%1\$s\n\t\t\t\tLogin Name:\t%2\$s\n\t\t\t\tPassword:\t%3\$s\n\n\t\t\t\tYou may change that password from your account settings page after logging in.\n\t\t\t"] = "\nI dettagli del tuo account sono:\n\n Indirizzo del sito: %1\$s\n Nome utente: %2\$s\n Password: %3\$s\n\nPuoi cambiare questa password dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato.";
-$a->strings["Your password has been changed at %s"] = "La tua password presso %s è stata cambiata";
-$a->strings["Forgot your Password?"] = "Hai dimenticato la password?";
-$a->strings["Enter your email address and submit to have your password reset. Then check your email for further instructions."] = "Inserisci il tuo indirizzo email per reimpostare la password.";
-$a->strings["Nickname or Email: "] = "Nome utente o email: ";
-$a->strings["Reset"] = "Reimposta";
$a->strings["System down for maintenance"] = "Sistema in manutenzione";
-$a->strings["No keywords to match. Please add keywords to your default profile."] = "Nessuna parola chiave per l'abbinamento. Aggiungi parole chiave al tuo profilo predefinito.";
-$a->strings["is interested in:"] = "è interessato a:";
-$a->strings["Profile Match"] = "Profili corrispondenti";
-$a->strings["No matches"] = "Nessun risultato";
-$a->strings["Mood"] = "Umore";
-$a->strings["Set your current mood and tell your friends"] = "Condividi il tuo umore con i tuoi amici";
$a->strings["Welcome to Friendica"] = "Benvenuto su Friendica";
$a->strings["New Member Checklist"] = "Cose da fare per i Nuovi Utenti";
$a->strings["We would like to offer some tips and links to help make your experience enjoyable. Click any item to visit the relevant page. A link to this page will be visible from your home page for two weeks after your initial registration and then will quietly disappear."] = "Vorremmo offrirti qualche trucco e dei link alla guida per aiutarti ad avere un'esperienza divertente. Clicca su un qualsiasi elemento per visitare la relativa pagina. Un link a questa pagina sarà visibile nella tua home per due settimane dopo la tua registrazione.";
$a->strings["Getting Help"] = "Ottenere Aiuto";
$a->strings["Go to the Help Section"] = "Vai alla sezione Guida";
$a->strings["Our <strong>help</strong> pages may be consulted for detail on other program features and resources."] = "Le nostre pagine della <strong>guida</strong> possono essere consultate per avere dettagli su altre caratteristiche del programma e altre risorse.";
+$a->strings["Visit %s's profile [%s]"] = "Visita il profilo di %s [%s]";
+$a->strings["Edit contact"] = "Modifica contatto";
$a->strings["Contacts who are not members of a group"] = "Contatti che non sono membri di un gruppo";
-$a->strings["No more system notifications."] = "Nessuna nuova notifica di sistema.";
-$a->strings["System Notifications"] = "Notifiche di sistema";
-$a->strings["Post successful."] = "Inviato!";
-$a->strings["Subscribing to OStatus contacts"] = "Iscrizione a contatti OStatus";
-$a->strings["No contact provided."] = "Nessun contatto disponibile.";
-$a->strings["Couldn't fetch information for contact."] = "Non è stato possibile recuperare le informazioni del contatto.";
-$a->strings["Couldn't fetch friends for contact."] = "Non è stato possibile recuperare gli amici del contatto.";
-$a->strings["Done"] = "Fatto";
-$a->strings["success"] = "successo";
-$a->strings["failed"] = "fallito";
-$a->strings["Keep this window open until done."] = "Tieni questa finestra aperta fino a che ha finito.";
-$a->strings["Not Extended"] = "Not Extended";
-$a->strings["Poke/Prod"] = "Tocca/Pungola";
-$a->strings["poke, prod or do other things to somebody"] = "tocca, pungola o fai altre cose a qualcuno";
-$a->strings["Recipient"] = "Destinatario";
-$a->strings["Choose what you wish to do to recipient"] = "Scegli cosa vuoi fare al destinatario";
-$a->strings["Make this post private"] = "Rendi questo post privato";
-$a->strings["Image uploaded but image cropping failed."] = "L'immagine è stata caricata, ma il non è stato possibile ritagliarla.";
-$a->strings["Image size reduction [%s] failed."] = "Il ridimensionamento dell'immagine [%s] è fallito.";
-$a->strings["Shift-reload the page or clear browser cache if the new photo does not display immediately."] = "Ricarica la pagina con shift+F5 o cancella la cache del browser se la nuova foto non viene mostrata immediatamente.";
-$a->strings["Unable to process image"] = "Impossibile elaborare l'immagine";
-$a->strings["Image exceeds size limit of %s"] = "La dimensione dell'immagine supera il limite di %s";
-$a->strings["Unable to process image."] = "Impossibile caricare l'immagine.";
-$a->strings["Upload File:"] = "Carica un file:";
-$a->strings["Select a profile:"] = "Seleziona un profilo:";
-$a->strings["Upload"] = "Carica";
-$a->strings["or"] = "o";
-$a->strings["skip this step"] = "salta questo passaggio";
-$a->strings["select a photo from your photo albums"] = "seleziona una foto dai tuoi album";
-$a->strings["Crop Image"] = "Ritaglia immagine";
-$a->strings["Please adjust the image cropping for optimum viewing."] = "Ritaglia l'immagine per una visualizzazione migliore.";
-$a->strings["Done Editing"] = "Finito";
-$a->strings["Image uploaded successfully."] = "Immagine caricata con successo.";
-$a->strings["Image upload failed."] = "Caricamento immagine fallito.";
$a->strings["Permission denied"] = "Permesso negato";
$a->strings["Invalid profile identifier."] = "Identificativo del profilo non valido.";
$a->strings["Profile Visibility Editor"] = "Modifica visibilità del profilo";
$a->strings["Click on a contact to add or remove."] = "Clicca su un contatto per aggiungerlo o rimuoverlo.";
$a->strings["Visible To"] = "Visibile a";
$a->strings["All Contacts (with secure profile access)"] = "Tutti i contatti (con profilo ad accesso sicuro)";
-$a->strings["Account approved."] = "Account approvato.";
-$a->strings["Registration revoked for %s"] = "Registrazione revocata per %s";
-$a->strings["Please login."] = "Accedi.";
-$a->strings["Remove My Account"] = "Rimuovi il mio account";
-$a->strings["This will completely remove your account. Once this has been done it is not recoverable."] = "Questo comando rimuoverà completamente il tuo account. Una volta rimosso non potrai più recuperarlo.";
-$a->strings["Please enter your password for verification:"] = "Inserisci la tua password per verifica:";
-$a->strings["Resubscribing to OStatus contacts"] = "Risottoscrivi i contatti OStatus";
-$a->strings["Error"] = "Errore";
-$a->strings["%1\$s is following %2\$s's %3\$s"] = "%1\$s sta seguendo %3\$s di %2\$s";
-$a->strings["Do you really want to delete this suggestion?"] = "Vuoi veramente cancellare questo suggerimento?";
-$a->strings["No suggestions available. If this is a new site, please try again in 24 hours."] = "Nessun suggerimento disponibile. Se questo è un sito nuovo, riprova tra 24 ore.";
-$a->strings["Ignore/Hide"] = "Ignora / Nascondi";
-$a->strings["Tag removed"] = "Tag rimosso";
-$a->strings["Remove Item Tag"] = "Rimuovi il tag";
-$a->strings["Select a tag to remove: "] = "Seleziona un tag da rimuovere: ";
+$a->strings["[Embedded content - reload page to view]"] = "[Contenuto incorporato - ricarica la pagina per visualizzarlo correttamente]";
+$a->strings["Public access denied."] = "Accesso negato.";
+$a->strings["No contacts."] = "Nessun contatto.";
+$a->strings["Access denied."] = "Accesso negato.";
+$a->strings["Only logged in users are permitted to perform a probing."] = "Solo agli utenti loggati è permesso effettuare un probe.";
$a->strings["This site has exceeded the number of allowed daily account registrations. Please try again tomorrow."] = "Questo sito ha superato il numero di registrazioni giornaliere consentite. Prova di nuovo domani.";
$a->strings["Import"] = "Importa";
$a->strings["Move account"] = "Muovi account";
$a->strings["This feature is experimental. We can't import contacts from the OStatus network (GNU Social/Statusnet) or from Diaspora"] = "Questa funzione è sperimentale. Non possiamo importare i contatti dalla rete OStatus (GNU Social/Statusnet) o da Diaspora";
$a->strings["Account file"] = "File account";
$a->strings["To export your account, go to \"Settings->Export your personal data\" and select \"Export account\""] = "Per esportare il tuo account, vai su \"Impostazioni -> Esporta i tuoi dati personali\" e seleziona \"Esporta account\"";
-$a->strings["[Embedded content - reload page to view]"] = "[Contenuto incorporato - ricarica la pagina per visualizzarlo correttamente]";
-$a->strings["No contacts."] = "Nessun contatto.";
-$a->strings["Access denied."] = "Accesso negato.";
-$a->strings["Invalid request."] = "Richiesta non valida.";
-$a->strings["Sorry, maybe your upload is bigger than the PHP configuration allows"] = "Mi spiace, forse il file che stai caricando è più grosso di quanto la configurazione di PHP permetta";
-$a->strings["Or - did you try to upload an empty file?"] = "O.. non avrai provato a caricare un file vuoto?";
-$a->strings["File exceeds size limit of %s"] = "Il file supera la dimensione massima di %s";
-$a->strings["File upload failed."] = "Caricamento del file non riuscito.";
-$a->strings["Number of daily wall messages for %s exceeded. Message failed."] = "Numero giornaliero di messaggi per %s superato. Invio fallito.";
-$a->strings["No recipient selected."] = "Nessun destinatario selezionato.";
-$a->strings["Unable to check your home location."] = "Impossibile controllare la tua posizione di origine.";
-$a->strings["Message could not be sent."] = "Il messaggio non può essere inviato.";
-$a->strings["Message collection failure."] = "Errore recuperando il messaggio.";
-$a->strings["Message sent."] = "Messaggio inviato.";
-$a->strings["No recipient."] = "Nessun destinatario.";
-$a->strings["Send Private Message"] = "Invia un messaggio privato";
-$a->strings["If you wish for %s to respond, please check that the privacy settings on your site allow private mail from unknown senders."] = "Se vuoi che %s ti risponda, controlla che le tue impostazioni di privacy permettano la ricezione di messaggi privati da mittenti sconosciuti.";
-$a->strings["To:"] = "A:";
-$a->strings["Subject:"] = "Oggetto:";
-$a->strings["Source (bbcode) text:"] = "Testo sorgente (bbcode):";
-$a->strings["Source (Diaspora) text to convert to BBcode:"] = "Testo sorgente (da Diaspora) da convertire in BBcode:";
-$a->strings["Source input: "] = "Sorgente:";
-$a->strings["bb2html (raw HTML): "] = "bb2html (HTML grezzo):";
-$a->strings["bb2html: "] = "bb2html:";
-$a->strings["bb2html2bb: "] = "bb2html2bb: ";
-$a->strings["bb2md: "] = "bb2md: ";
-$a->strings["bb2md2html: "] = "bb2md2html: ";
-$a->strings["bb2dia2bb: "] = "bb2dia2bb: ";
-$a->strings["bb2md2html2bb: "] = "bb2md2html2bb: ";
-$a->strings["Source input (Diaspora format): "] = "Sorgente (formato Diaspora):";
-$a->strings["diaspora2bb: "] = "diaspora2bb: ";
+$a->strings["Not available."] = "Non disponibile.";
+$a->strings["No results."] = "Nessun risultato.";
+$a->strings["No friends to display."] = "Nessun amico da visualizzare.";
+$a->strings["The post was created"] = "Il messaggio è stato creato";
+$a->strings["Access to this profile has been restricted."] = "L'accesso a questo profilo è stato limitato.";
$a->strings["View"] = "Mostra";
$a->strings["Previous"] = "Precedente";
$a->strings["Next"] = "Successivo";
$a->strings["This calendar format is not supported"] = "Questo formato di calendario non è supportato";
$a->strings["No exportable data found"] = "Nessun dato esportabile trovato";
$a->strings["calendar"] = "calendario";
-$a->strings["Not available."] = "Non disponibile.";
-$a->strings["No results."] = "Nessun risultato.";
-$a->strings["Profile not found."] = "Profilo non trovato.";
-$a->strings["This may occasionally happen if contact was requested by both persons and it has already been approved."] = "Questo può accadere occasionalmente se la richiesta di contatto era stata inviata da entrambe le persone e già approvata.";
-$a->strings["Response from remote site was not understood."] = "Errore di comunicazione con l'altro sito.";
-$a->strings["Unexpected response from remote site: "] = "La risposta dell'altro sito non può essere gestita: ";
-$a->strings["Confirmation completed successfully."] = "Conferma completata con successo.";
-$a->strings["Remote site reported: "] = "Il sito remoto riporta: ";
-$a->strings["Temporary failure. Please wait and try again."] = "Problema temporaneo. Attendi e riprova.";
-$a->strings["Introduction failed or was revoked."] = "La presentazione ha generato un errore o è stata revocata.";
-$a->strings["Unable to set contact photo."] = "Impossibile impostare la foto del contatto.";
-$a->strings["No user record found for '%s' "] = "Nessun utente trovato '%s'";
-$a->strings["Our site encryption key is apparently messed up."] = "La nostra chiave di criptazione del sito sembra essere corrotta.";
-$a->strings["Empty site URL was provided or URL could not be decrypted by us."] = "E' stato fornito un indirizzo vuoto o non possiamo decrittare l'indirizzo.";
-$a->strings["Contact record was not found for you on our site."] = "Il contatto non è stato trovato sul nostro sito.";
-$a->strings["Site public key not available in contact record for URL %s."] = "La chiave pubblica del sito non è disponibile per l'URL %s";
-$a->strings["The ID provided by your system is a duplicate on our system. It should work if you try again."] = "L'ID fornito dal tuo sistema è duplicato sul nostro sistema. Se riprovi dovrebbe funzionare.";
-$a->strings["Unable to set your contact credentials on our system."] = "Impossibile impostare le credenziali del tuo contatto sul nostro sistema.";
-$a->strings["Unable to update your contact profile details on our system"] = "Impossibile aggiornare i dettagli del tuo contatto sul nostro sistema";
-$a->strings["%1\$s has joined %2\$s"] = "%1\$s si è unito a %2\$s";
+$a->strings["%1\$s welcomes %2\$s"] = "%s dà il benvenuto a %s";
$a->strings["This introduction has already been accepted."] = "Questa presentazione è già stata accettata.";
$a->strings["Profile location is not valid or does not contain profile information."] = "L'indirizzo del profilo non è valido o non contiene un profilo.";
$a->strings["Warning: profile location has no identifiable owner name."] = "Attenzione: l'indirizzo del profilo non riporta il nome del proprietario.";
$a->strings["You have already introduced yourself here."] = "Ti sei già presentato qui.";
$a->strings["Apparently you are already friends with %s."] = "Pare che tu e %s siate già amici.";
$a->strings["Invalid profile URL."] = "Indirizzo profilo non valido.";
+$a->strings["Failed to update contact record."] = "Errore nell'aggiornamento del contatto.";
$a->strings["Your introduction has been sent."] = "La tua presentazione è stata inviata.";
$a->strings["Remote subscription can't be done for your network. Please subscribe directly on your system."] = "La richiesta di connessione remota non può essere effettuata per la tua rete. Invia la richiesta direttamente sul nostro sistema.";
$a->strings["Please login to confirm introduction."] = "Accedi per confermare la presentazione.";
$a->strings[" - please do not use this form. Instead, enter %s into your Diaspora search bar."] = " - per favore non usare questa form. Invece, inserisci %s nella tua barra di ricerca su Diaspora.";
$a->strings["Your Identity Address:"] = "L'indirizzo della tua identità:";
$a->strings["Submit Request"] = "Invia richiesta";
-$a->strings["People Search - %s"] = "Cerca persone - %s";
-$a->strings["Forum Search - %s"] = "Ricerca Forum - %s";
-$a->strings["Event can not end before it has started."] = "Un evento non può finire prima di iniziare.";
-$a->strings["Event title and start time are required."] = "Titolo e ora di inizio dell'evento sono richiesti.";
-$a->strings["Create New Event"] = "Crea un nuovo evento";
-$a->strings["Event details"] = "Dettagli dell'evento";
-$a->strings["Starting date and Title are required."] = "La data di inizio e il titolo sono richiesti.";
-$a->strings["Event Starts:"] = "L'evento inizia:";
-$a->strings["Required"] = "Richiesto";
-$a->strings["Finish date/time is not known or not relevant"] = "La data/ora di fine non è definita";
-$a->strings["Event Finishes:"] = "L'evento finisce:";
-$a->strings["Adjust for viewer timezone"] = "Visualizza con il fuso orario di chi legge";
-$a->strings["Description:"] = "Descrizione:";
-$a->strings["Title:"] = "Titolo:";
-$a->strings["Share this event"] = "Condividi questo evento";
-$a->strings["Failed to remove event"] = "Rimozione evento fallita.";
-$a->strings["Event removed"] = "Evento rimosso";
+$a->strings["Item not found"] = "Oggetto non trovato";
+$a->strings["Edit post"] = "Modifica messaggio";
+$a->strings["Not Found"] = "Non trovato";
+$a->strings["Contact added"] = "Contatto aggiunto";
$a->strings["You already added this contact."] = "Hai già aggiunto questo contatto.";
$a->strings["Diaspora support isn't enabled. Contact can't be added."] = "Il supporto Diaspora non è abilitato. Il contatto non può essere aggiunto.";
$a->strings["OStatus support is disabled. Contact can't be added."] = "Il supporto OStatus non è abilitato. Il contatto non può essere aggiunto.";
$a->strings["The network type couldn't be detected. Contact can't be added."] = "Non è possibile rilevare il tipo di rete. Il contatto non può essere aggiunto.";
-$a->strings["Contact added"] = "Contatto aggiunto";
-$a->strings["This is Friendica, version"] = "Questo è Friendica, versione";
-$a->strings["running at web location"] = "in esecuzione all'indirizzo web";
-$a->strings["Please visit <a href=\"http://friendica.com\">Friendica.com</a> to learn more about the Friendica project."] = "Visita <a href=\"http://friendica.com\">Friendica.com</a> per saperne di più sul progetto Friendica.";
-$a->strings["Bug reports and issues: please visit"] = "Segnalazioni di bug e problemi: visita";
-$a->strings["the bugtracker at github"] = "il bugtracker su github";
-$a->strings["Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - dot com"] = "Suggerimenti, lodi, donazioni, ecc - e-mail a \"Info\" at Friendica punto com";
-$a->strings["Installed plugins/addons/apps:"] = "Plugin/componenti aggiuntivi/applicazioni installate";
-$a->strings["No installed plugins/addons/apps"] = "Nessun plugin/componente aggiuntivo/applicazione installata";
-$a->strings["On this server the following remote servers are blocked."] = "In questo server i seguenti server remoti sono bloccati.";
-$a->strings["Reason for the block"] = "Motivazione del blocco";
+$a->strings["Profile URL"] = "URL Profilo";
$a->strings["Group created."] = "Gruppo creato.";
$a->strings["Could not create group."] = "Impossibile creare il gruppo.";
$a->strings["Group not found."] = "Gruppo non trovato.";
$a->strings["Group Editor"] = "Modifica gruppo";
$a->strings["Edit Group Name"] = "Modifica Nome Gruppo";
$a->strings["Members"] = "Membri";
+$a->strings["All Contacts"] = "Tutti i contatti";
+$a->strings["Group is empty"] = "Il gruppo è vuoto";
$a->strings["Remove Contact"] = "Rimuovi Contatto";
$a->strings["Add Contact"] = "Aggiungi Contatto";
-$a->strings["Manage Identities and/or Pages"] = "Gestisci identità e/o pagine";
-$a->strings["Toggle between different identities or community/group pages which share your account details or which you have been granted \"manage\" permissions"] = "Cambia tra differenti identità o pagine comunità/gruppi che condividono il tuo account o per cui hai i permessi di gestione";
-$a->strings["Select an identity to manage: "] = "Seleziona un'identità da gestire:";
-$a->strings["Unable to locate contact information."] = "Impossibile trovare le informazioni del contatto.";
-$a->strings["Do you really want to delete this message?"] = "Vuoi veramente cancellare questo messaggio?";
-$a->strings["Message deleted."] = "Messaggio eliminato.";
-$a->strings["Conversation removed."] = "Conversazione rimossa.";
-$a->strings["No messages."] = "Nessun messaggio.";
-$a->strings["Message not available."] = "Messaggio non disponibile.";
-$a->strings["Delete message"] = "Elimina il messaggio";
-$a->strings["Delete conversation"] = "Elimina la conversazione";
-$a->strings["No secure communications available. You <strong>may</strong> be able to respond from the sender's profile page."] = "Nessuna comunicazione sicura disponibile, <strong>Potresti</strong> essere in grado di rispondere dalla pagina del profilo del mittente.";
-$a->strings["Send Reply"] = "Invia la risposta";
-$a->strings["Unknown sender - %s"] = "Mittente sconosciuto - %s";
-$a->strings["You and %s"] = "Tu e %s";
-$a->strings["%s and You"] = "%s e Tu";
-$a->strings["D, d M Y - g:i A"] = "D d M Y - G:i";
-$a->strings["%d message"] = array(
- 0 => "%d messaggio",
- 1 => "%d messaggi",
-);
-$a->strings["Remove term"] = "Rimuovi termine";
-$a->strings["Warning: This group contains %s member from a network that doesn't allow non public messages."] = array(
- 0 => "Attenzione: Questo gruppo contiene %s membro da una rete che non permette la ricezione di messaggi non pubblici.",
- 1 => "Attenzione: Questo gruppo contiene %s membri da reti che non permettono la ricezione di messaggi non pubblici.",
+$a->strings["No profile"] = "Nessun profilo";
+$a->strings["Help:"] = "Guida:";
+$a->strings["Page not found."] = "Pagina non trovata.";
+$a->strings["Welcome to %s"] = "Benvenuto su %s";
+$a->strings["Total invitation limit exceeded."] = "Limite totale degli inviti superato.";
+$a->strings["%s : Not a valid email address."] = "%s: non è un indirizzo email valido.";
+$a->strings["Please join us on Friendica"] = "Unisciti a noi su Friendica";
+$a->strings["Invitation limit exceeded. Please contact your site administrator."] = "Limite degli inviti superato. Contatta l'amministratore del tuo sito.";
+$a->strings["%s : Message delivery failed."] = "%s: la consegna del messaggio fallita.";
+$a->strings["%d message sent."] = array(
+ 0 => "%d messaggio inviato.",
+ 1 => "%d messaggi inviati.",
);
-$a->strings["Messages in this group won't be send to these receivers."] = "I messaggi in questo gruppo non saranno inviati ai quei contatti.";
-$a->strings["Private messages to this person are at risk of public disclosure."] = "I messaggi privati a questa persona potrebbero risultare visibili anche pubblicamente.";
-$a->strings["Invalid contact."] = "Contatto non valido.";
-$a->strings["Commented Order"] = "Ordina per commento";
-$a->strings["Sort by Comment Date"] = "Ordina per data commento";
-$a->strings["Posted Order"] = "Ordina per invio";
-$a->strings["Sort by Post Date"] = "Ordina per data messaggio";
-$a->strings["Posts that mention or involve you"] = "Messaggi che ti citano o coinvolgono";
-$a->strings["New"] = "Nuovo";
-$a->strings["Activity Stream - by date"] = "Activity Stream - per data";
-$a->strings["Shared Links"] = "Links condivisi";
-$a->strings["Interesting Links"] = "Link Interessanti";
-$a->strings["Starred"] = "Preferiti";
-$a->strings["Favourite Posts"] = "Messaggi preferiti";
+$a->strings["You have no more invitations available"] = "Non hai altri inviti disponibili";
+$a->strings["Visit %s for a list of public sites that you can join. Friendica members on other sites can all connect with each other, as well as with members of many other social networks."] = "Visita %s per una lista di siti pubblici a cui puoi iscriverti. I membri Friendica su altri siti possono collegarsi uno con l'altro, come con membri di molti altri social network.";
+$a->strings["To accept this invitation, please visit and register at %s or any other public Friendica website."] = "Per accettare questo invito, visita e registrati su %s o su un'altro sito web Friendica aperto al pubblico.";
+$a->strings["Friendica sites all inter-connect to create a huge privacy-enhanced social web that is owned and controlled by its members. They can also connect with many traditional social networks. See %s for a list of alternate Friendica sites you can join."] = "I siti Friendica son tutti collegati tra loro per creare una grossa rete sociale rispettosa della privacy, posseduta e controllata dai suoi membri. I siti Friendica possono anche collegarsi a molti altri social network tradizionali. Vai su %s per una lista di siti Friendica alternativi a cui puoi iscriverti.";
+$a->strings["Our apologies. This system is not currently configured to connect with other public sites or invite members."] = "Ci scusiamo, questo sistema non è configurato per collegarsi con altri siti pubblici o per invitare membri.";
+$a->strings["To accept this invitation, please visit and register at %s."] = "Per accettare questo invito, visita e registrati su %s";
+$a->strings["Friendica sites all inter-connect to create a huge privacy-enhanced social web that is owned and controlled by its members. They can also connect with many traditional social networks."] = "";
+$a->strings["Send invitations"] = "Invia inviti";
+$a->strings["Enter email addresses, one per line:"] = "Inserisci gli indirizzi email, uno per riga:";
+$a->strings["Your message:"] = "Il tuo messaggio:";
+$a->strings["You are cordially invited to join me and other close friends on Friendica - and help us to create a better social web."] = "Sei cordialmente invitato/a ad unirti a me e ad altri amici su Friendica, e ad aiutarci a creare una rete sociale migliore.";
+$a->strings["You will need to supply this invitation code: \$invite_code"] = "Sarà necessario fornire questo codice invito: \$invite_code";
+$a->strings["Once you have registered, please connect with me via my profile page at:"] = "Una volta registrato, connettiti con me dal mio profilo:";
+$a->strings["For more information about the Friendica project and why we feel it is important, please visit http://friendi.ca"] = "Per maggiori informazioni sul progetto Friendica e perchè pensiamo sia importante, visita http://friendi.ca ";
+$a->strings["Time Conversion"] = "Conversione Ora";
+$a->strings["Friendica provides this service for sharing events with other networks and friends in unknown timezones."] = "Friendica fornisce questo servizio per la condivisione di eventi con altre reti e amici in fusi orari sconosciuti.";
+$a->strings["UTC time: %s"] = "Ora UTC: %s";
+$a->strings["Current timezone: %s"] = "Fuso orario corrente: %s";
+$a->strings["Converted localtime: %s"] = "Ora locale convertita: %s";
+$a->strings["Please select your timezone:"] = "Selezionare il tuo fuso orario:";
+$a->strings["No valid account found."] = "Nessun account valido trovato.";
+$a->strings["Password reset request issued. Check your email."] = "La richiesta per reimpostare la password è stata inviata. Controlla la tua email.";
+$a->strings["\n\t\tDear %1\$s,\n\t\t\tA request was recently received at \"%2\$s\" to reset your account\n\t\tpassword. In order to confirm this request, please select the verification link\n\t\tbelow or paste it into your web browser address bar.\n\n\t\tIf you did NOT request this change, please DO NOT follow the link\n\t\tprovided and ignore and/or delete this email.\n\n\t\tYour password will not be changed unless we can verify that you\n\t\tissued this request."] = "\nGentile %1\$s,\n abbiamo ricevuto su \"%2\$s\" una richiesta di resettare la password del tuo account. Per confermare questa richiesta, selezionate il link di conferma qui sotto o incollatelo nella barra indirizzo del vostro browser.\n\nSe NON hai richiesto questa modifica, NON selezionare il link e ignora o cancella questa email.\n\nLa tua password non verrà modificata a meno che non possiamo verificare che tu abbia effettivamente richiesto la modifica.";
+$a->strings["\n\t\tFollow this link to verify your identity:\n\n\t\t%1\$s\n\n\t\tYou will then receive a follow-up message containing the new password.\n\t\tYou may change that password from your account settings page after logging in.\n\n\t\tThe login details are as follows:\n\n\t\tSite Location:\t%2\$s\n\t\tLogin Name:\t%3\$s"] = "\nSegui questo link per verificare la tua identità:\n\n%1\$s\n\nRiceverai in un successivo messaggio la nuova password.\nPotrai cambiarla dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato.\n\nI dettagli del tuo account sono:\n Indirizzo del sito: %2\$s\n Nome utente: %3\$s";
+$a->strings["Password reset requested at %s"] = "Richiesta reimpostazione password su %s";
+$a->strings["Request could not be verified. (You may have previously submitted it.) Password reset failed."] = "La richiesta non può essere verificata. (Puoi averla già richiesta precedentemente). Reimpostazione password fallita.";
+$a->strings["Password Reset"] = "Reimpostazione password";
+$a->strings["Your password has been reset as requested."] = "La tua password è stata reimpostata come richiesto.";
+$a->strings["Your new password is"] = "La tua nuova password è";
+$a->strings["Save or copy your new password - and then"] = "Salva o copia la tua nuova password, quindi";
+$a->strings["click here to login"] = "clicca qui per entrare";
+$a->strings["Your password may be changed from the <em>Settings</em> page after successful login."] = "Puoi cambiare la tua password dalla pagina <em>Impostazioni</em> dopo aver effettuato l'accesso.";
+$a->strings["\n\t\t\t\tDear %1\$s,\n\t\t\t\t\tYour password has been changed as requested. Please retain this\n\t\t\t\tinformation for your records (or change your password immediately to\n\t\t\t\tsomething that you will remember).\n\t\t\t"] = "\nGentile %1\$s,\n La tua password è stata modificata come richiesto.\nSalva questa password, o sostituiscila immediatamente con qualcosa che puoi ricordare.";
+$a->strings["\n\t\t\t\tYour login details are as follows:\n\n\t\t\t\tSite Location:\t%1\$s\n\t\t\t\tLogin Name:\t%2\$s\n\t\t\t\tPassword:\t%3\$s\n\n\t\t\t\tYou may change that password from your account settings page after logging in.\n\t\t\t"] = "\nI dettagli del tuo account sono:\n\n Indirizzo del sito: %1\$s\n Nome utente: %2\$s\n Password: %3\$s\n\nPuoi cambiare questa password dalla pagina \"Impostazioni\" del tuo account dopo esserti autenticato.";
+$a->strings["Your password has been changed at %s"] = "La tua password presso %s è stata cambiata";
+$a->strings["Forgot your Password?"] = "Hai dimenticato la password?";
+$a->strings["Enter your email address and submit to have your password reset. Then check your email for further instructions."] = "Inserisci il tuo indirizzo email per reimpostare la password.";
+$a->strings["Nickname or Email: "] = "Nome utente o email: ";
+$a->strings["Reset"] = "Reimposta";
+$a->strings["Manage Identities and/or Pages"] = "Gestisci identità e/o pagine";
+$a->strings["Toggle between different identities or community/group pages which share your account details or which you have been granted \"manage\" permissions"] = "Cambia tra differenti identità o pagine comunità/gruppi che condividono il tuo account o per cui hai i permessi di gestione";
+$a->strings["Select an identity to manage: "] = "Seleziona un'identità da gestire:";
+$a->strings["No keywords to match. Please add keywords to your default profile."] = "Nessuna parola chiave per l'abbinamento. Aggiungi parole chiave al tuo profilo predefinito.";
+$a->strings["is interested in:"] = "è interessato a:";
+$a->strings["Profile Match"] = "Profili corrispondenti";
+$a->strings["No matches"] = "Nessun risultato";
+$a->strings["No recipient selected."] = "Nessun destinatario selezionato.";
+$a->strings["Unable to locate contact information."] = "Impossibile trovare le informazioni del contatto.";
+$a->strings["Message could not be sent."] = "Il messaggio non può essere inviato.";
+$a->strings["Message collection failure."] = "Errore recuperando il messaggio.";
+$a->strings["Message sent."] = "Messaggio inviato.";
+$a->strings["Do you really want to delete this message?"] = "Vuoi veramente cancellare questo messaggio?";
+$a->strings["Message deleted."] = "Messaggio eliminato.";
+$a->strings["Conversation removed."] = "Conversazione rimossa.";
+$a->strings["Send Private Message"] = "Invia un messaggio privato";
+$a->strings["To:"] = "A:";
+$a->strings["Subject:"] = "Oggetto:";
+$a->strings["No messages."] = "Nessun messaggio.";
+$a->strings["Message not available."] = "Messaggio non disponibile.";
+$a->strings["Delete message"] = "Elimina il messaggio";
+$a->strings["Delete conversation"] = "Elimina la conversazione";
+$a->strings["No secure communications available. You <strong>may</strong> be able to respond from the sender's profile page."] = "Nessuna comunicazione sicura disponibile, <strong>Potresti</strong> essere in grado di rispondere dalla pagina del profilo del mittente.";
+$a->strings["Send Reply"] = "Invia la risposta";
+$a->strings["Unknown sender - %s"] = "Mittente sconosciuto - %s";
+$a->strings["You and %s"] = "Tu e %s";
+$a->strings["%s and You"] = "%s e Tu";
+$a->strings["D, d M Y - g:i A"] = "D d M Y - G:i";
+$a->strings["%d message"] = array(
+ 0 => "%d messaggio",
+ 1 => "%d messaggi",
+);
+$a->strings["Invalid request identifier."] = "L'identificativo della richiesta non è valido.";
+$a->strings["Discard"] = "Scarta";
+$a->strings["Ignore"] = "Ignora";
+$a->strings["Network Notifications"] = "Notifiche dalla rete";
+$a->strings["System Notifications"] = "Notifiche di sistema";
+$a->strings["Personal Notifications"] = "Notifiche personali";
+$a->strings["Home Notifications"] = "Notifiche bacheca";
+$a->strings["Show Ignored Requests"] = "Mostra richieste ignorate";
+$a->strings["Hide Ignored Requests"] = "Nascondi richieste ignorate";
+$a->strings["Notification type: "] = "Tipo di notifica: ";
+$a->strings["suggested by %s"] = "suggerito da %s";
+$a->strings["Hide this contact from others"] = "Nascondi questo contatto agli altri";
+$a->strings["Post a new friend activity"] = "Invia una attività \"è ora amico con\"";
+$a->strings["if applicable"] = "se applicabile";
+$a->strings["Approve"] = "Approva";
+$a->strings["Claims to be known to you: "] = "Dice di conoscerti: ";
+$a->strings["yes"] = "si";
+$a->strings["no"] = "no";
+$a->strings["Shall your connection be bidirectional or not?"] = "La connessione dovrà essere bidirezionale o no?";
+$a->strings["Accepting %s as a friend allows %s to subscribe to your posts, and you will also receive updates from them in your news feed."] = "Accettando %s come amico permette a %s di seguire i tuoi post, e a te di riceverne gli aggiornamenti.";
+$a->strings["Accepting %s as a subscriber allows them to subscribe to your posts, but you will not receive updates from them in your news feed."] = "Accentrando %s come abbonato gli permette di abbonarsi ai tuoi messaggi, ma tu non riceverai aggiornamenti da lui.";
+$a->strings["Accepting %s as a sharer allows them to subscribe to your posts, but you will not receive updates from them in your news feed."] = "Accentando %s come condivisore, gli permetti di abbonarsi ai tuoi messaggi, ma tu non riceverai nessun aggiornamento da loro.";
+$a->strings["Friend"] = "Amico";
+$a->strings["Sharer"] = "Condivisore";
+$a->strings["Subscriber"] = "Abbonato";
+$a->strings["No introductions."] = "Nessuna presentazione.";
+$a->strings["Show unread"] = "Mostra non letti";
+$a->strings["Show all"] = "Mostra tutti";
+$a->strings["No more %s notifications."] = "Nessun'altra notifica %s.";
+$a->strings["No more system notifications."] = "Nessuna nuova notifica di sistema.";
+$a->strings["Post successful."] = "Inviato!";
$a->strings["OpenID protocol error. No ID returned."] = "Errore protocollo OpenID. Nessun ID ricevuto.";
$a->strings["Account not found and OpenID registration is not permitted on this site."] = "L'account non è stato trovato, e la registrazione via OpenID non è permessa su questo sito.";
-$a->strings["Recent Photos"] = "Foto recenti";
-$a->strings["Upload New Photos"] = "Carica nuove foto";
-$a->strings["everybody"] = "tutti";
-$a->strings["Contact information unavailable"] = "I dati di questo contatto non sono disponibili";
-$a->strings["Album not found."] = "Album non trovato.";
-$a->strings["Delete Album"] = "Rimuovi album";
-$a->strings["Do you really want to delete this photo album and all its photos?"] = "Vuoi davvero cancellare questo album e tutte le sue foto?";
-$a->strings["Delete Photo"] = "Rimuovi foto";
-$a->strings["Do you really want to delete this photo?"] = "Vuoi veramente cancellare questa foto?";
-$a->strings["%1\$s was tagged in %2\$s by %3\$s"] = "%1\$s è stato taggato in %2\$s da %3\$s";
-$a->strings["a photo"] = "una foto";
-$a->strings["Image file is empty."] = "Il file dell'immagine è vuoto.";
-$a->strings["No photos selected"] = "Nessuna foto selezionata";
-$a->strings["Access to this item is restricted."] = "Questo oggetto non è visibile a tutti.";
-$a->strings["You have used %1$.2f Mbytes of %2$.2f Mbytes photo storage."] = "Hai usato %1$.2f MBytes su %2$.2f disponibili.";
-$a->strings["Upload Photos"] = "Carica foto";
-$a->strings["New album name: "] = "Nome nuovo album: ";
-$a->strings["or existing album name: "] = "o nome di un album esistente: ";
-$a->strings["Do not show a status post for this upload"] = "Non creare un post per questo upload";
-$a->strings["Show to Groups"] = "Mostra ai gruppi";
-$a->strings["Show to Contacts"] = "Mostra ai contatti";
-$a->strings["Private Photo"] = "Foto privata";
-$a->strings["Public Photo"] = "Foto pubblica";
-$a->strings["Edit Album"] = "Modifica album";
-$a->strings["Show Newest First"] = "Mostra nuove foto per prime";
-$a->strings["Show Oldest First"] = "Mostra vecchie foto per prime";
-$a->strings["View Photo"] = "Vedi foto";
-$a->strings["Permission denied. Access to this item may be restricted."] = "Permesso negato. L'accesso a questo elemento può essere limitato.";
-$a->strings["Photo not available"] = "Foto non disponibile";
-$a->strings["View photo"] = "Vedi foto";
-$a->strings["Edit photo"] = "Modifica foto";
-$a->strings["Use as profile photo"] = "Usa come foto del profilo";
-$a->strings["View Full Size"] = "Vedi dimensione intera";
-$a->strings["Tags: "] = "Tag: ";
-$a->strings["[Remove any tag]"] = "[Rimuovi tutti i tag]";
-$a->strings["New album name"] = "Nuovo nome dell'album";
-$a->strings["Caption"] = "Titolo";
-$a->strings["Add a Tag"] = "Aggiungi tag";
-$a->strings["Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"] = "Esempio: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping";
-$a->strings["Do not rotate"] = "Non ruotare";
-$a->strings["Rotate CW (right)"] = "Ruota a destra";
-$a->strings["Rotate CCW (left)"] = "Ruota a sinistra";
-$a->strings["Private photo"] = "Foto privata";
-$a->strings["Public photo"] = "Foto pubblica";
-$a->strings["Map"] = "Mappa";
-$a->strings["View Album"] = "Sfoglia l'album";
-$a->strings["Only logged in users are permitted to perform a probing."] = "Solo agli utenti loggati è permesso effettuare un probe.";
+$a->strings["Not Extended"] = "Not Extended";
$a->strings["Tips for New Members"] = "Consigli per i Nuovi Utenti";
-$a->strings["Profile deleted."] = "Profilo eliminato.";
-$a->strings["Profile-"] = "Profilo-";
-$a->strings["New profile created."] = "Il nuovo profilo è stato creato.";
-$a->strings["Profile unavailable to clone."] = "Impossibile duplicare il profilo.";
-$a->strings["Profile Name is required."] = "Il nome profilo è obbligatorio .";
-$a->strings["Marital Status"] = "Stato civile";
-$a->strings["Romantic Partner"] = "Partner romantico";
-$a->strings["Work/Employment"] = "Lavoro/Impiego";
-$a->strings["Religion"] = "Religione";
-$a->strings["Political Views"] = "Orientamento Politico";
-$a->strings["Gender"] = "Sesso";
-$a->strings["Sexual Preference"] = "Preferenza sessuale";
-$a->strings["XMPP"] = "XMPP";
-$a->strings["Homepage"] = "Homepage";
-$a->strings["Interests"] = "Interessi";
-$a->strings["Address"] = "Indirizzo";
-$a->strings["Location"] = "Posizione";
-$a->strings["Profile updated."] = "Profilo aggiornato.";
-$a->strings[" and "] = "e ";
-$a->strings["public profile"] = "profilo pubblico";
-$a->strings["%1\$s changed %2\$s to “%3\$s”"] = "%1\$s ha cambiato %2\$s in “%3\$s”";
-$a->strings[" - Visit %1\$s's %2\$s"] = "- Visita %2\$s di %1\$s";
-$a->strings["%1\$s has an updated %2\$s, changing %3\$s."] = "%1\$s ha un %2\$s aggiornato. Ha cambiato %3\$s";
-$a->strings["Hide contacts and friends:"] = "Nascondi contatti:";
-$a->strings["Hide your contact/friend list from viewers of this profile?"] = "Nascondi la tua lista di contatti/amici ai visitatori di questo profilo?";
-$a->strings["Show more profile fields:"] = "Mostra più informazioni di profilo:";
-$a->strings["Profile Actions"] = "Azioni Profilo";
-$a->strings["Edit Profile Details"] = "Modifica i dettagli del profilo";
-$a->strings["Change Profile Photo"] = "Cambia la foto del profilo";
-$a->strings["View this profile"] = "Visualizza questo profilo";
-$a->strings["Create a new profile using these settings"] = "Crea un nuovo profilo usando queste impostazioni";
-$a->strings["Clone this profile"] = "Clona questo profilo";
-$a->strings["Delete this profile"] = "Elimina questo profilo";
-$a->strings["Basic information"] = "Informazioni di base";
-$a->strings["Profile picture"] = "Immagine del profilo";
-$a->strings["Preferences"] = "Preferenze";
-$a->strings["Status information"] = "Informazioni stato";
-$a->strings["Additional information"] = "Informazioni aggiuntive";
-$a->strings["Relation"] = "Relazione";
-$a->strings["Your Gender:"] = "Il tuo sesso:";
-$a->strings["<span class=\"heart\">♥</span> Marital Status:"] = "<span class=\"heart\">♥</span> Stato sentimentale:";
-$a->strings["Example: fishing photography software"] = "Esempio: pesca fotografia programmazione";
-$a->strings["Profile Name:"] = "Nome del profilo:";
-$a->strings["This is your <strong>public</strong> profile.<br />It <strong>may</strong> be visible to anybody using the internet."] = "Questo è il tuo profilo <strong>publico</strong>.<br /><strong>Potrebbe</strong> essere visto da chiunque attraverso internet.";
-$a->strings["Your Full Name:"] = "Il tuo nome completo:";
-$a->strings["Title/Description:"] = "Breve descrizione (es. titolo, posizione, altro):";
-$a->strings["Street Address:"] = "Indirizzo (via/piazza):";
-$a->strings["Locality/City:"] = "Località:";
-$a->strings["Region/State:"] = "Regione/Stato:";
-$a->strings["Postal/Zip Code:"] = "CAP:";
-$a->strings["Country:"] = "Nazione:";
-$a->strings["Who: (if applicable)"] = "Con chi: (se possibile)";
-$a->strings["Examples: cathy123, Cathy Williams, cathy@example.com"] = "Esempio: cathy123, Cathy Williams, cathy@example.com";
-$a->strings["Since [date]:"] = "Dal [data]:";
-$a->strings["Tell us about yourself..."] = "Raccontaci di te...";
-$a->strings["XMPP (Jabber) address:"] = "Indirizzo XMPP (Jabber):";
-$a->strings["The XMPP address will be propagated to your contacts so that they can follow you."] = "L'indirizzo XMPP verrà propagato ai tuoi contatti così che possano seguirti.";
-$a->strings["Homepage URL:"] = "Homepage:";
-$a->strings["Religious Views:"] = "Orientamento religioso:";
-$a->strings["Public Keywords:"] = "Parole chiave visibili a tutti:";
-$a->strings["(Used for suggesting potential friends, can be seen by others)"] = "(E' utilizzato per suggerire potenziali amici, può essere visto da altri)";
-$a->strings["Private Keywords:"] = "Parole chiave private:";
-$a->strings["(Used for searching profiles, never shown to others)"] = "(Usato per cercare tra i profili, non è mai visibile agli altri)";
-$a->strings["Musical interests"] = "Interessi musicali";
-$a->strings["Books, literature"] = "Libri, letteratura";
-$a->strings["Television"] = "Televisione";
-$a->strings["Film/dance/culture/entertainment"] = "Film/danza/cultura/intrattenimento";
-$a->strings["Hobbies/Interests"] = "Hobby/interessi";
-$a->strings["Love/romance"] = "Amore";
-$a->strings["Work/employment"] = "Lavoro/impiego";
-$a->strings["School/education"] = "Scuola/educazione";
-$a->strings["Contact information and Social Networks"] = "Informazioni su contatti e social network";
-$a->strings["Edit/Manage Profiles"] = "Modifica / Gestisci profili";
-$a->strings["Registration successful. Please check your email for further instructions."] = "Registrazione completata. Controlla la tua mail per ulteriori informazioni.";
-$a->strings["Failed to send email message. Here your accout details:<br> login: %s<br> password: %s<br><br>You can change your password after login."] = "Si è verificato un errore inviando l'email. I dettagli del tuo account:<br> login: %s<br> password: %s<br><br>Puoi cambiare la password dopo il login.";
-$a->strings["Registration successful."] = "Registrazione completata.";
-$a->strings["Your registration can not be processed."] = "La tua registrazione non puo' essere elaborata.";
-$a->strings["Your registration is pending approval by the site owner."] = "La tua richiesta è in attesa di approvazione da parte del proprietario del sito.";
-$a->strings["You may (optionally) fill in this form via OpenID by supplying your OpenID and clicking 'Register'."] = "Se vuoi, puoi riempire questo modulo tramite OpenID, inserendo il tuo OpenID e cliccando 'Registra'.";
-$a->strings["If you are not familiar with OpenID, please leave that field blank and fill in the rest of the items."] = "Se non hai familiarità con OpenID, lascia il campo vuoto e riempi il resto della maschera.";
-$a->strings["Your OpenID (optional): "] = "Il tuo OpenID (opzionale): ";
-$a->strings["Include your profile in member directory?"] = "Includi il tuo profilo nell'elenco pubblico?";
-$a->strings["Note for the admin"] = "Nota per l'amministratore";
-$a->strings["Leave a message for the admin, why you want to join this node"] = "Lascia un messaggio per l'amministratore, per esempio perché vuoi registrarti su questo nodo";
-$a->strings["Membership on this site is by invitation only."] = "La registrazione su questo sito è solo su invito.";
-$a->strings["Your invitation ID: "] = "L'ID del tuo invito:";
-$a->strings["Registration"] = "Registrazione";
-$a->strings["Your Full Name (e.g. Joe Smith, real or real-looking): "] = "Il tuo nome completo (es. Mario Rossi, vero o che sembri vero): ";
-$a->strings["Your Email Address: "] = "Il tuo indirizzo email: ";
-$a->strings["New Password:"] = "Nuova password:";
-$a->strings["Leave empty for an auto generated password."] = "Lascia vuoto per generare automaticamente una password.";
-$a->strings["Confirm:"] = "Conferma:";
-$a->strings["Choose a profile nickname. This must begin with a text character. Your profile address on this site will then be '<strong>nickname@\$sitename</strong>'."] = "Scegli un nome utente. Deve cominciare con una lettera. L'indirizzo del tuo profilo sarà '<strong>soprannome@\$sitename</strong>'.";
-$a->strings["Choose a nickname: "] = "Scegli un nome utente: ";
-$a->strings["Import your profile to this friendica instance"] = "Importa il tuo profilo in questo server friendica";
-$a->strings["Only logged in users are permitted to perform a search."] = "Solo agli utenti autenticati è permesso eseguire ricerche.";
-$a->strings["Too Many Requests"] = "Troppe richieste";
-$a->strings["Only one search per minute is permitted for not logged in users."] = "Solo una ricerca al minuto è permessa agli utenti non autenticati.";
-$a->strings["Items tagged with: %s"] = "Elementi taggati con: %s";
-$a->strings["Account"] = "Account";
-$a->strings["Additional features"] = "Funzionalità aggiuntive";
-$a->strings["Display"] = "Visualizzazione";
-$a->strings["Social Networks"] = "Social Networks";
-$a->strings["Plugins"] = "Plugin";
-$a->strings["Connected apps"] = "Applicazioni collegate";
-$a->strings["Export personal data"] = "Esporta dati personali";
-$a->strings["Remove account"] = "Rimuovi account";
-$a->strings["Missing some important data!"] = "Mancano alcuni dati importanti!";
-$a->strings["Failed to connect with email account using the settings provided."] = "Impossibile collegarsi all'account email con i parametri forniti.";
-$a->strings["Email settings updated."] = "Impostazioni e-mail aggiornate.";
-$a->strings["Features updated"] = "Funzionalità aggiornate";
-$a->strings["Relocate message has been send to your contacts"] = "Il messaggio di trasloco è stato inviato ai tuoi contatti";
-$a->strings["Empty passwords are not allowed. Password unchanged."] = "Le password non possono essere vuote. Password non cambiata.";
-$a->strings["Wrong password."] = "Password sbagliata.";
-$a->strings["Password changed."] = "Password cambiata.";
-$a->strings["Password update failed. Please try again."] = "Aggiornamento password fallito. Prova ancora.";
-$a->strings[" Please use a shorter name."] = " Usa un nome più corto.";
-$a->strings[" Name too short."] = " Nome troppo corto.";
-$a->strings["Wrong Password"] = "Password Sbagliata";
-$a->strings[" Not valid email."] = " Email non valida.";
-$a->strings[" Cannot change to that email."] = "Non puoi usare quella email.";
-$a->strings["Private forum has no privacy permissions. Using default privacy group."] = "Il forum privato non ha permessi di privacy. Uso il gruppo di privacy predefinito.";
-$a->strings["Private forum has no privacy permissions and no default privacy group."] = "Il gruppo privato non ha permessi di privacy e nessun gruppo di privacy predefinito.";
-$a->strings["Settings updated."] = "Impostazioni aggiornate.";
-$a->strings["Add application"] = "Aggiungi applicazione";
-$a->strings["Save Settings"] = "Salva Impostazioni";
-$a->strings["Consumer Key"] = "Consumer Key";
-$a->strings["Consumer Secret"] = "Consumer Secret";
-$a->strings["Redirect"] = "Redirect";
-$a->strings["Icon url"] = "Url icona";
-$a->strings["You can't edit this application."] = "Non puoi modificare questa applicazione.";
-$a->strings["Connected Apps"] = "Applicazioni Collegate";
-$a->strings["Client key starts with"] = "Chiave del client inizia con";
-$a->strings["No name"] = "Nessun nome";
-$a->strings["Remove authorization"] = "Rimuovi l'autorizzazione";
-$a->strings["No Plugin settings configured"] = "Nessun plugin ha impostazioni modificabili";
-$a->strings["Plugin Settings"] = "Impostazioni plugin";
-$a->strings["Off"] = "Spento";
-$a->strings["On"] = "Acceso";
-$a->strings["Additional Features"] = "Funzionalità aggiuntive";
-$a->strings["General Social Media Settings"] = "Impostazioni Media Sociali";
-$a->strings["Disable intelligent shortening"] = "Disabilita accorciamento intelligente";
-$a->strings["Normally the system tries to find the best link to add to shortened posts. If this option is enabled then every shortened post will always point to the original friendica post."] = "Normalmente il sistema tenta di trovare il migliore link da aggiungere a un post accorciato. Se questa opzione è abilitata, ogni post accorciato conterrà sempre un link al post originale su Friendica.";
-$a->strings["Automatically follow any GNU Social (OStatus) followers/mentioners"] = "Segui automaticamente chiunque da GNU Social (OStatus) ti segua o ti menzioni";
-$a->strings["If you receive a message from an unknown OStatus user, this option decides what to do. If it is checked, a new contact will be created for every unknown user."] = "Se ricevi un messaggio da un utente OStatus sconosciuto, questa opzione decide cosa fare. Se selezionato, un nuovo contatto verrà creato per ogni utente sconosciuto.";
-$a->strings["Default group for OStatus contacts"] = "Gruppo di default per i contatti OStatus";
-$a->strings["Your legacy GNU Social account"] = "Il tuo vecchio account GNU Social";
-$a->strings["If you enter your old GNU Social/Statusnet account name here (in the format user@domain.tld), your contacts will be added automatically. The field will be emptied when done."] = "Se inserisci il nome del tuo vecchio account GNU Social/Statusnet qui (nel formato utente@dominio.tld), i tuoi contatti verranno automaticamente aggiunti. Il campo verrà svuotato una volta terminato.";
-$a->strings["Repair OStatus subscriptions"] = "Ripara le iscrizioni OStatus";
-$a->strings["Built-in support for %s connectivity is %s"] = "Il supporto integrato per la connettività con %s è %s";
-$a->strings["enabled"] = "abilitato";
-$a->strings["disabled"] = "disabilitato";
-$a->strings["GNU Social (OStatus)"] = "GNU Social (OStatus)";
-$a->strings["Email access is disabled on this site."] = "L'accesso email è disabilitato su questo sito.";
-$a->strings["Email/Mailbox Setup"] = "Impostazioni email";
-$a->strings["If you wish to communicate with email contacts using this service (optional), please specify how to connect to your mailbox."] = "Se vuoi comunicare con i contatti email usando questo servizio, specifica come collegarti alla tua casella di posta. (opzionale)";
-$a->strings["Last successful email check:"] = "Ultimo controllo email eseguito con successo:";
-$a->strings["IMAP server name:"] = "Nome server IMAP:";
-$a->strings["IMAP port:"] = "Porta IMAP:";
-$a->strings["Security:"] = "Sicurezza:";
-$a->strings["None"] = "Nessuna";
-$a->strings["Email login name:"] = "Nome utente email:";
-$a->strings["Email password:"] = "Password email:";
-$a->strings["Reply-to address:"] = "Indirizzo di risposta:";
-$a->strings["Send public posts to all email contacts:"] = "Invia i messaggi pubblici ai contatti email:";
-$a->strings["Action after import:"] = "Azione post importazione:";
-$a->strings["Move to folder"] = "Sposta nella cartella";
-$a->strings["Move to folder:"] = "Sposta nella cartella:";
-$a->strings["No special theme for mobile devices"] = "Nessun tema speciale per i dispositivi mobili";
-$a->strings["Display Settings"] = "Impostazioni Grafiche";
-$a->strings["Display Theme:"] = "Tema:";
-$a->strings["Mobile Theme:"] = "Tema mobile:";
-$a->strings["Suppress warning of insecure networks"] = "Sopprimi avvisi reti insicure";
-$a->strings["Should the system suppress the warning that the current group contains members of networks that can't receive non public postings."] = "Il sistema sopprimerà l'avviso che il gruppo selezionato contiene membri di reti che non possono ricevere post non pubblici.";
-$a->strings["Update browser every xx seconds"] = "Aggiorna il browser ogni x secondi";
-$a->strings["Minimum of 10 seconds. Enter -1 to disable it."] = "Minimo 10 secondi. Inserisci -1 per disabilitarlo";
-$a->strings["Number of items to display per page:"] = "Numero di elementi da mostrare per pagina:";
-$a->strings["Maximum of 100 items"] = "Massimo 100 voci";
-$a->strings["Number of items to display per page when viewed from mobile device:"] = "Numero di voci da visualizzare per pagina quando si utilizza un dispositivo mobile:";
-$a->strings["Don't show emoticons"] = "Non mostrare le emoticons";
-$a->strings["Calendar"] = "Calendario";
-$a->strings["Beginning of week:"] = "Inizio della settimana:";
-$a->strings["Don't show notices"] = "Non mostrare gli avvisi";
-$a->strings["Infinite scroll"] = "Scroll infinito";
-$a->strings["Automatic updates only at the top of the network page"] = "Aggiornamenti automatici solo in cima alla pagina \"rete\"";
-$a->strings["Bandwith Saver Mode"] = "Modalità Salva Banda";
-$a->strings["When enabled, embedded content is not displayed on automatic updates, they only show on page reload."] = "Quando abilitato, il contenuto embeddato non è mostrato quando la pagina si aggiorna automaticamente, ma solo quando la pagina viene ricaricata.";
-$a->strings["General Theme Settings"] = "Opzioni Generali Tema";
-$a->strings["Custom Theme Settings"] = "Opzioni Personalizzate Tema";
-$a->strings["Content Settings"] = "Opzioni Contenuto";
-$a->strings["Theme settings"] = "Impostazioni tema";
-$a->strings["Account Types"] = "Tipi di Account";
-$a->strings["Personal Page Subtypes"] = "Sottotipi di Pagine Personali";
-$a->strings["Community Forum Subtypes"] = "Sottotipi di Community Forum";
-$a->strings["Personal Page"] = "Pagina Personale";
-$a->strings["This account is a regular personal profile"] = "Questo account è un profilo personale regolare";
-$a->strings["Organisation Page"] = "Pagina Organizzazione";
-$a->strings["This account is a profile for an organisation"] = "Questo account è il profilo per un'organizzazione";
-$a->strings["News Page"] = "Pagina Notizie";
-$a->strings["This account is a news account/reflector"] = "Questo account è un account di notizie";
-$a->strings["Community Forum"] = "Community Forum";
-$a->strings["This account is a community forum where people can discuss with each other"] = "Questo account è un forum comunitario dove le persone possono discutere tra loro";
-$a->strings["Normal Account Page"] = "Pagina Account Normale";
-$a->strings["This account is a normal personal profile"] = "Questo account è un normale profilo personale";
-$a->strings["Soapbox Page"] = "Pagina Sandbox";
-$a->strings["Automatically approve all connection/friend requests as read-only fans"] = "Chi richiede la connessione/amicizia sarà accettato automaticamente come fan che potrà solamente leggere la bacheca";
-$a->strings["Public Forum"] = "Forum Pubblico";
-$a->strings["Automatically approve all contact requests"] = "Approva automaticamente tutte le richieste di contatto";
-$a->strings["Automatic Friend Page"] = "Pagina con amicizia automatica";
-$a->strings["Automatically approve all connection/friend requests as friends"] = "Chi richiede la connessione/amicizia sarà accettato automaticamente come amico";
-$a->strings["Private Forum [Experimental]"] = "Forum privato [sperimentale]";
-$a->strings["Private forum - approved members only"] = "Forum privato - solo membri approvati";
-$a->strings["OpenID:"] = "OpenID:";
-$a->strings["(Optional) Allow this OpenID to login to this account."] = "(Opzionale) Consente di loggarti in questo account con questo OpenID";
-$a->strings["Publish your default profile in your local site directory?"] = "Pubblica il tuo profilo predefinito nell'elenco locale del sito";
-$a->strings["Your profile may be visible in public."] = "Il tuo profilo potrebbe essere visibile pubblicamente.";
-$a->strings["Publish your default profile in the global social directory?"] = "Pubblica il tuo profilo predefinito nell'elenco sociale globale";
-$a->strings["Hide your contact/friend list from viewers of your default profile?"] = "Nascondi la lista dei tuoi contatti/amici dai visitatori del tuo profilo predefinito";
-$a->strings["If enabled, posting public messages to Diaspora and other networks isn't possible."] = "Se abilitato, l'invio di messaggi pubblici verso Diaspora e altri network non sarà possibile";
-$a->strings["Allow friends to post to your profile page?"] = "Permetti agli amici di scrivere sulla tua pagina profilo?";
-$a->strings["Allow friends to tag your posts?"] = "Permetti agli amici di aggiungere tag ai tuoi messaggi?";
-$a->strings["Allow us to suggest you as a potential friend to new members?"] = "Ci permetti di suggerirti come potenziale amico ai nuovi membri?";
-$a->strings["Permit unknown people to send you private mail?"] = "Permetti a utenti sconosciuti di inviarti messaggi privati?";
-$a->strings["Profile is <strong>not published</strong>."] = "Il profilo <strong>non è pubblicato</strong>.";
-$a->strings["Your Identity Address is <strong>'%s'</strong> or '%s'."] = "L'indirizzo della tua identità è <strong>'%s'</strong> or '%s'.";
-$a->strings["Automatically expire posts after this many days:"] = "Fai scadere i post automaticamente dopo x giorni:";
-$a->strings["If empty, posts will not expire. Expired posts will be deleted"] = "Se lasciato vuoto, i messaggi non verranno cancellati.";
-$a->strings["Advanced expiration settings"] = "Impostazioni avanzate di scadenza";
-$a->strings["Advanced Expiration"] = "Scadenza avanzata";
-$a->strings["Expire posts:"] = "Fai scadere i post:";
-$a->strings["Expire personal notes:"] = "Fai scadere le Note personali:";
-$a->strings["Expire starred posts:"] = "Fai scadere i post Speciali:";
-$a->strings["Expire photos:"] = "Fai scadere le foto:";
-$a->strings["Only expire posts by others:"] = "Fai scadere solo i post degli altri:";
-$a->strings["Account Settings"] = "Impostazioni account";
-$a->strings["Password Settings"] = "Impostazioni password";
-$a->strings["Leave password fields blank unless changing"] = "Lascia questi campi in bianco per non effettuare variazioni alla password";
-$a->strings["Current Password:"] = "Password Attuale:";
-$a->strings["Your current password to confirm the changes"] = "La tua password attuale per confermare le modifiche";
-$a->strings["Password:"] = "Password:";
-$a->strings["Basic Settings"] = "Impostazioni base";
-$a->strings["Email Address:"] = "Indirizzo Email:";
-$a->strings["Your Timezone:"] = "Il tuo fuso orario:";
-$a->strings["Your Language:"] = "La tua lingua:";
-$a->strings["Set the language we use to show you friendica interface and to send you emails"] = "Imposta la lingua che sarà usata per mostrarti l'interfaccia di Friendica e per inviarti le email";
-$a->strings["Default Post Location:"] = "Località predefinita:";
-$a->strings["Use Browser Location:"] = "Usa la località rilevata dal browser:";
-$a->strings["Security and Privacy Settings"] = "Impostazioni di sicurezza e privacy";
-$a->strings["Maximum Friend Requests/Day:"] = "Numero massimo di richieste di amicizia al giorno:";
-$a->strings["(to prevent spam abuse)"] = "(per prevenire lo spam)";
-$a->strings["Default Post Permissions"] = "Permessi predefiniti per i messaggi";
-$a->strings["(click to open/close)"] = "(clicca per aprire/chiudere)";
-$a->strings["Default Private Post"] = "Default Post Privato";
-$a->strings["Default Public Post"] = "Default Post Pubblico";
-$a->strings["Default Permissions for New Posts"] = "Permessi predefiniti per i nuovi post";
-$a->strings["Maximum private messages per day from unknown people:"] = "Numero massimo di messaggi privati da utenti sconosciuti per giorno:";
-$a->strings["Notification Settings"] = "Impostazioni notifiche";
-$a->strings["By default post a status message when:"] = "Invia un messaggio di stato quando:";
-$a->strings["accepting a friend request"] = "accetti una richiesta di amicizia";
-$a->strings["joining a forum/community"] = "ti unisci a un forum/comunità";
-$a->strings["making an <em>interesting</em> profile change"] = "fai un <em>interessante</em> modifica al profilo";
-$a->strings["Send a notification email when:"] = "Invia una mail di notifica quando:";
-$a->strings["You receive an introduction"] = "Ricevi una presentazione";
-$a->strings["Your introductions are confirmed"] = "Le tue presentazioni sono confermate";
-$a->strings["Someone writes on your profile wall"] = "Qualcuno scrive sulla bacheca del tuo profilo";
-$a->strings["Someone writes a followup comment"] = "Qualcuno scrive un commento a un tuo messaggio";
-$a->strings["You receive a private message"] = "Ricevi un messaggio privato";
-$a->strings["You receive a friend suggestion"] = "Hai ricevuto un suggerimento di amicizia";
-$a->strings["You are tagged in a post"] = "Sei stato taggato in un post";
-$a->strings["You are poked/prodded/etc. in a post"] = "Sei 'toccato'/'spronato'/ecc. in un post";
-$a->strings["Activate desktop notifications"] = "Attiva notifiche desktop";
-$a->strings["Show desktop popup on new notifications"] = "Mostra un popup di notifica sul desktop all'arrivo di nuove notifiche";
-$a->strings["Text-only notification emails"] = "Email di notifica in solo testo";
-$a->strings["Send text only notification emails, without the html part"] = "Invia le email di notifica in solo testo, senza la parte in html";
-$a->strings["Advanced Account/Page Type Settings"] = "Impostazioni avanzate Account/Tipo di pagina";
-$a->strings["Change the behaviour of this account for special situations"] = "Modifica il comportamento di questo account in situazioni speciali";
-$a->strings["Relocate"] = "Trasloca";
-$a->strings["If you have moved this profile from another server, and some of your contacts don't receive your updates, try pushing this button."] = "Se hai spostato questo profilo da un'altro server, e alcuni dei tuoi contatti non ricevono i tuoi aggiornamenti, prova a premere questo bottone.";
-$a->strings["Resend relocate message to contacts"] = "Invia nuovamente il messaggio di trasloco ai contatti";
+$a->strings["Remove My Account"] = "Rimuovi il mio account";
+$a->strings["This will completely remove your account. Once this has been done it is not recoverable."] = "Questo comando rimuoverà completamente il tuo account. Una volta rimosso non potrai più recuperarlo.";
+$a->strings["Please enter your password for verification:"] = "Inserisci la tua password per verifica:";
+$a->strings["Resubscribing to OStatus contacts"] = "Risottoscrivi i contatti OStatus";
+$a->strings["Error"] = "Errore";
+$a->strings["Done"] = "Fatto";
+$a->strings["Keep this window open until done."] = "Tieni questa finestra aperta fino a che ha finito.";
+$a->strings["%1\$s is following %2\$s's %3\$s"] = "%1\$s sta seguendo %3\$s di %2\$s";
+$a->strings["Tag removed"] = "Tag rimosso";
+$a->strings["Remove Item Tag"] = "Rimuovi il tag";
+$a->strings["Select a tag to remove: "] = "Seleziona un tag da rimuovere: ";
+$a->strings["Remove"] = "Rimuovi";
$a->strings["Export account"] = "Esporta account";
$a->strings["Export your account info and contacts. Use this to make a backup of your account and/or to move it to another server."] = "Esporta le informazioni del tuo account e dei contatti. Usa questa funzione per fare un backup del tuo account o per spostarlo in un altro server.";
$a->strings["Export all"] = "Esporta tutto";
$a->strings["Export your accout info, contacts and all your items as json. Could be a very big file, and could take a lot of time. Use this to make a full backup of your account (photos are not exported)"] = "Esporta le informazioni del tuo account, i tuoi contatti e tutti i tuoi elementi in json. Può diventare un file veramente molto grosso e metterci un sacco di tempo. Usa questa funzione per fare un backup completo del tuo account (le foto non sono esportate)";
-$a->strings["Do you really want to delete this video?"] = "Vuoi veramente cancellare questo video?";
-$a->strings["Delete Video"] = "Rimuovi video";
-$a->strings["No videos selected"] = "Nessun video selezionato";
-$a->strings["Recent Videos"] = "Video Recenti";
-$a->strings["Upload New Videos"] = "Carica Nuovo Video";
+$a->strings["Export personal data"] = "Esporta dati personali";
+$a->strings["Number of daily wall messages for %s exceeded. Message failed."] = "Numero giornaliero di messaggi per %s superato. Invio fallito.";
+$a->strings["Unable to check your home location."] = "Impossibile controllare la tua posizione di origine.";
+$a->strings["No recipient."] = "Nessun destinatario.";
+$a->strings["If you wish for %s to respond, please check that the privacy settings on your site allow private mail from unknown senders."] = "Se vuoi che %s ti risponda, controlla che le tue impostazioni di privacy permettano la ricezione di messaggi privati da mittenti sconosciuti.";
+$a->strings["No potential page delegates located."] = "Nessun potenziale delegato per la pagina è stato trovato.";
+$a->strings["Delegates are able to manage all aspects of this account/page except for basic account settings. Please do not delegate your personal account to anybody that you do not trust completely."] = "I Delegati sono in grado di gestire tutti gli aspetti di questa pagina, tranne per le impostazioni di base dell'account. Non delegare il tuo account personale a nessuno di cui non ti fidi ciecamente.";
+$a->strings["Existing Page Managers"] = "Gestori Pagina Esistenti";
+$a->strings["Existing Page Delegates"] = "Delegati Pagina Esistenti";
+$a->strings["Potential Delegates"] = "Delegati Potenziali";
+$a->strings["Add"] = "Aggiungi";
+$a->strings["No entries."] = "Nessuna voce.";
+$a->strings["Do you really want to delete this suggestion?"] = "Vuoi veramente cancellare questo suggerimento?";
+$a->strings["No suggestions available. If this is a new site, please try again in 24 hours."] = "Nessun suggerimento disponibile. Se questo è un sito nuovo, riprova tra 24 ore.";
+$a->strings["Ignore/Hide"] = "Ignora / Nascondi";
+$a->strings["Global Directory"] = "Elenco globale";
+$a->strings["Find on this site"] = "Cerca nel sito";
+$a->strings["Results for:"] = "Risultati per:";
+$a->strings["Site Directory"] = "Elenco del sito";
+$a->strings["No entries (some entries may be hidden)."] = "Nessuna voce (qualche voce potrebbe essere nascosta).";
+$a->strings["Files"] = "File";
+$a->strings["This is Friendica, version"] = "Questo è Friendica, versione";
+$a->strings["running at web location"] = "in esecuzione all'indirizzo web";
+$a->strings["Please visit <a href=\"https://friendi.ca\">Friendi.ca</a> to learn more about the Friendica project."] = "Visita <a href=\"https://friendi.ca\">Friendi.ca</a> per saperne di più sul progetto Friendica.";
+$a->strings["Bug reports and issues: please visit"] = "Segnalazioni di bug e problemi: visita";
+$a->strings["the bugtracker at github"] = "il bugtracker su github";
+$a->strings["Suggestions, praise, donations, etc. - please email \"Info\" at Friendica - dot com"] = "Suggerimenti, lodi, donazioni, ecc - e-mail a \"Info\" at Friendica punto com";
+$a->strings["Installed plugins/addons/apps:"] = "Plugin/componenti aggiuntivi/applicazioni installate";
+$a->strings["No installed plugins/addons/apps"] = "Nessun plugin/componente aggiuntivo/applicazione installata";
+$a->strings["On this server the following remote servers are blocked."] = "In questo server i seguenti server remoti sono bloccati.";
+$a->strings["Reason for the block"] = "Motivazione del blocco";
$a->strings["Friendica Communications Server - Setup"] = "Friendica Comunicazione Server - Impostazioni";
$a->strings["Could not connect to database."] = " Impossibile collegarsi con il database.";
$a->strings["Could not create table."] = "Impossibile creare le tabelle.";
$a->strings["The database configuration file \".htconfig.php\" could not be written. Please use the enclosed text to create a configuration file in your web server root."] = "Il file di configurazione del database \".htconfig.php\" non può essere scritto. Usa il testo qui di seguito per creare un file di configurazione nella cartella principale del tuo sito.";
$a->strings["<h1>What next</h1>"] = "<h1>Cosa fare ora</h1>";
$a->strings["IMPORTANT: You will need to [manually] setup a scheduled task for the poller."] = "IMPORTANTE: Devi impostare [manualmente] la pianificazione del poller.";
-$a->strings["Unable to locate original post."] = "Impossibile trovare il messaggio originale.";
-$a->strings["Empty post discarded."] = "Messaggio vuoto scartato.";
-$a->strings["System error. Post not saved."] = "Errore di sistema. Messaggio non salvato.";
-$a->strings["This message was sent to you by %s, a member of the Friendica social network."] = "Questo messaggio ti è stato inviato da %s, un membro del social network Friendica.";
-$a->strings["You may visit them online at %s"] = "Puoi visitarli online su %s";
-$a->strings["Please contact the sender by replying to this post if you do not wish to receive these messages."] = "Contatta il mittente rispondendo a questo post se non vuoi ricevere questi messaggi.";
-$a->strings["%s posted an update."] = "%s ha inviato un aggiornamento.";
-$a->strings["Invalid request identifier."] = "L'identificativo della richiesta non è valido.";
-$a->strings["Discard"] = "Scarta";
-$a->strings["Network Notifications"] = "Notifiche dalla rete";
-$a->strings["Personal Notifications"] = "Notifiche personali";
-$a->strings["Home Notifications"] = "Notifiche bacheca";
-$a->strings["Show Ignored Requests"] = "Mostra richieste ignorate";
-$a->strings["Hide Ignored Requests"] = "Nascondi richieste ignorate";
-$a->strings["Notification type: "] = "Tipo di notifica: ";
-$a->strings["suggested by %s"] = "suggerito da %s";
-$a->strings["Post a new friend activity"] = "Invia una attività \"è ora amico con\"";
-$a->strings["if applicable"] = "se applicabile";
-$a->strings["Approve"] = "Approva";
-$a->strings["Claims to be known to you: "] = "Dice di conoscerti: ";
-$a->strings["yes"] = "si";
-$a->strings["no"] = "no";
-$a->strings["Shall your connection be bidirectional or not?"] = "La connessione dovrà essere bidirezionale o no?";
-$a->strings["Accepting %s as a friend allows %s to subscribe to your posts, and you will also receive updates from them in your news feed."] = "Accettando %s come amico permette a %s di seguire i tuoi post, e a te di riceverne gli aggiornamenti.";
-$a->strings["Accepting %s as a subscriber allows them to subscribe to your posts, but you will not receive updates from them in your news feed."] = "Accentrando %s come abbonato gli permette di abbonarsi ai tuoi messaggi, ma tu non riceverai aggiornamenti da lui.";
-$a->strings["Accepting %s as a sharer allows them to subscribe to your posts, but you will not receive updates from them in your news feed."] = "Accentando %s come condivisore, gli permetti di abbonarsi ai tuoi messaggi, ma tu non riceverai nessun aggiornamento da loro.";
-$a->strings["Friend"] = "Amico";
-$a->strings["Sharer"] = "Condivisore";
-$a->strings["Subscriber"] = "Abbonato";
-$a->strings["No introductions."] = "Nessuna presentazione.";
-$a->strings["Show unread"] = "Mostra non letti";
-$a->strings["Show all"] = "Mostra tutti";
-$a->strings["No more %s notifications."] = "Nessun'altra notifica %s.";
-$a->strings["{0} wants to be your friend"] = "{0} vuole essere tuo amico";
-$a->strings["{0} sent you a message"] = "{0} ti ha inviato un messaggio";
-$a->strings["{0} requested registration"] = "{0} chiede la registrazione";
+$a->strings["Remove term"] = "Rimuovi termine";
+$a->strings["Only logged in users are permitted to perform a search."] = "Solo agli utenti autenticati è permesso eseguire ricerche.";
+$a->strings["Too Many Requests"] = "Troppe richieste";
+$a->strings["Only one search per minute is permitted for not logged in users."] = "Solo una ricerca al minuto è permessa agli utenti non autenticati.";
+$a->strings["Items tagged with: %s"] = "Elementi taggati con: %s";
+$a->strings["Results for: %s"] = "Risultati per: %s";
+$a->strings["Contact wasn't found or can't be unfollowed."] = "";
+$a->strings["Contact unfollowed"] = "";
+$a->strings["You aren't a friend of this contact."] = "Non sei un amico di questo contatto";
+$a->strings["Unfollowing is currently not supported by your network."] = "";
+$a->strings["Disconnect/Unfollow"] = "Disconnetti/Non Seguire";
$a->strings["Theme settings updated."] = "Impostazioni del tema aggiornate.";
$a->strings["Site"] = "Sito";
$a->strings["Users"] = "Utenti";
+$a->strings["Plugins"] = "Plugin";
$a->strings["Themes"] = "Temi";
+$a->strings["Additional features"] = "Funzionalità aggiuntive";
$a->strings["DB updates"] = "Aggiornamenti Database";
$a->strings["Inspect Queue"] = "Ispeziona Coda di invio";
$a->strings["Server Blocklist"] = "Server Blocklist";
$a->strings["Federation Statistics"] = "Statistiche sulla Federazione";
+$a->strings["Delete Item"] = "Rimuovi elemento";
$a->strings["Logs"] = "Log";
$a->strings["View Logs"] = "Vedi i log";
$a->strings["probe address"] = "controlla indirizzo";
$a->strings["Delete entry from blocklist?"] = "Eliminare la voce dalla blocklist?";
$a->strings["Server added to blocklist."] = "Server aggiunto alla blocklist.";
$a->strings["Site blocklist updated."] = "Blocklist del sito aggiornata.";
+$a->strings["Delete this Item"] = "Rimuovi questo elemento";
+$a->strings["On this page you can delete an item from your node. If the item is a top level posting, the entire thread will be deleted."] = "";
+$a->strings["You need to know the GUID of the item. You can find it e.g. by looking at the display URL. The last part of http://example.com/display/123456 is the GUID, here 123456."] = "";
+$a->strings["GUID"] = "";
+$a->strings["The GUID of the item you want to delete."] = "";
+$a->strings["Item marked for deletion."] = "";
$a->strings["unknown"] = "sconosciuto";
$a->strings["This page offers you some numbers to the known part of the federated social network your Friendica node is part of. These numbers are not complete but only reflect the part of the network your node is aware of."] = "Questa pagina offre alcuni numeri riguardo la porzione del social network federato di cui il tuo nodo Friendica fa parte. Questi numeri non sono completi ma riflettono esclusivamente la porzione di rete di cui il tuo nodo e' a conoscenza.";
$a->strings["The <em>Auto Discovered Contact Directory</em> feature is not enabled, it will improve the data displayed here."] = "La funzione <em>Elenco Contatti Scoperto Automaticamente</em> non è abilitata, migliorerà i dati visualizzati qui.";
$a->strings["Last Tried"] = "Ultimo Tentativo";
$a->strings["This page lists the content of the queue for outgoing postings. These are postings the initial delivery failed for. They will be resend later and eventually deleted if the delivery fails permanently."] = "Questa pagina elenca il contenuto della coda di invio dei post. Questi sono post la cui consegna è fallita. Verranno inviati nuovamente più tardi ed eventualmente cancellati se la consegna continua a fallire.";
$a->strings["Your DB still runs with MyISAM tables. You should change the engine type to InnoDB. As Friendica will use InnoDB only features in the future, you should change this! See <a href=\"%s\">here</a> for a guide that may be helpful converting the table engines. You may also use the command <tt>php include/dbstructure.php toinnodb</tt> of your Friendica installation for an automatic conversion.<br />"] = "Il tuo database contiene ancora tabelle MyISAM. Dovresti cambiare il motore a InnoDB. Siccome Friendica userà esclusivamente InnoDB nelle versioni a venire, dovresti cambiarle! Vedi <a href=\"%s\">qui</a> per una guida che puo' essere d'aiuto nel convertire il motore delle tabelle. Puoi anche usare il comando <tt>php include/dbstructure.php toinnodb</tt> nella tua installazione Friendica per eseguire la conversione automaticamente.<br />";
-$a->strings["You are using a MySQL version which does not support all features that Friendica uses. You should consider switching to MariaDB."] = "Stai usando una versione di MySQL che non supporta tutte le funzionalità che Friendica usa. Dovresti considerare di utilizzare MariaDB.";
+$a->strings["There is a new version of Friendica available for download. Your current version is %1\$s, upstream version is %2\$s"] = "";
+$a->strings["The database update failed. Please run \"php include/dbstructure.php update\" from the command line and have a look at the errors that might appear."] = "";
+$a->strings["The worker was never executed. Please check your database structure!"] = "";
+$a->strings["The last worker execution was on %s UTC. This is older than one hour. Please check your crontab settings."] = "";
$a->strings["Normal Account"] = "Account normale";
-$a->strings["Soapbox Account"] = "Account per comunicati e annunci";
-$a->strings["Community/Celebrity Account"] = "Account per celebrità o per comunità";
+$a->strings["Automatic Follower Account"] = "";
+$a->strings["Public Forum Account"] = "";
$a->strings["Automatic Friend Account"] = "Account per amicizia automatizzato";
$a->strings["Blog Account"] = "Account Blog";
-$a->strings["Private Forum"] = "Forum Privato";
+$a->strings["Private Forum Account"] = "";
$a->strings["Message queues"] = "Code messaggi";
$a->strings["Summary"] = "Sommario";
$a->strings["Registered users"] = "Utenti registrati";
$a->strings["Active plugins"] = "Plugin attivi";
$a->strings["Can not parse base url. Must have at least <scheme>://<domain>"] = "Impossibile analizzare l'url base. Deve avere almeno [schema]://[dominio]";
$a->strings["Site settings updated."] = "Impostazioni del sito aggiornate.";
+$a->strings["No special theme for mobile devices"] = "Nessun tema speciale per i dispositivi mobili";
$a->strings["No community page"] = "Nessuna pagina Comunità";
$a->strings["Public postings from users of this site"] = "Messaggi pubblici dagli utenti di questo sito";
$a->strings["Global community page"] = "Pagina Comunità globale";
+$a->strings["Never"] = "Mai";
$a->strings["At post arrival"] = "All'arrivo di un messaggio";
+$a->strings["Disabled"] = "Disabilitato";
$a->strings["Users, Global Contacts"] = "Utenti, Contatti Globali";
$a->strings["Users, Global Contacts/fallback"] = "Utenti, Contatti Globali/fallback";
$a->strings["One month"] = "Un mese";
$a->strings["No SSL policy, links will track page SSL state"] = "Nessuna gestione SSL, i link seguiranno lo stato SSL della pagina";
$a->strings["Force all links to use SSL"] = "Forza tutti i link ad usare SSL";
$a->strings["Self-signed certificate, use SSL for local links only (discouraged)"] = "Certificato auto-firmato, usa SSL solo per i link locali (sconsigliato)";
+$a->strings["Don't check"] = "";
+$a->strings["check the stable version"] = "";
+$a->strings["check the development version"] = "";
+$a->strings["Save Settings"] = "Salva Impostazioni";
+$a->strings["Republish users to directory"] = "";
+$a->strings["Registration"] = "Registrazione";
$a->strings["File upload"] = "Caricamento file";
$a->strings["Policies"] = "Politiche";
$a->strings["Auto Discovered Contact Directory"] = "Elenco Contatti Scoperto Automaticamente";
$a->strings["The maximum number of posts per user on the community page. (Not valid for 'Global Community')"] = "Il numero massimo di messaggi per utente mostrato nella pagina Comunità (non valido per 'Comunità globale')";
$a->strings["Enable OStatus support"] = "Abilita supporto OStatus";
$a->strings["Provide built-in OStatus (StatusNet, GNU Social etc.) compatibility. All communications in OStatus are public, so privacy warnings will be occasionally displayed."] = "Fornisce la compatibilità integrata a OStatus (StatusNet, Gnu Social, etc.). Tutte le comunicazioni su OStatus sono pubbliche, quindi un avviso di privacy verrà mostrato occasionalmente.";
-$a->strings["OStatus conversation completion interval"] = "Intervallo completamento conversazioni OStatus";
-$a->strings["How often shall the poller check for new entries in OStatus conversations? This can be a very ressource task."] = "quanto spesso il poller deve controllare se esistono nuovi commenti in una conversazione OStatus? Questo è un lavoro che può richiedere molte risorse.";
$a->strings["Only import OStatus threads from our contacts"] = "Importa conversazioni OStatus solo dai nostri contatti.";
$a->strings["Normally we import every content from our OStatus contacts. With this option we only store threads that are started by a contact that is known on our system."] = "Normalmente importiamo tutto il contenuto dai contatti OStatus. Con questa opzione salviamo solo le conversazioni iniziate da un contatto è conosciuto a questo nodo.";
$a->strings["OStatus support can only be enabled if threading is enabled."] = "Il supporto OStatus può essere abilitato solo se è abilitato il threading.";
$a->strings["Search the local directory instead of the global directory. When searching locally, every search will be executed on the global directory in the background. This improves the search results when the search is repeated."] = "Cerca nella directory locale invece che nella directory globale. Durante la ricerca a livello locale, ogni ricerca verrà eseguita sulla directory globale in background. Ciò migliora i risultati della ricerca quando la ricerca viene ripetuta.";
$a->strings["Publish server information"] = "Pubblica informazioni server";
$a->strings["If enabled, general server and usage data will be published. The data contains the name and version of the server, number of users with public profiles, number of posts and the activated protocols and connectors. See <a href='http://the-federation.info/'>the-federation.info</a> for details."] = "Se abilitata, saranno pubblicati i dati generali del server e i dati di utilizzo. I dati contengono il nome e la versione del server, il numero di utenti con profili pubblici, numero dei posti e dei protocolli e connettori attivati. Per informazioni, vedere <a href='http://the-federation.info/'> the-federation.info </a>.";
+$a->strings["Check upstream version"] = "";
+$a->strings["Enables checking for new Friendica versions at github. If there is a new version, you will be informed in the admin panel overview."] = "";
$a->strings["Suppress Tags"] = "Sopprimi Tags";
$a->strings["Suppress showing a list of hashtags at the end of the posting."] = "Non mostra la lista di hashtag in coda al messaggio";
$a->strings["Path to item cache"] = "Percorso cache elementi";
$a->strings["Only search in tags"] = "Cerca solo nei tag";
$a->strings["On large systems the text search can slow down the system extremely."] = "Su server con molti dati, la ricerca nel testo può estremamente rallentare il sistema.";
$a->strings["New base url"] = "Nuovo url base";
-$a->strings["Change base url for this server. Sends relocate message to all DFRN contacts of all users."] = "Cambia l'url base di questo server. Invia il messaggio di trasloco a tutti i contatti DFRN di tutti gli utenti.";
+$a->strings["Change base url for this server. Sends relocate message to all Friendica and Diaspora* contacts of all users."] = "";
$a->strings["RINO Encryption"] = "Crittografia RINO";
$a->strings["Encryption layer between nodes."] = "Crittografia delle comunicazioni tra nodi.";
$a->strings["Maximum number of parallel workers"] = "Massimo numero di lavori in parallelo";
$a->strings["Enable fastlane"] = "Abilita fastlane";
$a->strings["When enabed, the fastlane mechanism starts an additional worker if processes with higher priority are blocked by processes of lower priority."] = "Quando abilitato, il meccanismo di fastlane avvia processi aggiuntivi se processi con priorità più alta sono bloccati da processi con priorità più bassa.";
$a->strings["Enable frontend worker"] = "Abilita worker da frontend";
-$a->strings["When enabled the Worker process is triggered when backend access is performed (e.g. messages being delivered). On smaller sites you might want to call yourdomain.tld/worker on a regular basis via an external cron job. You should only enable this option if you cannot utilize cron/scheduled jobs on your server. The worker background process needs to be activated for this."] = "Quando abilitato, il processo è avviato quando viene eseguito un accesso al backend (per esempio, quando un messaggio viene consegnato). Su siti più piccoli potresti voler chiamare yourdomain.tld/worker regolarmente attraverso un cron esterno. Dovresti abilitare questa opzione solo se non puoi utilizzare cron sul tuo server. L'elaborazione in background con worker deve essere abilitata perchè questa opzione sia effettiva.";
+$a->strings["When enabled the Worker process is triggered when backend access is performed (e.g. messages being delivered). On smaller sites you might want to call %s/worker on a regular basis via an external cron job. You should only enable this option if you cannot utilize cron/scheduled jobs on your server."] = "";
$a->strings["Update has been marked successful"] = "L'aggiornamento è stato segnato come di successo";
$a->strings["Database structure update %s was successfully applied."] = "Aggiornamento struttura database %s applicata con successo.";
$a->strings["Executing of database structure update %s failed with error: %s"] = "Aggiornamento struttura database %s fallita con errore: %s";
$a->strings["Register date"] = "Data registrazione";
$a->strings["Last login"] = "Ultimo accesso";
$a->strings["Last item"] = "Ultimo elemento";
+$a->strings["Account"] = "Account";
$a->strings["Add User"] = "Aggiungi utente";
$a->strings["select all"] = "seleziona tutti";
$a->strings["User registrations waiting for confirm"] = "Richieste di registrazione in attesa di conferma";
$a->strings["No registrations."] = "Nessuna registrazione.";
$a->strings["Note from the user"] = "Nota dall'utente";
$a->strings["Deny"] = "Nega";
+$a->strings["Block"] = "Blocca";
+$a->strings["Unblock"] = "Sblocca";
$a->strings["Site admin"] = "Amministrazione sito";
$a->strings["Account expired"] = "Account scaduto";
$a->strings["New User"] = "Nuovo Utente";
$a->strings["Log level"] = "Livello di Log";
$a->strings["PHP logging"] = "Log PHP";
$a->strings["To enable logging of PHP errors and warnings you can add the following to the .htconfig.php file of your installation. The filename set in the 'error_log' line is relative to the friendica top-level directory and must be writeable by the web server. The option '1' for 'log_errors' and 'display_errors' is to enable these options, set to '0' to disable them."] = "Per abilitare il log degli errori e degli avvisi di PHP puoi aggiungere le seguenti righe al file .htconfig.php nella tua installazione. La posizione del file impostato in 'error_log' è relativa alla directory principale della tua installazione Friendica e il server web deve avere i permessi di scrittura sul file. Il valore '1' per 'log_errors' e 'display_errors' abilita le opzioni, imposta '0' per disabilitarle.";
+$a->strings["Off"] = "Spento";
+$a->strings["On"] = "Acceso";
$a->strings["Lock feature %s"] = "Blocca funzionalità %s";
$a->strings["Manage Additional Features"] = "Gestisci Funzionalità Aggiuntive";
+$a->strings["%d contact edited."] = array(
+ 0 => "%d contatto modificato.",
+ 1 => "%d contatti modificati",
+);
+$a->strings["Could not access contact record."] = "Non è possibile accedere al contatto.";
+$a->strings["Could not locate selected profile."] = "Non riesco a trovare il profilo selezionato.";
+$a->strings["Contact updated."] = "Contatto aggiornato.";
+$a->strings["Contact has been blocked"] = "Il contatto è stato bloccato";
+$a->strings["Contact has been unblocked"] = "Il contatto è stato sbloccato";
+$a->strings["Contact has been ignored"] = "Il contatto è ignorato";
+$a->strings["Contact has been unignored"] = "Il contatto non è più ignorato";
+$a->strings["Contact has been archived"] = "Il contatto è stato archiviato";
+$a->strings["Contact has been unarchived"] = "Il contatto è stato dearchiviato";
+$a->strings["Drop contact"] = "Cancella contatto";
+$a->strings["Do you really want to delete this contact?"] = "Vuoi veramente cancellare questo contatto?";
+$a->strings["Contact has been removed."] = "Il contatto è stato rimosso.";
+$a->strings["You are mutual friends with %s"] = "Sei amico reciproco con %s";
+$a->strings["You are sharing with %s"] = "Stai condividendo con %s";
+$a->strings["%s is sharing with you"] = "%s sta condividendo con te";
+$a->strings["Private communications are not available for this contact."] = "Le comunicazioni private non sono disponibili per questo contatto.";
+$a->strings["(Update was successful)"] = "(L'aggiornamento è stato completato)";
+$a->strings["(Update was not successful)"] = "(L'aggiornamento non è stato completato)";
+$a->strings["Suggest friends"] = "Suggerisci amici";
+$a->strings["Network type: %s"] = "Tipo di rete: %s";
+$a->strings["Communications lost with this contact!"] = "Comunicazione con questo contatto persa!";
+$a->strings["Fetch further information for feeds"] = "Recupera maggiori informazioni per i feed";
+$a->strings["Fetch information"] = "Recupera informazioni";
+$a->strings["Fetch information and keywords"] = "Recupera informazioni e parole chiave";
+$a->strings["Contact"] = "Contatto";
+$a->strings["Profile Visibility"] = "Visibilità del profilo";
+$a->strings["Please choose the profile you would like to display to %s when viewing your profile securely."] = "Seleziona il profilo che vuoi mostrare a %s quando visita il tuo profilo in modo sicuro.";
+$a->strings["Contact Information / Notes"] = "Informazioni / Note sul contatto";
+$a->strings["Their personal note"] = "";
+$a->strings["Edit contact notes"] = "Modifica note contatto";
+$a->strings["Block/Unblock contact"] = "Blocca/Sblocca contatto";
+$a->strings["Ignore contact"] = "Ignora il contatto";
+$a->strings["Repair URL settings"] = "Impostazioni riparazione URL";
+$a->strings["View conversations"] = "Vedi conversazioni";
+$a->strings["Last update:"] = "Ultimo aggiornamento:";
+$a->strings["Update public posts"] = "Aggiorna messaggi pubblici";
+$a->strings["Update now"] = "Aggiorna adesso";
+$a->strings["Unignore"] = "Non ignorare";
+$a->strings["Currently blocked"] = "Bloccato";
+$a->strings["Currently ignored"] = "Ignorato";
+$a->strings["Currently archived"] = "Al momento archiviato";
+$a->strings["Replies/likes to your public posts <strong>may</strong> still be visible"] = "Risposte ai tuoi post pubblici <strong>possono</strong> essere comunque visibili";
+$a->strings["Notification for new posts"] = "Notifica per i nuovi messaggi";
+$a->strings["Send a notification of every new post of this contact"] = "Invia una notifica per ogni nuovo messaggio di questo contatto";
+$a->strings["Blacklisted keywords"] = "Parole chiave in blacklist";
+$a->strings["Comma separated list of keywords that should not be converted to hashtags, when \"Fetch information and keywords\" is selected"] = "Lista separata da virgola di parole chiave che non dovranno essere convertite in hashtag, quando \"Recupera informazioni e parole chiave\" è selezionato";
+$a->strings["Actions"] = "Azioni";
+$a->strings["Contact Settings"] = "Impostazioni Contatto";
+$a->strings["Suggestions"] = "Suggerimenti";
+$a->strings["Suggest potential friends"] = "Suggerisci potenziali amici";
+$a->strings["Show all contacts"] = "Mostra tutti i contatti";
+$a->strings["Unblocked"] = "Sbloccato";
+$a->strings["Only show unblocked contacts"] = "Mostra solo contatti non bloccati";
+$a->strings["Blocked"] = "Bloccato";
+$a->strings["Only show blocked contacts"] = "Mostra solo contatti bloccati";
+$a->strings["Ignored"] = "Ignorato";
+$a->strings["Only show ignored contacts"] = "Mostra solo contatti ignorati";
+$a->strings["Archived"] = "Archiviato";
+$a->strings["Only show archived contacts"] = "Mostra solo contatti archiviati";
+$a->strings["Hidden"] = "Nascosto";
+$a->strings["Only show hidden contacts"] = "Mostra solo contatti nascosti";
+$a->strings["Search your contacts"] = "Cerca nei tuoi contatti";
+$a->strings["Update"] = "Aggiorna";
+$a->strings["Archive"] = "Archivia";
+$a->strings["Unarchive"] = "Dearchivia";
+$a->strings["Batch Actions"] = "Azioni Batch";
+$a->strings["View all contacts"] = "Vedi tutti i contatti";
+$a->strings["View all common friends"] = "Vedi tutti gli amici in comune";
+$a->strings["Advanced Contact Settings"] = "Impostazioni avanzate Contatto";
+$a->strings["Mutual Friendship"] = "Amicizia reciproca";
+$a->strings["is a fan of yours"] = "è un tuo fan";
+$a->strings["you are a fan of"] = "sei un fan di";
+$a->strings["Toggle Blocked status"] = "Inverti stato \"Blocca\"";
+$a->strings["Toggle Ignored status"] = "Inverti stato \"Ignora\"";
+$a->strings["Toggle Archive status"] = "Inverti stato \"Archiviato\"";
+$a->strings["Delete contact"] = "Rimuovi contatto";
+$a->strings["Profile not found."] = "Profilo non trovato.";
+$a->strings["This may occasionally happen if contact was requested by both persons and it has already been approved."] = "Questo può accadere occasionalmente se la richiesta di contatto era stata inviata da entrambe le persone e già approvata.";
+$a->strings["Response from remote site was not understood."] = "Errore di comunicazione con l'altro sito.";
+$a->strings["Unexpected response from remote site: "] = "La risposta dell'altro sito non può essere gestita: ";
+$a->strings["Confirmation completed successfully."] = "Conferma completata con successo.";
+$a->strings["Remote site reported: "] = "Il sito remoto riporta: ";
+$a->strings["Temporary failure. Please wait and try again."] = "Problema temporaneo. Attendi e riprova.";
+$a->strings["Introduction failed or was revoked."] = "La presentazione ha generato un errore o è stata revocata.";
+$a->strings["Unable to set contact photo."] = "Impossibile impostare la foto del contatto.";
+$a->strings["No user record found for '%s' "] = "Nessun utente trovato '%s'";
+$a->strings["Our site encryption key is apparently messed up."] = "La nostra chiave di criptazione del sito sembra essere corrotta.";
+$a->strings["Empty site URL was provided or URL could not be decrypted by us."] = "E' stato fornito un indirizzo vuoto o non possiamo decrittare l'indirizzo.";
+$a->strings["Contact record was not found for you on our site."] = "Il contatto non è stato trovato sul nostro sito.";
+$a->strings["Site public key not available in contact record for URL %s."] = "La chiave pubblica del sito non è disponibile per l'URL %s";
+$a->strings["The ID provided by your system is a duplicate on our system. It should work if you try again."] = "L'ID fornito dal tuo sistema è duplicato sul nostro sistema. Se riprovi dovrebbe funzionare.";
+$a->strings["Unable to set your contact credentials on our system."] = "Impossibile impostare le credenziali del tuo contatto sul nostro sistema.";
+$a->strings["Unable to update your contact profile details on our system"] = "Impossibile aggiornare i dettagli del tuo contatto sul nostro sistema";
+$a->strings["%1\$s has joined %2\$s"] = "%1\$s si è unito a %2\$s";
+$a->strings["People Search - %s"] = "Cerca persone - %s";
+$a->strings["Forum Search - %s"] = "Ricerca Forum - %s";
+$a->strings["Item has been removed."] = "L'oggetto è stato rimosso.";
+$a->strings["Event can not end before it has started."] = "Un evento non può finire prima di iniziare.";
+$a->strings["Event title and start time are required."] = "Titolo e ora di inizio dell'evento sono richiesti.";
+$a->strings["Create New Event"] = "Crea un nuovo evento";
+$a->strings["Event details"] = "Dettagli dell'evento";
+$a->strings["Starting date and Title are required."] = "La data di inizio e il titolo sono richiesti.";
+$a->strings["Event Starts:"] = "L'evento inizia:";
+$a->strings["Required"] = "Richiesto";
+$a->strings["Finish date/time is not known or not relevant"] = "La data/ora di fine non è definita";
+$a->strings["Event Finishes:"] = "L'evento finisce:";
+$a->strings["Adjust for viewer timezone"] = "Visualizza con il fuso orario di chi legge";
+$a->strings["Description:"] = "Descrizione:";
+$a->strings["Title:"] = "Titolo:";
+$a->strings["Share this event"] = "Condividi questo evento";
+$a->strings["Failed to remove event"] = "Rimozione evento fallita.";
+$a->strings["Event removed"] = "Evento rimosso";
+$a->strings["Friend suggestion sent."] = "Suggerimento di amicizia inviato.";
+$a->strings["Suggest Friends"] = "Suggerisci amici";
+$a->strings["Suggest a friend for %s"] = "Suggerisci un amico a %s";
+$a->strings["Unable to locate original post."] = "Impossibile trovare il messaggio originale.";
+$a->strings["Empty post discarded."] = "Messaggio vuoto scartato.";
+$a->strings["System error. Post not saved."] = "Errore di sistema. Messaggio non salvato.";
+$a->strings["This message was sent to you by %s, a member of the Friendica social network."] = "Questo messaggio ti è stato inviato da %s, un membro del social network Friendica.";
+$a->strings["You may visit them online at %s"] = "Puoi visitarli online su %s";
+$a->strings["Please contact the sender by replying to this post if you do not wish to receive these messages."] = "Contatta il mittente rispondendo a questo post se non vuoi ricevere questi messaggi.";
+$a->strings["%s posted an update."] = "%s ha inviato un aggiornamento.";
+$a->strings["Mood"] = "Umore";
+$a->strings["Set your current mood and tell your friends"] = "Condividi il tuo umore con i tuoi amici";
+$a->strings["Warning: This group contains %s member from a network that doesn't allow non public messages."] = array(
+ 0 => "Attenzione: Questo gruppo contiene %s membro da una rete che non permette la ricezione di messaggi non pubblici.",
+ 1 => "Attenzione: Questo gruppo contiene %s membri da reti che non permettono la ricezione di messaggi non pubblici.",
+);
+$a->strings["Messages in this group won't be send to these receivers."] = "I messaggi in questo gruppo non saranno inviati ai quei contatti.";
+$a->strings["No such group"] = "Nessun gruppo";
+$a->strings["Group: %s"] = "Gruppo: %s";
+$a->strings["Private messages to this person are at risk of public disclosure."] = "I messaggi privati a questa persona potrebbero risultare visibili anche pubblicamente.";
+$a->strings["Invalid contact."] = "Contatto non valido.";
+$a->strings["Commented Order"] = "Ordina per commento";
+$a->strings["Sort by Comment Date"] = "Ordina per data commento";
+$a->strings["Posted Order"] = "Ordina per invio";
+$a->strings["Sort by Post Date"] = "Ordina per data messaggio";
+$a->strings["Posts that mention or involve you"] = "Messaggi che ti citano o coinvolgono";
+$a->strings["New"] = "Nuovo";
+$a->strings["Activity Stream - by date"] = "Activity Stream - per data";
+$a->strings["Shared Links"] = "Links condivisi";
+$a->strings["Interesting Links"] = "Link Interessanti";
+$a->strings["Starred"] = "Preferiti";
+$a->strings["Favourite Posts"] = "Messaggi preferiti";
+$a->strings["Subscribing to OStatus contacts"] = "Iscrizione a contatti OStatus";
+$a->strings["No contact provided."] = "Nessun contatto disponibile.";
+$a->strings["Couldn't fetch information for contact."] = "Non è stato possibile recuperare le informazioni del contatto.";
+$a->strings["Couldn't fetch friends for contact."] = "Non è stato possibile recuperare gli amici del contatto.";
+$a->strings["success"] = "successo";
+$a->strings["failed"] = "fallito";
+$a->strings["ignored"] = "ignorato";
+$a->strings["Recent Photos"] = "Foto recenti";
+$a->strings["Upload New Photos"] = "Carica nuove foto";
+$a->strings["everybody"] = "tutti";
+$a->strings["Contact information unavailable"] = "I dati di questo contatto non sono disponibili";
+$a->strings["Album not found."] = "Album non trovato.";
+$a->strings["Delete Album"] = "Rimuovi album";
+$a->strings["Do you really want to delete this photo album and all its photos?"] = "Vuoi davvero cancellare questo album e tutte le sue foto?";
+$a->strings["Delete Photo"] = "Rimuovi foto";
+$a->strings["Do you really want to delete this photo?"] = "Vuoi veramente cancellare questa foto?";
+$a->strings["%1\$s was tagged in %2\$s by %3\$s"] = "%1\$s è stato taggato in %2\$s da %3\$s";
+$a->strings["a photo"] = "una foto";
+$a->strings["Image exceeds size limit of %s"] = "La dimensione dell'immagine supera il limite di %s";
+$a->strings["Image file is empty."] = "Il file dell'immagine è vuoto.";
+$a->strings["Unable to process image."] = "Impossibile caricare l'immagine.";
+$a->strings["Image upload failed."] = "Caricamento immagine fallito.";
+$a->strings["No photos selected"] = "Nessuna foto selezionata";
+$a->strings["Access to this item is restricted."] = "Questo oggetto non è visibile a tutti.";
+$a->strings["Upload Photos"] = "Carica foto";
+$a->strings["New album name: "] = "Nome nuovo album: ";
+$a->strings["or existing album name: "] = "o nome di un album esistente: ";
+$a->strings["Do not show a status post for this upload"] = "Non creare un post per questo upload";
+$a->strings["Show to Groups"] = "Mostra ai gruppi";
+$a->strings["Show to Contacts"] = "Mostra ai contatti";
+$a->strings["Private Photo"] = "Foto privata";
+$a->strings["Public Photo"] = "Foto pubblica";
+$a->strings["Edit Album"] = "Modifica album";
+$a->strings["Show Newest First"] = "Mostra nuove foto per prime";
+$a->strings["Show Oldest First"] = "Mostra vecchie foto per prime";
+$a->strings["View Photo"] = "Vedi foto";
+$a->strings["Permission denied. Access to this item may be restricted."] = "Permesso negato. L'accesso a questo elemento può essere limitato.";
+$a->strings["Photo not available"] = "Foto non disponibile";
+$a->strings["View photo"] = "Vedi foto";
+$a->strings["Edit photo"] = "Modifica foto";
+$a->strings["Use as profile photo"] = "Usa come foto del profilo";
+$a->strings["Private Message"] = "Messaggio privato";
+$a->strings["View Full Size"] = "Vedi dimensione intera";
+$a->strings["Tags: "] = "Tag: ";
+$a->strings["[Remove any tag]"] = "[Rimuovi tutti i tag]";
+$a->strings["New album name"] = "Nuovo nome dell'album";
+$a->strings["Caption"] = "Titolo";
+$a->strings["Add a Tag"] = "Aggiungi tag";
+$a->strings["Example: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping"] = "Esempio: @bob, @Barbara_Jensen, @jim@example.com, #California, #camping";
+$a->strings["Do not rotate"] = "Non ruotare";
+$a->strings["Rotate CW (right)"] = "Ruota a destra";
+$a->strings["Rotate CCW (left)"] = "Ruota a sinistra";
+$a->strings["Private photo"] = "Foto privata";
+$a->strings["Public photo"] = "Foto pubblica";
+$a->strings["I like this (toggle)"] = "Mi piace (clic per cambiare)";
+$a->strings["I don't like this (toggle)"] = "Non mi piace (clic per cambiare)";
+$a->strings["This is you"] = "Questo sei tu";
+$a->strings["Comment"] = "Commento";
+$a->strings["Map"] = "Mappa";
+$a->strings["View Album"] = "Sfoglia l'album";
+$a->strings["{0} wants to be your friend"] = "{0} vuole essere tuo amico";
+$a->strings["{0} sent you a message"] = "{0} ti ha inviato un messaggio";
+$a->strings["{0} requested registration"] = "{0} chiede la registrazione";
+$a->strings["Poke/Prod"] = "Tocca/Pungola";
+$a->strings["poke, prod or do other things to somebody"] = "tocca, pungola o fai altre cose a qualcuno";
+$a->strings["Recipient"] = "Destinatario";
+$a->strings["Choose what you wish to do to recipient"] = "Scegli cosa vuoi fare al destinatario";
+$a->strings["Make this post private"] = "Rendi questo post privato";
+$a->strings["Image uploaded but image cropping failed."] = "L'immagine è stata caricata, ma il non è stato possibile ritagliarla.";
+$a->strings["Image size reduction [%s] failed."] = "Il ridimensionamento dell'immagine [%s] è fallito.";
+$a->strings["Shift-reload the page or clear browser cache if the new photo does not display immediately."] = "Ricarica la pagina con shift+F5 o cancella la cache del browser se la nuova foto non viene mostrata immediatamente.";
+$a->strings["Unable to process image"] = "Impossibile elaborare l'immagine";
+$a->strings["Upload File:"] = "Carica un file:";
+$a->strings["Select a profile:"] = "Seleziona un profilo:";
+$a->strings["Upload"] = "Carica";
+$a->strings["or"] = "o";
+$a->strings["skip this step"] = "salta questo passaggio";
+$a->strings["select a photo from your photo albums"] = "seleziona una foto dai tuoi album";
+$a->strings["Crop Image"] = "Ritaglia immagine";
+$a->strings["Please adjust the image cropping for optimum viewing."] = "Ritaglia l'immagine per una visualizzazione migliore.";
+$a->strings["Done Editing"] = "Finito";
+$a->strings["Image uploaded successfully."] = "Immagine caricata con successo.";
+$a->strings["Profile deleted."] = "Profilo eliminato.";
+$a->strings["Profile-"] = "Profilo-";
+$a->strings["New profile created."] = "Il nuovo profilo è stato creato.";
+$a->strings["Profile unavailable to clone."] = "Impossibile duplicare il profilo.";
+$a->strings["Profile Name is required."] = "Il nome profilo è obbligatorio .";
+$a->strings["Marital Status"] = "Stato civile";
+$a->strings["Romantic Partner"] = "Partner romantico";
+$a->strings["Work/Employment"] = "Lavoro/Impiego";
+$a->strings["Religion"] = "Religione";
+$a->strings["Political Views"] = "Orientamento Politico";
+$a->strings["Gender"] = "Sesso";
+$a->strings["Sexual Preference"] = "Preferenza sessuale";
+$a->strings["XMPP"] = "XMPP";
+$a->strings["Homepage"] = "Homepage";
+$a->strings["Interests"] = "Interessi";
+$a->strings["Address"] = "Indirizzo";
+$a->strings["Location"] = "Posizione";
+$a->strings["Profile updated."] = "Profilo aggiornato.";
+$a->strings[" and "] = "e ";
+$a->strings["public profile"] = "profilo pubblico";
+$a->strings["%1\$s changed %2\$s to “%3\$s”"] = "%1\$s ha cambiato %2\$s in “%3\$s”";
+$a->strings[" - Visit %1\$s's %2\$s"] = "- Visita %2\$s di %1\$s";
+$a->strings["%1\$s has an updated %2\$s, changing %3\$s."] = "%1\$s ha un %2\$s aggiornato. Ha cambiato %3\$s";
+$a->strings["Hide contacts and friends:"] = "Nascondi contatti:";
+$a->strings["Hide your contact/friend list from viewers of this profile?"] = "Nascondi la tua lista di contatti/amici ai visitatori di questo profilo?";
+$a->strings["Show more profile fields:"] = "Mostra più informazioni di profilo:";
+$a->strings["Profile Actions"] = "Azioni Profilo";
+$a->strings["Edit Profile Details"] = "Modifica i dettagli del profilo";
+$a->strings["Change Profile Photo"] = "Cambia la foto del profilo";
+$a->strings["View this profile"] = "Visualizza questo profilo";
+$a->strings["Create a new profile using these settings"] = "Crea un nuovo profilo usando queste impostazioni";
+$a->strings["Clone this profile"] = "Clona questo profilo";
+$a->strings["Delete this profile"] = "Elimina questo profilo";
+$a->strings["Basic information"] = "Informazioni di base";
+$a->strings["Profile picture"] = "Immagine del profilo";
+$a->strings["Preferences"] = "Preferenze";
+$a->strings["Status information"] = "Informazioni stato";
+$a->strings["Additional information"] = "Informazioni aggiuntive";
+$a->strings["Relation"] = "Relazione";
+$a->strings["Your Gender:"] = "Il tuo sesso:";
+$a->strings["<span class=\"heart\">♥</span> Marital Status:"] = "<span class=\"heart\">♥</span> Stato sentimentale:";
+$a->strings["Example: fishing photography software"] = "Esempio: pesca fotografia programmazione";
+$a->strings["Profile Name:"] = "Nome del profilo:";
+$a->strings["This is your <strong>public</strong> profile.<br />It <strong>may</strong> be visible to anybody using the internet."] = "Questo è il tuo profilo <strong>publico</strong>.<br /><strong>Potrebbe</strong> essere visto da chiunque attraverso internet.";
+$a->strings["Your Full Name:"] = "Il tuo nome completo:";
+$a->strings["Title/Description:"] = "Breve descrizione (es. titolo, posizione, altro):";
+$a->strings["Street Address:"] = "Indirizzo (via/piazza):";
+$a->strings["Locality/City:"] = "Località:";
+$a->strings["Region/State:"] = "Regione/Stato:";
+$a->strings["Postal/Zip Code:"] = "CAP:";
+$a->strings["Country:"] = "Nazione:";
+$a->strings["Who: (if applicable)"] = "Con chi: (se possibile)";
+$a->strings["Examples: cathy123, Cathy Williams, cathy@example.com"] = "Esempio: cathy123, Cathy Williams, cathy@example.com";
+$a->strings["Since [date]:"] = "Dal [data]:";
+$a->strings["Tell us about yourself..."] = "Raccontaci di te...";
+$a->strings["XMPP (Jabber) address:"] = "Indirizzo XMPP (Jabber):";
+$a->strings["The XMPP address will be propagated to your contacts so that they can follow you."] = "L'indirizzo XMPP verrà propagato ai tuoi contatti così che possano seguirti.";
+$a->strings["Homepage URL:"] = "Homepage:";
+$a->strings["Religious Views:"] = "Orientamento religioso:";
+$a->strings["Public Keywords:"] = "Parole chiave visibili a tutti:";
+$a->strings["(Used for suggesting potential friends, can be seen by others)"] = "(E' utilizzato per suggerire potenziali amici, può essere visto da altri)";
+$a->strings["Private Keywords:"] = "Parole chiave private:";
+$a->strings["(Used for searching profiles, never shown to others)"] = "(Usato per cercare tra i profili, non è mai visibile agli altri)";
+$a->strings["Musical interests"] = "Interessi musicali";
+$a->strings["Books, literature"] = "Libri, letteratura";
+$a->strings["Television"] = "Televisione";
+$a->strings["Film/dance/culture/entertainment"] = "Film/danza/cultura/intrattenimento";
+$a->strings["Hobbies/Interests"] = "Hobby/interessi";
+$a->strings["Love/romance"] = "Amore";
+$a->strings["Work/employment"] = "Lavoro/impiego";
+$a->strings["School/education"] = "Scuola/educazione";
+$a->strings["Contact information and Social Networks"] = "Informazioni su contatti e social network";
+$a->strings["Edit/Manage Profiles"] = "Modifica / Gestisci profili";
+$a->strings["Registration successful. Please check your email for further instructions."] = "Registrazione completata. Controlla la tua mail per ulteriori informazioni.";
+$a->strings["Failed to send email message. Here your accout details:<br> login: %s<br> password: %s<br><br>You can change your password after login."] = "Si è verificato un errore inviando l'email. I dettagli del tuo account:<br> login: %s<br> password: %s<br><br>Puoi cambiare la password dopo il login.";
+$a->strings["Registration successful."] = "Registrazione completata.";
+$a->strings["Your registration can not be processed."] = "La tua registrazione non puo' essere elaborata.";
+$a->strings["Your registration is pending approval by the site owner."] = "La tua richiesta è in attesa di approvazione da parte del proprietario del sito.";
+$a->strings["You may (optionally) fill in this form via OpenID by supplying your OpenID and clicking 'Register'."] = "Se vuoi, puoi riempire questo modulo tramite OpenID, inserendo il tuo OpenID e cliccando 'Registra'.";
+$a->strings["If you are not familiar with OpenID, please leave that field blank and fill in the rest of the items."] = "Se non hai familiarità con OpenID, lascia il campo vuoto e riempi il resto della maschera.";
+$a->strings["Your OpenID (optional): "] = "Il tuo OpenID (opzionale): ";
+$a->strings["Include your profile in member directory?"] = "Includi il tuo profilo nell'elenco pubblico?";
+$a->strings["Note for the admin"] = "Nota per l'amministratore";
+$a->strings["Leave a message for the admin, why you want to join this node"] = "Lascia un messaggio per l'amministratore, per esempio perché vuoi registrarti su questo nodo";
+$a->strings["Membership on this site is by invitation only."] = "La registrazione su questo sito è solo su invito.";
+$a->strings["Your invitation ID: "] = "L'ID del tuo invito:";
+$a->strings["Your Full Name (e.g. Joe Smith, real or real-looking): "] = "Il tuo nome completo (es. Mario Rossi, vero o che sembri vero): ";
+$a->strings["Your Email Address: "] = "Il tuo indirizzo email: ";
+$a->strings["New Password:"] = "Nuova password:";
+$a->strings["Leave empty for an auto generated password."] = "Lascia vuoto per generare automaticamente una password.";
+$a->strings["Confirm:"] = "Conferma:";
+$a->strings["Choose a profile nickname. This must begin with a text character. Your profile address on this site will then be '<strong>nickname@\$sitename</strong>'."] = "Scegli un nome utente. Deve cominciare con una lettera. L'indirizzo del tuo profilo sarà '<strong>soprannome@\$sitename</strong>'.";
+$a->strings["Choose a nickname: "] = "Scegli un nome utente: ";
+$a->strings["Import your profile to this friendica instance"] = "Importa il tuo profilo in questo server friendica";
+$a->strings["Account approved."] = "Account approvato.";
+$a->strings["Registration revoked for %s"] = "Registrazione revocata per %s";
+$a->strings["Please login."] = "Accedi.";
+$a->strings["Display"] = "Visualizzazione";
+$a->strings["Social Networks"] = "Social Networks";
+$a->strings["Connected apps"] = "Applicazioni collegate";
+$a->strings["Remove account"] = "Rimuovi account";
+$a->strings["Missing some important data!"] = "Mancano alcuni dati importanti!";
+$a->strings["Failed to connect with email account using the settings provided."] = "Impossibile collegarsi all'account email con i parametri forniti.";
+$a->strings["Email settings updated."] = "Impostazioni e-mail aggiornate.";
+$a->strings["Features updated"] = "Funzionalità aggiornate";
+$a->strings["Relocate message has been send to your contacts"] = "Il messaggio di trasloco è stato inviato ai tuoi contatti";
+$a->strings["Empty passwords are not allowed. Password unchanged."] = "Le password non possono essere vuote. Password non cambiata.";
+$a->strings["Wrong password."] = "Password sbagliata.";
+$a->strings["Password changed."] = "Password cambiata.";
+$a->strings["Password update failed. Please try again."] = "Aggiornamento password fallito. Prova ancora.";
+$a->strings[" Please use a shorter name."] = " Usa un nome più corto.";
+$a->strings[" Name too short."] = " Nome troppo corto.";
+$a->strings["Wrong Password"] = "Password Sbagliata";
+$a->strings[" Not valid email."] = " Email non valida.";
+$a->strings[" Cannot change to that email."] = "Non puoi usare quella email.";
+$a->strings["Private forum has no privacy permissions. Using default privacy group."] = "Il forum privato non ha permessi di privacy. Uso il gruppo di privacy predefinito.";
+$a->strings["Private forum has no privacy permissions and no default privacy group."] = "Il gruppo privato non ha permessi di privacy e nessun gruppo di privacy predefinito.";
+$a->strings["Settings updated."] = "Impostazioni aggiornate.";
+$a->strings["Add application"] = "Aggiungi applicazione";
+$a->strings["Consumer Key"] = "Consumer Key";
+$a->strings["Consumer Secret"] = "Consumer Secret";
+$a->strings["Redirect"] = "Redirect";
+$a->strings["Icon url"] = "Url icona";
+$a->strings["You can't edit this application."] = "Non puoi modificare questa applicazione.";
+$a->strings["Connected Apps"] = "Applicazioni Collegate";
+$a->strings["Edit"] = "Modifica";
+$a->strings["Client key starts with"] = "Chiave del client inizia con";
+$a->strings["No name"] = "Nessun nome";
+$a->strings["Remove authorization"] = "Rimuovi l'autorizzazione";
+$a->strings["No Plugin settings configured"] = "Nessun plugin ha impostazioni modificabili";
+$a->strings["Plugin Settings"] = "Impostazioni plugin";
+$a->strings["Additional Features"] = "Funzionalità aggiuntive";
+$a->strings["General Social Media Settings"] = "Impostazioni Media Sociali";
+$a->strings["Disable intelligent shortening"] = "Disabilita accorciamento intelligente";
+$a->strings["Normally the system tries to find the best link to add to shortened posts. If this option is enabled then every shortened post will always point to the original friendica post."] = "Normalmente il sistema tenta di trovare il migliore link da aggiungere a un post accorciato. Se questa opzione è abilitata, ogni post accorciato conterrà sempre un link al post originale su Friendica.";
+$a->strings["Automatically follow any GNU Social (OStatus) followers/mentioners"] = "Segui automaticamente chiunque da GNU Social (OStatus) ti segua o ti menzioni";
+$a->strings["If you receive a message from an unknown OStatus user, this option decides what to do. If it is checked, a new contact will be created for every unknown user."] = "Se ricevi un messaggio da un utente OStatus sconosciuto, questa opzione decide cosa fare. Se selezionato, un nuovo contatto verrà creato per ogni utente sconosciuto.";
+$a->strings["Default group for OStatus contacts"] = "Gruppo di default per i contatti OStatus";
+$a->strings["Your legacy GNU Social account"] = "Il tuo vecchio account GNU Social";
+$a->strings["If you enter your old GNU Social/Statusnet account name here (in the format user@domain.tld), your contacts will be added automatically. The field will be emptied when done."] = "Se inserisci il nome del tuo vecchio account GNU Social/Statusnet qui (nel formato utente@dominio.tld), i tuoi contatti verranno automaticamente aggiunti. Il campo verrà svuotato una volta terminato.";
+$a->strings["Repair OStatus subscriptions"] = "Ripara le iscrizioni OStatus";
+$a->strings["Built-in support for %s connectivity is %s"] = "Il supporto integrato per la connettività con %s è %s";
+$a->strings["enabled"] = "abilitato";
+$a->strings["disabled"] = "disabilitato";
+$a->strings["GNU Social (OStatus)"] = "GNU Social (OStatus)";
+$a->strings["Email access is disabled on this site."] = "L'accesso email è disabilitato su questo sito.";
+$a->strings["Email/Mailbox Setup"] = "Impostazioni email";
+$a->strings["If you wish to communicate with email contacts using this service (optional), please specify how to connect to your mailbox."] = "Se vuoi comunicare con i contatti email usando questo servizio, specifica come collegarti alla tua casella di posta. (opzionale)";
+$a->strings["Last successful email check:"] = "Ultimo controllo email eseguito con successo:";
+$a->strings["IMAP server name:"] = "Nome server IMAP:";
+$a->strings["IMAP port:"] = "Porta IMAP:";
+$a->strings["Security:"] = "Sicurezza:";
+$a->strings["None"] = "Nessuna";
+$a->strings["Email login name:"] = "Nome utente email:";
+$a->strings["Email password:"] = "Password email:";
+$a->strings["Reply-to address:"] = "Indirizzo di risposta:";
+$a->strings["Send public posts to all email contacts:"] = "Invia i messaggi pubblici ai contatti email:";
+$a->strings["Action after import:"] = "Azione post importazione:";
+$a->strings["Move to folder"] = "Sposta nella cartella";
+$a->strings["Move to folder:"] = "Sposta nella cartella:";
+$a->strings["Display Settings"] = "Impostazioni Grafiche";
+$a->strings["Display Theme:"] = "Tema:";
+$a->strings["Mobile Theme:"] = "Tema mobile:";
+$a->strings["Suppress warning of insecure networks"] = "Sopprimi avvisi reti insicure";
+$a->strings["Should the system suppress the warning that the current group contains members of networks that can't receive non public postings."] = "Il sistema sopprimerà l'avviso che il gruppo selezionato contiene membri di reti che non possono ricevere post non pubblici.";
+$a->strings["Update browser every xx seconds"] = "Aggiorna il browser ogni x secondi";
+$a->strings["Minimum of 10 seconds. Enter -1 to disable it."] = "Minimo 10 secondi. Inserisci -1 per disabilitarlo";
+$a->strings["Number of items to display per page:"] = "Numero di elementi da mostrare per pagina:";
+$a->strings["Maximum of 100 items"] = "Massimo 100 voci";
+$a->strings["Number of items to display per page when viewed from mobile device:"] = "Numero di voci da visualizzare per pagina quando si utilizza un dispositivo mobile:";
+$a->strings["Don't show emoticons"] = "Non mostrare le emoticons";
+$a->strings["Calendar"] = "Calendario";
+$a->strings["Beginning of week:"] = "Inizio della settimana:";
+$a->strings["Don't show notices"] = "Non mostrare gli avvisi";
+$a->strings["Infinite scroll"] = "Scroll infinito";
+$a->strings["Automatic updates only at the top of the network page"] = "Aggiornamenti automatici solo in cima alla pagina \"rete\"";
+$a->strings["When disabled, the network page is updated all the time, which could be confusing while reading."] = "";
+$a->strings["Bandwith Saver Mode"] = "Modalità Salva Banda";
+$a->strings["When enabled, embedded content is not displayed on automatic updates, they only show on page reload."] = "Quando abilitato, il contenuto embeddato non è mostrato quando la pagina si aggiorna automaticamente, ma solo quando la pagina viene ricaricata.";
+$a->strings["General Theme Settings"] = "Opzioni Generali Tema";
+$a->strings["Custom Theme Settings"] = "Opzioni Personalizzate Tema";
+$a->strings["Content Settings"] = "Opzioni Contenuto";
+$a->strings["Theme settings"] = "Impostazioni tema";
+$a->strings["Account Types"] = "Tipi di Account";
+$a->strings["Personal Page Subtypes"] = "Sottotipi di Pagine Personali";
+$a->strings["Community Forum Subtypes"] = "Sottotipi di Community Forum";
+$a->strings["Personal Page"] = "Pagina Personale";
+$a->strings["Account for a personal profile."] = "";
+$a->strings["Organisation Page"] = "Pagina Organizzazione";
+$a->strings["Account for an organisation that automatically approves contact requests as \"Followers\"."] = "";
+$a->strings["News Page"] = "Pagina Notizie";
+$a->strings["Account for a news reflector that automatically approves contact requests as \"Followers\"."] = "";
+$a->strings["Community Forum"] = "Community Forum";
+$a->strings["Account for community discussions."] = "";
+$a->strings["Normal Account Page"] = "Pagina Account Normale";
+$a->strings["Account for a regular personal profile that requires manual approval of \"Friends\" and \"Followers\"."] = "";
+$a->strings["Soapbox Page"] = "Pagina Sandbox";
+$a->strings["Account for a public profile that automatically approves contact requests as \"Followers\"."] = "";
+$a->strings["Public Forum"] = "Forum Pubblico";
+$a->strings["Automatically approves all contact requests."] = "";
+$a->strings["Automatic Friend Page"] = "Pagina con amicizia automatica";
+$a->strings["Account for a popular profile that automatically approves contact requests as \"Friends\"."] = "";
+$a->strings["Private Forum [Experimental]"] = "Forum privato [sperimentale]";
+$a->strings["Requires manual approval of contact requests."] = "";
+$a->strings["OpenID:"] = "OpenID:";
+$a->strings["(Optional) Allow this OpenID to login to this account."] = "(Opzionale) Consente di loggarti in questo account con questo OpenID";
+$a->strings["Publish your default profile in your local site directory?"] = "Pubblica il tuo profilo predefinito nell'elenco locale del sito";
+$a->strings["Your profile may be visible in public."] = "Il tuo profilo potrebbe essere visibile pubblicamente.";
+$a->strings["Publish your default profile in the global social directory?"] = "Pubblica il tuo profilo predefinito nell'elenco sociale globale";
+$a->strings["Hide your contact/friend list from viewers of your default profile?"] = "Nascondi la lista dei tuoi contatti/amici dai visitatori del tuo profilo predefinito";
+$a->strings["If enabled, posting public messages to Diaspora and other networks isn't possible."] = "Se abilitato, l'invio di messaggi pubblici verso Diaspora e altri network non sarà possibile";
+$a->strings["Allow friends to post to your profile page?"] = "Permetti agli amici di scrivere sulla tua pagina profilo?";
+$a->strings["Allow friends to tag your posts?"] = "Permetti agli amici di aggiungere tag ai tuoi messaggi?";
+$a->strings["Allow us to suggest you as a potential friend to new members?"] = "Ci permetti di suggerirti come potenziale amico ai nuovi membri?";
+$a->strings["Permit unknown people to send you private mail?"] = "Permetti a utenti sconosciuti di inviarti messaggi privati?";
+$a->strings["Profile is <strong>not published</strong>."] = "Il profilo <strong>non è pubblicato</strong>.";
+$a->strings["Your Identity Address is <strong>'%s'</strong> or '%s'."] = "L'indirizzo della tua identità è <strong>'%s'</strong> or '%s'.";
+$a->strings["Automatically expire posts after this many days:"] = "Fai scadere i post automaticamente dopo x giorni:";
+$a->strings["If empty, posts will not expire. Expired posts will be deleted"] = "Se lasciato vuoto, i messaggi non verranno cancellati.";
+$a->strings["Advanced expiration settings"] = "Impostazioni avanzate di scadenza";
+$a->strings["Advanced Expiration"] = "Scadenza avanzata";
+$a->strings["Expire posts:"] = "Fai scadere i post:";
+$a->strings["Expire personal notes:"] = "Fai scadere le Note personali:";
+$a->strings["Expire starred posts:"] = "Fai scadere i post Speciali:";
+$a->strings["Expire photos:"] = "Fai scadere le foto:";
+$a->strings["Only expire posts by others:"] = "Fai scadere solo i post degli altri:";
+$a->strings["Account Settings"] = "Impostazioni account";
+$a->strings["Password Settings"] = "Impostazioni password";
+$a->strings["Leave password fields blank unless changing"] = "Lascia questi campi in bianco per non effettuare variazioni alla password";
+$a->strings["Current Password:"] = "Password Attuale:";
+$a->strings["Your current password to confirm the changes"] = "La tua password attuale per confermare le modifiche";
+$a->strings["Password:"] = "Password:";
+$a->strings["Basic Settings"] = "Impostazioni base";
+$a->strings["Email Address:"] = "Indirizzo Email:";
+$a->strings["Your Timezone:"] = "Il tuo fuso orario:";
+$a->strings["Your Language:"] = "La tua lingua:";
+$a->strings["Set the language we use to show you friendica interface and to send you emails"] = "Imposta la lingua che sarà usata per mostrarti l'interfaccia di Friendica e per inviarti le email";
+$a->strings["Default Post Location:"] = "Località predefinita:";
+$a->strings["Use Browser Location:"] = "Usa la località rilevata dal browser:";
+$a->strings["Security and Privacy Settings"] = "Impostazioni di sicurezza e privacy";
+$a->strings["Maximum Friend Requests/Day:"] = "Numero massimo di richieste di amicizia al giorno:";
+$a->strings["(to prevent spam abuse)"] = "(per prevenire lo spam)";
+$a->strings["Default Post Permissions"] = "Permessi predefiniti per i messaggi";
+$a->strings["(click to open/close)"] = "(clicca per aprire/chiudere)";
+$a->strings["Default Private Post"] = "Default Post Privato";
+$a->strings["Default Public Post"] = "Default Post Pubblico";
+$a->strings["Default Permissions for New Posts"] = "Permessi predefiniti per i nuovi post";
+$a->strings["Maximum private messages per day from unknown people:"] = "Numero massimo di messaggi privati da utenti sconosciuti per giorno:";
+$a->strings["Notification Settings"] = "Impostazioni notifiche";
+$a->strings["By default post a status message when:"] = "Invia un messaggio di stato quando:";
+$a->strings["accepting a friend request"] = "accetti una richiesta di amicizia";
+$a->strings["joining a forum/community"] = "ti unisci a un forum/comunità";
+$a->strings["making an <em>interesting</em> profile change"] = "fai un <em>interessante</em> modifica al profilo";
+$a->strings["Send a notification email when:"] = "Invia una mail di notifica quando:";
+$a->strings["You receive an introduction"] = "Ricevi una presentazione";
+$a->strings["Your introductions are confirmed"] = "Le tue presentazioni sono confermate";
+$a->strings["Someone writes on your profile wall"] = "Qualcuno scrive sulla bacheca del tuo profilo";
+$a->strings["Someone writes a followup comment"] = "Qualcuno scrive un commento a un tuo messaggio";
+$a->strings["You receive a private message"] = "Ricevi un messaggio privato";
+$a->strings["You receive a friend suggestion"] = "Hai ricevuto un suggerimento di amicizia";
+$a->strings["You are tagged in a post"] = "Sei stato taggato in un post";
+$a->strings["You are poked/prodded/etc. in a post"] = "Sei 'toccato'/'spronato'/ecc. in un post";
+$a->strings["Activate desktop notifications"] = "Attiva notifiche desktop";
+$a->strings["Show desktop popup on new notifications"] = "Mostra un popup di notifica sul desktop all'arrivo di nuove notifiche";
+$a->strings["Text-only notification emails"] = "Email di notifica in solo testo";
+$a->strings["Send text only notification emails, without the html part"] = "Invia le email di notifica in solo testo, senza la parte in html";
+$a->strings["Show detailled notifications"] = "";
+$a->strings["Per default the notificiation are condensed to a single notification per item. When enabled, every notification is displayed."] = "";
+$a->strings["Advanced Account/Page Type Settings"] = "Impostazioni avanzate Account/Tipo di pagina";
+$a->strings["Change the behaviour of this account for special situations"] = "Modifica il comportamento di questo account in situazioni speciali";
+$a->strings["Relocate"] = "Trasloca";
+$a->strings["If you have moved this profile from another server, and some of your contacts don't receive your updates, try pushing this button."] = "Se hai spostato questo profilo da un'altro server, e alcuni dei tuoi contatti non ricevono i tuoi aggiornamenti, prova a premere questo bottone.";
+$a->strings["Resend relocate message to contacts"] = "Invia nuovamente il messaggio di trasloco ai contatti";
+$a->strings["Do you really want to delete this video?"] = "Vuoi veramente cancellare questo video?";
+$a->strings["Delete Video"] = "Rimuovi video";
+$a->strings["No videos selected"] = "Nessun video selezionato";
+$a->strings["Recent Videos"] = "Video Recenti";
+$a->strings["Upload New Videos"] = "Carica Nuovo Video";
+$a->strings["Invalid request."] = "Richiesta non valida.";
+$a->strings["Sorry, maybe your upload is bigger than the PHP configuration allows"] = "Mi spiace, forse il file che stai caricando è più grosso di quanto la configurazione di PHP permetta";
+$a->strings["Or - did you try to upload an empty file?"] = "O.. non avrai provato a caricare un file vuoto?";
+$a->strings["File exceeds size limit of %s"] = "Il file supera la dimensione massima di %s";
+$a->strings["File upload failed."] = "Caricamento del file non riuscito.";
+$a->strings["This entry was edited"] = "Questa voce è stata modificata";
+$a->strings["save to folder"] = "salva nella cartella";
+$a->strings["I will attend"] = "Parteciperò";
+$a->strings["I will not attend"] = "Non parteciperò";
+$a->strings["I might attend"] = "Forse parteciperò";
+$a->strings["add star"] = "aggiungi a speciali";
+$a->strings["remove star"] = "rimuovi da speciali";
+$a->strings["toggle star status"] = "Inverti stato preferito";
+$a->strings["starred"] = "preferito";
+$a->strings["ignore thread"] = "ignora la discussione";
+$a->strings["unignore thread"] = "non ignorare la discussione";
+$a->strings["toggle ignore status"] = "inverti stato \"Ignora\"";
+$a->strings["add tag"] = "aggiungi tag";
+$a->strings["like"] = "mi piace";
+$a->strings["dislike"] = "non mi piace";
+$a->strings["Share this"] = "Condividi questo";
+$a->strings["share"] = "condividi";
+$a->strings["to"] = "a";
$a->strings["via"] = "via";
+$a->strings["Wall-to-Wall"] = "Da bacheca a bacheca";
+$a->strings["via Wall-To-Wall:"] = "da bacheca a bacheca";
+$a->strings["%d comment"] = array(
+ 0 => "%d commento",
+ 1 => "%d commenti",
+);
+$a->strings["Bold"] = "Grassetto";
+$a->strings["Italic"] = "Corsivo";
+$a->strings["Underline"] = "Sottolineato";
+$a->strings["Quote"] = "Citazione";
+$a->strings["Code"] = "Codice";
+$a->strings["Image"] = "Immagine";
+$a->strings["Link"] = "Link";
+$a->strings["Video"] = "Video";
$a->strings["greenzero"] = "greenzero";
$a->strings["purplezero"] = "purplezero";
$a->strings["easterbunny"] = "easterbunny";
$a->strings["comix"] = "comix";
$a->strings["slackr"] = "slackr";
$a->strings["Variations"] = "Varianti";
+$a->strings["Repeat the image"] = "Ripeti l'immagine";
+$a->strings["Will repeat your image to fill the background."] = "Ripete l'immagine per riempire lo sfondo.";
+$a->strings["Stretch"] = "Stira";
+$a->strings["Will stretch to width/height of the image."] = "Stira l'immagine.";
+$a->strings["Resize fill and-clip"] = "Scala e ritaglia";
+$a->strings["Resize to fill and retain aspect ratio."] = "Scala l'immagine a riempire mantenendo le proporzioni.";
+$a->strings["Resize best fit"] = "Scala best fit";
+$a->strings["Resize to best fit and retain aspect ratio."] = "Scala l'immagine alla miglior dimensione per riempire mantenendo le proporzioni.";
$a->strings["Default"] = "Default";
-$a->strings["Note: "] = "Nota:";
+$a->strings["Note"] = "";
$a->strings["Check image permissions if all users are allowed to visit the image"] = "Controlla i permessi dell'immagine se tutti gli utenti sono autorizzati a vederla";
$a->strings["Select scheme"] = "Seleziona schema";
$a->strings["Navigation bar background color"] = "Colore di sfondo barra di navigazione";
$a->strings["Set the background color"] = "Imposta il colore di sfondo";
$a->strings["Content background transparency"] = "Trasparenza sfondo contenuto";
$a->strings["Set the background image"] = "Imposta l'immagine di sfondo";
-$a->strings["Repeat the image"] = "Ripeti l'immagine";
-$a->strings["Will repeat your image to fill the background."] = "Ripete l'immagine per riempire lo sfondo.";
-$a->strings["Stretch"] = "Stira";
-$a->strings["Will stretch to width/height of the image."] = "Stira l'immagine.";
-$a->strings["Resize fill and-clip"] = "Scala e ritaglia";
-$a->strings["Resize to fill and retain aspect ratio."] = "Scala l'immagine a riempire mantenendo le proporzioni.";
-$a->strings["Resize best fit"] = "Scala best fit";
-$a->strings["Resize to best fit and retain aspect ratio."] = "Scala l'immagine alla miglior dimensione per riempire mantenendo le proporzioni.";
$a->strings["Guest"] = "Ospite";
$a->strings["Visitor"] = "Visitatore";
$a->strings["Alignment"] = "Allineamento";
$a->strings["Color scheme"] = "Schema colori";
$a->strings["Posts font size"] = "Dimensione caratteri post";
$a->strings["Textareas font size"] = "Dimensione caratteri nelle aree di testo";
-$a->strings["Comma separated list of helper forums"] = "Lista separata da virgola di forum di aiuto";
-$a->strings["Set style"] = "Imposta stile";
-$a->strings["Community Pages"] = "Pagine Comunitarie";
$a->strings["Community Profiles"] = "Profili Comunità";
-$a->strings["Help or @NewHere ?"] = "Serve aiuto? Sei nuovo?";
-$a->strings["Connect Services"] = "Servizi connessi";
-$a->strings["Find Friends"] = "Trova Amici";
$a->strings["Last users"] = "Ultimi utenti";
+$a->strings["Find Friends"] = "Trova Amici";
$a->strings["Local Directory"] = "Elenco Locale";
$a->strings["Quick Start"] = "Quick Start";
-$a->strings["toggle mobile"] = "commuta tema mobile";
+$a->strings["Connect Services"] = "Servizi connessi";
+$a->strings["Comma separated list of helper forums"] = "Lista separata da virgola di forum di aiuto";
+$a->strings["Set style"] = "Imposta stile";
+$a->strings["Community Pages"] = "Pagine Comunitarie";
+$a->strings["Help or @NewHere ?"] = "Serve aiuto? Sei nuovo?";
$a->strings["Delete this item?"] = "Cancellare questo elemento?";
$a->strings["show fewer"] = "mostra di meno";
$a->strings["Update %s failed. See error logs."] = "aggiornamento %s fallito. Guarda i log di errore.";
$a->strings["terms of service"] = "condizioni del servizio";
$a->strings["Website Privacy Policy"] = "Politiche di privacy del sito";
$a->strings["privacy policy"] = "politiche di privacy";
+$a->strings["toggle mobile"] = "commuta tema mobile";
{{include file="field_select.tpl" field=$community_page_style}}
{{include file="field_input.tpl" field=$max_author_posts_community_page}}
- {{if $thread_allow.2}}
- {{include file="field_checkbox.tpl" field=$ostatus_disabled}}
- {{include file="field_checkbox.tpl" field=$ostatus_full_threads}}
- {{else}}
- <div class='field checkbox' id='div_id_{{$ostatus_disabled.0}}'>
- <label for='id_{{$ostatus_disabled.0}}'>{{$ostatus_disabled.1}}</label>
- <span id='id_{{$ostatus_disabled.0}}'>{{$ostatus_not_able}}</span>
- </div>
- {{/if}}
+ {{include file="field_checkbox.tpl" field=$ostatus_disabled}}
+ {{include file="field_checkbox.tpl" field=$ostatus_full_threads}}
{{if $diaspora_able}}
{{include file="field_checkbox.tpl" field=$diaspora_enabled}}
{{include file="field_checkbox.tpl" field=$dfrn_only}}
{{include file="field_input.tpl" field=$global_directory}}
<div class="submit"><input type="submit" name="republish_directory" value="{{$republish|escape:'html'}}" /></div>
- {{include file="field_checkbox.tpl" field=$thread_allow}}
{{include file="field_checkbox.tpl" field=$newuser_private}}
{{include file="field_checkbox.tpl" field=$enotify_no_content}}
{{include file="field_checkbox.tpl" field=$private_addons}}
-
<div id="contact-edit-wrapper" >
{{* Insert Tab-Nav *}}
{{if $lost_contact}}<li><div id="lost-contact-message">{{$lost_contact}}</div></li>{{/if}}
{{if $insecure}}<li><div id="insecure-message">{{$insecure}}</div></li> {{/if}}
- {{if $blocked}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $blocked && !$pending}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $pending}}<li><div id="pending-message">{{$pending}}</div></li>{{/if}}
{{if $ignored}}<li><div id="ignore-message">{{$ignored}}</div></li>{{/if}}
{{if $archived}}<li><div id="archive-message">{{$archived}}</div></li>{{/if}}
</ul>
{{include file="field_checkbox.tpl" field=$notify}}
{{if $fetch_further_information}}
{{include file="field_select.tpl" field=$fetch_further_information}}
- {{if $fetch_further_information.2 == 2 }} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
+ {{if $fetch_further_information.2 == 2 || $fetch_further_information.2 == 3}} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
{{/if}}
{{include file="field_checkbox.tpl" field=$hidden}}
{{include file="field_checkbox.tpl" field=$noinfo}}
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
+{{include file="field_checkbox.tpl" field=$smart_threading}}
<h2>{{$calendar_title}}</h2>
{{include file="field_select.tpl" field=$first_day_of_week}}
--- /dev/null
+
+<div class="tagblock widget">
+ <h3>{{$title}}</h3>
+
+ <div class="tag-cloud">
+ {{foreach $tags as $tag}}
+ <span class="tags">
+ <span class="tag{{$tag.level}}">#</span><a href="{{$tag.url}}" class="tag{{$tag.level}}">{{$tag.name}}</a>
+ </span>
+ {{/foreach}}
+ </div>
+ <div class="tagblock-widget-end clear"></div>
+</div>
function duepuntozero_init(App $a) {
-set_template_engine($a, 'smarty3');
+$a->set_template_engine('smarty3');
$colorset = PConfig::get( local_user(), 'duepuntozero','colorset');
if (!$colorset)
width: 75px;
border-radius: 4px;
}
+
+/* Tag cloud widget */
+.tagblock.widget > .tag-cloud {
+ text-align: center;
+}
/* Section */
section ul.tabs {
display: none !important;
{{if $lost_contact}}<li><div id="lost-contact-message">{{$lost_contact}}</div></li>{{/if}}
{{if $insecure}}<li><div id="insecure-message">{{$insecure}}</div></li> {{/if}}
- {{if $blocked}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $blocked && !$pending}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $pending}}<li><div id="pending-message">{{$pending}}</div></li>{{/if}}
{{if $ignored}}<li><div id="ignore-message">{{$ignored}}</div></li>{{/if}}
{{if $archived}}<li><div id="archive-message">{{$archived}}</div></li>{{/if}}
</ul>
{{include file="field_checkbox.tpl" field=$notify}}
{{if $fetch_further_information}}
{{include file="field_select.tpl" field=$fetch_further_information}}
- {{if $fetch_further_information.2 == 2 }} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
+ {{if $fetch_further_information.2 == 2 || $fetch_further_information.2 == 3}} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
{{/if}}
{{include file="field_checkbox.tpl" field=$hidden}}
{{include file="field_checkbox.tpl" field=$noinfo}}
{{include file="field_checkbox.tpl" field=$infinite_scroll}}
{{include file="field_checkbox.tpl" field=$bandwidth_saver}}
+ {{include file="field_checkbox.tpl" field=$smart_threading}}
<div class="form-group pull-right settings-submit-wrapper" >
<button type="submit" name="submit" class="btn btn-primary" value="{{$submit|escape:'html'}}">{{$submit}}</button>
// disable the events module link in the profile tab
$a->theme_events_in_profile = false;
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
$baseurl = System::baseUrl();
{{include file="field_checkbox.tpl" field=$diaspora_enabled}}
{{include file="field_checkbox.tpl" field=$dfrn_only}}
{{include file="field_input.tpl" field=$global_directory}}
- {{include file="field_checkbox.tpl" field=$thread_allow}}
{{include file="field_checkbox.tpl" field=$newuser_private}}
{{include file="field_checkbox.tpl" field=$enotify_no_content}}
{{include file="field_checkbox.tpl" field=$private_addons}}
$a->sourcename = 'Friendica mobile web';
$a->videowidth = 250;
$a->videoheight = 200;
- $a->theme_thread_allow = false;
$a->force_max_items = 10;
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
}
function frost_mobile_content_loaded(App $a) {
{{include file="field_checkbox.tpl" field=$diaspora_enabled}}
{{include file="field_checkbox.tpl" field=$dfrn_only}}
{{include file="field_input.tpl" field=$global_directory}}
- {{include file="field_checkbox.tpl" field=$thread_allow}}
{{include file="field_checkbox.tpl" field=$newuser_private}}
{{include file="field_checkbox.tpl" field=$enotify_no_content}}
{{include file="field_checkbox.tpl" field=$private_addons}}
function frost_init(App $a) {
$a->videowidth = 400;
$a->videoheight = 330;
- $a->theme_thread_allow = false;
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
}
function frost_content_loaded(App $a) {
use Friendica\Core\System;
function smoothly_init(App $a) {
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
$cssFile = null;
$ssl_state = null;
/// @TODO $a is no longer used
function vier_form(App $a, $style, $show_pages, $show_profiles, $show_helpers, $show_services, $show_friends, $show_lastusers) {
$styles = array(
- "plus"=>"Plus",
"breathe"=>"Breathe",
- "dark"=>"Dark",
- "shadow"=>"Shadow",
"netcolour"=>"Coloured Networks",
- "flat"=>"Flat"
+ "dark"=>"Dark",
+ "flat"=>"Flat",
+ "plus"=>"Plus",
+ "plusminus"=>"Plus Minus",
+ "shadow"=>"Shadow"
);
$show_or_not = array('0'=>t("don't show"), '1'=>t("show"),);
--- /dev/null
+/* Modifications by https://horche.demkontinuum.de/profile/hoergen */
+
+h1 {
+ font-size: 18px;
+ color: blue;
+}
+
+h2 {
+ font-size: 16px;
+ color: blue;
+ background-color: #EEEEEE;
+ border-radius:5px;
+}
+
+h3 {
+ font-size: 14px;
+ color: blue;
+}
+h4 { font-size: 14px;}
+
+h5 {
+ font-size: 16px;
+ color: black;
+ background-color: #cfcece;
+ border-radius:5px;
+}
+
+
+nav {
+ background: #fff;
+ box-shadow: 0px 2px 4px 0px rgba(0, 0, 0, 0.15);
+ padding-top: 6px;
+ padding-bottom: 6px;
+}
+
+nav a:active,
+nav a:link,
+nav a:visited,
+nav a {
+ color: #737373;
+}
+
+nav a:hover,
+#nav-messages-see-all a:hover {
+ color: #000;
+}
+
+.manage-notify {
+ background-color: #CB4437;
+ border-radius: 10px;
+ font: bold 11px/16px Arial;
+}
+
+nav .nav-notify {
+ background-color: #CB4437;
+ top: -3px;
+ right: -4px;
+ font: bold 11px/16px Arial;
+ padding: 1px;
+ border-radius: 10px;
+}
+
+nav .nav-menu-icon .nav-notify {
+ top: 0px;
+}
+
+nav .nav-menu.selected a {
+ color: #000;
+}
+
+nav .nav-menu:hover,
+nav .nav-menu.selected {
+ border-bottom: 2px solid #427FED;
+}
+
+nav .nav-menu {
+ height: 23px;
+ font-size: 14px;
+ font-weight: initial;
+}
+
+#nav-apps-menu,
+#nav-site-menu,
+#nav-notifications-menu,
+#nav-user-menu {
+ top: 32px;
+}
+
+#nav-messages-menu {
+ top: 32px;
+}
+
+#nav-messages-see-all a {
+ color: #737373;
+}
+
+ul.tabs li .active, span.pager_current a {
+ border-bottom: 2px solid #427FED;
+}
+
+span.pager_current, span.pager_n a:hover,
+span.pager_first a:hover, span.pager_last a:hover,
+span.pager_prev a:hover, span.pager_next a:hover,
+ul.tabs a:hover {
+ border-bottom: 2px solid #427FED;
+}
+
+nav #nav-notifications-linkmenu.on .icon.s22.notify, nav #nav-notifications-linkmenu.selected .icon.s22.notify {
+ color: #737373;
+}
+
+nav #nav-messages-linkmenu.selected,
+nav #nav-user-linklabel.selected,
+nav #nav-apps-link.selected {
+ background-color: #fff;
+ border-bottom-style: none;
+}
+
+div.jGrowl div.info {
+ background: #fff url("../../../images/icons/48/info.png") no-repeat 5px center;
+}
+
+div.jGrowl div.notice {
+ color: #737373;
+}
+div.jGrowl div.info {
+ color: #737373;
+}
+
+.birthday-notice, .event-notice {
+ font-weight: initial;
+}
+
+div.pager, ul.tabs {
+ font-weight: initial;
+}
+
+nav .nav-menu-icon.selected {
+ background-color: #fff;
+}
+
+#jot #jot-tools li:hover {
+ background-color: #fff;
+}
+
+nav .icon {
+ color: #737373;
+}
+
+nav a:hover .icon {
+ color: #000;
+}
+
+ul.menu-popup {
+ border: 0px solid #FFF;
+ margin-top: 0px;
+}
+
+header #banner a, header #banner a:active, header #banner a:visited, header #banner a:link, header #banner a:hover {
+ color: #737373;
+}
+
+header {
+ left: 10px;
+}
+
+header #banner {
+ margin-top: 6px;
+}
+
+#banner #logo-text {
+ margin-left: 5px;
+}
+
+aside {
+ top: 44px;
+ height: calc(100% - 54px);
+}
+
+right_aside {
+ top: 44px;
+}
+
+section {
+ top: 44px;
+}
+
+nav #nav-search-box #nav-search-text {
+ background-color: initial;
+ border-style: solid;
+ border-width: 1px;
+ border-color: rgba(0, 0, 0, 0.15);
+}
+
+.widget h3 {
+ padding: 0px;
+ margin: 0px;
+ border-radius:5px;
+ font-size: 14px;
+ font-weight: initial;
+ background-color: #EEEEEE;
+ color: #505050;
+ font-weight: bolder;
+ width: 100%;
+}
+
+/* Timeline */
+
+div.pager, ul.tabs {
+ border-radius:5px;
+}
+
+/* Post*/
+
+#profile-jot-form { border-radius: 5px; }
+
+.tread-wrapper { border-radius: 5px; }
+
+/* Post header */
+
+.wall-item-container .wall-item-name,
+.wall-item-container .shared-author {
+ color: #555;
+ font-weight: normal;
+ font-size:10px;
+ -webkit-transition: all 0.2s ease-in-out;
+ -moz-transition: all 0.2s ease-in-out;
+ -o-transition: all 0.2s ease-in-out;
+ -ms-transition: all 0.2s ease-in-out;
+ transition: all 0.2s ease-in-out;
+}
+
+.toplevel_item:hover .wall-item-name,
+.wall-item-container:hover .wall-item-name,
+.toplevel_item:hover .shared-author,
+.wall-item-container:hover .shared-author {
+ color: #36c;
+ font-weight: normal;
+ -webkit-transition: all 0.2s ease-in-out;
+ -moz-transition: all 0.2s ease-in-out;
+ -o-transition: all 0.2s ease-in-out;
+ -ms-transition: all 0.2s ease-in-out;
+ transition: all 0.2s ease-in-out;
+}
+
+.dt-published { font-size:10px; }
+
+/* Post content */
+.wall-item-content blockquote {
+ border-left: 2px solid #D2D2D2;
+ margin-top: 10px;
+ margin-bottom:10px;
+ padding-left: 5px;
+}
+
+.wall-item-content strong { color:#565656; }
+
+.wall-item-network { font-size:10px; }
+
+.mention { font-size:12px;}
+
+.tag { font-size:12px; }
+
+.type-link, .type-video {
+ border-top: 0px solid #D2D2D2;
+ border-bottom: 0px solid #D2D2D2;
+ display: block;
+ padding-top: 5px;
+ padding-bottom: 5px;
+ margin-top: 20px;
+}
+
+.type-link blockquote{
+ border-left: 2px solid #D2D2D2;
+ margin-top: 10px;
+ margin-bottom:10px;
+ padding-left: 5px;
+ font-size:12px;
+}
+
+/* Post footer */
+.wall-item-like { font-size:12px; }
+
+.wall-item-actions-author{
+ font-size:10px;
+ font-weight:normal;
+ margin-bottom: -0.7em;
+ line-height: 5px;
+}
+
+.icon-commenting::before {
+ font-size: 17px;
+}
+
+.wall-item-tags { font-size:10px; }
+
+.wall-item-container.comment .contact-photo { height:25px; width:25px;}
+
+#item-delete-selected { font-size:12px; }
+
+.item-select {
+ width: 1px;
+ height: 1px;
+ background: #000;
+ position: relative;
+ border-radius: 9px;
+}
+
+.contact-menu {
+ font-size:12px;
+ padding-top:0px;
+ padding-bottom:0px;
+}
+
+.wall-item-bottom { font-size: 14px; }
+
+/* comments */
+
+.wall-item-like { font-size:10px; }
+
+.wall-item-container.comment { border-bottom: 0px; }
+
+.hide-comments-outer {
+ margin-left: 80px;
+ margin-bottom: 5px;
+ width: 660px;
+ border-bottom: 0px;
+ border-top: 0px;
+ font-size: 10px;
+ padding: 8px;
+}
+
+.fakelink {
+ color: #36c;
+ text-decoration: none;
+ font-size: 10px;
+ cursor: pointer;
+}
+
+/* Calendar */
+
+.fc-body { background-color: white; }
+
+.fc-content, .fc-widget {
+ background-color: #a7ecff;
+ color: black;
+ text-decoration: normal;
+}
+
+.fc-toolbar {
+ text-align: center;
+ margin-bottom: 1em;
+ background: white;
+}
+
+.fc-day-grid-event .fc-time {
+ font-weight: normal;
+ font-size: 10px;
+}
+
+.fc-title, fc-time { text-decoration: normal; }
+
+.fc-unthemed .fc-today { background: #f9ff97; }
+
+/* remove standard-styles */
+
+select {
+ -webkit-appearance: none;
+ -moz-appearance: none;
+ appearance: none;
+ border:1px;
+ border-radius: 5px;
+}
+
+option {
+ background:white;
+ border-top:0px solid #000;
+ height:18px;
+ font-size:14px;
+}
+
+/* styling */
+select {
+ border: 1px solid #bbb;
+ background-color: lightgrey;
+ box-shadow: 0 0px 0px 0 rgba(0,0,0,0.5);
+ height:20px;
+}
+
+/* Settings */
+
+.ps-theme-default h1,h2,h3,h4,h5{
+ color:black;
+ border-radius:5px;
+}
+
+.settings-heading * {
+ color: black;
+}
+
+.settings-heading {
+ font-size: 18px;
+ font-weight: bold;
+ background-color: #cfcece;
+ border-radius: 5px;
+}
+
+.setings-contend-block {
+ background-color: white;
+}
+
+#settings-form {
+ background-color: whitesmoke;
+}
+
+.field_help {
+ font-size:12px;
+ display: block;
+ margin-left: 20px;
+ color: #666666;
+}
+
+.field label {
+ width: 300px;
+}
$stylecssfile = 'view/theme/vier/plus.css';
else if ($style == "dark")
$stylecssfile = 'view/theme/vier/dark.css';
+else if ($style == "plusminus")
+ $stylecssfile = 'view/theme/vier/plusminus.css';
if (file_exists($THEMEPATH."//style.css")) {
$stylecss = file_get_contents($THEMEPATH."//style.css")."\n";
{{if $lost_contact}}<li><div id="lost-contact-message">{{$lost_contact}}</div></li>{{/if}}
{{if $insecure}}<li><div id="insecure-message">{{$insecure}}</div></li> {{/if}}
- {{if $blocked}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $blocked && !$pending}}<li><div id="block-message">{{$blocked}}</div></li>{{/if}}
+ {{if $pending}}<li><div id="pending-message">{{$pending}}</div></li>{{/if}}
{{if $ignored}}<li><div id="ignore-message">{{$ignored}}</div></li>{{/if}}
{{if $archived}}<li><div id="archive-message">{{$archived}}</div></li>{{/if}}
</ul>
{{include file="field_checkbox.tpl" field=$notify}}
{{if $fetch_further_information}}
{{include file="field_select.tpl" field=$fetch_further_information}}
- {{if $fetch_further_information.2 == 2 }} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
+ {{if $fetch_further_information.2 == 2 || $fetch_further_information.2 == 3}} {{include file="field_textarea.tpl" field=$ffi_keyword_blacklist}} {{/if}}
{{/if}}
{{include file="field_checkbox.tpl" field=$hidden}}
*/
use Friendica\App;
+use Friendica\Content\ForumManager;
use Friendica\Core\Config;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
+use Friendica\Model\GlobalContact;
require_once "include/plugin.php";
-require_once "include/socgraph.php";
require_once "mod/proxy.php";
function vier_init(App $a) {
$a->theme_events_in_profile = false;
- set_template_engine($a, 'smarty3');
+ $a->set_template_engine('smarty3');
if ($a->argv[0].$a->argv[1] === "profile".$a->user['nickname'] || $a->argv[0] === "network" && local_user()) {
vier_community_info();
// comunity_profiles
if ($show_profiles) {
-
- $r = suggestion_query(local_user(), 0, 9);
+ $r = GlobalContact::suggestionQuery(local_user(), 0, 9);
$tpl = get_markup_template('ch_directory_item.tpl');
if (DBM::is_result($r)) {
//Community_Pages at right_aside
if ($show_pages && local_user()) {
-
- require_once 'include/ForumManager.php';
-
if (x($_GET, 'cid') && intval($_GET['cid']) != 0) {
$cid = $_GET['cid'];
}
//sort by last updated item
$lastitem = true;
- $contacts = ForumManager::get_list($a->user['uid'],true,$lastitem, true);
+ $contacts = ForumManager::getList($a->user['uid'], $lastitem, true, true);
$total = count($contacts);
$visible_forums = 10;
if (count($contacts)) {
-
$id = 0;
foreach ($contacts as $contact) {
-
$selected = (($cid == $contact['id']) ? ' forum-selected' : '');
$entry = array(
$tpl = get_markup_template('widget_forumlist_right.tpl');
- $page .= replace_macros($tpl, array(
- '$title' => t('Forums'),
- '$forums' => $entries,
- '$link_desc' => t('External link to forum'),
- '$total' => $total,
- '$visible_forums' => $visible_forums,
- '$showmore' => t('show more'),
- ));
+ $page .= replace_macros(
+ $tpl,
+ array(
+ '$title' => t('Forums'),
+ '$forums' => $entries,
+ '$link_desc' => t('External link to forum'),
+ '$total' => $total,
+ '$visible_forums' => $visible_forums,
+ '$showmore' => t('show more'))
+ );
$aside['$page'] = $page;
}