$val) { $warning = ''; $value = @Simplel10n::extractString($key); if ($value == $val[0]) { $status[$locale]++; $warning = ' ** String needs translation **'; } if ($val[1]) { echo '# Translation note: ' . $val[1] . $warning . "\n"; } elseif ($warning != '') { echo '# Translation note: ' . $warning . "\n"; } echo ";$val[0]\n"; echo $value . "\n\n\n"; } $content = ob_get_contents(); ob_end_clean(); file_put_contents($lang_file_path. '.lang', $content); unset($GLOBALS['locale']); } // Display a short status report header('Content-Type:text/plain'); echo "Number of English strings: " . count($GLOBALS['english']) . "\n"; echo "Your installation has these languages installed: " . implode(', ', $locales) . "\n"; foreach ($locales as $val) { echo $val . " has " . $status[$val] . " untranslated strings.\n"; } } update_lang_files($root, $root . 'app/l10n');