code:
# Translation of StatusNet - Sitemap to German (Deutsch)
# Exported from translatewiki.net
#
# Author: Fujnky
# Author: Michael
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:01+0000\n"
"Language-Team: German <https://translatewiki.net/wiki/Portal:de>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: de\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Sitemap"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Sitemap-Einstellungen dieser StatusNet-Website"

#. TRANS: Field label.
msgid "Google key"
msgstr "Google-Schlüssel"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Google Webmaster-Tools-Verifikationsschlüssel."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoo-Schlüssel"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "„Yahoo! Site Explorer“-Verifikationsschlüssel"

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bing-Schlüssel"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Bing Webmaster-Tools-Verifikationsschlüssel."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Speichern"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Sitemap-Einstellungen speichern."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Sitemap-Konfiguration"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Sitemap"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Dieses Plugin ermöglicht die Erstellung von Sitemaps für Bing, Yahoo! und "
"Google."


code:
# Translation of StatusNet - Sitemap to Zazaki (Zazaki)
# Exported from translatewiki.net
#
# Author: Erdemaslancan
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:01+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Pusulay sita"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr ""

#. TRANS: Field label.
msgid "Google key"
msgstr "Google kesa"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr ""

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoo kesa"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr ""

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bing kesa"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr ""

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Star ke"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr ""

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr ""

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Pusulay sita"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""

license: mit


code:
# Translation of StatusNet - Sitemap to Spanish (español)
# Exported from translatewiki.net
#
# Author: Armando-Martin
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:01+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Mapa del sitio"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Configuración del mapa del sitio para este sitio de StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Clave Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Clave de verificación de Google Webmaster Tools."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Clave Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Clave de verificación de Yahoo! Site Explorer."

#. TRANS: Field label.
msgid "Bing key"
msgstr "Clave Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Clave de verificación de Bing Webmaster Tools."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Guardar"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Guardar la configuración del mapa del sitio."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Configuración del mapa del sitio"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Mapa del sitio"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Este complemento (plugin) permite la creación de mapas de sitios para Bing, "
"Yahoo! y Google."


code:
# Translation of StatusNet - Sitemap to Basque (euskara)
# Exported from translatewiki.net
#
# Author: Artsuaga
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:01+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Gunemapa"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Saio-ezarpenak StatusNet gune honetarako"

#. TRANS: Field label.
msgid "Google key"
msgstr "Google gakoa"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr ""

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoo gakoa"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr ""

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bing gakoa"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr ""

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Gorde"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Gorde gunemapa aukerak."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Gunemapa konfigurazioa"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Gunemapa"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""


code:
# Translation of StatusNet - Sitemap to French (français)
# Exported from translatewiki.net
#
# Author: Peter17
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:01+0000\n"
"Language-Team: French <https://translatewiki.net/wiki/Portal:fr>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: fr\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Plan du site"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Paramètres de plan du site pour ce site StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Clé Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Clé de vérification pour les outils Google Webmaster."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Clé Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Clé de vérification pour l’explorateur de site Yahoo!"

#. TRANS: Field label.
msgid "Bing key"
msgstr "Clé Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Clé de vérification pour les outils Bing Webmaster."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Sauvegarder"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Sauvegarder les paramètres de plan du site."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Configuration du plan du site"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Plan du site"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Cette extension permet de créer des plans du site pour Bing, Yahoo! et "
"Google."


code:
# Translation of StatusNet - Sitemap to Galician (galego)
# Exported from translatewiki.net
#
# Author: Toliño
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Galician <https://translatewiki.net/wiki/Portal:gl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: gl\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Mapa do sitio"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Configuración de mapa do sitio para este sitio StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Clave Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Clave de verificación para as ferramentas de Google Webmaster."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Clave Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Clave de verificación para o explorador de sitios de Yahoo!"

#. TRANS: Field label.
msgid "Bing key"
msgstr "Clave Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Clave de verificación para as ferramentas de Bing Webmaster."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Gardar"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Gardar a configuración do mapa do sitio."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Configuración do mapa do sitio"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Mapa do sitio"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Este complemento permite a creación de mapas do sitio para Bing, Yahoo! e "
"Google."


code:
# Translation of StatusNet - Sitemap to Interlingua (interlingua)
# Exported from translatewiki.net
#
# Author: McDutchie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Interlingua <https://translatewiki.net/wiki/Portal:ia>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ia\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Mappa del sito"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Configuration de mappa de sito pro iste sito StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Clave Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Clave de verification de Google Webmaster Tools."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Clave Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Clave de verification de Yahoo Site Explorer."

#. TRANS: Field label.
msgid "Bing key"
msgstr "Clave Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Clave de verification de Bing Webmaster Tools."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Salveguardar"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Salveguardar configuration de mappa de sito."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Configuration de mappa de sito"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Mappa del sito"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Iste plug-in permitte le creation de mappas de sito pro Bing, Yahoo! e "
"Google."


code:
# Translation of StatusNet - Sitemap to Japanese (日本語)
# Exported from translatewiki.net
#
# Author: Shirayuki
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=1; plural=0;\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "サイトマップ"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr ""

#. TRANS: Field label.
msgid "Google key"
msgstr "Google キー"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr ""

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoo キー"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr ""

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bing キー"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr ""

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "保存"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr ""

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr ""

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "サイトマップ"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""


code:
# Translation of StatusNet - Sitemap to Macedonian (македонски)
# Exported from translatewiki.net
#
# Author: Bjankuloski06
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Macedonian <https://translatewiki.net/wiki/Portal:mk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: mk\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n == 1 || n%10 == 1) ? 0 : 1;\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "План на мреж. место"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Нагодувања за планот на ова StatusNet-мрежно место"

#. TRANS: Field label.
msgid "Google key"
msgstr "Google-клуч"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Потврден клуч за Управните алатки на Google."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoo-клуч"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Потврден клуч за Yahoo! Site Explorer."

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bing-клуч"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Потврден клуч за Управните алатки на Bing."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Зачувај"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Зачувај нагодувања за план."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Поставки за план"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "План на мреж. место"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Овој приклучок овозможува создавање на планови на мреж. места на Bing, "
"Yahoo! и Google."


code:
# Translation of StatusNet - Sitemap to Dutch (Nederlands)
# Exported from translatewiki.net
#
# Author: Siebrand
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Dutch <https://translatewiki.net/wiki/Portal:nl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: nl\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Sitemap"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Sitemapinstellingen voor deze StatusNetwebsite"

