1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-15 22:45:57 +00:00

add gettext to js, bump translations

This commit is contained in:
Andrew Dolgov
2007-03-06 07:11:28 +01:00
parent 793185a9a5
commit 709e7dc29b
5 changed files with 68 additions and 44 deletions

26
localized_js.php Normal file
View File

@@ -0,0 +1,26 @@
<?php
require "functions.php";
header("Content-Type: text/plain; charset=UTF-8");
function js_decl($s1, $s2) {
return "T_messages[\"$s1\"] = \"$s2\";\n";
}
?>
var T_messages = new Object();
function __(msg) {
if (T_messages[msg]) {
return T_messages[msg];
} else {
return msg;
}
}
<?php
print js_decl("display feeds", __("display feeds"));
print js_decl("display tags", __("display tags"));
?>