summaryrefslogtreecommitdiffstats
path: root/core/js/js.js
blob: 7e44b7ce6d5cc041b6d79c2c1637d3c593a6bbc4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
var _l10ncache = {};
function t(app,text){
	if( !( app in _l10ncache )){
		$.post( oc_webroot+'/l10n/javascript.php', {'app': app}, function(jsondata){
			_l10ncache[app] = jsondata.data;
		});

		// Bad answer ...
		if( !( app in _l10ncache )){
			_l10ncache[app] = [];
		}
	}
	if( typeof( _l10ncache[app][text] ) !== 'undefined' ){
		return _l10ncache[app][text];
	}
	else{
		return text;
	}
}

$(document).ready(function(){
	// Put fancy stuff in here
});