#. TRANS: Field label.
msgid "Google key"
msgstr "Googlesleutel"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Verificatiesleutel voor Google Webmaster Tools."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Yahoosleutel"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Verificatiesleutel voor Yahoo! Site Explorer."

#. TRANS: Field label.
msgid "Bing key"
msgstr "Bingsleutel"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Verificatiesleutel voor Bing Webmaster Tools."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Opslaan"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Instellingen voor sitemap opslaan."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Instellingen voor sitemap"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Sitemap"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Deze plugin maakt het mogelijk sitemaps aan te maken voor Bing, Yahoo! en "
"Google."


code:
# Translation of StatusNet - Sitemap to Russian (русский)
# Exported from translatewiki.net
#
# Author: MaxSem
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Russian <https://translatewiki.net/wiki/Portal:ru>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ru\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Карта сайта"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Настройки карты этого сайта на движке StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Ключ Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Ключ для подтверждения в инструментах вебмастера Google."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Ключ Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Ключ для подтверждения в Yahoo! Site Explorer."

#. TRANS: Field label.
msgid "Bing key"
msgstr "Ключ Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Ключ для подтверждения в инструментах вебмастера Bing."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Сохранить"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Сохранить настройки карты сайта."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Настройки карты сайта"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Карта сайта"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr "Этот плагин позволяет создавать карты сайта для Bing, Yahoo! и Google."


code:
# Translation of StatusNet - Sitemap to Tagalog (Tagalog)
# Exported from translatewiki.net
#
# Author: AnakngAraw
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:02+0000\n"
"Language-Team: Tagalog <https://translatewiki.net/wiki/Portal:tl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: tl\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Mapa ng sityo"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Mga katakdaan ng mapa ng sityo para sa sityong ito ng StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Susi ng Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Susing pantiyak ng mga Kasangkapan ng Maestro ng Web ng Google."

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Susi ng Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Susing pantiyak ng Panggalugad ng Sityo ng Yahoo!"

#. TRANS: Field label.
msgid "Bing key"
msgstr "Susi ng Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Susing pantiyak ng mga Kasangkapan ng Maestro ng Web ng Bing."

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Sagipin"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Sagipin ang mga katakdaan ng mapa ng sityo."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Pagkakaayos ng mapa ng sityo"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Mapa ng sityo"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Nagpapahintulot ang pampasak na ito ng paglikha ng mga mapa ng sityo para sa "
"Bing, Yahoo! at Google."


code:
# Translation of StatusNet - Sitemap to Ukrainian (українська)
# Exported from translatewiki.net
#
# Author: Boogie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Sitemap\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: Ukrainian <https://translatewiki.net/wiki/Portal:uk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:35+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: uk\n"
"X-Message-Group: #out-statusnet-plugin-sitemap\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Title for sitemap.
msgid "Sitemap"
msgstr "Карта сайту"

#. TRANS: Instructions for sitemap.
msgid "Sitemap settings for this StatusNet site"
msgstr "Налаштування карти сайту на даному сайті StatusNet"

#. TRANS: Field label.
msgid "Google key"
msgstr "Ключ Google"

#. TRANS: Title for field label.
msgid "Google Webmaster Tools verification key."
msgstr "Ключ підтвердження Google Webmaster Tools"

#. TRANS: Field label.
msgid "Yahoo key"
msgstr "Ключ Yahoo"

#. TRANS: Title for field label.
msgid "Yahoo! Site Explorer verification key."
msgstr "Ключ підтвердження Yahoo! Site Explorer"

#. TRANS: Field label.
msgid "Bing key"
msgstr "Ключ Bing"

#. TRANS: Title for field label.
msgid "Bing Webmaster Tools verification key."
msgstr "Ключ підтвердження Bing Webmaster Tools"

#. TRANS: Submit button text to save sitemap settings.
msgctxt "BUTTON"
msgid "Save"
msgstr "Зберегти"

#. TRANS: Submit button title to save sitemap settings.
msgid "Save sitemap settings."
msgstr "Зберегти налаштування карти сайту."

#. TRANS: Menu item title/tooltip
msgid "Sitemap configuration"
msgstr "Конфігурація карти сайту"

#. TRANS: Menu item for site administration
msgctxt "MENU"
msgid "Sitemap"
msgstr "Карта сайту"

#. TRANS: Plugin description.
msgid "This plugin allows creation of sitemaps for Bing, Yahoo! and Google."
msgstr ""
"Цей додаток дозволяє створювати карти сайту для Bing, Yahoo! та Google."


code:
#!/usr/bin/env php
<?php
/*
 * StatusNet - a distributed open-source microblogging tool
 * Copyright (C) 2010, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));

$helptext = <<<END_OF_UPDATECOUNTS_HELP
updatecounts.php [options]
Update the notice and user counts cached in the database.

END_OF_UPDATECOUNTS_HELP;

require_once INSTALLDIR.'/scripts/commandline.inc';

// Will fill the cache

$userCounts = Sitemap_user_count::getAll();
$noticeCounts = Sitemap_notice_count::getAll();

echo "Done.\n";


code:
<?php
/*
 * StatusNet - the distributed open-source microblogging tool
 * Copyright (C) 2010, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

/**
 * @package SlicedFavoritesPlugin
 * @maintainer Brion Vibber <brion@status.net>
 */

if (!defined('STATUSNET')) { exit(1); }

class SlicedFavoritesPlugin extends Plugin
{
    /**
     * Example:
     *
     *   addPlugin('SlicedFavorites', array(
     *     'slices' => array(
     *       // show only pop's notices on /favorited
     *       'default' => array('include' => array('pop')),
     *
     *       // show only son's notices on /favorited/blog
     *       'blog' => array('include' => array('son')),
     *
     *       // show all favorited notices except pop's and son's on /favorited/submitted
     *       'submitted' => array('exclude' => array('pop', 'son')),
     *
     *       // show all favorited notices on /favorited/everybody
     *       'everybody' => array(),
     *     )
     *   ));
     *
     * @var array
     */
    public $slices = array();

    /**
     * Hook for RouterInitialized event.
     *
     * @param URLMapper $m path-to-action mapper
     * @return boolean hook return
     */
    public function onRouterInitialized(URLMapper $m)
    {
        $m->connect('favorited/:slice',
                    array('action' => 'favoritedslice'),
                    array('slice' => '[a-zA-Z0-9]+'));

        return true;
    }

