* (bug 9712) Use Arabic comma in date/time formats for Arabic and Farsi
authorRaimond Spekking <raymond@users.mediawiki.org>
Tue, 1 May 2007 10:14:33 +0000 (10:14 +0000)
committerRaimond Spekking <raymond@users.mediawiki.org>
Tue, 1 May 2007 10:14:33 +0000 (10:14 +0000)
RELEASE-NOTES
languages/messages/MessagesAr.php
languages/messages/MessagesFa.php

index 67ba32c..0eacfd1 100644 (file)
@@ -372,7 +372,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
   - don't emit TOC when there are no visible headers
 * (bug 7629) Fix $wgBrowserBlackList to avoid false positive on MSIE
   when certain plugins are present which alter the user agent
-
+* (bug 9712) Use Arabic comma in date/time formats for Arabic and Farsi
 
 == Maintenance ==
 
index 7c8e5fe..ace978d 100644 (file)
@@ -14,6 +14,67 @@ $defaultUserOptionOverrides = array(
        # Underlines seriously harm legibility. Force off:
        'underline' => 0,
 );
+/**
+ * A list of date format preference keys which can be selected in user 
+ * preferences. New preference keys can be added, provided they are supported
+ * by the language class's timeanddate(). Only the 5 keys listed below are 
+ * supported by the wikitext converter (DateFormatter.php).
+ *
+ * The special key "default" is an alias for either dmy or mdy depending on 
+ * $wgAmericanDates
+ */
+$datePreferences = array(
+       'default',
+       'mdy',
+       'dmy',
+       'ymd',
+       'ISO 8601',
+);
+
+/**
+ * The date format to use for generated dates in the user interface.
+ * This may be one of the above date preferences, or the special value 
+ * "dmy or mdy", which uses mdy if $wgAmericanDates is true, and dmy 
+ * if $wgAmericanDates is false.
+ */
+$defaultDateFormat = 'dmy or mdy';
+
+/**
+ * Associative array mapping old numeric date formats, which may still be 
+ * stored in user preferences, to the new string formats.
+ */
+$datePreferenceMigrationMap = array(
+       'default',
+       'mdy',
+       'dmy',
+       'ymd'
+);
+
+/**
+ * These are formats for dates generated by MediaWiki (as opposed to the wikitext
+ * DateFormatter). Documentation for the format string can be found in 
+ * Language.php, search for sprintfDate. 
+ *
+ * This array is automatically inherited by all subclasses. Individual keys can be
+ * overridden.
+ */
+$dateFormats = array(
+       'mdy time' => 'H:i',
+       'mdy date' => 'xg j، Y', # Arabic comma
+       'mdy both' => 'H:i، xg j، Y', # Arabic comma
+
+       'dmy time' => 'H:i',
+       'dmy date' => 'j xg Y',
+       'dmy both' => 'H:i، j xg Y', # Arabic comma
+
+       'ymd time' => 'H:i',
+       'ymd date' => 'Y xg j',
+       'ymd both' => 'H:i، Y xg j', # Arabic comma
+
+       'ISO 8601 time' => 'xnH:xni:xns',
+       'ISO 8601 date' => 'xnY-xnm-xnd',
+       'ISO 8601 both' => 'xnY-xnm-xnd"T"xnH:xni:xns',
+);
 
 $namespaceNames = array(
        NS_MEDIA            => 'ملف',
@@ -1283,7 +1344,7 @@ $1 ساعة.',
 
 # Watchlist
 'watchlist'            => 'قائمة مراقبتي',
-'mywatchlist'         => 'قائمة مراقبتي',
+'mywatchlist'          => 'قائمة مراقبتي',
 'watchlistfor'         => "(ل '''$1''')",
 'nowatchlist'          => 'لا يوجد شيء في قائمة مراقبتك.',
 'watchlistanontext'    => 'الرجاء $1 لعرض أو تعديل الصفحات في قائمة مراقبتك.',
@@ -1474,7 +1535,7 @@ $NEWPAGE
 # Contributions
 'contributions' => 'مساهمات المستخدم',
 'mycontris'     => 'مساهماتي',
-'contribsub2'    => 'للمستخدم $1 ($2)',
+'contribsub2'   => 'للمستخدم $1 ($2)',
 'nocontribs'    => 'لا توجد تعديلات تطابق هذه المحددات.',
 'ucnote'        => 'في الأسفل ستجد آخر <b>$1</b> تعديل لهذا المستخدم في <b>$2</b> أيام.',
 'uclinks'       => 'عرض آخر $1 تعديل;  عرض آخر $2 يوم.',
@@ -1519,12 +1580,6 @@ $NEWPAGE
 'ipbexpiry'                   => 'مدّة المنع',
 'ipbreason'                   => 'السبب',
 'ipbreasonotherlist'          => 'سبب آخر',
-'ipbreason-list'              => '*#أسباب المنع عناوين الأيبي
-*تخريب
-*سخام وصلات
-*#أسباب المنع للمستخدمين المسجلين
-*سباب
-*دمية جورب',
 'ipbanononly'                 => 'فقط المستخدمين المجهولين',
 'ipbcreateaccount'            => 'منع إنشاء حساب جديد',
 'ipbenableautoblock'          => 'امنع العناوين المستخدمة بواسطة هذا المستخدم.',
@@ -1566,7 +1621,6 @@ $NEWPAGE
 'unblocklogentry'             => 'إزالة منع $1',
 'block-log-flags-anononly'    => 'المستخدمون المجهولون فقط',
 'block-log-flags-nocreate'    => 'منع إنشاء حساب',
-'block-log-flags-autoblock'   => 'منع تلقائي',
 'range_block_disabled'        => 'إمكانية الإداري لمنع نطاق معطلة.',
 'ipb_expiry_invalid'          => 'تاريخ انتهاء المنع المدخل غير صحيح.',
 'ipb_already_blocked'         => 'سبق منع "$1"',
@@ -2024,6 +2078,15 @@ $1',
 'livepreview-error'   => 'لم ينجح الاتصال: $1 "$2"
 حاول تجربة العرض العادي.',
 
+# Unknown messages
+'block-log-flags-autoblock' => 'منع تلقائي',
+'ipbreason-list'            => '*#أسباب المنع عناوين الأيبي
+*تخريب
+*سخام وصلات
+*#أسباب المنع للمستخدمين المسجلين
+*سباب
+*دمية جورب',
+
 );
 
 ?>
