Last modified: 2006-05-12 14:56:20 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T7905, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 5905 - Add plural support for Bosnian
Add plural support for Bosnian
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Internationalization (Other open bugs)
1.7.x
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-11 06:52 UTC by demicx
Modified: 2006-05-12 14:56 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description demicx 2006-05-11 06:52:22 UTC
Please add plural form support for Bosnian language (LanguageBs.php) Code
below is copied from LanguageHr.php

I don't sure that this all what I need to add. So please verify and add missing
parts.


function convertPlural( $count, $wordform1, $wordform2, $wordform3) {
		$count = str_replace ('.', '', $count);
		if ($count > 10 && floor(($count % 100) / 10) == 1) {
			return $wordform3;
		} else {
			switch ($count % 10) {
				case 1: return $wordform1;
				case 2:
				case 3:
				case 4: return $wordform2;
				default: return $wordform3;
			}
		}
	}

}


Test case:

for {{plural:X|članak|članka|članaka}}

1 članak
2 – 4 članka
5 – 20 članaka
21 članak
22 – 24 članka
25 – 30 članaka
Comment 1 Niklas Laxström 2006-05-12 14:56:20 UTC
Committed to trunk.
Resuls for 0-25:

0 članaka
1-4 članak
5-20 članaka
21 članak
22-24 članka
25 članaka 

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links