I am trying to get the orkut localization example to work, http://code.google.com/p/opensocial-resources/wiki/OrkutLocalization. I am running into a problem with the gadgets.Prefs() section, it appears that the line var prefs = new gadgets.Prefs(); simply returns a reference to gadgets. Then I get an error when calling the getLang function, "prefs.getLang is not a function". If I call directly to gadgets.Prefs.prototype.getLang(), it works, so the function itself exists. Here is the function I am using:
function getLocale() { var locale = "en_US"; if(globalMinorVersionNumber <= 6) { //TODO: } else { if(gadgets != null && gadgets.Prefs() != null) { var prefs = new gadgets.Prefs(); if(prefs != null) { locale= prefs.getLang(); locale = locale.replace("-","_"); } } } return locale; } --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Orkut Developer Forum" group. To post to this group, send email to opensocial-orkut@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/opensocial-orkut?hl=en -~----------~----~----~----~------~----~------~--~---