index 515bf26..bd86321 100644 (file)
@@ -54,6 +54,69 @@ $defaultUserOptionOverrides = array(
        # Underlines seriously harm legibility. Force off:
        'underline' => 0,
 );
+
+
+/**
+ * A list of date format preference keys which can be selected in user 
+ * preferences. New preference keys can be added, provided they are supported
+ * by the language class's timeanddate(). Only the 5 keys listed below are 
+ * supported by the wikitext converter (DateFormatter.php).
+ *
+ * The special key "default" is an alias for either dmy or mdy depending on 
+ * $wgAmericanDates
+ */
+$datePreferences = array(
+       'default',
+       'mdy',
+       'dmy',
+       'ymd',
+       'ISO 8601',
+);
+
+/**
+ * The date format to use for generated dates in the user interface.
+ * This may be one of the above date preferences, or the special value 
+ * "dmy or mdy", which uses mdy if $wgAmericanDates is true, and dmy 
+ * if $wgAmericanDates is false.
+ */
+$defaultDateFormat = 'dmy or mdy';
+
+/**
+ * Associative array mapping old numeric date formats, which may still be 
+ * stored in user preferences, to the new string formats.
+ */
+$datePreferenceMigrationMap = array(
+       'default',
+       'mdy',
+       'dmy',
+       'ymd'
+);
+
+/**
+ * These are formats for dates generated by MediaWiki (as opposed to the wikitext
+ * DateFormatter). Documentation for the format string can be found in 
+ * Language.php, search for sprintfDate. 
+ *
+ * This array is automatically inherited by all subclasses. Individual keys can be
+ * overridden.
+ */
+$dateFormats = array(
+       'mdy time' => 'H:i',
+       'mdy date' => 'xg j، Y', # Arabic comma
+       'mdy both' => 'H:i، xg j، Y', # Arabic comma
+
+       'dmy time' => 'H:i',
+       'dmy date' => 'j xg Y',
+       'dmy both' => 'H:i، j xg Y', # Arabic comma
+
+       'ymd time' => 'H:i',
+       'ymd date' => 'Y xg j',
+       'ymd both' => 'H:i، Y xg j', # Arabic comma
+
+       'ISO 8601 time' => 'xnH:xni:xns',
+       'ISO 8601 date' => 'xnY-xnm-xnd',
+       'ISO 8601 both' => 'xnY-xnm-xnd"T"xnH:xni:xns',
+);
 $linkTrail = "/^([a-z]+)(.*)\$/sD"; /* This may need to be changed --RP */
 
 $messages = array(