Hello, In my gadget I am trying to display a viewer, but get the error message: "unauthorized: The currently logged in user and/or the gadget requesting data, does not have access to person data".
Please tell me why I keep getting this error. The code I am using is below. <div id="message"> </div> <script type="text/javascript"> function request() { var req = opensocial.newDataRequest(); req.add(req.newFetchPersonRequest(opensocial.IdSpec.PersonId.VIEWER), 'viewer'); req.send(response); } function response(data) { var viewer = data.get('viewer'); if (viewer.hadError()) { alert("OpenSocial Error: " + viewer.getErrorMessage()); } var html = 'Helllo, ' + viewer.getDisplayName(); document.getElementById('message').innerHTML = html; } gadgets.util.registerOnLoadHandler(request); With thanks, Zachary --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "OpenSocial Application Development" group. To post to this group, send email to opensocial-api@googlegroups.com To unsubscribe from this group, send email to opensocial-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/opensocial-api?hl=en -~----------~----~----~----~------~----~------~--~---