    // Take over the default... :D
    function onArgsInitialize($args)
    {
        if (array_key_exists('action', $args)) {
            $action = trim($args['action']);
            if ($action == 'favorited') {
                common_redirect(common_local_url('favoritedslice', array('slice' => 'default')));
                exit(0);
            }
        }
        return true;
    }

    function onSlicedFavoritesGetSettings($slice, &$data)
    {
        if (isset($this->slices[$slice])) {
            $data = $this->slices[$slice];
            return false;
        }
        return true;
    }

    /**
     * Provide plugin version information.
     *
     * This data is used when showing the version page.
     *
     * @param array &$versions array of version data arrays; see EVENTS.txt
     *
     * @return boolean hook value
     */
    function onPluginVersion(&$versions)
    {
        $url = 'http://status.net/wiki/Plugin:SlicedFavorites';

        $versions[] = array('name' => 'SlicedFavorites',
            'version' => GNUSOCIAL_VERSION,
            'author' => 'Brion Vibber',
            'homepage' => $url,
            'rawdescription' =>
            // TRANS: Plugin description.
            _m('Shows timelines of popular notices for defined subsets of users.'));

        return true;
    }
}


code:
<?php
/**
 * StatusNet, the distributed open-source microblogging tool
 *
 * List of popular notices
 *
 * PHP version 5
 *
 * LICENCE: This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * @category  Public
 * @package   StatusNet
 * @author    Zach Copley <zach@status.net>
 * @author    Evan Prodromou <evan@status.net>
 * @copyright 2008-2009 StatusNet, Inc.
 * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
 * @link      http://status.net/
 */

if (!defined('STATUSNET') && !defined('LACONICA')) {
    exit(1);
}

class FavoritedSliceAction extends FavoritedAction
{
    private $includeUsers = array(), $excludeUsers = array();

    /**
     * Take arguments for running
     *
     * @param array $args $_REQUEST args
     *
     * @return boolean success flag
     *
     * @todo move queries from showContent() to here
     */
    function prepare($args)
    {
        parent::prepare($args);

        $this->slice = $this->arg('slice', 'default');
        $data = array();
        if (Event::handle('SlicedFavoritesGetSettings', array($this->slice, &$data))) {
            // TRANS: Client exception.
            throw new ClientException(_m('Unknown favorites slice.'));
        }
        if (isset($data['include'])) {
            $this->includeUsers = $data['include'];
        }
        if (isset($data['exclude'])) {
            $this->excludeUsers = $data['exclude'];
        }

        return true;
    }

    /**
     * Content area
     *
     * Shows the list of popular notices
     *
     * @return void
     */
    function showContent()
    {
        $slice = $this->sliceWhereClause();
        if (!$slice) {
            return parent::showContent();
        }

        $weightexpr = common_sql_weight('fave.modified', common_config('popular', 'dropoff'));
        $cutoff = sprintf("fave.modified > '%s'",
                          common_sql_date(time() - common_config('popular', 'cutoff')));

        $qry = 'SELECT notice.*, '.
          $weightexpr . ' as weight ' .
          'FROM notice JOIN fave ON notice.id = fave.notice_id ' .
          "WHERE $cutoff AND $slice " .
          'GROUP BY id,profile_id,uri,content,rendered,url,created,notice.modified,reply_to,is_local,source,notice.conversation ' .
          'ORDER BY weight DESC';

        $offset = ($this->page - 1) * NOTICES_PER_PAGE;
        $limit  = NOTICES_PER_PAGE + 1;

        if (common_config('db', 'type') == 'pgsql') {
            $qry .= ' LIMIT ' . $limit . ' OFFSET ' . $offset;
        } else {
            $qry .= ' LIMIT ' . $offset . ', ' . $limit;
        }

        $notice = Memcached_DataObject::cachedQuery('Notice',
                                                    $qry,
                                                    600);

        $nl = new NoticeList($notice, $this);

        $cnt = $nl->show();

        if ($cnt == 0) {
            $this->showEmptyList();
        }

        $this->pagination($this->page > 1, $cnt > NOTICES_PER_PAGE,
                          $this->page, 'favorited');
    }

    private function sliceWhereClause()
    {
        $include = $this->nicknamesToIds($this->includeUsers);
        $exclude = $this->nicknamesToIds($this->excludeUsers);

        if (count($include) == 1) {
            return "profile_id = " . intval($include[0]);
        } else if (count($include) > 1) {
            return "profile_id IN (" . implode(',', $include) . ")";
        } else if (count($exclude) == 1) {
            return "profile_id != " . intval($exclude[0]);
        } else if (count($exclude) > 1) {
            return "profile_id NOT IN (" . implode(',', $exclude) . ")";
        } else {
            return false;
        }
    }

    /**
     *
     * @param array $nicks array of user nicknames
     * @return array of profile/user IDs
     */
    private function nicknamesToIds($nicks)
    {
        $ids = array();
        foreach ($nicks as $nick) {
            // not the most efficient way for a big list!
            $user = User::getKV('nickname', $nick);
            if ($user) {
                $ids[] = intval($user->id);
            }
        }
        return $ids;
    }
}


code:
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\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"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"

#. TRANS: Plugin description.
#: SlicedFavoritesPlugin.php:129
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""

#. TRANS: Client exception.
#: favoritedsliceaction.php:56
msgid "Unknown favorites slice."
msgstr ""


code:
# Translation of StatusNet - SlicedFavorites to German (Deutsch)
# Exported from translatewiki.net
#
# Author: Fujnky
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: German <https://translatewiki.net/wiki/Portal:de>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: de\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Zeigt Zeitleisten beliebter Nachrichten für eine definierte Teilmenge von "
"Benutzern."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Unbekannter Favoriten-Slice."


code:
# Translation of StatusNet - SlicedFavorites to Spanish (español)
# Exported from translatewiki.net
#
# Author: Armando-Martin
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Muestra listas de notas populares para subconjuntos definidos de usuarios."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Sección de favoritos desconocida"


code:
# Translation of StatusNet - SlicedFavorites to Basque (euskara)
# Exported from translatewiki.net
#
# Author: Artsuaga
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Gogokoen atal ezezaguna."


