Nasty has uploaded a new change for review. ( 
https://gerrit.wikimedia.org/r/378711 )

Change subject: Initial commit
......................................................................

Initial commit

Change-Id: Ifad9bdd7361f5bf3c61eac1503891b890933d343
---
A .gitreview
A Authors.class.php
A composer.json
A doc/Hooks.txt
A extension.json
A i18n/ast.json
A i18n/ba.json
A i18n/bcc.json
A i18n/bn.json
A i18n/br.json
A i18n/ca.json
A i18n/ce.json
A i18n/de.json
A i18n/diq.json
A i18n/el.json
A i18n/en.json
A i18n/es.json
A i18n/et.json
A i18n/eu.json
A i18n/fa.json
A i18n/fr.json
A i18n/gl.json
A i18n/gu.json
A i18n/he.json
A i18n/hi.json
A i18n/hu.json
A i18n/ia.json
A i18n/id.json
A i18n/it.json
A i18n/ja.json
A i18n/kn.json
A i18n/ko.json
A i18n/ksh.json
A i18n/lb.json
A i18n/lt.json
A i18n/lv.json
A i18n/mk.json
A i18n/mr.json
A i18n/nb.json
A i18n/nl.json
A i18n/oc.json
A i18n/pl.json
A i18n/ps.json
A i18n/pt-br.json
A i18n/pt.json
A i18n/qqq.json
A i18n/roa-tara.json
A i18n/ru.json
A i18n/sl.json
A i18n/sv.json
A i18n/tr.json
A i18n/uk.json
A i18n/vi.json
A i18n/zh-hans.json
A i18n/zh-hant.json
A languages/Authors.i18n.magic.php
A resources/bluespice.authors.css
A resources/images/bs-author-orig-bg.png
A resources/images/more-users_v2.png
A views/view.Authors.php
A views/view.AuthorsUserPageProfileImageSetting.php
61 files changed, 1,445 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceAuthors 
refs/changes/11/378711/1

diff --git a/.gitreview b/.gitreview
new file mode 100644
index 0000000..bee6799
--- /dev/null
+++ b/.gitreview
@@ -0,0 +1,6 @@
+[gerrit]
+host=gerrit.wikimedia.org
+port=29418
+project=mediawiki/extensions/BlueSpiceAuthors.git
+track=1
+defaultrebase=0
diff --git a/Authors.class.php b/Authors.class.php
new file mode 100644
index 0000000..22bc111
--- /dev/null
+++ b/Authors.class.php
@@ -0,0 +1,337 @@
+<?php
+/**
+ * Authors extension for BlueSpice
+ *
+ * Displays authors of an article with image.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 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 General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ *
+ * This file is part of BlueSpice MediaWiki
+ * For further information visit http://www.bluespice.com
+ *
+ * @author     Markus Glaser <gla...@hallowelt.com>
+ * @author     Robert Vogel <vo...@hallowelt.com>
+ * @version    2.23.1
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ * @copyright  Copyright (C) 2016 Hallo Welt! GmbH, All rights reserved.
+ * @license    http://www.gnu.org/copyleft/gpl.html GNU Public License v2 or 
later
+ * @filesource
+ */
+
+//Last review MRG (30.06.11 10:25)
+
+/**
+ * Base class for Authors extension
+ * @package BlueSpice_Extensions
+ * @subpackage Authors
+ */
+class Authors extends BsExtensionMW {
+
+       /**
+        * Initialization of Authors extension
+        */
+       protected function initExt() {
+               wfProfileIn( 'BS::'.__METHOD__ );
+               // Hooks
+               $this->setHook( 'SkinTemplateOutputPageBeforeExec' );
+               $this->setHook( 'BeforePageDisplay' );
+               $this->setHook( 'BSInsertMagicAjaxGetData' );
+               $this->setHook( 'BS:UserPageSettings', 'onUserPageSettings' );
+               $this->setHook( 'PageContentSave' );
+
+               BsConfig::registerVar( 'MW::Authors::Blacklist',   array( 
'MediaWiki default' ), BsConfig::LEVEL_PRIVATE|BsConfig::TYPE_ARRAY_STRING );
+               BsConfig::registerVar( 'MW::Authors::Limit',       10,          
                 BsConfig::LEVEL_PUBLIC|BsConfig::TYPE_INT, 
'bs-authors-pref-limit', 'int' );
+               BsConfig::registerVar( 'MW::Authors::MoreImage',   
'more-users_v2.png',          BsConfig::LEVEL_PRIVATE|BsConfig::TYPE_STRING );
+               BsConfig::registerVar( 'MW::Authors::Show',        true,        
                 BsConfig::LEVEL_PUBLIC|BsConfig::TYPE_BOOL, 
'bs-authors-pref-show', 'toggle' );
+
+               $this->mCore->registerBehaviorSwitch( 'bs_noauthors' );
+
+               wfProfileOut( 'BS::'.__METHOD__ );
+       }
+
+       /**
+        * Inject tags into InsertMagic
+        * @param Object $oResponse reference
+        * $param String $type
+        * @return always true to keep hook running
+        */
+       public function onBSInsertMagicAjaxGetData( &$oResponse, $type ) {
+               if( $type != 'switches' ) return true;
+
+               $oDescriptor = new stdClass();
+               $oDescriptor->id = 'bs:authors';
+               $oDescriptor->type = 'switch';
+               $oDescriptor->name = 'NOAUTHORS';
+               $oDescriptor->desc = wfMessage( 'bs-authors-switch-description' 
)->plain();
+               $oDescriptor->code = '__NOAUTHORS__';
+               $oDescriptor->previewable = false;
+               $oResponse->result[] = $oDescriptor;
+
+               return true;
+       }
+
+       /**
+        * Hook-Handler for MediaWiki 'BeforePageDisplay' hook. Sets context if 
needed.
+        * @param OutputPage $oOutputPage
+        * @param Skin $oSkin
+        * @return bool
+        */
+       public function onBeforePageDisplay( &$oOutputPage, &$oSkin ) {
+               if ( $this->checkContext() === false ) return true;
+               $oOutputPage->addModuleStyles('ext.bluespice.authors.styles');
+
+               return true;
+       }
+
+       /**
+        * Hook-handler for 'BS:UserPageSettings'
+        * @param User $oUser The current MediaWiki User object
+        * @param Title $oTitle The current MediaWiki Title object
+        * @param array $aSettingViews A list of View objects
+        * @return array The SettingsViews array with an andditional View object
+        */
+       public function onUserPageSettings( $oUser, $oTitle, &$aSettingViews ){
+               $oUserPageSettingsView = new 
ViewAuthorsUserPageProfileImageSetting();
+               $oUserPageSettingsView->setCurrentUser( $oUser );
+               $aSettingViews[] = $oUserPageSettingsView;
+               return true;
+       }
+
+       /**
+        * Hook-Handler for 'SkinTemplateOutputPageBeforeExec'. Creates the 
authors list below an article.
+        * @param SkinTemplate $sktemplate a collection of views. Add the view 
that needs to be displayed
+        * @param BaseTemplate $tpl currently logged in user. Not used in this 
context.
+        * @return bool always true
+        */
+       public function onSkinTemplateOutputPageBeforeExec( &$sktemplate, &$tpl 
) {
+               if ( $this->checkContext() === false ) {
+                       return true;
+               }
+
+               $aDetails = array();
+               $oAuthorsView = $this->getAuthorsViewForAfterContent( 
$sktemplate, $aDetails );
+               $tpl->data['bs_dataAfterContent']['bs-authors'] = array(
+                       'position' => 10,
+                       'label' => wfMessage( 'bs-authors-title', 
$aDetails['count'], $aDetails['username'] )->text(),
+                       'content' => $oAuthorsView
+               );
+               return true;
+       }
+
+       private function getAuthorsViewForAfterContent( $oSkin, &$aDetails ) {
+               $oTitle = $oSkin->getTitle();
+
+               //Read in config variables
+               $iLimit = BsConfig::get( 'MW::Authors::Limit' );
+               $aBlacklist = BsConfig::get( 'MW::Authors::Blacklist' );
+               $sMoreImage = BsConfig::get( 'MW::Authors::MoreImage' );
+
+               $sPrintable = $oSkin->getRequest()->getVal( 'printable', 'no' );
+               $iArticleId = $oTitle->getArticleID();
+
+               $sKey = BsCacheHelper::getCacheKey( 'BlueSpice', 'Authors', 
$iArticleId );
+               $aData = BsCacheHelper::get( $sKey );
+
+               if ( $aData !== false ) {
+                       wfDebugLog( 'BsMemcached', __CLASS__ . ': Fetched 
AuthorsView and Details from cache' );
+                       $oAuthorsView = $aData['view'];
+                       $aDetails = $aData['details'];
+               } else {
+                       wfDebugLog( 'BsMemcached', __CLASS__ . ': Fetching 
AuthorsView and Details from DB' );
+                       //HINT: Maybe we want to use MW interface 
Article::getContributors() to have better caching
+                       //HINT2: Check if available in MW 1.17+
+                       // SW: There is still no caching in 
WikiPage::getContributors()! 17.07.2014
+                       $dbr = wfGetDB( DB_REPLICA );
+                       $res = $dbr->select(
+                                       array( 'revision' ), array( 
'rev_user_text', 'MAX(rev_timestamp) AS ts' ), array( 'rev_page' => $iArticleId 
), __METHOD__, array(
+                               'GROUP BY' => 'rev_user_text',
+                               'ORDER BY' => 'ts DESC'
+                                       )
+                       );
+
+                       if ( $res->numRows() == 0 ) {
+                               return true;
+                       }
+
+                       $oAuthorsView = new ViewAuthors();
+                       if ( $sPrintable == 'yes' ) {
+                               $oAuthorsView->setOption( 'print', true );
+                       }
+
+                       $aUserNames = array();
+                       foreach ( $res as $row ) {
+                               $aUserNames[] = $row->rev_user_text;
+                       }
+
+                       $iCount = count( $aUserNames );
+                       $aDetails['count'] = $iCount;
+
+                       $sOriginatorUserName = 
$oTitle->getFirstRevision()->getUserText();
+                       $sOriginatorUserName = 
$this->checkOriginatorForBlacklist(
+                               $sOriginatorUserName, 
$oTitle->getFirstRevision(), $aBlacklist
+                       );
+
+                       if ( $iCount > 1 ) {
+                               array_unshift( $aUserNames, 
$sOriginatorUserName );
+                               $iCount++;
+                       }
+
+                       $bAddMore = false;
+                       if ( $iCount > $iLimit ) {
+                               $bAddMore = true;
+                       }
+
+                       $i = 0;
+                       $iItems = 0;
+                       $aDetails['username'] = '';
+                       while ( $i < $iCount ) {
+                               if ( $iItems > $iLimit ) {
+                                       break;
+                               }
+                               $sUserName = $aUserNames[$i];
+
+                               if ( User::isIP( $sUserName ) ) {
+                                       unset( $aUserNames[$i] );
+                                       $i++;
+                                       continue;
+                               }
+
+                               $oAuthorUser = User::newFromName( $sUserName );
+
+                               if ( !is_object( $oAuthorUser ) || in_array( 
$oAuthorUser->getName(), $aBlacklist ) ) {
+                                       unset( $aUserNames[$i] );
+                                       $i++;
+                                       continue;
+                               }
+                               $aDetails['username'] = $oAuthorUser->getName();
+
+                               $oUserMiniProfileView = 
BsCore::getInstance()->getUserMiniProfile(
+                                       $oAuthorUser
+                               );
+                               if ( $sPrintable == 'yes' ) {
+                                       $oUserMiniProfileView->setOption( 
'print', true );
+                               }
+
+                               $iItems++;
+                               $i++;
+                               $oAuthorsView->addItem( $oUserMiniProfileView );
+                       }
+
+                       if ( $bAddMore === true ) {
+                               $oMoreAuthorsView = 
BsCore::getInstance()->getUserMiniProfile(
+                                       new User()
+                               );
+                               $oMoreAuthorsView->setOption( 
'userdisplayname', wfMessage( 'bs-authors-show-all-authors' )->plain() );
+                               $oMoreAuthorsView->setOption( 'userimagesrc', 
$this->getImagePath( true ) . '/' . $sMoreImage );
+                               $oMoreAuthorsView->setOption( 'linktargethref', 
$oTitle->getLocalURL( array( 'action' => 'history' ) ) );
+                               $oMoreAuthorsView->setOption( 'classes', array( 
'bs-authors-more-icon' ) );
+                               if ( $sPrintable == 'yes' ) {
+                                       $oMoreAuthorsView->setOption( 'print', 
true );
+                               }
+
+                               $oAuthorsView->addItem( $oMoreAuthorsView );
+                       }
+
+                       $dbr->freeResult( $res );
+                       BsCacheHelper::set(
+                               $sKey,
+                               array(
+                                       'view' => $oAuthorsView,
+                                       'details' => $aDetails
+                               )
+                       );
+               }
+
+               return $oAuthorsView;
+       }
+
+       /**
+        * Walks the line of revisions to find first editor that is not on 
blacklist
+        * @param string $sOriginatorUserName
+        * @param Revision $oRevision
+        * @return string The originators username
+        */
+       private function checkOriginatorForBlacklist( $sOriginatorUserName, 
$oRevision, $aBlacklist ) {
+               if( $oRevision instanceof Revision == false ) {
+                       return $sOriginatorUserName;
+               }
+               $sOriginatorUserName = $oRevision->getUserText();
+               if(in_array( $sOriginatorUserName, $aBlacklist) ) {
+                       return 
$this->checkOriginatorForBlacklist($sOriginatorUserName, $oRevision->getNext(), 
$aBlacklist);
+               }
+               return $sOriginatorUserName;
+       }
+
+       /**
+        * Checks wether to set Context or not.
+        * @return bool
+        */
+       private function checkContext() {
+               if ( BsConfig::get( 'MW::Authors::Show' ) === false ) {
+                       return false;
+               }
+
+               $oTitle = $this->getTitle();
+               if ( !is_object( $oTitle ) ) {
+                       return false;
+               }
+
+               if ( !$oTitle->exists() ) {
+                       return false;
+               }
+
+               // Do only display when user is allowed to read
+               if ( !$oTitle->userCan( 'read' ) ) {
+                       return false;
+               }
+
+               // Do only display in view mode
+               if ( $this->getRequest()->getVal( 'action', 'view' ) != 'view' 
) {
+                       return false;
+               }
+
+               // Do not display on SpecialPages, CategoryPages or ImagePages
+               if ( in_array( $oTitle->getNamespace(), array( NS_SPECIAL, 
NS_CATEGORY, NS_FILE ) ) ) {
+                       return false;
+               }
+
+               // Do not display if __NOAUTHORS__ keyword is found
+               $vNoAuthors = BsArticleHelper::getInstance( $oTitle 
)->getPageProp( 'bs_noauthors' );
+               if( $vNoAuthors === '' ) {
+                       return false;
+               }
+
+               return true;
+       }
+
+       /**
+        * Invalidates cache for authors
+        * @param WikiPage $wikiPage
+        * @param User $user
+        * @param Content $content
+        * @param type $summary
+        * @param type $isMinor
+        * @param type $isWatch
+        * @param type $section
+        * @param type $flags
+        * @param Status $status
+        * @return boolean
+        */
+       public static function onPageContentSave( $wikiPage, $user, $content, 
$summary, $isMinor, $isWatch, $section, $flags, $status ) {
+               BsCacheHelper::invalidateCache( BsCacheHelper::getCacheKey( 
'BlueSpice', 'Authors', $wikiPage->getTitle()->getArticleID() ) );
+               return true;
+       }
+}
diff --git a/composer.json b/composer.json
new file mode 100644
index 0000000..c80eb60
--- /dev/null
+++ b/composer.json
@@ -0,0 +1,8 @@
+{
+       "autoload" : {
+               "psr-4": {
+                       "BlueSpice\\ExtendedStatistics\\Tests\\" : 
"tests/phpunit",
+                       "BlueSpice\\ExtendedStatistics\\" : "src"
+               }
+       }
+}
\ No newline at end of file
diff --git a/doc/Hooks.txt b/doc/Hooks.txt
new file mode 100755
index 0000000..e69de29
--- /dev/null
+++ b/doc/Hooks.txt
diff --git a/extension.json b/extension.json
new file mode 100644
index 0000000..4925921
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,42 @@
+{
+       "name": "Authors",
+       "version": "2.27.1-alpha",
+       "url": "https://help.bluespice.com/index.php/Authors";,
+       "author": [
+               "Markus Glaser",
+               "Robert Vogel"
+       ],
+       "descriptionmsg": "bs-authors-desc",
+       "type": "bluespice",
+       "bsgExtensions": {
+               "Authors": {
+                       "className": "Authors",
+                       "extPath": "/BlueSpiceAuthors"
+               }
+       },
+       "MessagesDirs": {
+               "Authors": [
+                       "i18n"
+               ]
+       },
+       "ExtensionMessagesFiles": {
+               "AuthorsMagic": "languages/Authors.i18n.magic.php"
+       },
+       "AutoloadClasses": {
+               "Authors": "Authors.class.php",
+               "ViewAuthors": "views/view.Authors.php",
+               "ViewAuthorsUserPageProfileImageSetting": 
"views/view.AuthorsUserPageProfileImageSetting.php"
+       },
+       "load_composer_autoloader" : true,
+       "ResourceModules": {
+               "ext.bluespice.authors.styles": {
+                       "styles": "bluespice.authors.css",
+                       "position": "top"
+               }
+       },
+       "ResourceFileModulePaths": {
+               "localBasePath": "resources",
+               "remoteExtPath": "BlueSpiceAuthors/resources"
+       },
+       "manifest_version": 1
+}
diff --git a/i18n/ast.json b/i18n/ast.json
new file mode 100755
index 0000000..73ce8d1
--- /dev/null
+++ b/i18n/ast.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Xuacu"
+               ]
+       },
+       "bs-authors-desc": "Amuesa la imaxe de perfil de los autores d'una 
páxina",
+       "prefs-authors": "Autores d'esta páxina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autores}}",
+       "bs-authors-profileimage": "Imaxe de perfil",
+       "bs-authors-profileimage-change": "Cambiar la imaxe de perfil",
+       "bs-authors-show-all-authors": "Más autores disponibles",
+       "bs-authors-pref-imageheight": "Altor de la imaxe:",
+       "bs-authors-pref-imagewidth": "Anchu de la imaxe:",
+       "bs-authors-pref-limit": "Llende d'autores a amosar:",
+       "bs-authors-pref-show": "Amosar autores",
+       "bs-authors-switch-description": "Tapecer los autores nesta páxina."
+}
diff --git a/i18n/ba.json b/i18n/ba.json
new file mode 100755
index 0000000..6201330
--- /dev/null
+++ b/i18n/ba.json
@@ -0,0 +1,19 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Рустам Нурыев",
+                       "Sagan"
+               ]
+       },
+       "bs-authors-desc": "Бит авторҙарының профиль картинаһын күрһәтә",
+       "prefs-authors": "Был бит авторҙары",
+       "bs-authors-title": "{{GENDER:$2|Автор{{PLURAL:$1|}}}}",
+       "bs-authors-profileimage": "Профиль рәсем",
+       "bs-authors-profileimage-change": "Рәсем профилен үҙгәртергә",
+       "bs-authors-show-all-authors": "Башҡа авторҙар ҙа бар",
+       "bs-authors-pref-imageheight": "Рәсем бейеклеге",
+       "bs-authors-pref-imagewidth": "Рәсем киңлеге",
+       "bs-authors-pref-limit": "Авторҙар һанына сикләү",
+       "bs-authors-pref-show": "Авторҙарҙы күрһәтергә",
+       "bs-authors-switch-description": "Был биттең авторҙарын йәшерергә"
+}
diff --git a/i18n/bcc.json b/i18n/bcc.json
new file mode 100755
index 0000000..a9fba5c
--- /dev/null
+++ b/i18n/bcc.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Baloch Afghanistan"
+               ]
+       },
+       "bs-authors-title": "{{جمع:$1|{{جینسیت:$2|نویشتاروک}}|نویشتاروکان}}"
+}
diff --git a/i18n/bn.json b/i18n/bn.json
new file mode 100755
index 0000000..b158558
--- /dev/null
+++ b/i18n/bn.json
@@ -0,0 +1,9 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Aftab1995",
+                       "Aftabuzzaman"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|লেখক}}|লেখকগণ}}"
+}
diff --git a/i18n/br.json b/i18n/br.json
new file mode 100755
index 0000000..eb5d4ed
--- /dev/null
+++ b/i18n/br.json
@@ -0,0 +1,17 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Y-M D",
+                       "Fohanno"
+               ]
+       },
+       "prefs-authors": "Aozerien ar bajenn-mañ",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Aozer|Aozerez}}}}",
+       "bs-authors-profileimage": "Skeudenn ar profil",
+       "bs-authors-profileimage-change": "Cheñch skeudenn ar profil",
+       "bs-authors-show-all-authors": "Aozerien ouzhpenn da gaout",
+       "bs-authors-pref-imageheight": "Sav ar skeudenn :",
+       "bs-authors-pref-imagewidth": "Ledander ar skeudenn :",
+       "bs-authors-pref-show": "Diskwel an aozerien",
+       "bs-authors-switch-description": "Kuzhat an aozerien war ar bajenn-mañ."
+}
diff --git a/i18n/ca.json b/i18n/ca.json
new file mode 100755
index 0000000..35aac42
--- /dev/null
+++ b/i18n/ca.json
@@ -0,0 +1,9 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Fitoschido"
+               ]
+       },
+       "prefs-authors": "Autors d’aquesta pàgina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autors}}"
+}
diff --git a/i18n/ce.json b/i18n/ce.json
new file mode 100755
index 0000000..a66c734
--- /dev/null
+++ b/i18n/ce.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Умар"
+               ]
+       },
+       "bs-authors-desc": "АгӀонийн автораш гойту цера суьрташцан",
+       "prefs-authors": "ХӀокху агӀона автораш",
+       "bs-authors-title": "{{PLURAL:$1|Автор|Автораш}}",
+       "bs-authors-profileimage": "Сурт профиль чохь ду",
+       "bs-authors-profileimage-change": "Бехк ма билла сурт профиль чохь ду",
+       "bs-authors-show-all-authors": "Кхин бу автораш",
+       "bs-authors-pref-imageheight": "Суьртан локхалла:",
+       "bs-authors-pref-imagewidth": "Суьртан шоралла:",
+       "bs-authors-pref-limit": "Гойтуш болу авторийн дукхалин доза тохар:",
+       "bs-authors-pref-show": "Гайта автораш",
+       "bs-authors-switch-description": "ХӀокху агӀона автораш къайлабоху."
+}
diff --git a/i18n/de.json b/i18n/de.json
new file mode 100755
index 0000000..52dcbba
--- /dev/null
+++ b/i18n/de.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Stephan Muggli <mug...@hallowelt.biz>",
+                       "Metalhead64",
+                       "Smuggli"
+               ]
+       },
+       "bs-authors-desc": "Zeigt Profilbilder für Autoren einer Seite an",
+       "prefs-authors": "Autoren dieser Seite",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autorin}}|Autoren}}",
+       "bs-authors-profileimage": "Profilbild",
+       "bs-authors-profileimage-change": "Profilbild ändern",
+       "bs-authors-show-all-authors": "Weitere Autoren vorhanden",
+       "bs-authors-pref-imageheight": "Bildhöhe:",
+       "bs-authors-pref-imagewidth": "Bildbreite:",
+       "bs-authors-pref-limit": "Maximale Anzahl angezeigter Autoren:",
+       "bs-authors-pref-show": "Autoren anzeigen",
+       "bs-authors-switch-description": "Autoren werden auf dieser Seite nicht 
angezeigt."
+}
diff --git a/i18n/diq.json b/i18n/diq.json
new file mode 100755
index 0000000..4b381b1
--- /dev/null
+++ b/i18n/diq.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Mirzali",
+                       "Kumkumuk",
+                       "1917 Ekim Devrimi"
+               ]
+       },
+       "bs-authors-desc": "Qandé nuştekarê perer profila resimi bıasne",
+       "prefs-authors": "Nuştekarê perer",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Nuştekar}}|Nuştekari}}",
+       "bs-authors-profileimage": "Resmê profili",
+       "bs-authors-profileimage-change": "Resmê profili bıvurne",
+       "bs-authors-show-all-authors": "Dehana vêşi mewcud nuştekari",
+       "bs-authors-pref-imageheight": "Berziya resımi:",
+       "bs-authors-pref-imagewidth": "Herayiya resımi:",
+       "bs-authors-pref-limit": "Limita karberan bıasne:",
+       "bs-authors-pref-show": "Nuştoğan bımotne",
+       "bs-authors-switch-description": "Perer de nustoğan bınımn"
+}
diff --git a/i18n/el.json b/i18n/el.json
new file mode 100755
index 0000000..5338079
--- /dev/null
+++ b/i18n/el.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Geraki"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Συντάκτης}}|Συντάκτες}}"
+}
diff --git a/i18n/en.json b/i18n/en.json
new file mode 100644
index 0000000..a11cd17
--- /dev/null
+++ b/i18n/en.json
@@ -0,0 +1,16 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Stephan Muggli <mug...@hallowelt.biz>"
+               ]
+       },
+       "bs-authors-desc": "Displays the profile picture for authors of a page",
+       "prefs-authors": "Authors of this page",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Author}}|Authors}}",
+       "bs-authors-profileimage": "Profile picture",
+       "bs-authors-profileimage-change": "Change profile picture",
+       "bs-authors-show-all-authors": "More authors available",
+       "bs-authors-pref-limit": "Limit of authors to display:",
+       "bs-authors-pref-show": "Display authors",
+       "bs-authors-switch-description": "Hides authors on this page."
+}
diff --git a/i18n/es.json b/i18n/es.json
new file mode 100755
index 0000000..16fb1ce
--- /dev/null
+++ b/i18n/es.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Fitoschido",
+                       "Mcervera",
+                       "Macofe"
+               ]
+       },
+       "bs-authors-desc": "Muestra las imágenes de perfil de los autores de 
una página",
+       "prefs-authors": "Autores de esta página",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autores}}",
+       "bs-authors-profileimage": "Imagen de perfil",
+       "bs-authors-profileimage-change": "Cambiar imagen de perfil",
+       "bs-authors-show-all-authors": "Más autores disponibles",
+       "bs-authors-pref-imageheight": "Altura de la imagen:",
+       "bs-authors-pref-imagewidth": "Anchura de la imagen:",
+       "bs-authors-pref-limit": "Límite de autores que mostrar:",
+       "bs-authors-pref-show": "Mostrar autores",
+       "bs-authors-switch-description": "Oculta los autores de esta página."
+}
diff --git a/i18n/et.json b/i18n/et.json
new file mode 100755
index 0000000..65fd302
--- /dev/null
+++ b/i18n/et.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Boxmein"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor}} |Autorid}}"
+}
diff --git a/i18n/eu.json b/i18n/eu.json
new file mode 100755
index 0000000..1408334
--- /dev/null
+++ b/i18n/eu.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Subi"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Egilea}}|Egileak}}"
+}
diff --git a/i18n/fa.json b/i18n/fa.json
new file mode 100755
index 0000000..0acae1e
--- /dev/null
+++ b/i18n/fa.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Alirezaaa"
+               ]
+       },
+       "bs-authors-desc": "تصویر مشخصات را برای نویسنده‌های یک صفحه نشان 
می‌دهد",
+       "prefs-authors": "نویسنده‌های این صفحه",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|نویسنده}}|نویسنده‌ها}}",
+       "bs-authors-profileimage": "تصویر مشخصات",
+       "bs-authors-profileimage-change": "تغییر تصویر مشخصات",
+       "bs-authors-show-all-authors": "نویسنده‌های بیشتری در دسترس هستند",
+       "bs-authors-pref-imageheight": "بلندی تصویر:",
+       "bs-authors-pref-imagewidth": "پهنای تصویر:",
+       "bs-authors-pref-limit": "محدودیت نویسنده‌ها برای نمایش:",
+       "bs-authors-pref-show": "نمایش نویسنده‌ها",
+       "bs-authors-switch-description": "نویسنده‌ها را در این صفحه پنهان 
می‌کند."
+}
diff --git a/i18n/fr.json b/i18n/fr.json
new file mode 100755
index 0000000..4df0cb9
--- /dev/null
+++ b/i18n/fr.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Gomoko"
+               ]
+       },
+       "bs-authors-desc": "Affiche l’image de profil des auteurs d’une page",
+       "prefs-authors": "Auteurs de cette page",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Auteur}}|Auteurs}}",
+       "bs-authors-profileimage": "Image du profil",
+       "bs-authors-profileimage-change": "Modifier l’image du profil",
+       "bs-authors-show-all-authors": "Plus d’auteurs disponibles",
+       "bs-authors-pref-imageheight": "Hauteur de l’image :",
+       "bs-authors-pref-imagewidth": "Largeur de l’image :",
+       "bs-authors-pref-limit": "Limite des auteurs à afficher :",
+       "bs-authors-pref-show": "Afficher les auteurs",
+       "bs-authors-switch-description": "Masque les auteurs sur cette page."
+}
diff --git a/i18n/gl.json b/i18n/gl.json
new file mode 100755
index 0000000..9a76ec2
--- /dev/null
+++ b/i18n/gl.json
@@ -0,0 +1,19 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Elisardojm",
+                       "Toliño"
+               ]
+       },
+       "bs-authors-desc": "Mostra as imaxes de perfil dos autores dunha 
páxina",
+       "prefs-authors": "Autores desta páxina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autores}}",
+       "bs-authors-profileimage": "Imaxe do perfil",
+       "bs-authors-profileimage-change": "Cambiar a imaxe do perfil",
+       "bs-authors-show-all-authors": "Máis autores dispoñibles",
+       "bs-authors-pref-imageheight": "Altura da imaxe:",
+       "bs-authors-pref-imagewidth": "Ancho da imaxe:",
+       "bs-authors-pref-limit": "Límite de autores a mostrar:",
+       "bs-authors-pref-show": "Mostrar os autores",
+       "bs-authors-switch-description": "Agocha os autores nesta páxina."
+}
diff --git a/i18n/gu.json b/i18n/gu.json
new file mode 100755
index 0000000..fc6ccbd
--- /dev/null
+++ b/i18n/gu.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "KartikMistry"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|લેખક}}|લેખકો}}"
+}
diff --git a/i18n/he.json b/i18n/he.json
new file mode 100755
index 0000000..41b7f2e
--- /dev/null
+++ b/i18n/he.json
@@ -0,0 +1,19 @@
+{
+       "@metadata": {
+               "authors": [
+                       "ערן",
+                       "Guycn2"
+               ]
+       },
+       "bs-authors-desc": "מציג את תמונת הפרופיל עבור מחברים של דף",
+       "prefs-authors": "מחברי הדף",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|מחבר|מחברת}}|מחברים}}",
+       "bs-authors-profileimage": "תמונת הפרופיל",
+       "bs-authors-profileimage-change": "שינוי תמונת הפרופיל",
+       "bs-authors-show-all-authors": "מחברים נוספים זמינים",
+       "bs-authors-pref-imageheight": "גובה התמונה:",
+       "bs-authors-pref-imagewidth": "רוחב התמונה:",
+       "bs-authors-pref-limit": "מספר המחברים להצגה:",
+       "bs-authors-pref-show": "הצגת מחברים",
+       "bs-authors-switch-description": "הסתרת המחברים בדף זה."
+}
diff --git a/i18n/hi.json b/i18n/hi.json
new file mode 100644
index 0000000..ddda352
--- /dev/null
+++ b/i18n/hi.json
@@ -0,0 +1,12 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Jayprakash12345",
+                       "Sfic"
+               ]
+       },
+       "bs-authors-profileimage": "प्रोफ़ाइल छवि",
+       "bs-authors-profileimage-change": "प्रोफ़ाइल छवि को बदलें",
+       "bs-authors-pref-show": "लेखक को दर्शाए।",
+       "bs-authors-switch-description": "इस पृष्ठ पर लेखकों को छुपाए।"
+}
diff --git a/i18n/hu.json b/i18n/hu.json
new file mode 100755
index 0000000..ea5d82d
--- /dev/null
+++ b/i18n/hu.json
@@ -0,0 +1,11 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Misibacsi"
+               ]
+       },
+       "bs-authors-profileimage": "Profilkép",
+       "bs-authors-profileimage-change": "Profilkép módosítása",
+       "bs-authors-pref-imageheight": "Képmagasság:",
+       "bs-authors-pref-imagewidth": "Képszélesség:"
+}
diff --git a/i18n/ia.json b/i18n/ia.json
new file mode 100755
index 0000000..d95d15c
--- /dev/null
+++ b/i18n/ia.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "McDutchie"
+               ]
+       },
+       "bs-authors-desc": "Monstra le imagines de profilo del autores de un 
pagina",
+       "prefs-authors": "Autores de iste pagina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor}}|Autores}}",
+       "bs-authors-profileimage": "Imagine de profilo",
+       "bs-authors-profileimage-change": "Cambiar imagine de profilo",
+       "bs-authors-show-all-authors": "Altere autores disponibile",
+       "bs-authors-pref-imageheight": "Altitude del imagine:",
+       "bs-authors-pref-imagewidth": "Latitude del imagine:",
+       "bs-authors-pref-limit": "Numero maxime de autores a monstrar:",
+       "bs-authors-pref-show": "Monstrar autores",
+       "bs-authors-switch-description": "Celar le autores in iste pagina."
+}
diff --git a/i18n/id.json b/i18n/id.json
new file mode 100755
index 0000000..1c01d3a
--- /dev/null
+++ b/i18n/id.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Arifin.wijaya"
+               ]
+       },
+       "bs-authors-desc": "Menampilkan foto profil untuk penulis halaman",
+       "prefs-authors": "Penulis halaman ini",
+       "bs-authors-title": "{{PLURAL:$1|Penulis|Penulis}}",
+       "bs-authors-profileimage": "Foto profil",
+       "bs-authors-profileimage-change": "Ubah foto profil",
+       "bs-authors-show-all-authors": "Penulis lain tersedia",
+       "bs-authors-pref-imageheight": "Tinggi gambar:",
+       "bs-authors-pref-imagewidth": "Lebar gambar:",
+       "bs-authors-pref-limit": "Batas penulis untuk menampilkan:",
+       "bs-authors-pref-show": "Tampilkan penulis",
+       "bs-authors-switch-description": "Sembunyikan penulis di halaman ini."
+}
diff --git a/i18n/it.json b/i18n/it.json
new file mode 100755
index 0000000..cb2f0fa
--- /dev/null
+++ b/i18n/it.json
@@ -0,0 +1,19 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Beta16",
+                       "Nemo bis"
+               ]
+       },
+       "bs-authors-desc": "Visualizza l'immagine del profilo per gli autori di 
una pagina",
+       "prefs-authors": "Autori di questa pagina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autore|Autrice}}|Autori}}",
+       "bs-authors-profileimage": "Immagine profilo",
+       "bs-authors-profileimage-change": "Cambia immagine del profilo",
+       "bs-authors-show-all-authors": "Altri autori disponibili",
+       "bs-authors-pref-imageheight": "Altezza immagine:",
+       "bs-authors-pref-imagewidth": "Larghezza immagine:",
+       "bs-authors-pref-limit": "Limite degli autori da visualizzare:",
+       "bs-authors-pref-show": "Visualizza autori",
+       "bs-authors-switch-description": "Nasconde gli autori su questa pagina."
+}
diff --git a/i18n/ja.json b/i18n/ja.json
new file mode 100755
index 0000000..1a31757
--- /dev/null
+++ b/i18n/ja.json
@@ -0,0 +1,16 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Shirayuki"
+               ]
+       },
+       "bs-authors-desc": "ページの作者のプロフィール画像を表示する",
+       "prefs-authors": "このページの作者",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|作者}}|作者}}",
+       "bs-authors-profileimage": "プロフィール画像",
+       "bs-authors-profileimage-change": "プロフィール画像を変更",
+       "bs-authors-pref-imageheight": "画像の高さ:",
+       "bs-authors-pref-imagewidth": "画像の幅:",
+       "bs-authors-pref-limit": "表示する作者数の上限:",
+       "bs-authors-pref-show": "作者を表示"
+}
diff --git a/i18n/kn.json b/i18n/kn.json
new file mode 100755
index 0000000..7902a9f
--- /dev/null
+++ b/i18n/kn.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "VASANTH S.N."
+               ]
+       },
+       "bs-authors-desc": "ಪುಟದ ಲೇಖಕರನ್ನು ಅವರ ಭಾವಚಿತ್ರದೊಂದಿಗೆ ಪ್ರದರ್ಶಿಸುತ್ತದೆ",
+       "prefs-authors": "ಈ ಲೇಖನದ ಲೇಖಕರು",
+       "bs-authors-title": "{{PLURAL:$1|ಲೇಖಕ|ಲೇಖಕರು}}",
+       "bs-authors-profileimage": "ವ್ಯಕ್ತಿ ಚಿತ್ರ",
+       "bs-authors-profileimage-change": "ವ್ಯಕ್ತಿಚಿತ್ರದ ಭಾವಚಿತ್ರವನ್ನು 
ಬದಲಾಯಿಸಿ",
+       "bs-authors-show-all-authors": "ಹೆಚ್ಚಿನ ಲೇಖಕರು ಲಭ್ಯ",
+       "bs-authors-pref-imageheight": "ಭಾವಚಿತ್ರದ ಎತ್ತರ:",
+       "bs-authors-pref-imagewidth": "ಭಾವಚಿತ್ರದ ಅಗಲ:",
+       "bs-authors-pref-limit": "ಪ್ರದರ್ಶಿಸುವ ಲೇಖಕರ ಮಿತಿ:",
+       "bs-authors-pref-show": "ಲೇಖಕರನ್ನು ಪ್ರಕಟಪಡಿಸಿ",
+       "bs-authors-switch-description": "ಈ ಲೇಖನದಲ್ಲಿ ಲೇಖಕರನ್ನು 
ಅಡಗಿಸಲಾಗುತ್ತಿದೆ."
+}
diff --git a/i18n/ko.json b/i18n/ko.json
new file mode 100644
index 0000000..c3d5812
--- /dev/null
+++ b/i18n/ko.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Namoroka",
+                       "아라",
+                       "Hwangjy9"
+               ]
+       },
+       "bs-authors-desc": "문서 작성자의 프로필 사진 보기",
+       "prefs-authors": "이 문서의 작성자",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|작성자}}|작성자}}",
+       "bs-authors-profileimage": "프로필 사진",
+       "bs-authors-profileimage-change": "프로필 사진 바꾸기",
+       "bs-authors-show-all-authors": "더 많은 작성자들이 있습니다",
+       "bs-authors-pref-imageheight": "그림 높이:",
+       "bs-authors-pref-imagewidth": "그림 너비:",
+       "bs-authors-pref-limit": "작성자 표시의 제한:",
+       "bs-authors-pref-show": "작성자 표시",
+       "bs-authors-switch-description": "이 문서의 작성자를 숨깁니다."
+}
diff --git a/i18n/ksh.json b/i18n/ksh.json
new file mode 100755
index 0000000..567bea4
--- /dev/null
+++ b/i18n/ksh.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Purodha"
+               ]
+       },
+       "bs-authors-desc": "Zeijsch Bellder ussem Profihl  vun de Schrihver vun 
en Sigg aan.",
+       "prefs-authors": "De Schriiver aan heh dä Sigg",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Schriiver}}|Schriiver}}",
+       "bs-authors-profileimage": "E Beld för em Profihl",
+       "bs-authors-profileimage-change": "Donn dat Beld för em Profihl 
wähßelle",
+       "bs-authors-show-all-authors": "Et sinn_er noch mih Schrihver doh",
+       "bs-authors-pref-imageheight": "Däm Beld sing Hühde:",
+       "bs-authors-pref-imagewidth": "Däm Beld sing Breijde:",
+       "bs-authors-pref-limit": "De jrühßte Aanzahl Schrihver zom Aanzeije:",
+       "bs-authors-pref-show": "De Schrihver anzeije:",
+       "bs-authors-switch-description": "De Schrihver op heh dä Sigg nit 
aanzeije:"
+}
diff --git a/i18n/lb.json b/i18n/lb.json
new file mode 100755
index 0000000..1ffd002
--- /dev/null
+++ b/i18n/lb.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Robby"
+               ]
+       },
+       "bs-authors-desc": "Weist d'Profilbild vun den Auteure vun enger Säit",
+       "prefs-authors": "Auteure vun dëser Säit",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Auteur}}|Auteuren}}",
+       "bs-authors-profileimage": "Profilbild",
+       "bs-authors-profileimage-change": "Profilbild änneren",
+       "bs-authors-show-all-authors": "Méi Auteuren disponibel",
+       "bs-authors-pref-imageheight": "Héicht vum Bild:",
+       "bs-authors-pref-imagewidth": "Breet vum Bild:",
+       "bs-authors-pref-limit": "Maximal Zuel vun Auteuren déi gewise ginn:",
+       "bs-authors-pref-show": "Auteure weisen",
+       "bs-authors-switch-description": "Verstoppt d'Auteure op dëser Säit."
+}
diff --git a/i18n/lt.json b/i18n/lt.json
new file mode 100755
index 0000000..6b1cc60
--- /dev/null
+++ b/i18n/lt.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Eitvys200"
+               ]
+       },
+       "bs-authors-desc": "Rodo puslapio autorių profilio nuotraukas",
+       "prefs-authors": "Šio puslapio autoriai",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autorius}}|Autoriai}}",
+       "bs-authors-profileimage": "Profilio nuotrauka",
+       "bs-authors-profileimage-change": "Keisti profilio nuotrauka",
+       "bs-authors-show-all-authors": "Yra daugiau autorių",
+       "bs-authors-pref-imageheight": "Vaizdo aukštis:",
+       "bs-authors-pref-imagewidth": "Vaizdo plotis:",
+       "bs-authors-pref-limit": "Autorių rodinio limitas:",
+       "bs-authors-pref-show": "Rodyti autorius",
+       "bs-authors-switch-description": "Slėpti autorius šiame puslapyje."
+}
diff --git a/i18n/lv.json b/i18n/lv.json
new file mode 100755
index 0000000..e5babbb
--- /dev/null
+++ b/i18n/lv.json
@@ -0,0 +1,16 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Papuass"
+               ]
+       },
+       "prefs-authors": "Šīs lapas autori",
+       "bs-authors-title": 
"{{PLURAL:$1|Autori|{{GENDER:$2|Autors|Autore}}|Autori}}",
+       "bs-authors-profileimage": "Profila attēls",
+       "bs-authors-profileimage-change": "Mainīt profila attēlu",
+       "bs-authors-pref-imageheight": "Attēla augstums:",
+       "bs-authors-pref-imagewidth": "Attēla platums:",
+       "bs-authors-pref-limit": "Ierobežot rādāmos autorus:",
+       "bs-authors-pref-show": "Rādīt autorus",
+       "bs-authors-switch-description": "Paslēpj šīs lapas autorus."
+}
diff --git a/i18n/mk.json b/i18n/mk.json
new file mode 100755
index 0000000..91daf13
--- /dev/null
+++ b/i18n/mk.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Bjankuloski06"
+               ]
+       },
+       "bs-authors-desc": "Прикажува профилни слики на авторите на една 
страница",
+       "prefs-authors": "Автори на страницава",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Автор}}|Автори}}",
+       "bs-authors-profileimage": "Профилна слика",
+       "bs-authors-profileimage-change": "Промена на профилната слика",
+       "bs-authors-show-all-authors": "Промена на профилната слика",
+       "bs-authors-pref-imageheight": "Висина на сликата:",
+       "bs-authors-pref-imagewidth": "Ширина на сликата:",
+       "bs-authors-pref-limit": "Колку највеќе автори да се прикажуваат:",
+       "bs-authors-pref-show": "Прикажувај автори",
+       "bs-authors-switch-description": "Ги сокрива авторите на страницава."
+}
diff --git a/i18n/mr.json b/i18n/mr.json
new file mode 100755
index 0000000..de26f8c
--- /dev/null
+++ b/i18n/mr.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "V.narsikar"
+               ]
+       },
+       "bs-authors-desc": "पानाच्या लेखकाचे संक्षिप्त-वर्णनातील चित्र 
दर्शविते",
+       "prefs-authors": "पानाचे लेखक",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|लेखक}}}}",
+       "bs-authors-profileimage": "संक्षिप्त-वर्णनातील चित्र",
+       "bs-authors-profileimage-change": "संक्षिप्त-वर्णनातील चित्र बदला",
+       "bs-authors-show-all-authors": "अधिक लेखक उपलब्ध आहेत",
+       "bs-authors-pref-imageheight": "चित्राची उंची:",
+       "bs-authors-pref-imagewidth": "चित्राची रुंदी:",
+       "bs-authors-pref-limit": "लेखक दर्शविण्याची मर्यादा:",
+       "bs-authors-pref-show": "लेखक दर्शवा",
+       "bs-authors-switch-description": "या पानाचे लेखक लपविते."
+}
diff --git a/i18n/nb.json b/i18n/nb.json
new file mode 100755
index 0000000..de99cbd
--- /dev/null
+++ b/i18n/nb.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Jon Harald Søby"
+               ]
+       },
+       "bs-authors-desc": "Viser profilbildet til forfatterne av en side",
+       "prefs-authors": "Forfattere av denne siden",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Forfatter}}|Forfattere}}",
+       "bs-authors-profileimage": "Profilbilde",
+       "bs-authors-profileimage-change": "Endre profilbilde",
+       "bs-authors-show-all-authors": "Flere forfattere tilgjengelig",
+       "bs-authors-pref-imageheight": "Bildehøyde:",
+       "bs-authors-pref-imagewidth": "Bildebredde:",
+       "bs-authors-pref-limit": "Grense for antall forfattere å vise:",
+       "bs-authors-pref-show": "Vis forfattere",
+       "bs-authors-switch-description": "Skjul forfatterne på denne siden."
+}
diff --git a/i18n/nl.json b/i18n/nl.json
new file mode 100755
index 0000000..58e0265
--- /dev/null
+++ b/i18n/nl.json
@@ -0,0 +1,21 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Niknetniko",
+                       "SPQRobin",
+                       "Sjoerddebruin",
+                       "Siebrand"
+               ]
+       },
+       "bs-authors-desc": "Geeft de profielfoto weer van de auteurs van een 
pagina",
+       "prefs-authors": "Auteurs van deze pagina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Auteur}}|Auteurs}}",
+       "bs-authors-profileimage": "Profielafbeelding",
+       "bs-authors-profileimage-change": "Profielafbeelding wijzigen",
+       "bs-authors-show-all-authors": "Meer auteurs beschikbaar",
+       "bs-authors-pref-imageheight": "Afbeeldingshoogte:",
+       "bs-authors-pref-imagewidth": "Afbeeldingsbreedte:",
+       "bs-authors-pref-limit": "Limiet van auteurs om weer te geven:",
+       "bs-authors-pref-show": "Auteurs weergeven",
+       "bs-authors-switch-description": "Verbergt auteurs bij deze pagina."
+}
diff --git a/i18n/oc.json b/i18n/oc.json
new file mode 100755
index 0000000..42fb711
--- /dev/null
+++ b/i18n/oc.json
@@ -0,0 +1,16 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Cedric31"
+               ]
+       },
+       "prefs-authors": "Autors d'aquesta pagina",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor}}|Autors}}",
+       "bs-authors-profileimage": "Imatge del perfil",
+       "bs-authors-profileimage-change": "Modificar l’imatge del perfil",
+       "bs-authors-show-all-authors": "Mai d’autors disponibles",
+       "bs-authors-pref-imageheight": "Nautor de l’imatge :",
+       "bs-authors-pref-imagewidth": "Largor de l’imatge :",
+       "bs-authors-pref-limit": "Limit dels autors d'afichar :",
+       "bs-authors-pref-show": "Afichar los autors"
+}
diff --git a/i18n/pl.json b/i18n/pl.json
new file mode 100755
index 0000000..bb816ea
--- /dev/null
+++ b/i18n/pl.json
@@ -0,0 +1,17 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Chrumps",
+                       "Vengir"
+               ]
+       },
+       "prefs-authors": "Autorzy tej strony",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autorka}}|Autorów}}",
+       "bs-authors-profileimage": "Avatar",
+       "bs-authors-profileimage-change": "Zmień avatar",
+       "bs-authors-show-all-authors": "Więcej autorów…",
+       "bs-authors-pref-imageheight": "Wysokość obrazu:",
+       "bs-authors-pref-imagewidth": "Szerokość obrazu:",
+       "bs-authors-pref-show": "Wyświetl autorów",
+       "bs-authors-switch-description": "Ukrywa autorów tej strony."
+}
diff --git a/i18n/ps.json b/i18n/ps.json
new file mode 100755
index 0000000..e99b2f3
--- /dev/null
+++ b/i18n/ps.json
@@ -0,0 +1,10 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Ahmed-Najib-Biabani-Ibrahimkhel"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|ليکوال}}|ليکوالان}}",
+       "bs-authors-profileimage": "د پېژنليک انځور",
+       "bs-authors-profileimage-change": "پېژنليک انځور بدلول"
+}
diff --git a/i18n/pt-br.json b/i18n/pt-br.json
new file mode 100755
index 0000000..87ec378
--- /dev/null
+++ b/i18n/pt-br.json
@@ -0,0 +1,8 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Rodrigo codignoli"
+               ]
+       },
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autores}}"
+}
diff --git a/i18n/pt.json b/i18n/pt.json
new file mode 100755
index 0000000..3699a5d
--- /dev/null
+++ b/i18n/pt.json
@@ -0,0 +1,21 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Imperadeiro98",
+                       "Fúlvio",
+                       "Vitorvicentevalente",
+                       "Hamilton Abreu"
+               ]
+       },
+       "bs-authors-desc": "Apresenta a imagem do perfil dos autores de uma 
página",
+       "prefs-authors": "Autores desta página",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Autor|Autora}}|Autores}}",
+       "bs-authors-profileimage": "Imagem de perfil",
+       "bs-authors-profileimage-change": "Mudar a imagem de perfil",
+       "bs-authors-show-all-authors": "Mais autores disponíveis",
+       "bs-authors-pref-imageheight": "Altura da imagem:",
+       "bs-authors-pref-imagewidth": "Largura da imagem:",
+       "bs-authors-pref-limit": "Limite de autores para mostrar:",
+       "bs-authors-pref-show": "Mostrar autores",
+       "bs-authors-switch-description": "Esconde os autores nesta página."
+}
diff --git a/i18n/qqq.json b/i18n/qqq.json
new file mode 100644
index 0000000..86878d4
--- /dev/null
+++ b/i18n/qqq.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Stephan Muggli <mug...@hallowelt.biz>",
+                       "Shirayuki",
+                       "Liuxinyu970226"
+               ]
+       },
+       "bs-authors-desc": "Used in 
[{{canonicalurl:Special:WikiAdmin|mode=ExtensionInfo}} 
Special:WikiAdmin?mode=ExtensionInfo], description of authors extension",
+       "prefs-authors": "Used in 
[{{canonicalurl:Special:WikiAdmin|mode=Preferences}} 
Special:WikiAdmin?mode=Preferences], headline of authors section preferences",
+       "bs-authors-title": "Headline of authors below page content\n*$1 is the 
number of authors - use for PLURAL distinction\n*$2 is the username - use for 
GENDER distinction\n{{Identical|Author}}",
+       "bs-authors-profileimage": "Image title for profile image, used on user 
page",
+       "bs-authors-profileimage-change": "Text for change your profile image, 
shown on user page",
+       "bs-authors-show-all-authors": "Image title for more authors available, 
used if there are too many authors",
+       "bs-authors-pref-limit": "Option in 
[{{canonicalurl:Special:WikiAdmin|mode=Preferences}} 
Special:WikiAdmin?mode=Preferences], label for how much authors should be 
displayed:",
+       "bs-authors-pref-show": "Option in 
[{{canonicalurl:Special:WikiAdmin|mode=Preferences}} 
Special:WikiAdmin?mode=Preferences], checkbox label for display authors",
+       "bs-authors-switch-description": "Behaviour switch __NOAUTHORS__ 
description for hiding authors on this page, shown in InsertMagic."
+}
diff --git a/i18n/roa-tara.json b/i18n/roa-tara.json
new file mode 100644
index 0000000..77ce412
--- /dev/null
+++ b/i18n/roa-tara.json
@@ -0,0 +1,10 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Joetaras"
+               ]
+       },
+       "prefs-authors": "Auture de sta pàgene",
+       "bs-authors-pref-show": "Fà 'ndrucà le auture",
+       "bs-authors-switch-description": "Scunne le auture sus a sta pàgene."
+}
diff --git a/i18n/ru.json b/i18n/ru.json
new file mode 100755
index 0000000..0f2f1b1
--- /dev/null
+++ b/i18n/ru.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Okras",
+                       "Meshkov.a",
+                       "Eroha"
+               ]
+       },
+       "bs-authors-desc": "Выводит картинку профиля для авторов страницы",
+       "prefs-authors": "Авторы этой страницы",
+       "bs-authors-title": "{{GENDER:$2|Автор{{PLURAL:$1||а|ов}}}}",
+       "bs-authors-profileimage": "Изображение в профиле",
+       "bs-authors-profileimage-change": "Изменить изображение в профиле",
+       "bs-authors-show-all-authors": "Есть и другие авторы",
+       "bs-authors-pref-imageheight": "Высота изображения:",
+       "bs-authors-pref-imagewidth": "Ширина изображения:",
+       "bs-authors-pref-limit": "Ограничение на количество отображаемых 
авторов:",
+       "bs-authors-pref-show": "Отображать авторов",
+       "bs-authors-switch-description": "Скрывает авторов этой страницы."
+}
diff --git a/i18n/sl.json b/i18n/sl.json
new file mode 100755
index 0000000..2fdfd10
--- /dev/null
+++ b/i18n/sl.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Skalcaa"
+               ]
+       },
+       "bs-authors-desc": "Prikaže sliko profila avtorjev strani",
+       "prefs-authors": "Avtorji te strani",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Avtor}}|Avtorji}}",
+       "bs-authors-profileimage": "Slika profila",
+       "bs-authors-profileimage-change": "Spremeni sliko profila",
+       "bs-authors-show-all-authors": "Na voljo je več avtorjev",
+       "bs-authors-pref-imageheight": "Višina slike:",
+       "bs-authors-pref-imagewidth": "Širina slike:",
+       "bs-authors-pref-limit": "Število avtorjev za prikaz:",
+       "bs-authors-pref-show": "Prikaži avtorje",
+       "bs-authors-switch-description": "Skrije avtorje na tej strani."
+}
diff --git a/i18n/sv.json b/i18n/sv.json
new file mode 100755
index 0000000..4906043
--- /dev/null
+++ b/i18n/sv.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "WikiPhoenix",
+                       "Jopparn",
+                       "Lokal Profil"
+               ]
+       },
+       "bs-authors-desc": "Visar profilbilden för författare till en sida",
+       "prefs-authors": "Författarna till denna sida",
+       "bs-authors-title": "{{PLURAL:$1|{{GENDER:$2|Författare}}}}",
+       "bs-authors-profileimage": "Profilbild",
+       "bs-authors-profileimage-change": "Ändra profilbild",
+       "bs-authors-show-all-authors": "Fler författare tillgängliga",
+       "bs-authors-pref-imageheight": "Bildhöjd:",
+       "bs-authors-pref-imagewidth": "Bildbredd:",
+       "bs-authors-pref-limit": "Gräns för antal författare att visa:",
+       "bs-authors-pref-show": "Visa författare",
+       "bs-authors-switch-description": "Döljer författarna för denna sida."
+}
diff --git a/i18n/tr.json b/i18n/tr.json
new file mode 100755
index 0000000..a7d3d61
--- /dev/null
+++ b/i18n/tr.json
@@ -0,0 +1,11 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Sayginer"
+               ]
+       },
+       "bs-authors-profileimage": "Profil resmi",
+       "bs-authors-profileimage-change": "Profil resmini değiştir",
+       "bs-authors-pref-imageheight": "Resim yüksekliği:",
+       "bs-authors-pref-imagewidth": "Resim genişliği:"
+}
diff --git a/i18n/uk.json b/i18n/uk.json
new file mode 100755
index 0000000..6d6a22a
--- /dev/null
+++ b/i18n/uk.json
@@ -0,0 +1,20 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Base",
+                       "Ата",
+                       "Andriykopanytsia"
+               ]
+       },
+       "bs-authors-desc": "Відображає зображення профілів для авторів 
сторінки",
+       "prefs-authors": "Автори цієї сторіки",
+       "bs-authors-title": "{{GENDER:$2|Автор{{PLURAL:$1||ів|и}}}}",
+       "bs-authors-profileimage": "Зображення профілю",
+       "bs-authors-profileimage-change": "Змінити зображення профілю",
+       "bs-authors-show-all-authors": "Доступно більше авторів",
+       "bs-authors-pref-imageheight": "Висота зображення:",
+       "bs-authors-pref-imagewidth": "Ширина зображення:",
+       "bs-authors-pref-limit": "Обмеження числа авторів для відображення:",
+       "bs-authors-pref-show": "Відобразити авторів",
+       "bs-authors-switch-description": "Приховує авторів цієї сторінки."
+}
diff --git a/i18n/vi.json b/i18n/vi.json
new file mode 100755
index 0000000..548fc38
--- /dev/null
+++ b/i18n/vi.json
@@ -0,0 +1,14 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Dinhxuanduyet"
+               ]
+       },
+       "bs-authors-profileimage": "Hình thẻ",
+       "bs-authors-profileimage-change": "Thay đổi hình thẻ",
+       "bs-authors-show-all-authors": "Thêm tác giả hợp lệ",
+       "bs-authors-pref-imageheight": "Chiều cao hình ảnh:",
+       "bs-authors-pref-imagewidth": "Chiều rộng hình ảnh:",
+       "bs-authors-pref-limit": "Giới hạn các tác giả để hiển thị:",
+       "bs-authors-pref-show": "Hiển thị tác giả"
+}
diff --git a/i18n/zh-hans.json b/i18n/zh-hans.json
new file mode 100755
index 0000000..5f9f8a2
--- /dev/null
+++ b/i18n/zh-hans.json
@@ -0,0 +1,18 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Liuxinyu970226"
+               ]
+       },
+       "bs-authors-desc": "显示页面作者的个人资料图片",
+       "prefs-authors": "此页面作者",
+       "bs-authors-title": "$1位{{GENDER:$2|作者}}",
+       "bs-authors-profileimage": "描述图像",
+       "bs-authors-profileimage-change": "更改描述图像",
+       "bs-authors-show-all-authors": "更多作者可用",
+       "bs-authors-pref-imageheight": "图像高度:",
+       "bs-authors-pref-imagewidth": "图像宽度:",
+       "bs-authors-pref-limit": "作者显示限制:",
+       "bs-authors-pref-show": "显示作者",
+       "bs-authors-switch-description": "在此页面隐藏作者。"
+}
diff --git a/i18n/zh-hant.json b/i18n/zh-hant.json
new file mode 100755
index 0000000..e0e3269
--- /dev/null
+++ b/i18n/zh-hant.json
@@ -0,0 +1,21 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Liuxinyu970226",
+                       "Justincheng12345",
+                       "Cwlin0416",
+                       "LNDDYL"
+               ]
+       },
+       "bs-authors-desc": "顯示頁面作者的個人資料圖片",
+       "prefs-authors": "此頁面作者",
+       "bs-authors-title": "$1 位{{GENDER:$2|作者}}",
+       "bs-authors-profileimage": "設定檔圖片",
+       "bs-authors-profileimage-change": "變更設定檔圖片",
+       "bs-authors-show-all-authors": "更多作者可用",
+       "bs-authors-pref-imageheight": "圖片高度:",
+       "bs-authors-pref-imagewidth": "圖片寬度:",
+       "bs-authors-pref-limit": "顯示作者限制:",
+       "bs-authors-pref-show": "顯示作者",
+       "bs-authors-switch-description": "於此頁中隱藏作者。"
+}
diff --git a/languages/Authors.i18n.magic.php b/languages/Authors.i18n.magic.php
new file mode 100755
index 0000000..72ce02b
--- /dev/null
+++ b/languages/Authors.i18n.magic.php
@@ -0,0 +1,10 @@
+<?php
+$magicWords = array();
+
+$magicWords['en'] = array(
+       'bs_noauthors' => array( 0, '__NOAUTHORS__', '__NO_AUTHORS__' ),
+);
+
+$magicWords['de'] = array(
+       'bs_noauthors' => array( 0, '__KEINEAUTOREN__', '__KEINE_AUTOREN__' ),
+);
\ No newline at end of file
diff --git a/resources/bluespice.authors.css b/resources/bluespice.authors.css
new file mode 100644
index 0000000..cca3832
--- /dev/null
+++ b/resources/bluespice.authors.css
@@ -0,0 +1,40 @@
+/**
+ * Stylesheet for Authors
+ *
+ * Part of BlueSpice MediaWiki
+ *
+ * @author     Robert Vogel <vo...@hallowelt.com>
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ * @copyright  Copyright (C) 2016 Hallo Welt! GmbH, All rights reserved.
+ * @license    http://www.gnu.org/copyleft/gpl.html GNU Public License v2 or 
later
+ * @filesource
+ */
+
+#bs-authors-imageform fieldset {
+       margin: 0px;
+       padding-bottom: 5px;
+}
+
+#bs-authors-imageform > fieldset > img{
+       margin-bottom: 3px;
+}
+
+.bs-authors .bs-userminiprofile {
+       float: left;
+       margin-right: 3px;
+}
+
+.bs-authors-originator {
+       padding-right: 16px !important;
+       margin-right: 12px !important;
+       /* @embed */
+       background: url("../resources/images/bs-author-orig-bg.png") repeat-y  
right top;
+       height: 44px;
+}
+
+/*
+.bs-authors-originator img {
+    border: 2px #FFAE00 solid;
+}
+*/
\ No newline at end of file
diff --git a/resources/images/bs-author-orig-bg.png 
b/resources/images/bs-author-orig-bg.png
new file mode 100755
index 0000000..86c4855
--- /dev/null
+++ b/resources/images/bs-author-orig-bg.png
Binary files differ
diff --git a/resources/images/more-users_v2.png 
b/resources/images/more-users_v2.png
new file mode 100644
index 0000000..04d0d3c
--- /dev/null
+++ b/resources/images/more-users_v2.png
Binary files differ
diff --git a/views/view.Authors.php b/views/view.Authors.php
new file mode 100644
index 0000000..9aa4bd7
--- /dev/null
+++ b/views/view.Authors.php
@@ -0,0 +1,76 @@
+<?php
+/**
+ * Renders the Authors frame.
+ *
+ * Part of BlueSpice MediaWiki
+ *
+ * @author     Robert Vogel <vo...@hallowelt.com>
+
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ * @copyright  Copyright (C) 2016 Hallo Welt! GmbH, All rights reserved.
+ * @license    http://www.gnu.org/copyleft/gpl.html GNU Public License v2 or 
later
+ * @filesource
+ */
+
+// Last review MRG (30.06.11 10:25)
+
+/**
+ * This view renders the Authors frame.
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ */
+class ViewAuthors extends ViewBaseElement {
+
+       /**
+        * Constructor
+        */
+       public function __construct() {
+               parent::__construct();
+       }
+
+       /**
+        * This method actually generates the output
+        * @return string HTML output
+        */
+       public function execute( $params = false ) {
+               if ( empty( $this->_mItems ) ) {
+                       return '';
+               }
+               
+               $sAuthorsList = '';
+               $iAuthors = count( $this->_mItems );
+               $lastIndex = $iAuthors - 1;
+               for( $i = 0; $i < $iAuthors; $i++ ) {
+                       $oUserProfileImageView = $this->_mItems[$i];
+                       if( $i == 0 ) {
+                               $oUserProfileImageView->setOption( 'classes', 
array('bs-authors-originator') );
+                       }
+                       if ($i == $lastIndex ) {
+                               $oUserProfileImageView->setOption( 'classes', 
array('bs-authors-lasteditor') );
+                       }
+                       
+                       $sAuthorsList .= $oUserProfileImageView->execute();
+                       
+                       //Reset classes to prevent wrong styling in other places
+                       $oUserProfileImageView->setOption( 'classes', array() );
+               }
+
+               if( isset( $this->mOptions['print'] ) && 
$this->mOptions['print'] === true ) {
+                       $sAuthorsList = substr( $sAuthorsList, 0, -2 ); //Cut 
off tailing ', '
+               }
+
+               $aOut = array();
+               $aOut[] = '<div class="bs-authors">';
+               $aOut[] = '  <fieldset>';
+               $aOut[] = '    <legend>';
+               $aOut[] = wfMessage( 'bs-authors-title', $iAuthors )->text();
+               $aOut[] = '    </legend>';
+               $aOut[] = $sAuthorsList;
+               $aOut[] = '  </fieldset>';
+               $aOut[] = '</div>';
+
+               return implode( "\n", $aOut );
+       }
+
+}
\ No newline at end of file
diff --git a/views/view.AuthorsUserPageProfileImageSetting.php 
b/views/view.AuthorsUserPageProfileImageSetting.php
new file mode 100644
index 0000000..5c8a4c6
--- /dev/null
+++ b/views/view.AuthorsUserPageProfileImageSetting.php
@@ -0,0 +1,127 @@
+<?php
+/**
+ * Renders the profile image frame on the users page.
+ *
+ * Part of BlueSpice MediaWiki
+ *
+ * @author     Robert Vogel <vo...@hallowelt.com>
+
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ * @copyright  Copyright (C) 2016 Hallo Welt! GmbH, All rights reserved.
+ * @license    http://www.gnu.org/copyleft/gpl.html GNU Public License v2 or 
later
+ * @filesource
+ */
+
+// Last review MRG (30.06.11 10:25)
+
+/**
+ * This view renders the profile image frame on the users page.
+ * @package    BlueSpice_Extensions
+ * @subpackage Authors
+ */
+class ViewAuthorsUserPageProfileImageSetting extends ViewBaseElement {
+       /*
+        * @var User $oUser The User object of the current user.
+        */
+       protected $oUser                = null;
+       /*
+        * @var string $sImagePath Path to the current user image.
+        */
+       protected $sImagePath           = '';
+       /*
+        * @var string $sUserDisplayName Display name of the current user.
+        */
+       protected $sUserDisplayName     = '';
+       /*
+        * @var string $sImageUploadPath URL of upload script for changing the 
current user image.
+        */
+       protected $sImageUploadPath     = '';
+
+       /**
+        * This method actually generates the output
+        * @param mixed $params Comes from base class definition. Not used in 
this implementation.
+        * @return string HTML output
+        */
+       public function  execute( $params = false ) {
+               $this->initFields();
+               Hooks::run( 'BsAuthorPageProfileImageAfterInitFields', array( 
$this, $this->oUser ) );
+
+               $aOut = array();
+               $aOut[] = '<div id="bs-authors-imageform" 
class="bs-userpagesettings-item">';
+               $aOut[] = $this->renderLink(
+                       array(
+                               'href'   => htmlspecialchars( 
$this->sImageUploadPath ),
+                               'title'  => wfMessage( 
'bs-authors-profileimage-change' )->plain()
+                       ),
+                       '<img src="'.$this->sImagePath.'" 
alt="'.$this->sUserDisplayName.'" width="64" title="'.wfMessage( 
'bs-authors-profileimage' )->plain().'" />'.
+                       '<div class="bs-user-label">'.wfMessage( 
'bs-authors-profileimage-change' )->plain().'</div>'
+               );
+               $aOut[] = '</div>';
+
+               return implode( "\n", $aOut );
+       }
+
+       /**
+        * Setter for internal User object.
+        * @param User $oUser The MediaWiki User object the profile image frame 
should be rendered for.
+        */
+       public function setCurrentUser( $oUser ) {
+               $this->oUser = $oUser;
+       }
+
+       public function setImagePath( $sImagePath ) {
+               $this->sImagePath = $sImagePath;
+       }
+
+       public function getImagePath() {
+               return $this->sImagePath;
+       }
+
+       /**
+        * Initializes required fields.
+        */
+       private function initFields() {
+               if ( $this->oUser === null ) throw new BsException( 
__METHOD__.' - No user specified.' );
+
+               $this->sUserDisplayName = 
BsCore::getInstance()->getUserDisplayName( $this->oUser );
+               $sUserImage             = $this->oUser->getOption( 
'MW::UserImage', '' ); //BsConfig::get() won't work on first call
+
+               //Is it a URL? Some external image?
+               $aParsedUrl = parse_url( $sUserImage );
+               if ( !empty($sUserImage) && ($sUserImage{0} == '/' || isset( 
$aParsedUrl['scheme'] )) ) {
+                       $this->sImageUploadPath = SpecialPage::getTitleFor( 
'Preferences' )->getLinkUrl();
+
+                       $aPathInfo = pathinfo( $aParsedUrl['path'] );
+                       $aFileExtWhitelist = array( 'gif', 'jpg', 'jpeg', 'png' 
);
+                       $this->sImagePath  = 
$aParsedUrl['scheme'].'://'.$aParsedUrl['host'].$aParsedUrl['path'];
+
+                       if ( !in_array( strtolower( $aPathInfo['extension'] ), 
$aFileExtWhitelist ) ) {
+                               $this->sImagePath = BsConfig::get( 
'MW::AnonUserImage' );
+                       }
+                       return;
+               }
+
+               $oUserImageFile = 
RepoGroup::singleton()->getLocalRepo()->newFile( $sUserImage );
+               if ( $oUserImageFile ) {
+                       $UserImageArticle       = new ImagePage( 
$oUserImageFile->getTitle() );
+                       $this->sImageUploadPath = 
$UserImageArticle->getUploadUrl();
+
+                       if ( $oUserImageFile->exists() === false ) {
+                               $this->sImagePath = BsConfig::get( 
'MW::DefaultUserImage' );
+                       }
+                       else {
+                               $oUserThumbnail = $oUserImageFile->transform( 
array( 'width' => 64, 'height' => 64 ) );
+                               if ( $oUserThumbnail !== false ) {
+                                       $this->sImagePath = 
$oUserThumbnail->getUrl();
+                               }
+                               else {
+                                       $this->sImagePath = 
$oUserImageFile->getUrl();
+                               }
+                       }
+               }
+               else {
+                       $this->sImagePath = BsConfig::get( 
'MW::DefaultUserImage' );
+               }
+       }
+}

-- 
To view, visit https://gerrit.wikimedia.org/r/378711
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ifad9bdd7361f5bf3c61eac1503891b890933d343
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceAuthors
Gerrit-Branch: master
Gerrit-Owner: Nasty <kon...@hallowelt.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to