Benutzer:Andreas Plank/LocalSettings

Aus Open Source Ecology - Germany
< Benutzer:Andreas Plank
Version vom 17. März 2018, 23:25 Uhr von Andreas Plank (Diskussion | Beiträge) (Die Seite wurde neu angelegt: „<source lang="PHP"> ############################################ # Allow User CSS or JavaScripts, e.g. for customizing the editor # $wgAllowUserCssPrefs option…“)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen
############################################
# Allow User CSS or JavaScripts, e.g. for customizing the editor
# $wgAllowUserCssPrefs option disables CSS-based preferences. These are injected by a 'stylesheet' /w/index.php?title=-&action=raw&gen=css, which is ~20 times slower to get out to the browser than a normal stylesheet. Getting rid of these options can dramatically improve page load times
$wgAllowUserCssPrefs=false;
# However, user javascript and CSS are enabled
$wgAllowUserJs  = true;
$wgAllowUserCss = true;

############################################
# Start MediaWiki Language Extension Bundle
  # wfLoadExtension( 'cldr' );
  
#  require_once "$IP/extensions/Babel/Babel.php";

#  require_once "$IP/extensions/cldr/cldr.php";
  wfLoadExtension( 'Babel' );
  wfLoadExtension( 'cldr' );
  wfLoadExtension( 'CleanChanges' );
  # require_once "$IP/extensions/CleanChanges/CleanChanges.php";
  $wgCCTrailerFilter = true;
  $wgCCUserFilter = false;
  $wgDefaultUserOptions['usenewrc'] = 1;

  wfLoadExtension( 'LocalisationUpdate' );
  $wgLocalisationUpdateDirectory = "$IP/cache";
include_once("$IP/extensions/Translate/Translate.php");
  $wgGroupPermissions['translator']['translate'] = true;
  $wgGroupPermissions['translator']['skipcaptcha'] = true; // Bug 34182: needed with ConfirmEdit
  $wgTranslateDocumentationLanguageCode = 'qqq';
  $wgExtraLanguageNames['qqq'] = 'Dokumentation von Nachrichten'; # No linguistic content. Used for documenting messages
  # $wgTranslateDelayedMessageIndexRebuild = true;
  # $wgTranslatePageTranslationULS = true; // default: false
  # Add this if you want to enable access to page translation
  $wgGroupPermissions['sysop']['pagetranslation'] = true;
  $wgGroupPermissions['user']['pagetranslation'] = true; 
  $wgGroupPermissions['bureaucrat']['pagetranslation'] = true;
  
  $wgGroupPermissions['user']['translate'] = true;
  $wgGroupPermissions['user']['translate-messagereview'] = true;
  $wgGroupPermissions['bureaucrat']['translate'] = true;
  $wgGroupPermissions['bureaucrat']['translate-manage'] = true;
  $wgGroupPermissions['bureaucrat']['translate-import'] = true;
  $wgGroupPermissions['bureaucrat']['pagetranslation'] = true;
  $wgGroupPermissions['bureaucrat']['translate-messagereview'] = true;
  $wgGroupPermissions['bureaucrat']['translate-proofr'] = true;
  $wgGroupPermissions['bureaucrat']['translate-groupreview'] = true;
  $wgTranslateLanguageFallbacks['de-formal'] = array('de', 'en');
  $wgTranslatePageTranslationULS = true;
  $wgTranslateTranslationServices = array();
  $GLOBALS['wgTranslateTranslationServices']['TTMServer'] = array(
    'database' => $wgDBname, // Passed to wfGetDB
    'cutoff' => 0.75,
    'type' => 'ttmserver',
    'public' => true,
  );
  $wgTranslateTranslationServices['Yandex'] = array(
    'url' => 'https://translate.yandex.net/api/v1.5/tr.json/translate',
    'key' => "xxxxxxxxxxxxxxxxxxxxxxxxxxxx", # see https://tech.yandex.com/translate/
    'pairs' => 'https://translate.yandex.net/api/v1.5/tr.json/getLangs',
    'timeout' => 10,
    'langorder' => array( 'de', 'en', 'cs', 'ru', 'uk', 'fr', 'pl', 'it', 'es', 'tr' ),
    'langlimit' => 0,
    'type' => 'yandex',
  );
  
  $wgTranslateWorkflowStates = array(
       'new' => array( 'color' => 'FF0000' ), // red
       'needs_proofreading' => array( 'color' => '0000FF' ), // blue
       'ready' => array( 'color' => 'FFFF00' ), // yellow
       'published' => array(
           'color' => '00FF00', // green
           'right' => 'centralnotice-admin'
       ),
  );
wfLoadExtension( 'UniversalLanguageSelector' );
#   require_once "$IP/extensions/UniversalLanguageSelector/UniversalLanguageSelector.php";
# End MediaWiki Language Extension Bundle
############################################