code:
# Translation of StatusNet - SlicedFavorites to French (français)
# Exported from translatewiki.net
#
# Author: Peter17
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: French <https://translatewiki.net/wiki/Portal:fr>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: fr\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Affiche des listes d’avis populaires pour des sous-ensembles définis "
"d’utilisateurs."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Tranche préférée inconnue."


code:
# Translation of StatusNet - SlicedFavorites to Galician (galego)
# Exported from translatewiki.net
#
# Author: Toliño
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: Galician <https://translatewiki.net/wiki/Portal:gl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: gl\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Mostra listas de notas populares para os subconxuntos definidos de usuarios."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Anaco de favoritos descoñecido."


code:
# Translation of StatusNet - SlicedFavorites to Hebrew (עברית)
# Exported from translatewiki.net
#
# Author: Amire80
# Author: YaronSh
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: Hebrew <https://translatewiki.net/wiki/Portal:he>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: he\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr "הצגת צירי זמן של עדכונים פופולריים לתת־קבוצות מסוימות של משתמשים."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "נתח מועדפים בלתי ידוע."


code:
# Translation of StatusNet - SlicedFavorites to Interlingua (interlingua)
# Exported from translatewiki.net
#
# Author: McDutchie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: Interlingua <https://translatewiki.net/wiki/Portal:ia>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ia\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr "Monstra chronologias de notas popular pro certe gruppos de usatores."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Section de favorites incognite."


code:
# Translation of StatusNet - SlicedFavorites to Indonesian (Bahasa Indonesia)
# Exported from translatewiki.net
#
# Author: Farras
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:03+0000\n"
"Language-Team: Indonesian <https://translatewiki.net/wiki/Portal:id>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: id\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=1; plural=0;\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Menampilkan garis waktu pemberitahuan populer untuk sekumpulan pengguna yang "
"ditentukan."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Pembagian favorit tidak diketahui."


code:
# Translation of StatusNet - SlicedFavorites to Macedonian (македонски)
# Exported from translatewiki.net
#
# Author: Bjankuloski06
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: Macedonian <https://translatewiki.net/wiki/Portal:mk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: mk\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n == 1 || n%10 == 1) ? 0 : 1;\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Прикажува хронологии на популарни забелешки за определени подмножества "
"корисници."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Непознато парче од бендисаните."


code:
# Translation of StatusNet - SlicedFavorites to Dutch (Nederlands)
# Exported from translatewiki.net
#
# Author: Siebrand
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: Dutch <https://translatewiki.net/wiki/Portal:nl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: nl\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Geeft de tijdlijnen van populaire mededelingen weer voor ingestelde groepen "
"gebruikers."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Onbekende favorietengebruikersgroep."


code:
# Translation of StatusNet - SlicedFavorites to Russian (русский)
# Exported from translatewiki.net
#
# Author: Александр Сигачёв
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: Russian <https://translatewiki.net/wiki/Portal:ru>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ru\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Показывает хронологию популярных уведомлений для определенных подмножеств "
"пользователей."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Неизвестный срез избранного."


code:
# Translation of StatusNet - SlicedFavorites to Tagalog (Tagalog)
# Exported from translatewiki.net
#
# Author: AnakngAraw
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: Tagalog <https://translatewiki.net/wiki/Portal:tl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: tl\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr ""
"Nagpapakita ng mga guhit ng panahon ng tanyag na mga pabatid para sa "
"inilarawang mga kabahaging pangkat ng mga tagagamit."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Hindi nalalamang hiwa ng mga paborito."


code:
# Translation of StatusNet - SlicedFavorites to Ukrainian (українська)
# Exported from translatewiki.net
#
# Author: Boogie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SlicedFavorites\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: Ukrainian <https://translatewiki.net/wiki/Portal:uk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:36+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: uk\n"
"X-Message-Group: #out-statusnet-plugin-slicedfavorites\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Plugin description.
msgid "Shows timelines of popular notices for defined subsets of users."
msgstr "Показує стрічки популярних дописів для певних підмножин користувачів."

#. TRANS: Client exception.
msgid "Unknown favorites slice."
msgstr "Невідома вибірка обраних повідомлень."


code:
You can get a significant boost in performance using Sphinx Search
instead of your database server to search for users and notices.
<http://sphinxsearch.com/>.

Configuration
-------------

In StatusNet's configuration, you can adjust the following settings
under 'sphinx':

enabled: Set to true to enable. Default false.
server: a string with the hostname of the sphinx server.
port: an integer with the port number of the sphinx server.

Requirements
------------

To use a Sphinx server to search users and notices, you also need
to install, compile and enable the sphinx pecl extension for php on the
client side, which itself depends on the sphinx development files.
"pecl install sphinx" should take care of that. Add "extension=sphinx.so"
to your php.ini and reload apache to enable it.

You can update your MySQL or Postgresql databases to drop their fulltext
search indexes, since they're now provided by sphinx.

You will also need a Sphinx server to serve the search queries.

On the sphinx server side, a script reads the main database and build
the keyword index. A cron job reads the database and keeps the sphinx
indexes up to date. scripts/sphinx-cron.sh should be called by cron
every 5 minutes, for example. scripts/sphinx.sh is an init.d script
to start and stop the sphinx search daemon.

Server configuration
--------------------
scripts/gen_config.php can generate a sphinx.conf file listing MySQL
data sources for your databases. You may need to tweak paths afterwards.

  $ plugins/SphinxSearch/scripts/gen_config.php > sphinx.conf

If you wish, you can build a full config yourself based on sphinx.conf.sample

path: plugins/SphinxSearch/README


code:
<?php
/**
 * StatusNet, the distributed open-source microblogging tool
 *
 * PHP version 5
 *
 * LICENCE: This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * @category  Plugin
 * @package   StatusNet
 * @author    Brion Vibber <brion@status.net>
 * @copyright 2009 Control Yourself, Inc.
 * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
 * @link      http://laconi.ca/
 */

if (!defined('STATUSNET')) {
    exit(1);
}

// Set defaults if not already set in the config array...
global $config;
$sphinxDefaults =
    array('enabled' => true,
          'server' => 'localhost',
          'port' => 3312);
foreach($sphinxDefaults as $key => $val) {
    if (!isset($config['sphinx'][$key])) {
        $config['sphinx'][$key] = $val;
    }
}

