Hi! Anyone has an idea about how to show GMail contact photos in a Gadget?
I startet with the example in http://gadget-doc-examples.googlecode.com/svn/trunk/opensocial-gadgets/oauth-contacts.xml So I use the oAuth-Proxy to Access Contact Information. Works quite well for Contact information from within the feed, but fails for stuff linked from the feed. I get Photo-Url and etag, but then I'm stuck when it comes to insert it into the gadgets DOM, as I wouldn't know of any way to send any http-authentication or etag-http-header from within an html-img-Element. Here is the relevant (not working) code: for(var k=0;k<entry.link.length;k++) // travel through all link elements { // Pick the valid Photo-Links if ((entry.link[k].type=="image/*")&&(typeof(entry.link [k].gd$etag)!='undefined')) { imgnode = document.createElement('img'); imgnode.setAttribute('src', entry.link[k].href); imgnode.setAttribute('alt', entry.title.$t); imgnode.setAttribute('width', '80'); imgnode.setAttribute('height', '80'); imgnode.setAttribute('border', '0'); tdata1.appendChild(imgnode); } } I would prefer a simpler solution than a seperate php reflecting the image.... --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "iGoogle Developer Forum" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Gadgets-API?hl=en -~----------~----~----~----~------~----~------~--~---
