2

OpenSocial 응용 프로그램에 다국어 지원을 추가하려고합니다. 가제트 XML 마크 업에서 내 메시지 묶음에 연결할 수 있습니다.OpenSocial 가젯 응용 프로그램의 현지화

<Module> 
    <ModulePrefs title="Hello" description="Message bundle demo"> 
    <Require feature="opensocial-0.7"/> 
    <Locale lang="en" messages="http://example.com/hello/en_ALL.xml"/> 
    </ModulePrefs> 
    . . . 
</Module> 

실제로 어떻게 값을 추출합니까?

답변

5

값을 추출하려면 당신은 getMsg 방법을 사용해야합니다

var prefs = new gadgets.Prefs(); 
var msg = prefs.getMsg('hello_world'); 
관련 문제