/**
 * Plugin for Sphinx search backend.
 *
 * @category Plugin
 * @package  StatusNet
 * @author   Brion Vibber <brion@status.net>
 * @license  http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
 * @link     http://laconi.ca/
 * @link     http://twitter.com/
 */
class SphinxSearchPlugin extends Plugin
{
    /**
     * Automatically load any classes used
     *
     * @param string $cls the class
     * @return boolean hook return
     */
    function onAutoload($cls)
    {
        switch ($cls) {
        case 'SphinxSearch':
            include_once INSTALLDIR . '/plugins/SphinxSearch/' .
              strtolower($cls) . '.php';
            return false;
        }

        return parent::onAutoload($cls);
    }

    /**
     * Create sphinx search engine object for the given table type.
     *
     * @param Memcached_DataObject $target
     * @param string $table
     * @param out &$search_engine SearchEngine object on output if successful
     * @ return boolean hook return
     */
    function onGetSearchEngine(Memcached_DataObject $target, $table, &$search_engine)
    {
        if (common_config('sphinx', 'enabled')) {
            if (!class_exists('SphinxClient')) {
                // TRANS: Server exception.
                throw new ServerException(_m('Sphinx PHP extension must be installed.'));
            }
            $engine = new SphinxSearch($target, $table);
            if ($engine->is_connected()) {
                $search_engine = $engine;
                return false;
            }
        }
        // Sphinx disabled or disconnected
        return true;
    }

    /**
     * Provide plugin version information.
     *
     * This data is used when showing the version page.
     *
     * @param array &$versions array of version data arrays; see EVENTS.txt
     *
     * @return boolean hook value
     */
    function onPluginVersion(&$versions)
    {
        $url = 'http://status.net/wiki/Plugin:SphinxSearch';

        $versions[] = array('name' => 'SphinxSearch',
            'version' => GNUSOCIAL_VERSION,
            'author' => 'Brion Vibber',
            'homepage' => $url,
            'rawdescription' =>
            // TRANS: Plugin description.
            _m('Plugin for Sphinx search backend.'));

        return true;
    }
}


code:
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\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"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
#: sphinxsearch.php:129
msgid "Sphinx search could not identify database name."
msgstr ""

#. TRANS: Server exception.
#: SphinxSearchPlugin.php:87
msgid "Sphinx PHP extension must be installed."
msgstr ""

#. TRANS: Plugin description.
#: SphinxSearchPlugin.php:118
msgid "Plugin for Sphinx search backend."
msgstr ""


code:
# Translation of StatusNet - SphinxSearch to Breton (Brezhoneg)
# Expored from translatewiki.net
#
# Author: Fulup
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2010-12-16 15:08+0000\n"
"PO-Revision-Date: 2010-12-16 15:12:57+0000\n"
"Language-Team: Breton <http://translatewiki.net/wiki/Portal:br>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2010-11-30 20:43:54+0000\n"
"X-Generator: MediaWiki 1.18alpha (r78478); Translate extension (2010-09-17)\n"
"X-Translation-Project: translatewiki.net at http://translatewiki.net\n"
"X-Language-Code: br\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. TRANS: Server exception.
#: SphinxSearchPlugin.php:87
msgid "Sphinx PHP extension must be installed."
msgstr "Rekis eo d'an astenn Sphinx PHP bezañ staliet."

#. TRANS: Plugin description.
#: SphinxSearchPlugin.php:118
msgid "Plugin for Sphinx search backend."
msgstr ""

#. TRANS: Server exception thrown when a database name cannot be identified.
#: sphinxsearch.php:96
msgid "Sphinx search could not identify database name."
msgstr ""


code:
# Translation of StatusNet - SphinxSearch to German (Deutsch)
# Exported from translatewiki.net
#
# Author: Fujnky
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: German <https://translatewiki.net/wiki/Portal:de>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: de\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "Sphinx-Suche konnte den Datenbanknamen nicht identifizieren."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Sphinx-PHP-Erweiterung muss installiert sein."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Plugin für das Sphinx-Suchbackend."


code:
# Translation of StatusNet - SphinxSearch to Spanish (español)
# Exported from translatewiki.net
#
# Author: Armando-Martin
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "La búsqueda Sphinx nn pudo identificar el nombre de la base de datos."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "La extensión PHP Sphinx debe ser instalada."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Complemento (plugin) para el motor de búsquedas Sphinx."


code:
# Translation of StatusNet - SphinxSearch to French (français)
# Exported from translatewiki.net
#
# Author: Peter17
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:04+0000\n"
"Language-Team: French <https://translatewiki.net/wiki/Portal:fr>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: fr\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr ""
"La recherche Sphinx n’a pas pu identifier le nom de la base de données."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "L’extension PHP Sphinx doit être installée."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Extension pour le moteur de recherche Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Galician (galego)
# Exported from translatewiki.net
#
# Author: Toliño
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Galician <https://translatewiki.net/wiki/Portal:gl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: gl\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "A procura Sphinx non puido identificar o nome da base de datos."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Cómpre que a extensión PHP Sphinx estea instalada."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Complemento para o motor de procuras Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Interlingua (interlingua)
# Exported from translatewiki.net
#
# Author: McDutchie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Interlingua <https://translatewiki.net/wiki/Portal:ia>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ia\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "Le recerca Sphinx non poteva identificar le nomine del base de datos."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Le extension PHP Sphinx debe esser installate."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Plug-in pro back-end de recerca Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Macedonian (македонски)
# Exported from translatewiki.net
#
# Author: Bjankuloski06
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Macedonian <https://translatewiki.net/wiki/Portal:mk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: mk\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n == 1 || n%10 == 1) ? 0 : 1;\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "Пребарувањето со Sphinx не можеше да го утврди името на базата."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Мора да се инсталира PHP-додатокот Sphinx"

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Приклучок за пребарување со Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Dutch (Nederlands)
# Exported from translatewiki.net
#
# Author: Siebrand
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Dutch <https://translatewiki.net/wiki/Portal:nl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: nl\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr ""
"Het was voor Sphinx search niet mogelijk een database te identificeren."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "De PHP-extensie Sphinx moet geïnstalleerd. zijn."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Plug-in voor een Sphinxbackend."


