From 0767c9b06b5c3ec28acae0279ebba65980270cb1 Mon Sep 17 00:00:00 2001 From: Yannick Warnier Date: Thu, 23 Mar 2017 19:09:28 -0500 Subject: [PATCH] Add script to generate a table of missing terms in a language. Edit to set $language, then run in a browser and copy-paste in a spreadsheet soft to hand out to professional translators - refs BT#12413 --- .../build_translation_request_file.php | 53 +++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100755 tests/scripts/build_translation_request_file.php diff --git a/tests/scripts/build_translation_request_file.php b/tests/scripts/build_translation_request_file.php new file mode 100755 index 0000000000..f5f9e4f834 --- /dev/null +++ b/tests/scripts/build_translation_request_file.php @@ -0,0 +1,53 @@ +\n"; +echo "CountTermEnglishGerman"; +$i = 1; +$countWords = 0; +foreach ($missingTerms as $term => $value) { + if (isset($referenceTerms[$term])) { + $trimmed = trim($referenceTerms[$term],';" '); + $countWords += str_word_count($trimmed); + echo "$i$term".$trimmed."\n"; + } + $i++; +} +echo "\n"; +echo "Total words to be translated: ".$countWords.PHP_EOL;