code:
# Translation of StatusNet - SphinxSearch to Russian (русский)
# Exported from translatewiki.net
#
# Author: MaxSem
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Russian <https://translatewiki.net/wiki/Portal:ru>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ru\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "Поиск Sphinx не смог определить название базы данных."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Необходимо установить расширение Sphinx для PHP."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Плагин для поискового движка Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Tagalog (Tagalog)
# Exported from translatewiki.net
#
# Author: AnakngAraw
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Tagalog <https://translatewiki.net/wiki/Portal:tl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: tl\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr ""
"Hindi makilala ng panghanap ng Sphinx ang pangalan ng kalipunan ng dato."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Dapat na iluklok ang dugtong na PHP ng Sphinx."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Pamasak para sa wakas ng likuran ng panghanap ng Sphinx."


code:
# Translation of StatusNet - SphinxSearch to Ukrainian (українська)
# Exported from translatewiki.net
#
# Author: Boogie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - SphinxSearch\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:05+0000\n"
"Language-Team: Ukrainian <https://translatewiki.net/wiki/Portal:uk>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-05 21:51:37+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: uk\n"
"X-Message-Group: #out-statusnet-plugin-sphinxsearch\n"
"Plural-Forms: nplurals=3; plural=(n%10 == 1 && n%100 != 11) ? 0 : ( (n%10 >= "
"2 && n%10 <= 4 && (n%100 < 10 || n%100 >= 20)) ? 1 : 2 );\n"

#. TRANS: Server exception thrown when a database name cannot be identified.
msgid "Sphinx search could not identify database name."
msgstr "Пошук Sphinx не може визначити ім’я бази даних."

#. TRANS: Server exception.
msgid "Sphinx PHP extension must be installed."
msgstr "Розширення Sphinx PHP повинно бути встановлено."

#. TRANS: Plugin description.
msgid "Plugin for Sphinx search backend."
msgstr "Додаток для пошуку за допомогою Sphinx."


code:
#!/usr/bin/env php
<?php
/*
 * StatusNet - the distributed open-source microblogging tool
 * Copyright (C) 2009, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.     See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.     If not, see <http://www.gnu.org/licenses/>.
 */

define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));

$longoptions = array('base=', 'network');

$helptext = <<<END_OF_TRIM_HELP
Generates sphinx.conf file based on StatusNet configuration.
    --base               Base dir to Sphinx install
                         (default /usr/local)
    --network            Use status_network global config table
                         (non-functional at present)

END_OF_TRIM_HELP;

require_once INSTALLDIR . '/scripts/commandline.inc';
require dirname(__FILE__) . '/sphinx-utils.php';

$timestamp = date('r');
print <<<END
#
# Sphinx configuration for StatusNet
# Generated {$timestamp}
#

END;

sphinx_iterate_sites('sphinx_site_template');

print <<<END

indexer
{
    mem_limit               = 300M
}

searchd
{
    port                    = 3312
    log                     = {$base}/log/searchd.log
    query_log               = {$base}/log/query.log
    read_timeout            = 5
    max_children            = 30
    pid_file                = {$base}/log/searchd.pid
    max_matches             = 1000
    seamless_rotate         = 1
    preopen_indexes         = 0
    unlink_old              = 1
}

END;

/**
 * Build config entries for a single site
 * @fixme we only seem to have master DB currently available...
 */
function sphinx_site_template($sn)
{
    return
        sphinx_template($sn,
            'profile',
            'SELECT id, UNIX_TIMESTAMP(created) as created_ts, nickname, fullname, location, bio, homepage FROM profile',
            'SELECT * FROM profile where id = $id') .
        sphinx_template($sn,
            'notice',
            'SELECT id, UNIX_TIMESTAMP(created) as created_ts, content FROM notice',
            'SELECT * FROM notice where notice.id = $id AND notice.is_local != -2');
}

function sphinx_template($sn, $table, $query, $query_info)
{
    $base = sphinx_base();
    $dbtype = common_config('db', 'type');

    print <<<END

#
# {$sn->sitename}
#
source {$sn->dbname}_src_{$table}
{
    type                    = {$dbtype}
    sql_host                = {$sn->dbhost}
    sql_user                = {$sn->dbuser}
    sql_pass                = {$sn->dbpass}
    sql_db                  = {$sn->dbname}
    sql_query_pre           = SET NAMES utf8;
    sql_query               = {$query}
    sql_query_info          = {$query_info}
    sql_attr_timestamp      = created_ts
}

index {$sn->dbname}_{$table}
{
    source                  = {$sn->dbname}_src_{$table}
    path                    = {$base}/data/{$sn->dbname}_{$table}
    docinfo                 = extern
    charset_type            = utf-8
    min_word_len            = 3
}

END;
}


code:
#!/usr/bin/env php
<?php
/*
 * StatusNet - the distributed open-source microblogging tool
 * Copyright (C) 2009, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.     See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.     If not, see <http://www.gnu.org/licenses/>.
 */

define('INSTALLDIR', realpath(dirname(__FILE__) . '/../../..'));

$longoptions = array('base=', 'network');

$helptext = <<<END_OF_TRIM_HELP
Runs Sphinx search indexer.
    --rotate             Have Sphinx run index update in background and
                         rotate updated indexes into place as they finish.
    --base               Base dir to Sphinx install
                         (default /usr/local)
    --network            Use status_network global config table for site list
                         (non-functional at present)

END_OF_TRIM_HELP;

require_once INSTALLDIR . '/scripts/commandline.inc';
require dirname(__FILE__) . '/sphinx-utils.php';

sphinx_iterate_sites('sphinx_index_update');

function sphinx_index_update($sn)
{
    $base = sphinx_base();

    $baseIndexes = array('notice', 'profile');
    $params = array();

    if (have_option('rotate')) {
        $params[] = '--rotate';
    }
    foreach ($baseIndexes as $index) {
        $params[] = "{$sn->dbname}_{$index}";
    }

    $params = implode(' ', $params);
    $cmd = "$base/bin/indexer --config $base/etc/sphinx.conf $params";

    print "$cmd\n";
    system($cmd);
}


code:
<?php
/*
 * StatusNet - the distributed open-source microblogging tool
 * Copyright (C) 2009, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.     See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.     If not, see <http://www.gnu.org/licenses/>.
 */

function sphinx_use_network()
{
    return have_option('network');
}

function sphinx_base()
{
    if (have_option('base')) {
        return get_option_value('base');
    } else {
        return "/usr/local/sphinx";
    }
}

function sphinx_iterate_sites($callback)
{
    if (sphinx_use_network()) {
        // @fixme this should use, like, some kind of config
        Status_network::setupDB('localhost', 'statusnet', 'statuspass', 'statusnet');
        $sn = new Status_network();
        if (!$sn->find()) {
            die("Confused... no sites in status_network table or lookup failed.\n");
        }
        while ($sn->fetch()) {
            $callback($sn);
        }
    } else {
        if (preg_match('!^(mysqli?|pgsql)://(.*?):(.*?)@(.*?)/(.*?)$!',
                common_config('db', 'database'), $matches)) {
            list(/*all*/, $dbtype, $dbuser, $dbpass, $dbhost, $dbname) = $matches;
            $sn = (object)array(
                'sitename' => common_config('site', 'name'),
                'dbhost' => $dbhost,
                'dbuser' => $dbuser,
                'dbpass' => $dbpass,
                'dbname' => $dbname);
            $callback($sn);
        } else {
            print "Unrecognized database configuration string in config.php\n";
            exit(1);
        }
    }
}


code:
#!/bin/bash

if [[ $1 = "start" ]]
then
	echo "Stopping any running daemons..."
	/usr/local/bin/searchd --config /usr/local/etc/sphinx.conf --stop 2> /dev/null
	echo "Starting sphinx search daemon..."
	/usr/local/bin/searchd --config /usr/local/etc/sphinx.conf 2> /dev/null
fi

if [[ $1 = "stop" ]]
then
	echo "Stopping sphinx search daemon..."
	/usr/local/bin/searchd --config /usr/local/etc/sphinx.conf --stop 2> /dev/null
fi


code:
#
# Minimal Sphinx configuration sample for statusnet
#

source src1
{
    type                    = mysql
    sql_host                = localhost
    sql_user                = USERNAME
    sql_pass                = PASSWORD
    sql_db                  = identi_ca
    sql_port                = 3306
    sql_query               = SELECT id, UNIX_TIMESTAMP(created) as created_ts, nickname, fullname, location, bio, homepage FROM profile
    sql_query_info          = SELECT * FROM profile where id = $id
    sql_attr_timestamp      = created_ts
}

source src2
{
    type                    = mysql
    sql_host                = localhost
    sql_user                = USERNAME
    sql_pass                = PASSWORD
    sql_db                  = identi_ca
    sql_port                = 3306
    sql_query               = SELECT id, UNIX_TIMESTAMP(created) as created_ts, content FROM notice
    sql_query_info          = SELECT * FROM notice where notice.id = $id AND notice.is_local != -2
    sql_attr_timestamp      = created_ts
}

index identica_notices
{
    source                  = src2
    path                    = DIRECTORY/data/identica_notices
    docinfo                 = extern
    charset_type            = utf-8
    min_word_len            = 3
    stopwords               = DIRECTORY/data/stopwords-en.txt
}

index identica_people
{
    source                  = src1
    path                    = DIRECTORY/data/identica_people
    docinfo                 = extern
    charset_type            = utf-8
    min_word_len            = 3
    stopwords               = DIRECTORY/data/stopwords-en.txt
}

indexer
{
    mem_limit               = 32M
}

searchd
{
    port                    = 3312
    log                     = DIRECTORY/log/searchd.log
    query_log               = DIRECTORY/log/query.log
    read_timeout            = 5
    max_children            = 30
    pid_file                = DIRECTORY/log/searchd.pid
    max_matches             = 1000
    seamless_rotate         = 1
    preopen_indexes         = 0
    unlink_old              = 1
}


code:
<?php
/*
 * StatusNet - the distributed open-source microblogging tool
 * Copyright (C) 2008, 2009, StatusNet, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

if (!defined('STATUSNET')) {
    exit(1);
}

class SphinxSearch extends SearchEngine
{
    private $sphinx;
    private $connected;

    function __construct($target, $table)
    {
        $fp = @fsockopen(common_config('sphinx', 'server'), common_config('sphinx', 'port'));
        if (!$fp) {
            $this->connected = false;
            return;
        }
        fclose($fp);
        parent::__construct($target, $table);
        $this->sphinx = new SphinxClient;
        $this->sphinx->setServer(common_config('sphinx', 'server'), common_config('sphinx', 'port'));
        $this->connected = true;
    }

    function is_connected()
    {
        return $this->connected;
    }

    function limit($offset, $count, $rss = false)
    {
        //FIXME without LARGEST_POSSIBLE, the most recent results aren't returned
        //      this probably has a large impact on performance
        $LARGEST_POSSIBLE = 1e6;

        if ($rss) {
            $this->sphinx->setLimits($offset, $count, $count, $LARGEST_POSSIBLE);
        }
        else {
            // return at most 50 pages of results
            $this->sphinx->setLimits($offset, $count, 50 * ($count - 1), $LARGEST_POSSIBLE);
        }

        return $this->target->limit(0, $count);
    }

    function query($q)
    {
        $result = $this->sphinx->query($q, $this->remote_table());
        if ($result === false) {
            throw new ServerException($this->sphinx->getLastError());
        }
        if (!isset($result['matches'])) return false;
        $id_set = join(', ', array_keys($result['matches']));
        $this->target->whereAdd("id in ($id_set)");
        return true;
     }

    function set_sort_mode($mode)
    {
        switch ($mode) {
        case 'chron':
            $this->sphinx->SetSortMode(SPH_SORT_ATTR_DESC, 'created_ts');
            return $this->target->orderBy('id desc');
            break;
        case 'reverse_chron':
            $this->sphinx->SetSortMode(SPH_SORT_ATTR_ASC, 'created_ts');
            return $this->target->orderBy('id asc');
            break;
        case 'nickname_desc':
            if ($this->table != 'profile') {
                throw new Exception(
                    'nickname_desc sort mode can only be use when searching profile.'
                );
            } else {
                $this->sphinx->SetSortMode(SPH_SORT_ATTR_DESC, 'nickname');
                return $this->target->orderBy('id desc');
            }
            break;
        case 'nickname_asc':
            if ($this->table != 'profile') {
                throw new Exception(
                    'nickname_desc sort mode can only be use when searching profile.'
                );
            } else {
                $this->sphinx->SetSortMode(SPH_SORT_ATTR_ASC, 'nickname');
                return $this->target->orderBy('id asc');
            }
            break;
        default:
            $this->sphinx->SetSortMode(SPH_SORT_ATTR_DESC, 'created_ts');
            return $this->target->orderBy('id desc');
            break;
        }
    }

    function remote_table()
    {
        return $this->dbname() . '_' . $this->table;
    }

    function dbname()
    {
        // @fixme there should be a less dreadful way to do this.
        // DB objects won't give database back until they connect, it's confusing
        if (preg_match('!^.*?://.*?:.*?@.*?/(.*?)$!', common_config('db', 'database'), $matches)) {
            return $matches[1];
        }

        // TRANS: Server exception thrown when a database name cannot be identified.
        throw new ServerException(_m("Sphinx search could not identify database name."));
    }
}


code:
<?php
/**
 * StatusNet, the distributed open-source microblogging tool
 *
 * Plugin to create pretty Spotify URLs
 *
 * PHP version 5
 *
 * LICENCE: This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * @category  Plugin
 * @package   StatusNet
 * @author    Nick Holliday <n.g.holliday@gmail.com>
 * @copyright Nick Holliday
 * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
 * @link      http://status.net/
 *
 * @see      Event
 */
if (!defined('STATUSNET')) {
    exit(1);
}
define('SPOTIFYPLUGIN_VERSION', '0.1');

/**
 * Plugin to create pretty Spotify URLs
 *
 * The Spotify API is called before the notice is saved to gather artist and track information.
 *
 * @category  Plugin
 * @package   StatusNet
 * @author    Nick Holliday <n.g.holliday@gmail.com>
 * @copyright Nick Holliday
 * @license   http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
 * @link      http://status.net/
 *
 * @see       Event
 */
class SpotifyPlugin extends Plugin
{
    function __construct()
    {
        parent::__construct();
    }

    function onStartNoticeSave($notice)
    {
        $notice->rendered = preg_replace_callback('/spotify:[a-z]{5,6}:[a-z0-9]{22}/i',
                                                  "renderSpotifyURILink",
                                                  $notice->rendered);

        $notice->rendered = preg_replace_callback('/http:\/\/open.spotify.com\/[a-z]{5,6}\/[a-z0-9]{22}<\/a>/i',
                                                  "renderSpotifyHTTPLink",
                                                  $notice->rendered);

        return true;
    }

    function onPluginVersion(&$versions)
    {
        $versions[] = array('name' => 'Spotify',
                            'version' => SPOTIFYPLUGIN_VERSION,
                            'author' => 'Nick Holliday',
                            'homepage' => 'http://status.net/wiki/Plugin:Spotify',
                            'rawdescription' =>
                            // TRANS: Plugin description.
                            _m('Create pretty Spotify URLs.'));

        return true;
    }
}

// @todo FIXME: This probably should not be global functions.
function doSpotifyLookup($uri, $isArtist)
{
    $request = HTTPClient::start();
    $response = $request->get('http://ws.spotify.com/lookup/1/?uri=' . $uri);
    if ($response->isOk()) {
        $xml = simplexml_load_string($response->getBody());

        if($isArtist)
            return $xml->name;
        else
            return $xml->artist->name . ' - ' . $xml->name;
    }
}

function renderSpotifyURILink($match)
{
    $isArtist = false;
    if(preg_match('/artist/', $match[0]) > 0) $isArtist = true;

    $name = doSpotifyLookup($match[0], $isArtist);
    return "" . $name . "";
}

function renderSpotifyHTTPLink($match)
{
    $match[0] = preg_replace('/http:\/\/open.spotify.com\//i', 'spotify:', $match[0]);
    $match[0] = preg_replace('/<\/a>/', '', $match[0]);
    $match[0] = preg_replace('/\//', ':', $match[0]);

    $isArtist = false;
    if(preg_match('/artist/', $match[0]) > 0) $isArtist = true;

    $name = doSpotifyLookup($match[0], $isArtist);
    return "" . $name . "";
}


code:
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\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"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"

#. TRANS: Plugin description.
#: SpotifyPlugin.php:84
msgid "Create pretty Spotify URLs."
msgstr ""


code:
# Translation of StatusNet - Spotify to German (Deutsch)
# Exported from translatewiki.net
#
# Author: ChrisiPK
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Language-Team: German <https://translatewiki.net/wiki/Portal:de>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: de\n"
"X-Message-Group: #out-statusnet-plugin-spotify\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr "Schöne Spotify-URLs erstellen."


code:
# Translation of StatusNet - Spotify to Spanish (español)
# Exported from translatewiki.net
#
# Author: Armando-Martin
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr ""
"Crear direcciones URL para Spotify."


code:
# Translation of StatusNet - Spotify to French (français)
# Exported from translatewiki.net
#
# Author: Gomoko
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"Plural-Forms: nplurals=2; plural=(n > 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr "Créer de jolies URLs Spotify."


code:
# Translation of StatusNet - Spotify to Galician (galego)
# Exported from translatewiki.net
#
# Author: Toliño
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Language-Team: Galician <https://translatewiki.net/wiki/Portal:gl>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: gl\n"
"X-Message-Group: #out-statusnet-plugin-spotify\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr ""
"Crear enderezos URL para Spotify."


code:
# Translation of StatusNet - Spotify to Hebrew (עברית)
# Exported from translatewiki.net
#
# Author: Amire80
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Language-Team: Hebrew <https://translatewiki.net/wiki/Portal:he>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: he\n"
"X-Message-Group: #out-statusnet-plugin-spotify\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr "יצירת כתובות יפות ל־Spotify."


code:
# Translation of StatusNet - Spotify to Interlingua (interlingua)
# Exported from translatewiki.net
#
# Author: McDutchie
# --
# This file is distributed under the same license as the StatusNet package.
#
msgid ""
msgstr ""
"Project-Id-Version: StatusNet - Spotify\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-06-30 11:07+0000\n"
"PO-Revision-Date: 2012-06-30 11:10:06+0000\n"
"Language-Team: Interlingua <https://translatewiki.net/wiki/Portal:ia>\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-POT-Import-Date: 2011-06-19 11:23:27+0000\n"
"X-Generator: MediaWiki 1.20alpha (233fc08); Translate 2012-06-21\n"
"X-Translation-Project: translatewiki.net <https://translatewiki.net>\n"
"X-Language-Code: ia\n"
"X-Message-Group: #out-statusnet-plugin-spotify\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. TRANS: Plugin description.
msgid "Create pretty Spotify URLs."
msgstr "Crear belle URLs de Spotify."